// @generated by jacquard-lexicon. DO NOT EDIT.
//
// Lexicon: app.bsky.video.getUploadLimits
//
// This file was automatically generated from Lexicon schemas.
// Any manual changes will be overwritten on the next regeneration.

#[allow(unused_imports)]
use alloc::collections::BTreeMap;

#[allow(unused_imports)]
use core::marker::PhantomData;
use jacquard_common::CowStr;
use jacquard_derive::{IntoStatic, lexicon};
use serde::{Serialize, Deserialize};

#[lexicon]
#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic)]
#[serde(rename_all = "camelCase")]
pub struct GetUploadLimitsOutput<'a> {
    pub can_upload: bool,
    #[serde(skip_serializing_if = "Option::is_none")]
    #[serde(borrow)]
    pub error: Option<CowStr<'a>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    #[serde(borrow)]
    pub message: Option<CowStr<'a>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub remaining_daily_bytes: Option<i64>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub remaining_daily_videos: Option<i64>,
}

/// XRPC request marker type.

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Copy)]
pub struct GetUploadLimits;
/// Response type for app.bsky.video.getUploadLimits
pub struct GetUploadLimitsResponse;
impl jacquard_common::xrpc::XrpcResp for GetUploadLimitsResponse {
    const NSID: &'static str = "app.bsky.video.getUploadLimits";
    const ENCODING: &'static str = "application/json";
    type Output<'de> = GetUploadLimitsOutput<'de>;
    type Err<'de> = jacquard_common::xrpc::GenericError<'de>;
}

impl jacquard_common::xrpc::XrpcRequest for GetUploadLimits {
    const NSID: &'static str = "app.bsky.video.getUploadLimits";
    const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Query;
    type Response = GetUploadLimitsResponse;
}

/// Endpoint type for app.bsky.video.getUploadLimits
pub struct GetUploadLimitsRequest;
impl jacquard_common::xrpc::XrpcEndpoint for GetUploadLimitsRequest {
    const PATH: &'static str = "/xrpc/app.bsky.video.getUploadLimits";
    const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Query;
    type Request<'de> = GetUploadLimits;
    type Response = GetUploadLimitsResponse;
}