pub struct SubAccount {
pub address: Option<SubAccountAddress>,
pub balances: Option<Vec<AccountBalance>>,
pub can_withdraw: Option<bool>,
pub created_at: Option<String>,
pub id: Option<Uuid>,
pub username: Option<String>,
}Expand description
SubAccount
JSON schema
{
"type": "object",
"properties": {
"address": {
"description": "Sub-account wallet address",
"type": [
"string",
"null"
],
"maxLength": 42,
"minLength": 42,
"pattern": "^0x[0-9a-fA-F]{40}$"
},
"balances": {
"type": [
"array",
"null"
],
"items": {
"$ref": "#/components/schemas/AccountBalance"
}
},
"can_withdraw": {
"description": "Whether the sub-account is allowed to withdraw",
"examples": [
false
],
"type": [
"boolean",
"null"
]
},
"created_at": {
"description": "Account creation timestamp (ISO 8601)",
"examples": [
"2023-11-13T10:30:00Z"
],
"type": [
"string",
"null"
]
},
"id": {
"description": "Sub-account UUID",
"examples": [
"123e4567-e89b-12d3-a456-426614174000"
],
"type": [
"string",
"null"
],
"format": "uuid"
},
"username": {
"description": "Sub-account display username",
"examples": [
"sub_trader_1"
],
"type": [
"string",
"null"
]
}
}
}Fields§
§address: Option<SubAccountAddress>Sub-account wallet address
balances: Option<Vec<AccountBalance>>§can_withdraw: Option<bool>Whether the sub-account is allowed to withdraw
created_at: Option<String>Account creation timestamp (ISO 8601)
id: Option<Uuid>Sub-account UUID
username: Option<String>Sub-account display username
Trait Implementations§
Source§impl Clone for SubAccount
impl Clone for SubAccount
Source§fn clone(&self) -> SubAccount
fn clone(&self) -> SubAccount
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 SubAccount
impl Debug for SubAccount
Source§impl Default for SubAccount
impl Default for SubAccount
Source§impl<'de> Deserialize<'de> for SubAccount
impl<'de> Deserialize<'de> for SubAccount
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 SubAccount
impl RefUnwindSafe for SubAccount
impl Send for SubAccount
impl Sync for SubAccount
impl Unpin for SubAccount
impl UnsafeUnpin for SubAccount
impl UnwindSafe for SubAccount
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