pub struct RedPacket {Show 17 fields
pub chain: Option<String>,
pub claim_authority: Option<String>,
pub claimed_amount: Option<String>,
pub claimed_count: Option<i32>,
pub created_at: Option<i64>,
pub creator: String,
pub expiration: Option<i64>,
pub expired: Option<bool>,
pub expired_at: Option<i64>,
pub id: String,
pub max_claims: i32,
pub memo: Option<String>,
pub mint: String,
pub refunded_amount: Option<String>,
pub share_id: Option<String>,
pub total_amount: String,
pub tx_hash: Option<String>,
}Expand description
Red packet detail
JSON schema
{
"description": "Red packet detail",
"type": "object",
"required": [
"creator",
"id",
"maxClaims",
"mint",
"totalAmount"
],
"properties": {
"chain": {
"description": "DTO.RED_PACKET.CHAIN",
"examples": [
"sol"
],
"type": "string"
},
"claimAuthority": {
"description": "DTO.RED_PACKET.CLAIM_AUTHORITY",
"examples": [
"Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB"
],
"type": "string"
},
"claimedAmount": {
"description": "DTO.RED_PACKET.CLAIMED_AMOUNT",
"examples": [
"500000000"
],
"type": "string"
},
"claimedCount": {
"description": "DTO.RED_PACKET.CLAIMED_COUNT",
"examples": [
5
],
"type": "integer",
"format": "int32"
},
"createdAt": {
"description": "DTO.RED_PACKET.CREATED_AT",
"examples": [
1717334400000
],
"type": "integer",
"format": "int64"
},
"creator": {
"description": "DTO.RED_PACKET.CREATOR",
"examples": [
"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"
],
"type": "string"
},
"expiration": {
"description": "DTO.RED_PACKET.EXPIRATION",
"examples": [
24
],
"type": "integer",
"format": "int64"
},
"expired": {
"description": "DTO.RED_PACKET.WITHDRAWED",
"type": "boolean"
},
"expiredAt": {
"description": "DTO.RED_PACKET.EXPIRES_AT",
"examples": [
1717420800000
],
"type": "integer",
"format": "int64"
},
"id": {
"description": "DTO.RED_PACKET.ID",
"examples": [
"Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB"
],
"type": "string"
},
"maxClaims": {
"description": "DTO.RED_PACKET.MAX_CLAIMS",
"examples": [
10
],
"type": "integer",
"format": "int32"
},
"memo": {
"description": "DTO.RED_PACKET.MEMO",
"examples": [
"Happy Red Packet"
],
"type": "string"
},
"mint": {
"description": "DTO.RED_PACKET.MINT",
"examples": [
"Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB"
],
"type": "string"
},
"refundedAmount": {
"description": "DTO.RED_PACKET.REFUND_AMOUNT",
"examples": [
"0"
],
"type": "string"
},
"shareId": {
"description": "DTO.RED_PACKET.SHARE_ID",
"examples": [
"abc123"
],
"type": "string"
},
"totalAmount": {
"description": "DTO.RED_PACKET.TOTAL_AMOUNT",
"examples": [
"1000000000"
],
"type": "string"
},
"txHash": {
"description": "DTO.RED_PACKET.TX_HASH",
"examples": [
"5UfDuX7hXbL3mFfPdq1pymNHM..."
],
"type": "string"
}
}
}Fields§
§chain: Option<String>DTO.RED_PACKET.CHAIN
DTO.RED_PACKET.CLAIM_AUTHORITY
claimed_amount: Option<String>DTO.RED_PACKET.CLAIMED_AMOUNT
claimed_count: Option<i32>DTO.RED_PACKET.CLAIMED_COUNT
created_at: Option<i64>DTO.RED_PACKET.CREATED_AT
creator: StringDTO.RED_PACKET.CREATOR
expiration: Option<i64>DTO.RED_PACKET.EXPIRATION
expired: Option<bool>DTO.RED_PACKET.WITHDRAWED
expired_at: Option<i64>DTO.RED_PACKET.EXPIRES_AT
id: StringDTO.RED_PACKET.ID
max_claims: i32DTO.RED_PACKET.MAX_CLAIMS
memo: Option<String>DTO.RED_PACKET.MEMO
mint: StringDTO.RED_PACKET.MINT
refunded_amount: Option<String>DTO.RED_PACKET.REFUND_AMOUNT
DTO.RED_PACKET.SHARE_ID
total_amount: StringDTO.RED_PACKET.TOTAL_AMOUNT
tx_hash: Option<String>DTO.RED_PACKET.TX_HASH
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for RedPacket
impl<'de> Deserialize<'de> for RedPacket
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RedPacket
impl RefUnwindSafe for RedPacket
impl Send for RedPacket
impl Sync for RedPacket
impl Unpin for RedPacket
impl UnsafeUnpin for RedPacket
impl UnwindSafe for RedPacket
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
Mutably borrows from an owned value. Read more