Skip to content

Commit

Permalink
fix: align response formats with Walrus (#336)
Browse files Browse the repository at this point in the history
  • Loading branch information
mlegner authored Dec 22, 2024
1 parent 090ac9a commit 8719f8f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions site-builder/src/walrus/output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pub type EpochCount = u32;

/// Either an event ID or an object ID.
#[derive(Debug, Clone, Deserialize)]
#[serde(rename_all = "camelCase")]
#[allow(unused)]
pub enum EventOrObjectId {
/// The variant representing an event ID.
Expand All @@ -27,6 +28,7 @@ pub enum EventOrObjectId {

/// The operation performed on blob and storage resources to register a blob.
#[derive(Debug, Clone, Deserialize)]
#[serde(rename_all = "camelCase", rename_all_fields = "camelCase")]
#[allow(unused)]
pub enum RegisterBlobOp {
/// The storage and blob resources are purchased from scratch.
Expand All @@ -53,6 +55,7 @@ pub enum BlobStoreResult {
#[serde_as(as = "DisplayFromStr")]
blob_id: BlobId,
/// The event where the blob was certified.
#[serde(flatten)]
event_or_object: EventOrObjectId,
/// The epoch until which the blob is stored (exclusive).
end_epoch: Epoch,
Expand Down

0 comments on commit 8719f8f

Please sign in to comment.