pub struct CreateUploadRequest {
pub size: u64,
pub hash: String,
pub content_type: String,
pub crypto_suite_id: u16,
pub protocol_version: String,
pub blob_role: BlobRole,
pub manifest_envelope: ManifestEnvelope,
pub album_id: Option<String>,
pub owner_id: Option<String>,
pub intent_id: Option<String>,
}Expand description
The POST /upload request body. Plaintext metadata (filename, capture date)
is deliberately absent — it rides the encrypted metadata blob.
Fields§
§size: u64Ciphertext size in bytes (declared once, immutable thereafter).
hash: StringCiphertext content hash, lowercase hex.
content_type: StringMIME type (closed enum per protocol version).
crypto_suite_id: u16Crypto suite the blob is sealed under.
protocol_version: StringProtocol date (YYYY-MM-DD) this client speaks — also sent as the
X-Capsule-Protocol header.
blob_role: BlobRoleThis blob’s role in its bundle.
manifest_envelope: ManifestEnvelopeThe unencrypted manifest fields the server validates.
album_id: Option<String>Optional album to add the asset to.
owner_id: Option<String>Optional owner id (defaults to the authenticated uploader).
intent_id: Option<String>Album-upgrade intent id (album upgrade ceremony only).
Trait Implementations§
Source§impl Clone for CreateUploadRequest
impl Clone for CreateUploadRequest
Source§fn clone(&self) -> CreateUploadRequest
fn clone(&self) -> CreateUploadRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CreateUploadRequest
impl Debug for CreateUploadRequest
Source§impl<'de> Deserialize<'de> for CreateUploadRequest
impl<'de> Deserialize<'de> for CreateUploadRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl From<CreateUploadRequest> for FfiUploadRequest
The reverse mapping, so FfiWorkspace::upload_blobs can hand back exactly what
FfiSession::upload takes. It reuses capsule_sdk::push’s envelope projection wholesale
— the invariant-15 per-blob ciphertext_hash rule has one implementation, in push, and
this is a shape conversion over its output.
impl From<CreateUploadRequest> for FfiUploadRequest
The reverse mapping, so FfiWorkspace::upload_blobs can hand back exactly what
FfiSession::upload takes. It reuses capsule_sdk::push’s envelope projection wholesale
— the invariant-15 per-blob ciphertext_hash rule has one implementation, in push, and
this is a shape conversion over its output.
Source§fn from(req: CreateUploadRequest) -> Self
fn from(req: CreateUploadRequest) -> Self
Source§impl From<FfiUploadRequest> for CreateUploadRequest
impl From<FfiUploadRequest> for CreateUploadRequest
Source§fn from(req: FfiUploadRequest) -> Self
fn from(req: FfiUploadRequest) -> Self
Auto Trait Implementations§
impl Freeze for CreateUploadRequest
impl RefUnwindSafe for CreateUploadRequest
impl Send for CreateUploadRequest
impl Sync for CreateUploadRequest
impl Unpin for CreateUploadRequest
impl UnsafeUnpin for CreateUploadRequest
impl UnwindSafe for CreateUploadRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> CompatExt for T
impl<T> CompatExt for T
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
§unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
Arc<> Read more§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more