fts_core/models/submission.rs
1use crate::models::{AuthRecord, CostRecord};
2use serde::{Deserialize, Serialize};
3use time::OffsetDateTime;
4use utoipa::ToSchema;
5
6/// A submission represents a bidder's complete set of active authorizations and costs
7/// that are considered for auction processing.
8///
9/// Submissions are not first-class primitives, but intermediate objects and not persisted entities.
10/// They're constructed from the current state of a bidder's auths and costs when needed for an auction.
11#[derive(Deserialize, Serialize, ToSchema)]
12pub struct SubmissionRecord {
13 /// A list of "active" auths
14 pub auths: Vec<AuthRecord>,
15
16 /// A list of "active" costs
17 pub costs: Vec<CostRecord>,
18
19 /// The system-time at which these lists were generated
20 #[serde(with = "time::serde::rfc3339")]
21 pub as_of: OffsetDateTime,
22}