pub struct DexPoolDto {Show 19 fields
pub chain: String,
pub created_block_timestamp: Option<String>,
pub fee_rate: Option<String>,
pub image: Option<String>,
pub liquidity_model: Option<DexPoolDtoLiquidityModel>,
pub pool_address: String,
pub program_address: Option<String>,
pub protocol_family: Option<String>,
pub protocol_name: Option<String>,
pub tick_spacing: Option<i64>,
pub token_a_address: String,
pub token_a_liquidity: Option<DexPoolTokenLiquidity>,
pub token_b_address: String,
pub token_b_liquidity: Option<DexPoolTokenLiquidity>,
pub token_count: Option<i64>,
pub tvl_in_sol: Option<String>,
pub tvl_in_usd: Option<String>,
pub type_: Option<DexPoolDtoType>,
pub version: Option<DexPoolDtoVersion>,
}Expand description
DexPoolDto
JSON schema
{
"type": "object",
"required": [
"chain",
"poolAddress",
"tokenAAddress",
"tokenBAddress"
],
"properties": {
"chain": {
"description": "DTO.DEX.CHAIN",
"examples": [
"sol"
],
"type": "string"
},
"createdBlockTimestamp": {
"description": "DTO.DEXPOOL.CREATED_BLOCK_TIMESTAMP",
"examples": [
"2024-01-15T10:30:00Z"
],
"type": "string"
},
"feeRate": {
"description": "DTO.DEXPOOL.FEE_RATE",
"examples": [
"0.003"
],
"type": "string"
},
"image": {
"description": "DTO.DEX.IMAGE",
"examples": [
"https://ipfs.io/ipfs/bafkreid7667676767676767676767676767676767676767676767676767676767676767"
],
"type": "string"
},
"liquidityModel": {
"description": "DTO.DEXPOOL.LIQUIDITY_MODEL",
"examples": [
1
],
"type": "number",
"enum": [
0.0,
1.0,
2.0,
3.0,
4.0
]
},
"poolAddress": {
"description": "DTO.DEXPOOL.POOL_ADDRESS",
"examples": [
"58oQChx4yWmvKdwLLZzBi4ChoCc2fqCUWBkwMihLYQo2"
],
"type": "string"
},
"programAddress": {
"description": "DTO.DEX.PROGRAM_ADDRESS",
"examples": [
"whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc"
],
"type": "string"
},
"protocolFamily": {
"description": "DTO.DEX.PROTOCOL_FAMILY",
"examples": [
"OrcaWhirpool"
],
"type": "string"
},
"protocolName": {
"description": "DTO.DEXPOOL.PROTOCOL_NAME",
"examples": [
"OrcaWhirpool AMM V2"
],
"type": "string"
},
"tickSpacing": {
"description": "DTO.DEXPOOL.TICK_SPACING",
"examples": [
64
],
"type": "integer"
},
"tokenAAddress": {
"description": "DTO.DEXPOOL.TOKEN_A",
"examples": [
"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"
],
"type": "string"
},
"tokenALiquidity": {
"description": "DTO.DEXPOOL.TOKEN_A_LIQUIDITY",
"allOf": [
{
"$ref": "#/components/schemas/DexPoolTokenLiquidity"
}
]
},
"tokenBAddress": {
"description": "DTO.DEXPOOL.TOKEN_B",
"examples": [
"Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB"
],
"type": "string"
},
"tokenBLiquidity": {
"description": "DTO.DEXPOOL.TOKEN_B_LIQUIDITY",
"allOf": [
{
"$ref": "#/components/schemas/DexPoolTokenLiquidity"
}
]
},
"tokenCount": {
"description": "DTO.DEXPOOL.TOKEN_COUNT",
"examples": [
2
],
"type": "integer"
},
"tvlInSol": {
"description": "DTO.DEXPOOL.TVL_SOL",
"examples": [
"1000000.45"
],
"type": "string"
},
"tvlInUsd": {
"description": "DTO.DEXPOOL.TVL_USD",
"examples": [
"1000000.45"
],
"type": "string"
},
"type": {
"description": "DTO.DEXPOOL.TYPE",
"examples": [
1
],
"type": "number",
"enum": [
0.0,
1.0,
2.0,
3.0,
4.0
]
},
"version": {
"description": "DTO.DEXPOOL.VERSION",
"examples": [
2
],
"type": "number",
"enum": [
0.0,
1.0,
2.0,
3.0
]
}
}
}Fields§
§chain: StringDTO.DEX.CHAIN
created_block_timestamp: Option<String>DTO.DEXPOOL.CREATED_BLOCK_TIMESTAMP
fee_rate: Option<String>DTO.DEXPOOL.FEE_RATE
image: Option<String>DTO.DEX.IMAGE
liquidity_model: Option<DexPoolDtoLiquidityModel>§pool_address: StringDTO.DEXPOOL.POOL_ADDRESS
program_address: Option<String>DTO.DEX.PROGRAM_ADDRESS
protocol_family: Option<String>DTO.DEX.PROTOCOL_FAMILY
protocol_name: Option<String>DTO.DEXPOOL.PROTOCOL_NAME
tick_spacing: Option<i64>DTO.DEXPOOL.TICK_SPACING
token_a_address: StringDTO.DEXPOOL.TOKEN_A
token_a_liquidity: Option<DexPoolTokenLiquidity>DTO.DEXPOOL.TOKEN_A_LIQUIDITY
token_b_address: StringDTO.DEXPOOL.TOKEN_B
token_b_liquidity: Option<DexPoolTokenLiquidity>DTO.DEXPOOL.TOKEN_B_LIQUIDITY
token_count: Option<i64>DTO.DEXPOOL.TOKEN_COUNT
tvl_in_sol: Option<String>DTO.DEXPOOL.TVL_SOL
tvl_in_usd: Option<String>DTO.DEXPOOL.TVL_USD
type_: Option<DexPoolDtoType>§version: Option<DexPoolDtoVersion>Implementations§
Source§impl DexPoolDto
impl DexPoolDto
pub fn builder() -> DexPoolDto
Trait Implementations§
Source§impl Clone for DexPoolDto
impl Clone for DexPoolDto
Source§fn clone(&self) -> DexPoolDto
fn clone(&self) -> DexPoolDto
Returns a duplicate of the value. Read more
1.0.0 · 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 DexPoolDto
impl Debug for DexPoolDto
Source§impl<'de> Deserialize<'de> for DexPoolDto
impl<'de> Deserialize<'de> for DexPoolDto
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
Source§impl From<&DexPoolDto> for DexPoolDto
impl From<&DexPoolDto> for DexPoolDto
Source§fn from(value: &DexPoolDto) -> Self
fn from(value: &DexPoolDto) -> Self
Converts to this type from the input type.
Source§impl From<DexPoolDto> for DexPoolDto
impl From<DexPoolDto> for DexPoolDto
Source§fn from(value: DexPoolDto) -> Self
fn from(value: DexPoolDto) -> Self
Converts to this type from the input type.
Source§impl Serialize for DexPoolDto
impl Serialize for DexPoolDto
Source§impl TryFrom<DexPoolDto> for DexPoolDto
impl TryFrom<DexPoolDto> for DexPoolDto
Source§type Error = ConversionError
type Error = ConversionError
The type returned in the event of a conversion error.
Source§fn try_from(value: DexPoolDto) -> Result<Self, ConversionError>
fn try_from(value: DexPoolDto) -> Result<Self, ConversionError>
Performs the conversion.
Auto Trait Implementations§
impl Freeze for DexPoolDto
impl RefUnwindSafe for DexPoolDto
impl Send for DexPoolDto
impl Sync for DexPoolDto
impl Unpin for DexPoolDto
impl UnwindSafe for DexPoolDto
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