pub struct NetWorthByTokensItem {Show 18 fields
pub accu_amount: Option<String>,
pub amount: String,
pub avg_cost_usd: Option<String>,
pub chain: String,
pub decimals: i32,
pub is_active: bool,
pub last_active_at: Option<i64>,
pub logo_uri: Option<String>,
pub name: String,
pub price_in_native: String,
pub price_in_usd: String,
pub realized_pnl_in_usd: Option<String>,
pub symbol: String,
pub token_address: String,
pub unrealized_pnl_in_usd: Option<String>,
pub value_in_native: String,
pub value_in_usd: String,
pub wallet_token_tags: Vec<String>,
}Expand description
Single token net-worth item (mirrors TS WalletNetWorthItemDTO).
JSON schema
{
"description": "Single token net-worth item (mirrors TS WalletNetWorthItemDTO).",
"type": "object",
"required": [
"amount",
"chain",
"decimals",
"isActive",
"name",
"priceInNative",
"priceInUsd",
"symbol",
"tokenAddress",
"valueInNative",
"valueInUsd"
],
"properties": {
"accuAmount": {
"description": "Accumulated net token position in token native units:\nbuy_amount - sell_amount + transfer_in_amount - transfer_out_amount.\nMirrors GMGN `accu_amount`. None when all four source fields are absent.",
"type": "string"
},
"amount": {
"description": "Token holding amount",
"examples": [
"1000.50"
],
"type": "string"
},
"avgCostUsd": {
"description": "Average cost per token in USD (balance_cost_avg_in_usd; sparse ~0.2% fill rate)",
"type": "string"
},
"chain": {
"description": "Blockchain network identifier",
"examples": [
"sol"
],
"type": "string"
},
"decimals": {
"description": "Token decimal places",
"examples": [
6
],
"type": "integer",
"format": "int32"
},
"isActive": {
"description": "Whether the wallet currently holds a non-zero balance",
"type": "boolean"
},
"lastActiveAt": {
"description": "Last active timestamp (ms since epoch)",
"type": "integer",
"format": "int64"
},
"logoUri": {
"description": "Token logo URI",
"examples": [
"https://s1.chainstream.io/tokens/images/usdc.webp"
],
"type": "string"
},
"name": {
"description": "Token display name",
"examples": [
"USD Coin"
],
"type": "string"
},
"priceInNative": {
"description": "Token price in native token",
"examples": [
"0.00000667"
],
"type": "string"
},
"priceInUsd": {
"description": "Token price in USD",
"examples": [
"1.0001"
],
"type": "string"
},
"realizedPnlInUsd": {
"description": "Realized PnL in USD (all-time cumulative)",
"type": "string"
},
"symbol": {
"description": "Token ticker symbol",
"examples": [
"USDC"
],
"type": "string"
},
"tokenAddress": {
"description": "Token contract address",
"examples": [
"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"
],
"type": "string"
},
"unrealizedPnlInUsd": {
"description": "Unrealized PnL in USD (current open position)",
"type": "string"
},
"valueInNative": {
"description": "Holding value in native token",
"examples": [
"6.67"
],
"type": "string"
},
"valueInUsd": {
"description": "Holding value in USD",
"examples": [
"1000.60"
],
"type": "string"
},
"walletTokenTags": {
"description": "Trader classification tags",
"type": "array",
"items": {
"type": "string"
}
}
}
}Fields§
§accu_amount: Option<String>Accumulated net token position in token native units:
buy_amount - sell_amount + transfer_in_amount - transfer_out_amount.
Mirrors GMGN accu_amount. None when all four source fields are absent.
amount: StringToken holding amount
avg_cost_usd: Option<String>Average cost per token in USD (balance_cost_avg_in_usd; sparse ~0.2% fill rate)
chain: StringBlockchain network identifier
decimals: i32Token decimal places
is_active: boolWhether the wallet currently holds a non-zero balance
last_active_at: Option<i64>Last active timestamp (ms since epoch)
logo_uri: Option<String>Token logo URI
name: StringToken display name
price_in_native: StringToken price in native token
price_in_usd: StringToken price in USD
realized_pnl_in_usd: Option<String>Realized PnL in USD (all-time cumulative)
symbol: StringToken ticker symbol
token_address: StringToken contract address
unrealized_pnl_in_usd: Option<String>Unrealized PnL in USD (current open position)
value_in_native: StringHolding value in native token
value_in_usd: StringHolding value in USD
Trader classification tags
Implementations§
Source§impl NetWorthByTokensItem
impl NetWorthByTokensItem
pub fn builder() -> NetWorthByTokensItem
Trait Implementations§
Source§impl Clone for NetWorthByTokensItem
impl Clone for NetWorthByTokensItem
Source§fn clone(&self) -> NetWorthByTokensItem
fn clone(&self) -> NetWorthByTokensItem
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more