pub struct PostStakeBody {
pub amount: NonZeroU64,
pub stake_source: PostStakeBodyStakeSource,
pub wallet_address: Option<String>,
}Expand description
PostStakeBody
JSON schema
{
"type": "object",
"required": [
"amount"
],
"properties": {
"amount": {
"description": "Stake amount in bond base units; must meet the high-assurance minimum.",
"examples": [
5000000
],
"type": "integer",
"format": "int64",
"minimum": 1.0
},
"stake_source": {
"description": "`operator_self` — the Operator of Record posts their own stake\n(authenticate with the operator's agent key).\n`external_backer` — an approved backer posts on the operator's\nbehalf (authenticate with the backer's own account credential\nand supply `wallet_address`).\n",
"default": "operator_self",
"type": "string",
"enum": [
"operator_self",
"external_backer"
]
},
"wallet_address": {
"description": "Required when `stake_source` is `external_backer`: the approved\nbacker wallet the stake is posted from. Must match an active\nallowlist entry for the task's operator.\n",
"examples": [
"0x71C7656EC7ab88b098defB751B7401B5f6d8976F"
],
"type": "string"
}
}
}Fields§
§amount: NonZeroU64Stake amount in bond base units; must meet the high-assurance minimum.
stake_source: PostStakeBodyStakeSourceoperator_self — the Operator of Record posts their own stake
(authenticate with the operator’s agent key).
external_backer — an approved backer posts on the operator’s
behalf (authenticate with the backer’s own account credential
and supply wallet_address).
wallet_address: Option<String>Required when stake_source is external_backer: the approved
backer wallet the stake is posted from. Must match an active
allowlist entry for the task’s operator.
Trait Implementations§
Source§impl Clone for PostStakeBody
impl Clone for PostStakeBody
Source§fn clone(&self) -> PostStakeBody
fn clone(&self) -> PostStakeBody
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PostStakeBody
impl Debug for PostStakeBody
Source§impl<'de> Deserialize<'de> for PostStakeBody
impl<'de> Deserialize<'de> for PostStakeBody
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 PostStakeBody
impl RefUnwindSafe for PostStakeBody
impl Send for PostStakeBody
impl Sync for PostStakeBody
impl Unpin for PostStakeBody
impl UnsafeUnpin for PostStakeBody
impl UnwindSafe for PostStakeBody
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