diff --git a/docs/auth/challenge.md b/docs/auth/challenge.md index 327d5be..dc326e5 100644 --- a/docs/auth/challenge.md +++ b/docs/auth/challenge.md @@ -106,7 +106,7 @@ Object with the properties: | notBefore | str | ISO 8601 datetime string that, if present, indicates when the signed authentication message will become valid. | Yes | | "2020-01-01T00:00:00.000Z" | | resources | List of str | List of information or references to information the user wishes to have resolved as part of authentication by the relying party. They are expressed as RFC 3986 URIs separated by new lines. | Yes | | ['https://docs.moralis.io/'] | | timeout | float | Time in seconds before the challenge is expired | Yes | 15 | 15 | -| chainId | enum[str]:
- "1"
- "5"
- "25"
- "56"
- "97"
- "137"
- "250"
- "338"
- "1337"
- "43113"
- "43114"
- "80001"
- "11155111" | EIP-155 Chain ID to which the session is bound, and the network where Contract Accounts must be resolved. | Yes | | "1" | +| chainId | enum[str]:
- "1"
- "5"
- "10"
- "25"
- "56"
- "97"
- "100"
- "137"
- "250"
- "338"
- "420"
- "1284"
- "1285"
- "1287"
- "1337"
- "8453"
- "10200"
- "43113"
- "43114"
- "80001"
- "80002"
- "84531"
- "88882"
- "88888"
- "11155111" | EIP-155 Chain ID to which the session is bound, and the network where Contract Accounts must be resolved. | Yes | | "1" | | address | str | Ethereum address performing the signing conformant to capitalization encoded checksum specified in EIP-55 where applicable. | Yes | | "0xAb5801a7D398351b8bE11C439e05C5B3259aeC9B" | diff --git a/docs/evm_api/balance.md b/docs/evm_api/balance.md index 7d72e15..fa1167f 100644 --- a/docs/evm_api/balance.md +++ b/docs/evm_api/balance.md @@ -39,7 +39,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address from which the native balance will be checked | Yes | | "0x057Ec652A4F150f7FF94f089A38008f49a0DF88e" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | float | The block number up to which the balances will be checked. | | | 1.2 | @@ -77,7 +77,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | wallet_addresses | List of str | The addresses to get metadata for | Yes | | [] | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | float | The block number on which the balances should be checked | | | 1.2 | diff --git a/docs/evm_api/block.md b/docs/evm_api/block.md index e97f787..86b139e 100644 --- a/docs/evm_api/block.md +++ b/docs/evm_api/block.md @@ -40,7 +40,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | block_number_or_hash | str | The block number or block hash | Yes | | "15863321" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | include | enum[str]:
- "internal_transactions" | If the result should contain the internal transactions. | | "" | "" | @@ -77,7 +77,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | block_number_or_hash | str | The block number or hash | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -113,7 +113,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | date | str | Unix date in milliseconds or a datestring (format in seconds or datestring accepted by momentjs) | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | diff --git a/docs/evm_api/defi.md b/docs/evm_api/defi.md index b6f2f45..dddba8c 100644 --- a/docs/evm_api/defi.md +++ b/docs/evm_api/defi.md @@ -47,7 +47,7 @@ print(result) | exchange | enum[str]:
- "uniswapv2"
- "uniswapv3"
- "sushiswapv2"
- "pancakeswapv2"
- "pancakeswapv1"
- "quickswap" | The factory name or address of the token exchange | Yes | | "uniswapv2" | | token0_address | str | The token0 address | Yes | | "0x2b591e99afe9f32eaa6214f7b7629768c40eeb39" | | token1_address | str | The token1 address | Yes | | "0xdac17f958d2ee523a2206206994597c13d831ec7" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | str | The block number to get the reserves from | | | "" | | to_date | str | Get the reserves up to this date (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | @@ -90,7 +90,7 @@ print(result) |------|------|-------------|----------|---------|---------| | token0_address | str | The token0 address | Yes | | "0xae7ab96520de3a18e5e111b5eaab095312d7fe84" | | token1_address | str | The token1 address | Yes | | "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | str | The block number to get the reserves from | | | "" | | to_date | str | Get the price up to this date (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | | exchange | str | The factory name or address of the token exchange | | | "" | @@ -131,7 +131,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | pair_address | str | The liquidity pair address | Yes | | "0xa2107fa5b38d9bbd2c461d6edf11b11a50f6b974" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | str | The block number to get the reserves from | | | "" | | to_date | str | Get the reserves up to this date (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | diff --git a/docs/evm_api/events.md b/docs/evm_api/events.md index c69a5e3..3ac77dc 100644 --- a/docs/evm_api/events.md +++ b/docs/evm_api/events.md @@ -50,7 +50,7 @@ print(result) |------|------|-------------|----------|---------|---------| | address | str | The address of the contract | Yes | | "" | | topic | str | The topic of the event | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the logs
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the logs.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the logs (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | @@ -110,7 +110,7 @@ print(result) |------|------|-------------|----------|---------|---------| | address | str | The address of the contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | | topic0 | str | topic0 | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | block_number | str | The block number
* Provide the param 'block_numer' or ('from_block' and / or 'to_block')
* If 'block_numer' is provided in combination with 'from_block' and / or 'to_block', 'block_number' will will be used
| | | "" | | from_block | str | The minimum block number from which to get the logs
* Provide the param 'block_numer' or ('from_block' and / or 'to_block')
* If 'block_numer' is provided in combination with 'from_block' and / or 'to_block', 'block_number' will will be used
| | | "" | | to_block | str | The maximum block number from which to get the logs
* Provide the param 'block_numer' or ('from_block' and / or 'to_block')
* If 'block_numer' is provided in combination with 'from_block' and / or 'to_block', 'block_number' will will be used
| | | "" | diff --git a/docs/evm_api/nft.md b/docs/evm_api/nft.md index 124b48f..69c0966 100644 --- a/docs/evm_api/nft.md +++ b/docs/evm_api/nft.md @@ -7,13 +7,17 @@ - [get_nft_bulk_contract_metadata](#get_nft_bulk_contract_metadata) - [get_nft_collection_stats](#get_nft_collection_stats) - [get_nft_contract_metadata](#get_nft_contract_metadata) +- [get_nft_contract_sale_prices](#get_nft_contract_sale_prices) - [get_nft_contract_transfers](#get_nft_contract_transfers) - [get_nft_lowest_price](#get_nft_lowest_price) - [get_nft_metadata](#get_nft_metadata) - [get_nft_owners](#get_nft_owners) +- [get_nft_sale_prices](#get_nft_sale_prices) - [get_nft_token_id_owners](#get_nft_token_id_owners) - [get_nft_token_stats](#get_nft_token_stats) - [get_nft_trades](#get_nft_trades) +- [get_nft_trades_by_token](#get_nft_trades_by_token) +- [get_nft_trades_by_wallet](#get_nft_trades_by_wallet) - [get_nft_transfers](#get_nft_transfers) - [get_nft_transfers_by_block](#get_nft_transfers_by_block) - [get_nft_transfers_from_to_block](#get_nft_transfers_from_to_block) @@ -65,7 +69,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | limit | int | The desired page size of the result. | | | 0 | | totalRanges | int | The number of subranges to split the results into | | | 0 | @@ -115,7 +119,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | ### Body @@ -162,7 +166,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | ### Body @@ -204,7 +208,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT collection | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -224,7 +228,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB", + "address": "0x524cab2ec69124574082676e6f654a18df49a048", "chain": "eth", } @@ -241,8 +245,46 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | + + + +--- +## get_nft_contract_sale_prices + +> `evm_api.nft.get_nft_contract_sale_prices()` + +Get the sold price for an NFT contract for the last x days (only trades paid in ETH). + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D", + "chain": "eth", + "days": 0, +} + +result = evm_api.nft.get_nft_contract_sale_prices( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The address of the NFT collection | Yes | | "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | +| days | int | The number of days to look back to find the lowest price
If not provided 7 days will be the default and 365 is the maximum
| | | 0 | @@ -286,7 +328,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from where to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from where to get the transfers.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The date from where to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | @@ -316,6 +358,7 @@ params = { "chain": "eth", "days": 0, "marketplace": "opensea", + "nft_metadata": True, } result = evm_api.nft.get_nft_lowest_price( @@ -332,9 +375,10 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | -| days | int | The number of days to look back to find the lowest price
If not provided 7 days will be the default
| | | 0 | -| marketplace | enum[str]:
- "opensea" | Marketplace from which to get the trades (only OpenSea is supported at the moment) | | "opensea" | "opensea" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | +| days | int | The number of days to look back to find the lowest price
If not provided 7 days will be the default and 365 is the maximum
| | | 0 | +| marketplace | enum[str]:
- "opensea"
- "blur"
- "looksrare"
- "x2y2"
- "0xprotocol" | Marketplace from which to get the trades. See [supported Marketplaces](https://docs.moralis.io/web3-data-api/evm/nft-marketplaces). | | "opensea" | "opensea" | +| nft_metadata | bool | Include the NFT Metadata of the NFT Token | | False | True | @@ -354,7 +398,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB", + "address": "0x524cab2ec69124574082676e6f654a18df49a048", "token_id": "1", "chain": "eth", "format": "decimal", @@ -375,9 +419,9 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | | token_id | str | The ID of the token | Yes | | "1" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | normalizeMetadata | bool | Should normalized metadata be returned? | | False | True | | media_items | bool | Should preview media data be returned? | | False | True | @@ -422,7 +466,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | limit | int | The desired page size of the result. | | | 0 | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | @@ -431,6 +475,46 @@ print(result) +--- +## get_nft_sale_prices + +> `evm_api.nft.get_nft_sale_prices()` + +Get the sold price for an NFT token for the last x days (only trades paid in ETH). + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D", + "token_id": "", + "chain": "eth", + "days": 0, +} + +result = evm_api.nft.get_nft_sale_prices( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The address of the NFT collection | Yes | | "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D" | +| token_id | str | The token id of the NFT collection | Yes | | "" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | +| days | int | The number of days to look back to find the lowest price
If not provided 7 days will be the default and 365 is the maximum
| | | 0 | + + + --- ## get_nft_token_id_owners @@ -447,7 +531,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB", + "address": "0x524cab2ec69124574082676e6f654a18df49a048", "token_id": "1", "chain": "eth", "format": "decimal", @@ -470,9 +554,9 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | | token_id | str | The ID of the token | Yes | | "1" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | limit | int | The desired page size of the result. | | | 0 | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | @@ -515,7 +599,7 @@ print(result) |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT collection | Yes | | "" | | token_id | str | The token id of the NFT collection | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -524,7 +608,7 @@ print(result) > `evm_api.nft.get_nft_trades()` -Get trades of NFTs for a given contract and marketplace. +Get trades of NFTs for a given contract with the ability to filter by marketplace. ### Example @@ -533,7 +617,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB", + "address": "0x524cab2ec69124574082676e6f654a18df49a048", "chain": "eth", "from_block": 0, "to_block": "", @@ -542,6 +626,7 @@ params = { "marketplace": "opensea", "cursor": "", "limit": 0, + "nft_metadata": True, } result = evm_api.nft.get_nft_trades( @@ -557,15 +642,118 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | +| from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | +| to_block | str | The block number to get the trades from | | | "" | +| from_date | str | The start date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | +| to_date | str | The end date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | +| marketplace | enum[str]:
- "opensea"
- "blur"
- "looksrare"
- "x2y2"
- "0xprotocol" | Marketplace from which to get the trades. See [supported Marketplaces](https://docs.moralis.io/web3-data-api/evm/nft-marketplaces). | | "opensea" | "opensea" | +| cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | +| limit | int | The desired page size of the result. | | | 0 | +| nft_metadata | bool | Include the NFT Metadata of the NFT Token | | False | True | + + + +--- +## get_nft_trades_by_token + +> `evm_api.nft.get_nft_trades_by_token()` + +Get trades of NFTs for a given contract and token ID. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "0x524cab2ec69124574082676e6f654a18df49a048", + "token_id": "123", + "chain": "eth", + "from_block": 0, + "to_block": "", + "from_date": "", + "to_date": "", + "cursor": "", + "limit": 0, + "nft_metadata": True, +} + +result = evm_api.nft.get_nft_trades_by_token( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | +| token_id | str | The token ID of the NFT contract | Yes | | "123" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | +| from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | +| to_block | str | The block number to get the trades from | | | "" | +| from_date | str | The start date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | +| to_date | str | The end date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | +| cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | +| limit | int | The desired page size of the result. | | | 0 | +| nft_metadata | bool | Include the NFT Metadata of the NFT Token | | False | True | + + + +--- +## get_nft_trades_by_wallet + +> `evm_api.nft.get_nft_trades_by_wallet()` + +Get trades of NFTs for a given wallet. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", + "chain": "eth", + "from_block": 0, + "to_block": "", + "from_date": "", + "to_date": "", + "cursor": "", + "limit": 0, + "nft_metadata": True, +} + +result = evm_api.nft.get_nft_trades_by_wallet( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The owner wallet address | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "avalanche"
- "0xa86a"
- "arbitrum"
- "0xa4b1"
- "base"
- "0x2105"
- "optimism"
- "0xa" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | str | The block number to get the trades from | | | "" | | from_date | str | The start date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | | to_date | str | The end date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | -| marketplace | enum[str]:
- "opensea" | Marketplace from which to get the trades (only OpenSea is supported at the moment) | | "opensea" | "opensea" | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | | limit | int | The desired page size of the result. | | | 0 | +| nft_metadata | bool | Include the NFT Metadata of the NFT Token | | False | True | @@ -583,7 +771,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB", + "address": "0x524cab2ec69124574082676e6f654a18df49a048", "token_id": "1", "chain": "eth", "format": "decimal", @@ -605,9 +793,9 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | +| address | str | The address of the NFT contract | Yes | | "0x524cab2ec69124574082676e6f654a18df49a048" | | token_id | str | The ID of the token | Yes | | "1" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | limit | int | The desired page size of the result. | | | 0 | | order | enum[str]:
- "ASC"
- "DESC" | The order of the result, in ascending (ASC) or descending (DESC) | | "DESC" | "DESC" | @@ -650,7 +838,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | block_number_or_hash | str | The block number or block hash | Yes | | "15846571" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | limit | int | The desired page size of the result. | | 100 | 0 | | order | enum[str]:
- "ASC"
- "DESC" | The order of the result, in ascending (ASC) or descending (DESC) | | "DESC" | "DESC" | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | @@ -695,7 +883,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transfers.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | @@ -721,7 +909,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "limit": 0, "exclude_spam": True, @@ -742,8 +930,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The wallet address of the owner of NFTs in the collections | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The wallet address of the owner of NFTs in the collections | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | limit | int | The desired page size of the result. | | | 0 | | exclude_spam | bool | Should spam NFTs be excluded from the result? | | False | True | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | @@ -765,7 +953,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "contract_addresses": [], "format": "decimal", @@ -791,8 +979,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The wallet address of the sender or recipient of the transfers | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The wallet address of the sender or recipient of the transfers | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | contract_addresses | List of str | List of contract addresses of transfers | | | [] | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | @@ -823,7 +1011,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "format": "decimal", "limit": 0, @@ -847,8 +1035,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the wallet | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the wallet | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | format | enum[str]:
- "decimal"
- "hex" | The format of the token ID | | "decimal" | "decimal" | | limit | int | The desired page size of the result. | | | 0 | | exclude_spam | bool | Should spam NFTs be excluded from the result? | | False | True | @@ -900,7 +1088,7 @@ print(result) |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | | token_id | str | The ID of the token | Yes | | "1" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | flag | enum[str]:
- "uri"
- "metadata" | The type of resync to operate | | "uri" | "uri" | | mode | enum[str]:
- "async"
- "sync" | To define the behaviour of the endpoint | | "async" | "sync" | @@ -938,7 +1126,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the NFT contract | Yes | | "0xb47e3cd837dDF8e4c57F05d70Ab865de6e193BBB" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | diff --git a/docs/evm_api/resolve.md b/docs/evm_api/resolve.md index a4587f0..a928374 100644 --- a/docs/evm_api/resolve.md +++ b/docs/evm_api/resolve.md @@ -22,7 +22,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", + "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", } result = evm_api.resolve.resolve_address( @@ -38,7 +38,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address to be resolved | Yes | | "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045" | +| address | str | The address to be resolved | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | diff --git a/docs/evm_api/token.md b/docs/evm_api/token.md index 297f2ee..7ac2956 100644 --- a/docs/evm_api/token.md +++ b/docs/evm_api/token.md @@ -7,10 +7,10 @@ - [get_token_metadata](#get_token_metadata) - [get_token_metadata_by_symbol](#get_token_metadata_by_symbol) - [get_token_owners](#get_token_owners) -- [get_token_pair_ohlc](#get_token_pair_ohlc) - [get_token_price](#get_token_price) - [get_token_stats](#get_token_stats) - [get_token_transfers](#get_token_transfers) +- [get_top_profitable_wallet_per_token](#get_top_profitable_wallet_per_token) - [get_wallet_token_balances](#get_wallet_token_balances) - [get_wallet_token_transfers](#get_wallet_token_transfers) @@ -50,7 +50,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | include | enum[str]:
- "percent_change" | If the result should contain the 24hr percent change | | "" | "" | @@ -98,7 +98,7 @@ print(result) | address | str | The address of the token contract | Yes | | "" | | owner_address | str | The address of the token owner | Yes | | "" | | spender_address | str | The address of the token spender | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -134,7 +134,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | addresses | List of str | The addresses to get metadata for | Yes | | [] | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -170,7 +170,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | symbols | List of str | The symbols to get metadata for | Yes | | [] | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -209,65 +209,13 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | token_address | str | The address of the token contract | Yes | | "0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | limit | int | The desired page size of the result. | | | 0 | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | | order | enum[str]:
- "ASC"
- "DESC" | The order of the result, in ascending (ASC) or descending (DESC) | | "DESC" | "DESC" | ---- -## get_token_pair_ohlc - -> `evm_api.token.get_token_pair_ohlc()` - -Get OHLC candle sticks of token pair. - - -### Example -```python -from moralis import evm_api - -api_key = "YOUR_API_KEY" -params = { - "token0": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2", - "token1": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48", - "exchange": "", - "interval": "1h", - "price_format": "", - "from_date": "", - "to_date": "", - "chain": "eth", - "limit": 0, - "cursor": "", -} - -result = evm_api.token.get_token_pair_ohlc( - api_key=api_key, - params=params, -) - -print(result) - -``` - -### Parameters - -| Name | Type | Description | Required | Default | Example | -|------|------|-------------|----------|---------|---------| -| token0 | str | The base token address | Yes | | "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2" | -| token1 | str | The quote token address | Yes | | "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" | -| exchange | str | The factory name or address of the token exchange | Yes | | "" | -| interval | str | The interval of the ohlc candles | Yes | "1h" | "1h" | -| price_format | str | The price format of the ohlc candles (usd, native) | Yes | | "" | -| from_date | str | The date from where to get the ohlc candles (format in seconds or datestring accepted by momentjs). | Yes | | "" | -| to_date | str | Get ohlc candles up until this date (format in seconds or datestring accepted by momentjs). | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | -| limit | int | The maximum number of ohlc candles to return (max 100) | | | 0 | -| cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | - - - --- ## get_token_price @@ -303,7 +251,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the token contract | Yes | | "0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | exchange | str | The factory name or address of the token exchange | | | "" | | to_block | int | The block number from which the token price should be checked | | | 0 | | include | enum[str]:
- "percent_change" | If the result should contain the 24hr percent change | | "" | "" | @@ -342,7 +290,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the erc20 token | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -385,7 +333,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | The address of the token contract | Yes | | "0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transfers
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transfers.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transfers (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | @@ -396,6 +344,44 @@ print(result) +--- +## get_top_profitable_wallet_per_token + +> `evm_api.token.get_top_profitable_wallet_per_token()` + +Retrieves a list of the top profitable wallets for a specific ERC20 token. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "days": "", + "chain": "eth", +} + +result = evm_api.token.get_top_profitable_wallet_per_token( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The ERC20 token address. | Yes | | "" | +| days | str | Timeframe in days for which profitability is calculated, can be 'all', '7d' or '30d' | | | "" | +| chain | enum[str]:
- "eth"
- "mainnet"
- "0x1"
- "matic"
- "0x89"
- "polygon"
- "bsc"
- "binance"
- "0x38"
- "fantom"
- "ftm"
- "0xfa"
- "arbitrum"
- "0xa4b1"
- "optimism"
- "0xa"
- "pulsechain"
- "0x171"
- "base"
- "0x2105" | The chain to query | | | "eth" | + + + --- ## get_wallet_token_balances @@ -410,7 +396,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "to_block": 1.2, "token_addresses": [], @@ -430,8 +416,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address from which token balances will be checked | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address from which token balances will be checked | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | float | The block number up to which the balances will be checked. | | | 1.2 | | token_addresses | List of str | The addresses to get balances for (optional) | | | [] | | exclude_spam | bool | Exclude spam tokens from the result | | True | True | @@ -452,7 +438,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "from_block": 0, "to_block": 0, @@ -477,8 +463,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the wallet | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the wallet | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transactions
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transactions.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transactions (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | diff --git a/docs/evm_api/transaction.md b/docs/evm_api/transaction.md index 242b702..35cb014 100644 --- a/docs/evm_api/transaction.md +++ b/docs/evm_api/transaction.md @@ -41,7 +41,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | transaction_hash | str | The transaction hash | Yes | | "0xdc85cb1b75fd09c2f6d001fea4aba83764193cbd7881a1fa8ccde350a5681109" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -78,7 +78,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | transaction_hash | str | The transaction hash | Yes | | "0xdc85cb1b75fd09c2f6d001fea4aba83764193cbd7881a1fa8ccde350a5681109" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | include | enum[str]:
- "internal_transactions" | If the result should contain the internal transactions. | | "" | "" | @@ -116,7 +116,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | transaction_hash | str | The transaction hash | Yes | | "0xdc85cb1b75fd09c2f6d001fea4aba83764193cbd7881a1fa8ccde350a5681109" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | include | enum[str]:
- "internal_transactions" | If the result should contain the internal transactions. | | "" | "" | @@ -135,7 +135,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "from_block": 0, "to_block": 0, @@ -160,8 +160,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the wallet | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the wallet | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transactions
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transactions.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transactions (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | @@ -187,7 +187,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "from_block": 0, "to_block": 0, @@ -212,8 +212,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the wallet | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the wallet | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transactions
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transactions.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transactions (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | diff --git a/docs/evm_api/utils.md b/docs/evm_api/utils.md index fb860cf..ded616d 100644 --- a/docs/evm_api/utils.md +++ b/docs/evm_api/utils.md @@ -65,7 +65,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | ### Body @@ -115,7 +115,7 @@ print(result) |------|------|-------------|----------|---------|---------| | address | str | The address of the contract | Yes | | "" | | function_name | str | The function name of the contract | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | ### Body diff --git a/docs/evm_api/wallets.md b/docs/evm_api/wallets.md index 202a879..1281e99 100644 --- a/docs/evm_api/wallets.md +++ b/docs/evm_api/wallets.md @@ -2,13 +2,128 @@ > `evm_api.wallets` +- [get_defi_positions_by_protocol](#get_defi_positions_by_protocol) +- [get_defi_positions_summary](#get_defi_positions_summary) +- [get_defi_summary](#get_defi_summary) - [get_wallet_active_chains](#get_wallet_active_chains) - [get_wallet_history](#get_wallet_history) - [get_wallet_net_worth](#get_wallet_net_worth) +- [get_wallet_profitability](#get_wallet_profitability) +- [get_wallet_profitability_summary](#get_wallet_profitability_summary) - [get_wallet_stats](#get_wallet_stats) - [get_wallet_token_balances_price](#get_wallet_token_balances_price) +--- +## get_defi_positions_by_protocol + +> `evm_api.wallets.get_defi_positions_by_protocol()` + +Get the detailed defi positions by protocol for a wallet address. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "protocol": "uniswap-v3", + "chain": "eth", +} + +result = evm_api.wallets.get_defi_positions_by_protocol( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | Wallet address | Yes | | "" | +| protocol | enum[str]:
- "uniswap-v2"
- "uniswap-v3"
- "pancakeswap-v2"
- "pancakeswap-v3"
- "quickswap-v2"
- "sushiswap-v2"
- "aave-v2"
- "aave-v3"
- "fraxswap-v1"
- "fraxswap-v2"
- "lido"
- "makerdao"
- "eigenlayer" | The protocol to query | Yes | "uniswap-v3" | "uniswap-v3" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | + + + +--- +## get_defi_positions_summary + +> `evm_api.wallets.get_defi_positions_summary()` + +Get the positions summary of a wallet address. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "chain": "eth", +} + +result = evm_api.wallets.get_defi_positions_summary( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | Wallet address | Yes | | "" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | + + + +--- +## get_defi_summary + +> `evm_api.wallets.get_defi_summary()` + +Get the defi summary of a wallet address. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "chain": "eth", +} + +result = evm_api.wallets.get_defi_summary( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | Wallet address | Yes | | "" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | + + + --- ## get_wallet_active_chains @@ -41,7 +156,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | Wallet address | Yes | | "" | -| chains | List of enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chains to query | | | [] | +| chains | List of enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chains to query | | | [] | @@ -59,7 +174,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "from_block": 0, "to_block": 0, @@ -67,6 +182,7 @@ params = { "to_date": "", "include_internal_transactions": True, "include_input_data": True, + "include_logs_data": True, "nft_metadata": True, "cursor": "", "order": "DESC", @@ -86,14 +202,15 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address of the wallet | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address of the wallet | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | from_block | int | The minimum block number from which to get the transactions
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | 0 | | to_block | int | The maximum block number from which to get the transactions.
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | 0 | | from_date | str | The start date from which to get the transactions (format in seconds or datestring accepted by momentjs)
* Provide the param 'from_block' or 'from_date'
* If 'from_date' and 'from_block' are provided, 'from_block' will be used.
| | | "" | | to_date | str | Get the transactions up to this date (format in seconds or datestring accepted by momentjs)
* Provide the param 'to_block' or 'to_date'
* If 'to_date' and 'to_block' are provided, 'to_block' will be used.
| | | "" | | include_internal_transactions | bool | If the result should contain the internal transactions. | | | True | | include_input_data | bool | Set the input data from the result | | False | True | +| include_logs_data | bool | Set the logs data from the result | | False | True | | nft_metadata | bool | If the result should contain the nft metadata. | | | True | | cursor | str | The cursor returned in the previous response (used for getting the next page). | | | "" | | order | enum[str]:
- "ASC"
- "DESC" | The order of the result, in ascending (ASC) or descending (DESC) | | "DESC" | "DESC" | @@ -115,7 +232,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chains": [], "exclude_spam": True, "exclude_unverified_contracts": True, @@ -134,13 +251,91 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The wallet address | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chains | List of enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chains to query | | | [] | +| address | str | The wallet address | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chains | List of enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chains to query | | | [] | | exclude_spam | bool | Exclude spam tokens from the result | | False | True | | exclude_unverified_contracts | bool | Exclude unverified contracts from the result | | False | True | +--- +## get_wallet_profitability + +> `evm_api.wallets.get_wallet_profitability()` + +Retrieves profitability information for a specific wallet address. Can be filtered by one or more tokens. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "days": "", + "chain": "eth", + "token_addresses": [], +} + +result = evm_api.wallets.get_wallet_profitability( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The wallet address for which profitability is to be retrieved. | Yes | | "" | +| days | str | Timeframe in days for which profitability is calculated, Options include 'all', '7', '30', '60', '90' default is 'all'. | | | "" | +| chain | enum[str]:
- "eth"
- "mainnet"
- "0x1"
- "matic"
- "0x89"
- "polygon"
- "bsc"
- "binance"
- "0x38"
- "fantom"
- "ftm"
- "0xfa"
- "arbitrum"
- "0xa4b1"
- "optimism"
- "0xa"
- "pulsechain"
- "0x171"
- "base"
- "0x2105" | The chain to query | | | "eth" | +| token_addresses | List of str | The token addresses list to filter the result with | | | [] | + + + +--- +## get_wallet_profitability_summary + +> `evm_api.wallets.get_wallet_profitability_summary()` + +Retrieves a summary of wallet profitability based on specified parameters including optional token addresses. + + +### Example +```python +from moralis import evm_api + +api_key = "YOUR_API_KEY" +params = { + "address": "", + "days": "", + "chain": "eth", +} + +result = evm_api.wallets.get_wallet_profitability_summary( + api_key=api_key, + params=params, +) + +print(result) + +``` + +### Parameters + +| Name | Type | Description | Required | Default | Example | +|------|------|-------------|----------|---------|---------| +| address | str | The wallet address for which profitability summary is to be retrieved. | Yes | | "" | +| days | str | Timeframe in days for the profitability summary. Options include 'all', '7', '30', '60', '90' default is 'all'. | | | "" | +| chain | enum[str]:
- "eth"
- "mainnet"
- "0x1"
- "matic"
- "0x89"
- "polygon"
- "bsc"
- "binance"
- "0x38"
- "fantom"
- "ftm"
- "0xfa"
- "arbitrum"
- "0xa4b1"
- "optimism"
- "0xa"
- "pulsechain"
- "0x171"
- "base"
- "0x2105" | The chain to query | | | "eth" | + + + --- ## get_wallet_stats @@ -173,7 +368,7 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| | address | str | Wallet address | Yes | | "" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | @@ -191,7 +386,7 @@ from moralis import evm_api api_key = "YOUR_API_KEY" params = { - "address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045", + "address": "0xcB1C1FdE09f811B294172696404e88E658659905", "chain": "eth", "to_block": 1.2, "token_addresses": [], @@ -215,8 +410,8 @@ print(result) | Name | Type | Description | Required | Default | Example | |------|------|-------------|----------|---------|---------| -| address | str | The address from which token balances will be checked | Yes | | "0xd8da6bf26964af9d7eed9e03e53415d37aa96045" | -| chain | enum[str]:
- "eth"
- "0x1"
- "goerli"
- "0x5"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "mumbai"
- "0x13881"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base testnet"
- "0x14a33"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507" | The chain to query | | "eth" | "eth" | +| address | str | The address from which token balances will be checked | Yes | | "0xcB1C1FdE09f811B294172696404e88E658659905" | +| chain | enum[str]:
- "eth"
- "0x1"
- "sepolia"
- "0xaa36a7"
- "polygon"
- "0x89"
- "bsc"
- "0x38"
- "bsc testnet"
- "0x61"
- "avalanche"
- "0xa86a"
- "fantom"
- "0xfa"
- "palm"
- "0x2a15c308d"
- "cronos"
- "0x19"
- "arbitrum"
- "0xa4b1"
- "chiliz"
- "0x15b38"
- "chiliz testnet"
- "0x15b32"
- "gnosis"
- "0x64"
- "gnosis testnet"
- "0x27d8"
- "base"
- "0x2105"
- "base sepolia"
- "0x14a34"
- "optimism"
- "0xa"
- "holesky"
- "0x4268"
- "polygon amoy"
- "0x13882"
- "linea"
- "0xe708"
- "moonbeam"
- "0x504"
- "moonriver"
- "0x505"
- "moonbase"
- "0x507"
- "linea sepolia"
- "0xe705" | The chain to query | | "eth" | "eth" | | to_block | float | The block number up to which the balances will be checked. | | | 1.2 | | token_addresses | List of str | The addresses to get balances for (optional) | | | [] | | exclude_spam | bool | Exclude spam tokens from the result | | False | True | diff --git a/src/moralis/evm_api/nft/get_nft_contract_sale_prices.py b/src/moralis/evm_api/nft/get_nft_contract_sale_prices.py new file mode 100644 index 0000000..e034866 --- /dev/null +++ b/src/moralis/evm_api/nft/get_nft_contract_sale_prices.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.nft_address_price.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_nft_contract_sale_prices(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_nft_contract_sale_prices( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/nft/get_nft_sale_prices.py b/src/moralis/evm_api/nft/get_nft_sale_prices.py new file mode 100644 index 0000000..56ce2a7 --- /dev/null +++ b/src/moralis/evm_api/nft/get_nft_sale_prices.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.nft_address_token_id_price.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_nft_sale_prices(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_nft_sale_prices( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/nft/get_nft_trades_by_token.py b/src/moralis/evm_api/nft/get_nft_trades_by_token.py new file mode 100644 index 0000000..aad481c --- /dev/null +++ b/src/moralis/evm_api/nft/get_nft_trades_by_token.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.nft_address_token_id_trades.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_nft_trades_by_token(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_nft_trades_by_token( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/nft/get_nft_trades_by_wallet.py b/src/moralis/evm_api/nft/get_nft_trades_by_wallet.py new file mode 100644 index 0000000..d07123e --- /dev/null +++ b/src/moralis/evm_api/nft/get_nft_trades_by_wallet.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.wallets_address_nfts_trades.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_nft_trades_by_wallet(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_nft_trades_by_wallet( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/nft/nft.py b/src/moralis/evm_api/nft/nft.py index 62f3111..fd372b5 100644 --- a/src/moralis/evm_api/nft/nft.py +++ b/src/moralis/evm_api/nft/nft.py @@ -3,13 +3,17 @@ from .get_nft_bulk_contract_metadata import get_nft_bulk_contract_metadata from .get_nft_collection_stats import get_nft_collection_stats from .get_nft_contract_metadata import get_nft_contract_metadata +from .get_nft_contract_sale_prices import get_nft_contract_sale_prices from .get_nft_contract_transfers import get_nft_contract_transfers from .get_nft_lowest_price import get_nft_lowest_price from .get_nft_metadata import get_nft_metadata from .get_nft_owners import get_nft_owners +from .get_nft_sale_prices import get_nft_sale_prices from .get_nft_token_id_owners import get_nft_token_id_owners from .get_nft_token_stats import get_nft_token_stats from .get_nft_trades import get_nft_trades +from .get_nft_trades_by_token import get_nft_trades_by_token +from .get_nft_trades_by_wallet import get_nft_trades_by_wallet from .get_nft_transfers import get_nft_transfers from .get_nft_transfers_by_block import get_nft_transfers_by_block from .get_nft_transfers_from_to_block import get_nft_transfers_from_to_block diff --git a/src/moralis/evm_api/token/get_top_profitable_wallet_per_token.py b/src/moralis/evm_api/token/get_top_profitable_wallet_per_token.py new file mode 100644 index 0000000..3b5cca2 --- /dev/null +++ b/src/moralis/evm_api/token/get_top_profitable_wallet_per_token.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.erc20_address_top_gainers.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_top_profitable_wallet_per_token(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_top_profitable_wallet_per_token( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/token/token.py b/src/moralis/evm_api/token/token.py index f3f4b1b..0fa3a5b 100644 --- a/src/moralis/evm_api/token/token.py +++ b/src/moralis/evm_api/token/token.py @@ -3,9 +3,9 @@ from .get_token_metadata import get_token_metadata from .get_token_metadata_by_symbol import get_token_metadata_by_symbol from .get_token_owners import get_token_owners -from .get_token_pair_ohlc import get_token_pair_ohlc from .get_token_price import get_token_price from .get_token_stats import get_token_stats from .get_token_transfers import get_token_transfers +from .get_top_profitable_wallet_per_token import get_top_profitable_wallet_per_token from .get_wallet_token_balances import get_wallet_token_balances from .get_wallet_token_transfers import get_wallet_token_transfers diff --git a/src/moralis/evm_api/wallets/get_defi_positions_by_protocol.py b/src/moralis/evm_api/wallets/get_defi_positions_by_protocol.py new file mode 100644 index 0000000..0b22025 --- /dev/null +++ b/src/moralis/evm_api/wallets/get_defi_positions_by_protocol.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.wallets_address_defi_protocol_positions.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_defi_positions_by_protocol(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_defi_positions_by_protocol( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/wallets/get_defi_positions_summary.py b/src/moralis/evm_api/wallets/get_defi_positions_summary.py new file mode 100644 index 0000000..acdcd64 --- /dev/null +++ b/src/moralis/evm_api/wallets/get_defi_positions_summary.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.wallets_address_defi_positions.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_defi_positions_summary(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_defi_positions_summary( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/token/get_token_pair_ohlc.py b/src/moralis/evm_api/wallets/get_defi_summary.py similarity index 77% rename from src/moralis/evm_api/token/get_token_pair_ohlc.py rename to src/moralis/evm_api/wallets/get_defi_summary.py index 9a6a165..6f296d8 100644 --- a/src/moralis/evm_api/token/get_token_pair_ohlc.py +++ b/src/moralis/evm_api/wallets/get_defi_summary.py @@ -2,7 +2,7 @@ import typing import typing_extensions from .api_instance import get_api_instance -from openapi_evm_api.paths.token0_token1_ohlc.get import RequestQueryParams, RequestPathParams +from openapi_evm_api.paths.wallets_address_defi_summary.get import RequestQueryParams, RequestPathParams @@ -12,11 +12,11 @@ class QueryParams(RequestQueryParams): class Params(QueryParams,RequestPathParams,): pass -def get_token_pair_ohlc(api_key: str, params: Params): +def get_defi_summary(api_key: str, params: Params): api_instance = get_api_instance(api_key, params) query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} - api_response = api_instance.get_token_pair_ohlc( + api_response = api_instance.get_defi_summary( query_params=query_params, path_params=path_params, accept_content_types=( diff --git a/src/moralis/evm_api/wallets/get_wallet_profitability.py b/src/moralis/evm_api/wallets/get_wallet_profitability.py new file mode 100644 index 0000000..7e460de --- /dev/null +++ b/src/moralis/evm_api/wallets/get_wallet_profitability.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.wallets_address_profitability.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_wallet_profitability(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_wallet_profitability( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/wallets/get_wallet_profitability_summary.py b/src/moralis/evm_api/wallets/get_wallet_profitability_summary.py new file mode 100644 index 0000000..fdb631e --- /dev/null +++ b/src/moralis/evm_api/wallets/get_wallet_profitability_summary.py @@ -0,0 +1,28 @@ +import json +import typing +import typing_extensions +from .api_instance import get_api_instance +from openapi_evm_api.paths.wallets_address_profitability_summary.get import RequestQueryParams, RequestPathParams + + + +class QueryParams(RequestQueryParams): + pass + +class Params(QueryParams,RequestPathParams,): + pass + +def get_wallet_profitability_summary(api_key: str, params: Params): + api_instance = get_api_instance(api_key, params) + query_params: typing.Any = {k: v for k, v in params.items() if k in RequestQueryParams.__annotations__.keys()} + path_params: typing.Any = {k: v for k, v in params.items() if k in RequestPathParams.__annotations__.keys()} + api_response = api_instance.get_wallet_profitability_summary( + query_params=query_params, + path_params=path_params, + accept_content_types=( + 'application/json; charset=utf-8', + ), + skip_deserialization=True + ) + + return json.loads(api_response.response.data) diff --git a/src/moralis/evm_api/wallets/wallets.py b/src/moralis/evm_api/wallets/wallets.py index c305a18..5aea23c 100644 --- a/src/moralis/evm_api/wallets/wallets.py +++ b/src/moralis/evm_api/wallets/wallets.py @@ -1,5 +1,10 @@ +from .get_defi_positions_by_protocol import get_defi_positions_by_protocol +from .get_defi_positions_summary import get_defi_positions_summary +from .get_defi_summary import get_defi_summary from .get_wallet_active_chains import get_wallet_active_chains from .get_wallet_history import get_wallet_history from .get_wallet_net_worth import get_wallet_net_worth +from .get_wallet_profitability import get_wallet_profitability +from .get_wallet_profitability_summary import get_wallet_profitability_summary from .get_wallet_stats import get_wallet_stats from .get_wallet_token_balances_price import get_wallet_token_balances_price diff --git a/src/openapi_auth/model/evm_challenge_request_dto.py b/src/openapi_auth/model/evm_challenge_request_dto.py index c0bdaab..67a61ba 100644 --- a/src/openapi_auth/model/evm_challenge_request_dto.py +++ b/src/openapi_auth/model/evm_challenge_request_dto.py @@ -67,16 +67,28 @@ class MetaOapg: enum_value_to_name = { "1": "POSITIVE_1", "5": "POSITIVE_5", + "10": "POSITIVE_10", "25": "POSITIVE_25", "56": "POSITIVE_56", "97": "POSITIVE_97", + "100": "POSITIVE_100", "137": "POSITIVE_137", "250": "POSITIVE_250", "338": "POSITIVE_338", + "420": "POSITIVE_420", + "1284": "POSITIVE_1284", + "1285": "POSITIVE_1285", + "1287": "POSITIVE_1287", "1337": "POSITIVE_1337", + "8453": "POSITIVE_8453", + "10200": "POSITIVE_10200", "43113": "POSITIVE_43113", "43114": "POSITIVE_43114", "80001": "POSITIVE_80001", + "80002": "POSITIVE_80002", + "84531": "POSITIVE_84531", + "88882": "POSITIVE_88882", + "88888": "POSITIVE_88888", "11155111": "POSITIVE_11155111", } @@ -88,6 +100,10 @@ def POSITIVE_1(cls): def POSITIVE_5(cls): return cls("5") + @schemas.classproperty + def POSITIVE_10(cls): + return cls("10") + @schemas.classproperty def POSITIVE_25(cls): return cls("25") @@ -100,6 +116,10 @@ def POSITIVE_56(cls): def POSITIVE_97(cls): return cls("97") + @schemas.classproperty + def POSITIVE_100(cls): + return cls("100") + @schemas.classproperty def POSITIVE_137(cls): return cls("137") @@ -112,10 +132,34 @@ def POSITIVE_250(cls): def POSITIVE_338(cls): return cls("338") + @schemas.classproperty + def POSITIVE_420(cls): + return cls("420") + + @schemas.classproperty + def POSITIVE_1284(cls): + return cls("1284") + + @schemas.classproperty + def POSITIVE_1285(cls): + return cls("1285") + + @schemas.classproperty + def POSITIVE_1287(cls): + return cls("1287") + @schemas.classproperty def POSITIVE_1337(cls): return cls("1337") + @schemas.classproperty + def POSITIVE_8453(cls): + return cls("8453") + + @schemas.classproperty + def POSITIVE_10200(cls): + return cls("10200") + @schemas.classproperty def POSITIVE_43113(cls): return cls("43113") @@ -128,6 +172,22 @@ def POSITIVE_43114(cls): def POSITIVE_80001(cls): return cls("80001") + @schemas.classproperty + def POSITIVE_80002(cls): + return cls("80002") + + @schemas.classproperty + def POSITIVE_84531(cls): + return cls("84531") + + @schemas.classproperty + def POSITIVE_88882(cls): + return cls("88882") + + @schemas.classproperty + def POSITIVE_88888(cls): + return cls("88888") + @schemas.classproperty def POSITIVE_11155111(cls): return cls("11155111") diff --git a/src/openapi_auth/model/evm_challenge_request_dto.pyi b/src/openapi_auth/model/evm_challenge_request_dto.pyi index 3db3963..6b31fc1 100644 --- a/src/openapi_auth/model/evm_challenge_request_dto.pyi +++ b/src/openapi_auth/model/evm_challenge_request_dto.pyi @@ -66,6 +66,10 @@ class EvmChallengeRequestDto( def POSITIVE_5(cls): return cls("5") + @schemas.classproperty + def POSITIVE_10(cls): + return cls("10") + @schemas.classproperty def POSITIVE_25(cls): return cls("25") @@ -78,6 +82,10 @@ class EvmChallengeRequestDto( def POSITIVE_97(cls): return cls("97") + @schemas.classproperty + def POSITIVE_100(cls): + return cls("100") + @schemas.classproperty def POSITIVE_137(cls): return cls("137") @@ -90,10 +98,34 @@ class EvmChallengeRequestDto( def POSITIVE_338(cls): return cls("338") + @schemas.classproperty + def POSITIVE_420(cls): + return cls("420") + + @schemas.classproperty + def POSITIVE_1284(cls): + return cls("1284") + + @schemas.classproperty + def POSITIVE_1285(cls): + return cls("1285") + + @schemas.classproperty + def POSITIVE_1287(cls): + return cls("1287") + @schemas.classproperty def POSITIVE_1337(cls): return cls("1337") + @schemas.classproperty + def POSITIVE_8453(cls): + return cls("8453") + + @schemas.classproperty + def POSITIVE_10200(cls): + return cls("10200") + @schemas.classproperty def POSITIVE_43113(cls): return cls("43113") @@ -106,6 +138,22 @@ class EvmChallengeRequestDto( def POSITIVE_80001(cls): return cls("80001") + @schemas.classproperty + def POSITIVE_80002(cls): + return cls("80002") + + @schemas.classproperty + def POSITIVE_84531(cls): + return cls("84531") + + @schemas.classproperty + def POSITIVE_88882(cls): + return cls("88882") + + @schemas.classproperty + def POSITIVE_88888(cls): + return cls("88888") + @schemas.classproperty def POSITIVE_11155111(cls): return cls("11155111") diff --git a/src/openapi_auth/model/evm_complete_challenge_response_dto.py b/src/openapi_auth/model/evm_complete_challenge_response_dto.py index 557cee1..ecef525 100644 --- a/src/openapi_auth/model/evm_complete_challenge_response_dto.py +++ b/src/openapi_auth/model/evm_complete_challenge_response_dto.py @@ -76,16 +76,28 @@ class MetaOapg: enum_value_to_name = { "1": "POSITIVE_1", "5": "POSITIVE_5", + "10": "POSITIVE_10", "25": "POSITIVE_25", "56": "POSITIVE_56", "97": "POSITIVE_97", + "100": "POSITIVE_100", "137": "POSITIVE_137", "250": "POSITIVE_250", "338": "POSITIVE_338", + "420": "POSITIVE_420", + "1284": "POSITIVE_1284", + "1285": "POSITIVE_1285", + "1287": "POSITIVE_1287", "1337": "POSITIVE_1337", + "8453": "POSITIVE_8453", + "10200": "POSITIVE_10200", "43113": "POSITIVE_43113", "43114": "POSITIVE_43114", "80001": "POSITIVE_80001", + "80002": "POSITIVE_80002", + "84531": "POSITIVE_84531", + "88882": "POSITIVE_88882", + "88888": "POSITIVE_88888", "11155111": "POSITIVE_11155111", } @@ -97,6 +109,10 @@ def POSITIVE_1(cls): def POSITIVE_5(cls): return cls("5") + @schemas.classproperty + def POSITIVE_10(cls): + return cls("10") + @schemas.classproperty def POSITIVE_25(cls): return cls("25") @@ -109,6 +125,10 @@ def POSITIVE_56(cls): def POSITIVE_97(cls): return cls("97") + @schemas.classproperty + def POSITIVE_100(cls): + return cls("100") + @schemas.classproperty def POSITIVE_137(cls): return cls("137") @@ -121,10 +141,34 @@ def POSITIVE_250(cls): def POSITIVE_338(cls): return cls("338") + @schemas.classproperty + def POSITIVE_420(cls): + return cls("420") + + @schemas.classproperty + def POSITIVE_1284(cls): + return cls("1284") + + @schemas.classproperty + def POSITIVE_1285(cls): + return cls("1285") + + @schemas.classproperty + def POSITIVE_1287(cls): + return cls("1287") + @schemas.classproperty def POSITIVE_1337(cls): return cls("1337") + @schemas.classproperty + def POSITIVE_8453(cls): + return cls("8453") + + @schemas.classproperty + def POSITIVE_10200(cls): + return cls("10200") + @schemas.classproperty def POSITIVE_43113(cls): return cls("43113") @@ -137,6 +181,22 @@ def POSITIVE_43114(cls): def POSITIVE_80001(cls): return cls("80001") + @schemas.classproperty + def POSITIVE_80002(cls): + return cls("80002") + + @schemas.classproperty + def POSITIVE_84531(cls): + return cls("84531") + + @schemas.classproperty + def POSITIVE_88882(cls): + return cls("88882") + + @schemas.classproperty + def POSITIVE_88888(cls): + return cls("88888") + @schemas.classproperty def POSITIVE_11155111(cls): return cls("11155111") diff --git a/src/openapi_auth/model/evm_complete_challenge_response_dto.pyi b/src/openapi_auth/model/evm_complete_challenge_response_dto.pyi index fb8029b..76a81e8 100644 --- a/src/openapi_auth/model/evm_complete_challenge_response_dto.pyi +++ b/src/openapi_auth/model/evm_complete_challenge_response_dto.pyi @@ -72,6 +72,10 @@ class EvmCompleteChallengeResponseDto( def POSITIVE_5(cls): return cls("5") + @schemas.classproperty + def POSITIVE_10(cls): + return cls("10") + @schemas.classproperty def POSITIVE_25(cls): return cls("25") @@ -84,6 +88,10 @@ class EvmCompleteChallengeResponseDto( def POSITIVE_97(cls): return cls("97") + @schemas.classproperty + def POSITIVE_100(cls): + return cls("100") + @schemas.classproperty def POSITIVE_137(cls): return cls("137") @@ -96,10 +104,34 @@ class EvmCompleteChallengeResponseDto( def POSITIVE_338(cls): return cls("338") + @schemas.classproperty + def POSITIVE_420(cls): + return cls("420") + + @schemas.classproperty + def POSITIVE_1284(cls): + return cls("1284") + + @schemas.classproperty + def POSITIVE_1285(cls): + return cls("1285") + + @schemas.classproperty + def POSITIVE_1287(cls): + return cls("1287") + @schemas.classproperty def POSITIVE_1337(cls): return cls("1337") + @schemas.classproperty + def POSITIVE_8453(cls): + return cls("8453") + + @schemas.classproperty + def POSITIVE_10200(cls): + return cls("10200") + @schemas.classproperty def POSITIVE_43113(cls): return cls("43113") @@ -112,6 +144,22 @@ class EvmCompleteChallengeResponseDto( def POSITIVE_80001(cls): return cls("80001") + @schemas.classproperty + def POSITIVE_80002(cls): + return cls("80002") + + @schemas.classproperty + def POSITIVE_84531(cls): + return cls("84531") + + @schemas.classproperty + def POSITIVE_88882(cls): + return cls("88882") + + @schemas.classproperty + def POSITIVE_88888(cls): + return cls("88888") + @schemas.classproperty def POSITIVE_11155111(cls): return cls("11155111") diff --git a/src/openapi_evm_api/apis/path_to_api.py b/src/openapi_evm_api/apis/path_to_api.py index 88b0da5..9ccccd8 100644 --- a/src/openapi_evm_api/apis/path_to_api.py +++ b/src/openapi_evm_api/apis/path_to_api.py @@ -11,6 +11,8 @@ from openapi_evm_api.apis.paths.nft_transfers import NftTransfers from openapi_evm_api.apis.paths.block_block_number_or_hash_nft_transfers import BlockBlockNumberOrHashNftTransfers from openapi_evm_api.apis.paths.nft_address_trades import NftAddressTrades +from openapi_evm_api.apis.paths.nft_address_token_id_trades import NftAddressTokenIdTrades +from openapi_evm_api.apis.paths.wallets_address_nfts_trades import WalletsAddressNftsTrades from openapi_evm_api.apis.paths.nft_address_metadata import NftAddressMetadata from openapi_evm_api.apis.paths.nft_metadata import NftMetadata from openapi_evm_api.apis.paths.nft_address_token_id import NftAddressTokenId @@ -19,6 +21,8 @@ from openapi_evm_api.apis.paths.nft_address_sync import NftAddressSync from openapi_evm_api.apis.paths.nft_address_token_id_metadata_resync import NftAddressTokenIdMetadataResync from openapi_evm_api.apis.paths.nft_address_lowestprice import NftAddressLowestprice +from openapi_evm_api.apis.paths.nft_address_price import NftAddressPrice +from openapi_evm_api.apis.paths.nft_address_token_id_price import NftAddressTokenIdPrice from openapi_evm_api.apis.paths.erc20_address_price import Erc20AddressPrice from openapi_evm_api.apis.paths.erc20_prices import Erc20Prices from openapi_evm_api.apis.paths.erc20_token_address_owners import Erc20TokenAddressOwners @@ -60,6 +64,9 @@ from openapi_evm_api.apis.paths.market_data_global_market_cap import MarketDataGlobalMarketCap from openapi_evm_api.apis.paths.market_data_global_volume import MarketDataGlobalVolume from openapi_evm_api.apis.paths.contracts_review import ContractsReview +from openapi_evm_api.apis.paths.wallets_address_defi_summary import WalletsAddressDefiSummary +from openapi_evm_api.apis.paths.wallets_address_defi_protocol_positions import WalletsAddressDefiProtocolPositions +from openapi_evm_api.apis.paths.wallets_address_defi_positions import WalletsAddressDefiPositions from openapi_evm_api.apis.paths.wallets_address_chains import WalletsAddressChains from openapi_evm_api.apis.paths.wallets_address_stats import WalletsAddressStats from openapi_evm_api.apis.paths.nft_address_stats import NftAddressStats @@ -76,7 +83,9 @@ from openapi_evm_api.apis.paths.discovery_tokens_top_losers import DiscoveryTokensTopLosers from openapi_evm_api.apis.paths.discovery_tokens_trending import DiscoveryTokensTrending from openapi_evm_api.apis.paths.discovery_token import DiscoveryToken -from openapi_evm_api.apis.paths.token0_token1_ohlc import Token0Token1Ohlc +from openapi_evm_api.apis.paths.wallets_address_profitability_summary import WalletsAddressProfitabilitySummary +from openapi_evm_api.apis.paths.wallets_address_profitability import WalletsAddressProfitability +from openapi_evm_api.apis.paths.erc20_address_top_gainers import Erc20AddressTopGainers PathToApi = typing_extensions.TypedDict( 'PathToApi', @@ -91,6 +100,8 @@ PathValues.NFT_TRANSFERS: NftTransfers, PathValues.BLOCK_BLOCK_NUMBER_OR_HASH_NFT_TRANSFERS: BlockBlockNumberOrHashNftTransfers, PathValues.NFT_ADDRESS_TRADES: NftAddressTrades, + PathValues.NFT_ADDRESS_TOKEN_ID_TRADES: NftAddressTokenIdTrades, + PathValues.WALLETS_ADDRESS_NFTS_TRADES: WalletsAddressNftsTrades, PathValues.NFT_ADDRESS_METADATA: NftAddressMetadata, PathValues.NFT_METADATA: NftMetadata, PathValues.NFT_ADDRESS_TOKEN_ID: NftAddressTokenId, @@ -99,6 +110,8 @@ PathValues.NFT_ADDRESS_SYNC: NftAddressSync, PathValues.NFT_ADDRESS_TOKEN_ID_METADATA_RESYNC: NftAddressTokenIdMetadataResync, PathValues.NFT_ADDRESS_LOWESTPRICE: NftAddressLowestprice, + PathValues.NFT_ADDRESS_PRICE: NftAddressPrice, + PathValues.NFT_ADDRESS_TOKEN_ID_PRICE: NftAddressTokenIdPrice, PathValues.ERC20_ADDRESS_PRICE: Erc20AddressPrice, PathValues.ERC20_PRICES: Erc20Prices, PathValues.ERC20_TOKEN_ADDRESS_OWNERS: Erc20TokenAddressOwners, @@ -140,6 +153,9 @@ PathValues.MARKETDATA_GLOBAL_MARKETCAP: MarketDataGlobalMarketCap, PathValues.MARKETDATA_GLOBAL_VOLUME: MarketDataGlobalVolume, PathValues.CONTRACTSREVIEW: ContractsReview, + PathValues.WALLETS_ADDRESS_DEFI_SUMMARY: WalletsAddressDefiSummary, + PathValues.WALLETS_ADDRESS_DEFI_PROTOCOL_POSITIONS: WalletsAddressDefiProtocolPositions, + PathValues.WALLETS_ADDRESS_DEFI_POSITIONS: WalletsAddressDefiPositions, PathValues.WALLETS_ADDRESS_CHAINS: WalletsAddressChains, PathValues.WALLETS_ADDRESS_STATS: WalletsAddressStats, PathValues.NFT_ADDRESS_STATS: NftAddressStats, @@ -156,7 +172,9 @@ PathValues.DISCOVERY_TOKENS_TOPLOSERS: DiscoveryTokensTopLosers, PathValues.DISCOVERY_TOKENS_TRENDING: DiscoveryTokensTrending, PathValues.DISCOVERY_TOKEN: DiscoveryToken, - PathValues.TOKEN0_TOKEN1_OHLC: Token0Token1Ohlc, + PathValues.WALLETS_ADDRESS_PROFITABILITY_SUMMARY: WalletsAddressProfitabilitySummary, + PathValues.WALLETS_ADDRESS_PROFITABILITY: WalletsAddressProfitability, + PathValues.ERC20_ADDRESS_TOPGAINERS: Erc20AddressTopGainers, } ) @@ -172,6 +190,8 @@ PathValues.NFT_TRANSFERS: NftTransfers, PathValues.BLOCK_BLOCK_NUMBER_OR_HASH_NFT_TRANSFERS: BlockBlockNumberOrHashNftTransfers, PathValues.NFT_ADDRESS_TRADES: NftAddressTrades, + PathValues.NFT_ADDRESS_TOKEN_ID_TRADES: NftAddressTokenIdTrades, + PathValues.WALLETS_ADDRESS_NFTS_TRADES: WalletsAddressNftsTrades, PathValues.NFT_ADDRESS_METADATA: NftAddressMetadata, PathValues.NFT_METADATA: NftMetadata, PathValues.NFT_ADDRESS_TOKEN_ID: NftAddressTokenId, @@ -180,6 +200,8 @@ PathValues.NFT_ADDRESS_SYNC: NftAddressSync, PathValues.NFT_ADDRESS_TOKEN_ID_METADATA_RESYNC: NftAddressTokenIdMetadataResync, PathValues.NFT_ADDRESS_LOWESTPRICE: NftAddressLowestprice, + PathValues.NFT_ADDRESS_PRICE: NftAddressPrice, + PathValues.NFT_ADDRESS_TOKEN_ID_PRICE: NftAddressTokenIdPrice, PathValues.ERC20_ADDRESS_PRICE: Erc20AddressPrice, PathValues.ERC20_PRICES: Erc20Prices, PathValues.ERC20_TOKEN_ADDRESS_OWNERS: Erc20TokenAddressOwners, @@ -221,6 +243,9 @@ PathValues.MARKETDATA_GLOBAL_MARKETCAP: MarketDataGlobalMarketCap, PathValues.MARKETDATA_GLOBAL_VOLUME: MarketDataGlobalVolume, PathValues.CONTRACTSREVIEW: ContractsReview, + PathValues.WALLETS_ADDRESS_DEFI_SUMMARY: WalletsAddressDefiSummary, + PathValues.WALLETS_ADDRESS_DEFI_PROTOCOL_POSITIONS: WalletsAddressDefiProtocolPositions, + PathValues.WALLETS_ADDRESS_DEFI_POSITIONS: WalletsAddressDefiPositions, PathValues.WALLETS_ADDRESS_CHAINS: WalletsAddressChains, PathValues.WALLETS_ADDRESS_STATS: WalletsAddressStats, PathValues.NFT_ADDRESS_STATS: NftAddressStats, @@ -237,6 +262,8 @@ PathValues.DISCOVERY_TOKENS_TOPLOSERS: DiscoveryTokensTopLosers, PathValues.DISCOVERY_TOKENS_TRENDING: DiscoveryTokensTrending, PathValues.DISCOVERY_TOKEN: DiscoveryToken, - PathValues.TOKEN0_TOKEN1_OHLC: Token0Token1Ohlc, + PathValues.WALLETS_ADDRESS_PROFITABILITY_SUMMARY: WalletsAddressProfitabilitySummary, + PathValues.WALLETS_ADDRESS_PROFITABILITY: WalletsAddressProfitability, + PathValues.ERC20_ADDRESS_TOPGAINERS: Erc20AddressTopGainers, } ) diff --git a/src/openapi_evm_api/apis/paths/erc20_address_top_gainers.py b/src/openapi_evm_api/apis/paths/erc20_address_top_gainers.py new file mode 100644 index 0000000..7aec0f4 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/erc20_address_top_gainers.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.erc20_address_top_gainers.get import ApiForget + + +class Erc20AddressTopGainers( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/nft_address_price.py b/src/openapi_evm_api/apis/paths/nft_address_price.py new file mode 100644 index 0000000..2b2d5ed --- /dev/null +++ b/src/openapi_evm_api/apis/paths/nft_address_price.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.nft_address_price.get import ApiForget + + +class NftAddressPrice( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/nft_address_token_id_price.py b/src/openapi_evm_api/apis/paths/nft_address_token_id_price.py new file mode 100644 index 0000000..06aee45 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/nft_address_token_id_price.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.nft_address_token_id_price.get import ApiForget + + +class NftAddressTokenIdPrice( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/nft_address_token_id_trades.py b/src/openapi_evm_api/apis/paths/nft_address_token_id_trades.py new file mode 100644 index 0000000..8539504 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/nft_address_token_id_trades.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.nft_address_token_id_trades.get import ApiForget + + +class NftAddressTokenIdTrades( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/token0_token1_ohlc.py b/src/openapi_evm_api/apis/paths/token0_token1_ohlc.py deleted file mode 100644 index a4c2d69..0000000 --- a/src/openapi_evm_api/apis/paths/token0_token1_ohlc.py +++ /dev/null @@ -1,7 +0,0 @@ -from openapi_evm_api.paths.token0_token1_ohlc.get import ApiForget - - -class Token0Token1Ohlc( - ApiForget, -): - pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_defi_positions.py b/src/openapi_evm_api/apis/paths/wallets_address_defi_positions.py new file mode 100644 index 0000000..59755cc --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_defi_positions.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_defi_positions.get import ApiForget + + +class WalletsAddressDefiPositions( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_defi_protocol_positions.py b/src/openapi_evm_api/apis/paths/wallets_address_defi_protocol_positions.py new file mode 100644 index 0000000..f731173 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_defi_protocol_positions.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_defi_protocol_positions.get import ApiForget + + +class WalletsAddressDefiProtocolPositions( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_defi_summary.py b/src/openapi_evm_api/apis/paths/wallets_address_defi_summary.py new file mode 100644 index 0000000..aa2a529 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_defi_summary.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_defi_summary.get import ApiForget + + +class WalletsAddressDefiSummary( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_nfts_trades.py b/src/openapi_evm_api/apis/paths/wallets_address_nfts_trades.py new file mode 100644 index 0000000..2802a09 --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_nfts_trades.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_nfts_trades.get import ApiForget + + +class WalletsAddressNftsTrades( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_profitability.py b/src/openapi_evm_api/apis/paths/wallets_address_profitability.py new file mode 100644 index 0000000..24deeaa --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_profitability.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_profitability.get import ApiForget + + +class WalletsAddressProfitability( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/paths/wallets_address_profitability_summary.py b/src/openapi_evm_api/apis/paths/wallets_address_profitability_summary.py new file mode 100644 index 0000000..430f7ce --- /dev/null +++ b/src/openapi_evm_api/apis/paths/wallets_address_profitability_summary.py @@ -0,0 +1,7 @@ +from openapi_evm_api.paths.wallets_address_profitability_summary.get import ApiForget + + +class WalletsAddressProfitabilitySummary( + ApiForget, +): + pass diff --git a/src/openapi_evm_api/apis/tags/nft_api.py b/src/openapi_evm_api/apis/tags/nft_api.py index 88f87d2..ca1529c 100644 --- a/src/openapi_evm_api/apis/tags/nft_api.py +++ b/src/openapi_evm_api/apis/tags/nft_api.py @@ -14,13 +14,17 @@ from openapi_evm_api.paths.nft_metadata.post import GetNftBulkContractMetadata from openapi_evm_api.paths.nft_address_stats.get import GetNftCollectionStats from openapi_evm_api.paths.nft_address_metadata.get import GetNftContractMetadata +from openapi_evm_api.paths.nft_address_price.get import GetNftContractSalePrices from openapi_evm_api.paths.nft_address_transfers.get import GetNftContractTransfers from openapi_evm_api.paths.nft_address_lowestprice.get import GetNftLowestPrice from openapi_evm_api.paths.nft_address_token_id.get import GetNftMetadata from openapi_evm_api.paths.nft_address_owners.get import GetNftOwners +from openapi_evm_api.paths.nft_address_token_id_price.get import GetNftSalePrices from openapi_evm_api.paths.nft_address_token_id_owners.get import GetNftTokenIdOwners from openapi_evm_api.paths.nft_address_token_id_stats.get import GetNftTokenStats from openapi_evm_api.paths.nft_address_trades.get import GetNftTrades +from openapi_evm_api.paths.nft_address_token_id_trades.get import GetNftTradesByToken +from openapi_evm_api.paths.wallets_address_nfts_trades.get import GetNftTradesByWallet from openapi_evm_api.paths.nft_address_token_id_transfers.get import GetNftTransfers from openapi_evm_api.paths.block_block_number_or_hash_nft_transfers.get import GetNftTransfersByBlock from openapi_evm_api.paths.nft_transfers.get import GetNftTransfersFromToBlock @@ -37,13 +41,17 @@ class NftApi( GetNftBulkContractMetadata, GetNftCollectionStats, GetNftContractMetadata, + GetNftContractSalePrices, GetNftContractTransfers, GetNftLowestPrice, GetNftMetadata, GetNftOwners, + GetNftSalePrices, GetNftTokenIdOwners, GetNftTokenStats, GetNftTrades, + GetNftTradesByToken, + GetNftTradesByWallet, GetNftTransfers, GetNftTransfersByBlock, GetNftTransfersFromToBlock, diff --git a/src/openapi_evm_api/apis/tags/token_api.py b/src/openapi_evm_api/apis/tags/token_api.py index 68d4936..e98ff39 100644 --- a/src/openapi_evm_api/apis/tags/token_api.py +++ b/src/openapi_evm_api/apis/tags/token_api.py @@ -14,10 +14,10 @@ from openapi_evm_api.paths.erc20_metadata.get import GetTokenMetadata from openapi_evm_api.paths.erc20_metadata_symbols.get import GetTokenMetadataBySymbol from openapi_evm_api.paths.erc20_token_address_owners.get import GetTokenOwners -from openapi_evm_api.paths.token0_token1_ohlc.get import GetTokenPairOhlc from openapi_evm_api.paths.erc20_address_price.get import GetTokenPrice from openapi_evm_api.paths.erc20_address_stats.get import GetTokenStats from openapi_evm_api.paths.erc20_address_transfers.get import GetTokenTransfers +from openapi_evm_api.paths.erc20_address_top_gainers.get import GetTopProfitableWalletPerToken from openapi_evm_api.paths.address_erc20.get import GetWalletTokenBalances from openapi_evm_api.paths.address_erc20_transfers.get import GetWalletTokenTransfers @@ -28,10 +28,10 @@ class TokenApi( GetTokenMetadata, GetTokenMetadataBySymbol, GetTokenOwners, - GetTokenPairOhlc, GetTokenPrice, GetTokenStats, GetTokenTransfers, + GetTopProfitableWalletPerToken, GetWalletTokenBalances, GetWalletTokenTransfers, ): diff --git a/src/openapi_evm_api/apis/tags/wallets_api.py b/src/openapi_evm_api/apis/tags/wallets_api.py index 97911a4..616e11f 100644 --- a/src/openapi_evm_api/apis/tags/wallets_api.py +++ b/src/openapi_evm_api/apis/tags/wallets_api.py @@ -9,17 +9,27 @@ Generated by: https://openapi-generator.tech """ +from openapi_evm_api.paths.wallets_address_defi_protocol_positions.get import GetDefiPositionsByProtocol +from openapi_evm_api.paths.wallets_address_defi_positions.get import GetDefiPositionsSummary +from openapi_evm_api.paths.wallets_address_defi_summary.get import GetDefiSummary from openapi_evm_api.paths.wallets_address_chains.get import GetWalletActiveChains from openapi_evm_api.paths.wallets_address_history.get import GetWalletHistory from openapi_evm_api.paths.wallets_address_net_worth.get import GetWalletNetWorth +from openapi_evm_api.paths.wallets_address_profitability.get import GetWalletProfitability +from openapi_evm_api.paths.wallets_address_profitability_summary.get import GetWalletProfitabilitySummary from openapi_evm_api.paths.wallets_address_stats.get import GetWalletStats from openapi_evm_api.paths.wallets_address_tokens.get import GetWalletTokenBalancesPrice class WalletsApi( + GetDefiPositionsByProtocol, + GetDefiPositionsSummary, + GetDefiSummary, GetWalletActiveChains, GetWalletHistory, GetWalletNetWorth, + GetWalletProfitability, + GetWalletProfitabilitySummary, GetWalletStats, GetWalletTokenBalancesPrice, ): diff --git a/src/openapi_evm_api/model/block_transaction.py b/src/openapi_evm_api/model/block_transaction.py index 6963534..d131de9 100644 --- a/src/openapi_evm_api/model/block_transaction.py +++ b/src/openapi_evm_api/model/block_transaction.py @@ -40,7 +40,6 @@ class MetaOapg: "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", "transaction_index", "nonce", "input", @@ -56,9 +55,18 @@ class properties: nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema + value = schemas.StrSchema + gas_price = schemas.StrSchema + input = schemas.StrSchema + receipt_cumulative_gas_used = schemas.StrSchema + receipt_gas_used = schemas.StrSchema + receipt_status = schemas.StrSchema + block_timestamp = schemas.StrSchema + block_number = schemas.StrSchema + block_hash = schemas.StrSchema - class to_address( + class from_address_label( schemas.StrBase, schemas.NoneBase, schemas.Schema, @@ -70,24 +78,15 @@ def __new__( cls, *args: typing.Union[None, str, ], _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'to_address': + ) -> 'from_address_label': return super().__new__( cls, *args, _configuration=_configuration, ) - value = schemas.StrSchema - gas_price = schemas.StrSchema - input = schemas.StrSchema - receipt_cumulative_gas_used = schemas.StrSchema - receipt_gas_used = schemas.StrSchema - receipt_status = schemas.StrSchema - block_timestamp = schemas.StrSchema - block_number = schemas.StrSchema - block_hash = schemas.StrSchema - class from_address_label( + class to_address( schemas.StrBase, schemas.NoneBase, schemas.Schema, @@ -99,7 +98,7 @@ def __new__( cls, *args: typing.Union[None, str, ], _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'from_address_label': + ) -> 'to_address': return super().__new__( cls, *args, @@ -223,7 +222,6 @@ def __getitem__(self, i: int) -> 'InternalTransaction': "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, @@ -234,6 +232,7 @@ def __getitem__(self, i: int) -> 'InternalTransaction': "block_number": block_number, "block_hash": block_hash, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -247,7 +246,6 @@ def __getitem__(self, i: int) -> 'InternalTransaction': receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce input: MetaOapg.properties.input @@ -269,9 +267,6 @@ def __getitem__(self, name: typing_extensions.Literal["transaction_index"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -302,6 +297,9 @@ def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -323,7 +321,7 @@ def __getitem__(self, name: typing_extensions.Literal["internal_transactions"]) @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -340,9 +338,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["transaction_index"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -373,6 +368,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOa @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -394,7 +392,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["internal_transactions"] @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): return super().get_item_oapg(name) @@ -406,7 +404,6 @@ def __new__( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, None, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], input: typing.Union[MetaOapg.properties.input, str, ], @@ -416,6 +413,7 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, None, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, None, str, schemas.Unset] = schemas.unset, @@ -433,7 +431,6 @@ def __new__( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, input=input, @@ -443,6 +440,7 @@ def __new__( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/block_transaction.pyi b/src/openapi_evm_api/model/block_transaction.pyi index 6963534..d131de9 100644 --- a/src/openapi_evm_api/model/block_transaction.pyi +++ b/src/openapi_evm_api/model/block_transaction.pyi @@ -40,7 +40,6 @@ class BlockTransaction( "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", "transaction_index", "nonce", "input", @@ -56,9 +55,18 @@ class BlockTransaction( nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema + value = schemas.StrSchema + gas_price = schemas.StrSchema + input = schemas.StrSchema + receipt_cumulative_gas_used = schemas.StrSchema + receipt_gas_used = schemas.StrSchema + receipt_status = schemas.StrSchema + block_timestamp = schemas.StrSchema + block_number = schemas.StrSchema + block_hash = schemas.StrSchema - class to_address( + class from_address_label( schemas.StrBase, schemas.NoneBase, schemas.Schema, @@ -70,24 +78,15 @@ class BlockTransaction( cls, *args: typing.Union[None, str, ], _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'to_address': + ) -> 'from_address_label': return super().__new__( cls, *args, _configuration=_configuration, ) - value = schemas.StrSchema - gas_price = schemas.StrSchema - input = schemas.StrSchema - receipt_cumulative_gas_used = schemas.StrSchema - receipt_gas_used = schemas.StrSchema - receipt_status = schemas.StrSchema - block_timestamp = schemas.StrSchema - block_number = schemas.StrSchema - block_hash = schemas.StrSchema - class from_address_label( + class to_address( schemas.StrBase, schemas.NoneBase, schemas.Schema, @@ -99,7 +98,7 @@ class BlockTransaction( cls, *args: typing.Union[None, str, ], _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'from_address_label': + ) -> 'to_address': return super().__new__( cls, *args, @@ -223,7 +222,6 @@ class BlockTransaction( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, @@ -234,6 +232,7 @@ class BlockTransaction( "block_number": block_number, "block_hash": block_hash, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -247,7 +246,6 @@ class BlockTransaction( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce input: MetaOapg.properties.input @@ -269,9 +267,6 @@ class BlockTransaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -302,6 +297,9 @@ class BlockTransaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -323,7 +321,7 @@ class BlockTransaction( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -340,9 +338,6 @@ class BlockTransaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -373,6 +368,9 @@ class BlockTransaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -394,7 +392,7 @@ class BlockTransaction( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", "logs", "internal_transactions", ], str]): return super().get_item_oapg(name) @@ -406,7 +404,6 @@ class BlockTransaction( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, None, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], input: typing.Union[MetaOapg.properties.input, str, ], @@ -416,6 +413,7 @@ class BlockTransaction( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, None, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, None, str, schemas.Unset] = schemas.unset, @@ -433,7 +431,6 @@ class BlockTransaction( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, input=input, @@ -443,6 +440,7 @@ class BlockTransaction( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/block_transaction_decoded.py b/src/openapi_evm_api/model/block_transaction_decoded.py index a6cbfd1..c24101e 100644 --- a/src/openapi_evm_api/model/block_transaction_decoded.py +++ b/src/openapi_evm_api/model/block_transaction_decoded.py @@ -40,7 +40,7 @@ class MetaOapg: "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", + "transaction_fee", "transaction_index", "decoded_call", "nonce", @@ -58,13 +58,13 @@ class properties: nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas_price = schemas.StrSchema input = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema receipt_gas_used = schemas.StrSchema receipt_status = schemas.StrSchema + transaction_fee = schemas.StrSchema block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema @@ -115,6 +115,7 @@ def __new__( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -143,19 +144,20 @@ def __new__( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, "receipt_gas_used": receipt_gas_used, "receipt_status": receipt_status, + "transaction_fee": transaction_fee, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, "logs": logs, "decoded_call": decoded_call, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -167,7 +169,7 @@ def __new__( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address + transaction_fee: MetaOapg.properties.transaction_fee transaction_index: MetaOapg.properties.transaction_index decoded_call: MetaOapg.properties.decoded_call nonce: MetaOapg.properties.nonce @@ -191,9 +193,6 @@ def __getitem__(self, name: typing_extensions.Literal["transaction_index"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -212,6 +211,9 @@ def __getitem__(self, name: typing_extensions.Literal["receipt_gas_used"]) -> Me @typing.overload def __getitem__(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -230,6 +232,9 @@ def __getitem__(self, name: typing_extensions.Literal["decoded_call"]) -> MetaOa @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -245,7 +250,7 @@ def __getitem__(self, name: typing_extensions.Literal["receipt_root"]) -> MetaOa @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -262,9 +267,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["transaction_index"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -283,6 +285,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["receipt_gas_used"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -301,6 +306,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["decoded_call"]) -> Meta @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -316,7 +324,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["receipt_root"]) -> typi @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): return super().get_item_oapg(name) @@ -328,7 +336,7 @@ def __new__( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], decoded_call: typing.Union[MetaOapg.properties.decoded_call, dict, frozendict.frozendict, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], @@ -340,6 +348,7 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, str, schemas.Unset] = schemas.unset, @@ -355,7 +364,7 @@ def __new__( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, + transaction_fee=transaction_fee, transaction_index=transaction_index, decoded_call=decoded_call, nonce=nonce, @@ -367,6 +376,7 @@ def __new__( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/block_transaction_decoded.pyi b/src/openapi_evm_api/model/block_transaction_decoded.pyi index a6cbfd1..c24101e 100644 --- a/src/openapi_evm_api/model/block_transaction_decoded.pyi +++ b/src/openapi_evm_api/model/block_transaction_decoded.pyi @@ -40,7 +40,7 @@ class BlockTransactionDecoded( "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", + "transaction_fee", "transaction_index", "decoded_call", "nonce", @@ -58,13 +58,13 @@ class BlockTransactionDecoded( nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas_price = schemas.StrSchema input = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema receipt_gas_used = schemas.StrSchema receipt_status = schemas.StrSchema + transaction_fee = schemas.StrSchema block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema @@ -115,6 +115,7 @@ class BlockTransactionDecoded( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -143,19 +144,20 @@ class BlockTransactionDecoded( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, "receipt_gas_used": receipt_gas_used, "receipt_status": receipt_status, + "transaction_fee": transaction_fee, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, "logs": logs, "decoded_call": decoded_call, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -167,7 +169,7 @@ class BlockTransactionDecoded( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address + transaction_fee: MetaOapg.properties.transaction_fee transaction_index: MetaOapg.properties.transaction_index decoded_call: MetaOapg.properties.decoded_call nonce: MetaOapg.properties.nonce @@ -191,9 +193,6 @@ class BlockTransactionDecoded( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -212,6 +211,9 @@ class BlockTransactionDecoded( @typing.overload def __getitem__(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -230,6 +232,9 @@ class BlockTransactionDecoded( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -245,7 +250,7 @@ class BlockTransactionDecoded( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -262,9 +267,6 @@ class BlockTransactionDecoded( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -283,6 +285,9 @@ class BlockTransactionDecoded( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -301,6 +306,9 @@ class BlockTransactionDecoded( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -316,7 +324,7 @@ class BlockTransactionDecoded( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): return super().get_item_oapg(name) @@ -328,7 +336,7 @@ class BlockTransactionDecoded( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], decoded_call: typing.Union[MetaOapg.properties.decoded_call, dict, frozendict.frozendict, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], @@ -340,6 +348,7 @@ class BlockTransactionDecoded( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, str, schemas.Unset] = schemas.unset, @@ -355,7 +364,7 @@ class BlockTransactionDecoded( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, + transaction_fee=transaction_fee, transaction_index=transaction_index, decoded_call=decoded_call, nonce=nonce, @@ -367,6 +376,7 @@ class BlockTransactionDecoded( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/block_transaction_verbose.py b/src/openapi_evm_api/model/block_transaction_verbose.py index 5a25f52..62333e4 100644 --- a/src/openapi_evm_api/model/block_transaction_verbose.py +++ b/src/openapi_evm_api/model/block_transaction_verbose.py @@ -40,7 +40,7 @@ class MetaOapg: "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", + "transaction_fee", "transaction_index", "decoded_call", "nonce", @@ -58,13 +58,13 @@ class properties: nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas_price = schemas.StrSchema input = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema receipt_gas_used = schemas.StrSchema receipt_status = schemas.StrSchema + transaction_fee = schemas.StrSchema block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema @@ -115,6 +115,7 @@ def __new__( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -143,19 +144,20 @@ def __new__( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, "receipt_gas_used": receipt_gas_used, "receipt_status": receipt_status, + "transaction_fee": transaction_fee, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, "logs": logs, "decoded_call": decoded_call, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -167,7 +169,7 @@ def __new__( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address + transaction_fee: MetaOapg.properties.transaction_fee transaction_index: MetaOapg.properties.transaction_index decoded_call: MetaOapg.properties.decoded_call nonce: MetaOapg.properties.nonce @@ -191,9 +193,6 @@ def __getitem__(self, name: typing_extensions.Literal["transaction_index"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -212,6 +211,9 @@ def __getitem__(self, name: typing_extensions.Literal["receipt_gas_used"]) -> Me @typing.overload def __getitem__(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -230,6 +232,9 @@ def __getitem__(self, name: typing_extensions.Literal["decoded_call"]) -> MetaOa @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -245,7 +250,7 @@ def __getitem__(self, name: typing_extensions.Literal["receipt_root"]) -> MetaOa @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -262,9 +267,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["transaction_index"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -283,6 +285,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["receipt_gas_used"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -301,6 +306,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["decoded_call"]) -> Meta @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -316,7 +324,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["receipt_root"]) -> typi @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): return super().get_item_oapg(name) @@ -328,7 +336,7 @@ def __new__( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], decoded_call: typing.Union[MetaOapg.properties.decoded_call, dict, frozendict.frozendict, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], @@ -340,6 +348,7 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, str, schemas.Unset] = schemas.unset, @@ -355,7 +364,7 @@ def __new__( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, + transaction_fee=transaction_fee, transaction_index=transaction_index, decoded_call=decoded_call, nonce=nonce, @@ -367,6 +376,7 @@ def __new__( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/block_transaction_verbose.pyi b/src/openapi_evm_api/model/block_transaction_verbose.pyi index 5a25f52..62333e4 100644 --- a/src/openapi_evm_api/model/block_transaction_verbose.pyi +++ b/src/openapi_evm_api/model/block_transaction_verbose.pyi @@ -40,7 +40,7 @@ class BlockTransactionVerbose( "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", + "transaction_fee", "transaction_index", "decoded_call", "nonce", @@ -58,13 +58,13 @@ class BlockTransactionVerbose( nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas_price = schemas.StrSchema input = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema receipt_gas_used = schemas.StrSchema receipt_status = schemas.StrSchema + transaction_fee = schemas.StrSchema block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema @@ -115,6 +115,7 @@ class BlockTransactionVerbose( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -143,19 +144,20 @@ class BlockTransactionVerbose( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "input": input, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, "receipt_gas_used": receipt_gas_used, "receipt_status": receipt_status, + "transaction_fee": transaction_fee, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, "logs": logs, "decoded_call": decoded_call, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "receipt_contract_address": receipt_contract_address, @@ -167,7 +169,7 @@ class BlockTransactionVerbose( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address + transaction_fee: MetaOapg.properties.transaction_fee transaction_index: MetaOapg.properties.transaction_index decoded_call: MetaOapg.properties.decoded_call nonce: MetaOapg.properties.nonce @@ -191,9 +193,6 @@ class BlockTransactionVerbose( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -212,6 +211,9 @@ class BlockTransactionVerbose( @typing.overload def __getitem__(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -230,6 +232,9 @@ class BlockTransactionVerbose( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -245,7 +250,7 @@ class BlockTransactionVerbose( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -262,9 +267,6 @@ class BlockTransactionVerbose( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -283,6 +285,9 @@ class BlockTransactionVerbose( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["receipt_status"]) -> MetaOapg.properties.receipt_status: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... @@ -301,6 +306,9 @@ class BlockTransactionVerbose( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -316,7 +324,7 @@ class BlockTransactionVerbose( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "transaction_fee", "block_timestamp", "block_number", "block_hash", "logs", "decoded_call", "from_address_label", "to_address", "to_address_label", "gas", "receipt_contract_address", "receipt_root", ], str]): return super().get_item_oapg(name) @@ -328,7 +336,7 @@ class BlockTransactionVerbose( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], decoded_call: typing.Union[MetaOapg.properties.decoded_call, dict, frozendict.frozendict, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], @@ -340,6 +348,7 @@ class BlockTransactionVerbose( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, str, schemas.Unset] = schemas.unset, @@ -355,7 +364,7 @@ class BlockTransactionVerbose( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, + transaction_fee=transaction_fee, transaction_index=transaction_index, decoded_call=decoded_call, nonce=nonce, @@ -367,6 +376,7 @@ class BlockTransactionVerbose( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, receipt_contract_address=receipt_contract_address, diff --git a/src/openapi_evm_api/model/chain_list.py b/src/openapi_evm_api/model/chain_list.py index 5daf215..5d21687 100644 --- a/src/openapi_evm_api/model/chain_list.py +++ b/src/openapi_evm_api/model/chain_list.py @@ -38,14 +38,10 @@ class MetaOapg: enum_value_to_name = { "eth": "ETH", "0x1": "X1", - "goerli": "GOERLI", - "0x5": "X5", "sepolia": "SEPOLIA", "0xaa36a7": "XAA36A7", "polygon": "POLYGON", "0x89": "X89", - "mumbai": "MUMBAI", - "0x13881": "X13881", "bsc": "BSC", "0x38": "X38", "bsc testnet": "BSC_TESTNET", @@ -70,8 +66,6 @@ class MetaOapg: "0x27d8": "X27D8", "base": "BASE", "0x2105": "X2105", - "base testnet": "BASE_TESTNET", - "0x14a33": "X14A33", "base sepolia": "BASE_SEPOLIA", "0x14a34": "X14A34", "optimism": "OPTIMISM", @@ -88,6 +82,8 @@ class MetaOapg: "0x505": "X505", "moonbase": "MOONBASE", "0x507": "X507", + "linea sepolia": "LINEA_SEPOLIA", + "0xe705": "XE705", } @schemas.classproperty @@ -98,14 +94,6 @@ def ETH(cls): def X1(cls): return cls("0x1") - @schemas.classproperty - def GOERLI(cls): - return cls("goerli") - - @schemas.classproperty - def X5(cls): - return cls("0x5") - @schemas.classproperty def SEPOLIA(cls): return cls("sepolia") @@ -122,14 +110,6 @@ def POLYGON(cls): def X89(cls): return cls("0x89") - @schemas.classproperty - def MUMBAI(cls): - return cls("mumbai") - - @schemas.classproperty - def X13881(cls): - return cls("0x13881") - @schemas.classproperty def BSC(cls): return cls("bsc") @@ -226,14 +206,6 @@ def BASE(cls): def X2105(cls): return cls("0x2105") - @schemas.classproperty - def BASE_TESTNET(cls): - return cls("base testnet") - - @schemas.classproperty - def X14A33(cls): - return cls("0x14a33") - @schemas.classproperty def BASE_SEPOLIA(cls): return cls("base sepolia") @@ -297,3 +269,11 @@ def MOONBASE(cls): @schemas.classproperty def X507(cls): return cls("0x507") + + @schemas.classproperty + def LINEA_SEPOLIA(cls): + return cls("linea sepolia") + + @schemas.classproperty + def XE705(cls): + return cls("0xe705") diff --git a/src/openapi_evm_api/model/chain_list.pyi b/src/openapi_evm_api/model/chain_list.pyi index 7c18fe1..a97f54f 100644 --- a/src/openapi_evm_api/model/chain_list.pyi +++ b/src/openapi_evm_api/model/chain_list.pyi @@ -41,14 +41,6 @@ class ChainList( def X1(cls): return cls("0x1") - @schemas.classproperty - def GOERLI(cls): - return cls("goerli") - - @schemas.classproperty - def X5(cls): - return cls("0x5") - @schemas.classproperty def SEPOLIA(cls): return cls("sepolia") @@ -65,14 +57,6 @@ class ChainList( def X89(cls): return cls("0x89") - @schemas.classproperty - def MUMBAI(cls): - return cls("mumbai") - - @schemas.classproperty - def X13881(cls): - return cls("0x13881") - @schemas.classproperty def BSC(cls): return cls("bsc") @@ -169,14 +153,6 @@ class ChainList( def X2105(cls): return cls("0x2105") - @schemas.classproperty - def BASE_TESTNET(cls): - return cls("base testnet") - - @schemas.classproperty - def X14A33(cls): - return cls("0x14a33") - @schemas.classproperty def BASE_SEPOLIA(cls): return cls("base sepolia") @@ -240,3 +216,11 @@ class ChainList( @schemas.classproperty def X507(cls): return cls("0x507") + + @schemas.classproperty + def LINEA_SEPOLIA(cls): + return cls("linea sepolia") + + @schemas.classproperty + def XE705(cls): + return cls("0xe705") diff --git a/src/openapi_evm_api/model/common_contract_data.py b/src/openapi_evm_api/model/common_contract_data.py new file mode 100644 index 0000000..22ce83a --- /dev/null +++ b/src/openapi_evm_api/model/common_contract_data.py @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class CommonContractData( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "spender", + "value", + "token", + } + + class properties: + value = schemas.StrSchema + + @staticmethod + def token() -> typing.Type['ContractTokenDetails']: + return ContractTokenDetails + + @staticmethod + def spender() -> typing.Type['ContractSpenderDetails']: + return ContractSpenderDetails + + + class value_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'value_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "value": value, + "token": token, + "spender": spender, + "value_formatted": value_formatted, + } + + spender: 'ContractSpenderDetails' + value: MetaOapg.properties.value + token: 'ContractTokenDetails' + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token"]) -> 'ContractTokenDetails': ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["spender"]) -> 'ContractSpenderDetails': ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value_formatted"]) -> MetaOapg.properties.value_formatted: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["value", "token", "spender", "value_formatted", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token"]) -> 'ContractTokenDetails': ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["spender"]) -> 'ContractSpenderDetails': ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value_formatted"]) -> typing.Union[MetaOapg.properties.value_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["value", "token", "spender", "value_formatted", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + spender: 'ContractSpenderDetails', + value: typing.Union[MetaOapg.properties.value, str, ], + token: 'ContractTokenDetails', + value_formatted: typing.Union[MetaOapg.properties.value_formatted, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'CommonContractData': + return super().__new__( + cls, + *args, + spender=spender, + value=value, + token=token, + value_formatted=value_formatted, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.contract_spender_details import ContractSpenderDetails +from openapi_evm_api.model.contract_token_details import ContractTokenDetails diff --git a/src/openapi_evm_api/model/common_contract_data.pyi b/src/openapi_evm_api/model/common_contract_data.pyi new file mode 100644 index 0000000..22ce83a --- /dev/null +++ b/src/openapi_evm_api/model/common_contract_data.pyi @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class CommonContractData( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "spender", + "value", + "token", + } + + class properties: + value = schemas.StrSchema + + @staticmethod + def token() -> typing.Type['ContractTokenDetails']: + return ContractTokenDetails + + @staticmethod + def spender() -> typing.Type['ContractSpenderDetails']: + return ContractSpenderDetails + + + class value_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'value_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "value": value, + "token": token, + "spender": spender, + "value_formatted": value_formatted, + } + + spender: 'ContractSpenderDetails' + value: MetaOapg.properties.value + token: 'ContractTokenDetails' + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token"]) -> 'ContractTokenDetails': ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["spender"]) -> 'ContractSpenderDetails': ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value_formatted"]) -> MetaOapg.properties.value_formatted: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["value", "token", "spender", "value_formatted", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token"]) -> 'ContractTokenDetails': ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["spender"]) -> 'ContractSpenderDetails': ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value_formatted"]) -> typing.Union[MetaOapg.properties.value_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["value", "token", "spender", "value_formatted", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + spender: 'ContractSpenderDetails', + value: typing.Union[MetaOapg.properties.value, str, ], + token: 'ContractTokenDetails', + value_formatted: typing.Union[MetaOapg.properties.value_formatted, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'CommonContractData': + return super().__new__( + cls, + *args, + spender=spender, + value=value, + token=token, + value_formatted=value_formatted, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.contract_spender_details import ContractSpenderDetails +from openapi_evm_api.model.contract_token_details import ContractTokenDetails diff --git a/src/openapi_evm_api/model/contract_spender_details.py b/src/openapi_evm_api/model/contract_spender_details.py new file mode 100644 index 0000000..62825f2 --- /dev/null +++ b/src/openapi_evm_api/model/contract_spender_details.py @@ -0,0 +1,199 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ContractSpenderDetails( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "address", + } + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class name( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'name': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class symbol( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'symbol': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class logo( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logo': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + "name": name, + "symbol": symbol, + "logo": logo, + } + + address: MetaOapg.properties.address + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> typing.Union[MetaOapg.properties.name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> typing.Union[MetaOapg.properties.symbol, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, ], + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + name: typing.Union[MetaOapg.properties.name, None, str, schemas.Unset] = schemas.unset, + symbol: typing.Union[MetaOapg.properties.symbol, None, str, schemas.Unset] = schemas.unset, + logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ContractSpenderDetails': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + name=name, + symbol=symbol, + logo=logo, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/contract_spender_details.pyi b/src/openapi_evm_api/model/contract_spender_details.pyi new file mode 100644 index 0000000..62825f2 --- /dev/null +++ b/src/openapi_evm_api/model/contract_spender_details.pyi @@ -0,0 +1,199 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ContractSpenderDetails( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "address", + } + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class name( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'name': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class symbol( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'symbol': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class logo( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logo': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + "name": name, + "symbol": symbol, + "logo": logo, + } + + address: MetaOapg.properties.address + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> typing.Union[MetaOapg.properties.name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> typing.Union[MetaOapg.properties.symbol, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, ], + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + name: typing.Union[MetaOapg.properties.name, None, str, schemas.Unset] = schemas.unset, + symbol: typing.Union[MetaOapg.properties.symbol, None, str, schemas.Unset] = schemas.unset, + logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ContractSpenderDetails': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + name=name, + symbol=symbol, + logo=logo, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/contract_token_details.py b/src/openapi_evm_api/model/contract_token_details.py new file mode 100644 index 0000000..ae55d86 --- /dev/null +++ b/src/openapi_evm_api/model/contract_token_details.py @@ -0,0 +1,148 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ContractTokenDetails( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "address", + "token_logo", + "token_name", + "token_symbol", + } + + class properties: + address = schemas.StrSchema + token_name = schemas.StrSchema + token_logo = schemas.StrSchema + token_symbol = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "token_name": token_name, + "token_logo": token_logo, + "token_symbol": token_symbol, + "address_label": address_label, + } + + address: MetaOapg.properties.address + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "token_name", "token_logo", "token_symbol", "address_label", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "token_name", "token_logo", "token_symbol", "address_label", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ContractTokenDetails': + return super().__new__( + cls, + *args, + address=address, + token_logo=token_logo, + token_name=token_name, + token_symbol=token_symbol, + address_label=address_label, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/contract_token_details.pyi b/src/openapi_evm_api/model/contract_token_details.pyi new file mode 100644 index 0000000..ae55d86 --- /dev/null +++ b/src/openapi_evm_api/model/contract_token_details.pyi @@ -0,0 +1,148 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ContractTokenDetails( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "address", + "token_logo", + "token_name", + "token_symbol", + } + + class properties: + address = schemas.StrSchema + token_name = schemas.StrSchema + token_logo = schemas.StrSchema + token_symbol = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "token_name": token_name, + "token_logo": token_logo, + "token_symbol": token_symbol, + "address_label": address_label, + } + + address: MetaOapg.properties.address + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "token_name", "token_logo", "token_symbol", "address_label", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "token_name", "token_logo", "token_symbol", "address_label", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ContractTokenDetails': + return super().__new__( + cls, + *args, + address=address, + token_logo=token_logo, + token_name=token_name, + token_symbol=token_symbol, + address_label=address_label, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_position_details.py b/src/openapi_evm_api/model/defi_position_details.py new file mode 100644 index 0000000..ac0d74f --- /dev/null +++ b/src/openapi_evm_api/model/defi_position_details.py @@ -0,0 +1,850 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiPositionDetails( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class fee_tier( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'fee_tier': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class range_tnd( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'range_tnd': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserves( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + items = schemas.StrSchema + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserves': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class current_price( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_price': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_in_range( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_in_range': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_upper( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_upper': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_lower( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_lower': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class liquidity( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'liquidity': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class range_start( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'range_start': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class pool_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'pool_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class position_key( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'position_key': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class nft_metadata( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + additional_properties = schemas.AnyTypeSchema + + + def __getitem__(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + # dict_instance[name] accessor + return super().__getitem__(name) + + def get_item_oapg(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + return super().get_item_oapg(name) + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[MetaOapg.additional_properties, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + ) -> 'nft_metadata': + return super().__new__( + cls, + *args, + _configuration=_configuration, + **kwargs, + ) + + + class asset_standard( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'asset_standard': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class apy( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'apy': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_variable_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_variable_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_stable_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_stable_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class shares( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'shares': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserve0( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserve0': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserve1( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserve1': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + factory = schemas.StrSchema + + + class pair( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'pair': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class share_of_pool( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'share_of_pool': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class no_price_available( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'no_price_available': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class shares_in_strategy( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'shares_in_strategy': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class strategy_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'strategy_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "fee_tier": fee_tier, + "range_tnd": range_tnd, + "reserves": reserves, + "current_price": current_price, + "is_in_range": is_in_range, + "price_upper": price_upper, + "price_lower": price_lower, + "price_label": price_label, + "liquidity": liquidity, + "range_start": range_start, + "pool_address": pool_address, + "position_key": position_key, + "nft_metadata": nft_metadata, + "asset_standard": asset_standard, + "apy": apy, + "is_debt": is_debt, + "is_variable_debt": is_variable_debt, + "is_stable_debt": is_stable_debt, + "shares": shares, + "reserve0": reserve0, + "reserve1": reserve1, + "factory": factory, + "pair": pair, + "share_of_pool": share_of_pool, + "no_price_available": no_price_available, + "shares_in_strategy": shares_in_strategy, + "strategy_address": strategy_address, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["fee_tier"]) -> MetaOapg.properties.fee_tier: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["range_tnd"]) -> MetaOapg.properties.range_tnd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserves"]) -> MetaOapg.properties.reserves: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_price"]) -> MetaOapg.properties.current_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_in_range"]) -> MetaOapg.properties.is_in_range: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_upper"]) -> MetaOapg.properties.price_upper: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_lower"]) -> MetaOapg.properties.price_lower: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_label"]) -> MetaOapg.properties.price_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["liquidity"]) -> MetaOapg.properties.liquidity: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["range_start"]) -> MetaOapg.properties.range_start: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pool_address"]) -> MetaOapg.properties.pool_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position_key"]) -> MetaOapg.properties.position_key: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["nft_metadata"]) -> MetaOapg.properties.nft_metadata: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["asset_standard"]) -> MetaOapg.properties.asset_standard: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["apy"]) -> MetaOapg.properties.apy: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_debt"]) -> MetaOapg.properties.is_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_variable_debt"]) -> MetaOapg.properties.is_variable_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_stable_debt"]) -> MetaOapg.properties.is_stable_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["shares"]) -> MetaOapg.properties.shares: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserve0"]) -> MetaOapg.properties.reserve0: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserve1"]) -> MetaOapg.properties.reserve1: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["factory"]) -> MetaOapg.properties.factory: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pair"]) -> MetaOapg.properties.pair: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["share_of_pool"]) -> MetaOapg.properties.share_of_pool: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["no_price_available"]) -> MetaOapg.properties.no_price_available: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["shares_in_strategy"]) -> MetaOapg.properties.shares_in_strategy: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["strategy_address"]) -> MetaOapg.properties.strategy_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["fee_tier", "range_tnd", "reserves", "current_price", "is_in_range", "price_upper", "price_lower", "price_label", "liquidity", "range_start", "pool_address", "position_key", "nft_metadata", "asset_standard", "apy", "is_debt", "is_variable_debt", "is_stable_debt", "shares", "reserve0", "reserve1", "factory", "pair", "share_of_pool", "no_price_available", "shares_in_strategy", "strategy_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["fee_tier"]) -> typing.Union[MetaOapg.properties.fee_tier, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["range_tnd"]) -> typing.Union[MetaOapg.properties.range_tnd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserves"]) -> typing.Union[MetaOapg.properties.reserves, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_price"]) -> typing.Union[MetaOapg.properties.current_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_in_range"]) -> typing.Union[MetaOapg.properties.is_in_range, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_upper"]) -> typing.Union[MetaOapg.properties.price_upper, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_lower"]) -> typing.Union[MetaOapg.properties.price_lower, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_label"]) -> typing.Union[MetaOapg.properties.price_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["liquidity"]) -> typing.Union[MetaOapg.properties.liquidity, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["range_start"]) -> typing.Union[MetaOapg.properties.range_start, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pool_address"]) -> typing.Union[MetaOapg.properties.pool_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position_key"]) -> typing.Union[MetaOapg.properties.position_key, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["nft_metadata"]) -> typing.Union[MetaOapg.properties.nft_metadata, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["asset_standard"]) -> typing.Union[MetaOapg.properties.asset_standard, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["apy"]) -> typing.Union[MetaOapg.properties.apy, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_debt"]) -> typing.Union[MetaOapg.properties.is_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_variable_debt"]) -> typing.Union[MetaOapg.properties.is_variable_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_stable_debt"]) -> typing.Union[MetaOapg.properties.is_stable_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["shares"]) -> typing.Union[MetaOapg.properties.shares, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserve0"]) -> typing.Union[MetaOapg.properties.reserve0, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserve1"]) -> typing.Union[MetaOapg.properties.reserve1, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["factory"]) -> typing.Union[MetaOapg.properties.factory, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pair"]) -> typing.Union[MetaOapg.properties.pair, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["share_of_pool"]) -> typing.Union[MetaOapg.properties.share_of_pool, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["no_price_available"]) -> typing.Union[MetaOapg.properties.no_price_available, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["shares_in_strategy"]) -> typing.Union[MetaOapg.properties.shares_in_strategy, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["strategy_address"]) -> typing.Union[MetaOapg.properties.strategy_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["fee_tier", "range_tnd", "reserves", "current_price", "is_in_range", "price_upper", "price_lower", "price_label", "liquidity", "range_start", "pool_address", "position_key", "nft_metadata", "asset_standard", "apy", "is_debt", "is_variable_debt", "is_stable_debt", "shares", "reserve0", "reserve1", "factory", "pair", "share_of_pool", "no_price_available", "shares_in_strategy", "strategy_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + fee_tier: typing.Union[MetaOapg.properties.fee_tier, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + range_tnd: typing.Union[MetaOapg.properties.range_tnd, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + reserves: typing.Union[MetaOapg.properties.reserves, list, tuple, None, schemas.Unset] = schemas.unset, + current_price: typing.Union[MetaOapg.properties.current_price, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + is_in_range: typing.Union[MetaOapg.properties.is_in_range, None, bool, schemas.Unset] = schemas.unset, + price_upper: typing.Union[MetaOapg.properties.price_upper, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + price_lower: typing.Union[MetaOapg.properties.price_lower, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + price_label: typing.Union[MetaOapg.properties.price_label, None, str, schemas.Unset] = schemas.unset, + liquidity: typing.Union[MetaOapg.properties.liquidity, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + range_start: typing.Union[MetaOapg.properties.range_start, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + pool_address: typing.Union[MetaOapg.properties.pool_address, None, str, schemas.Unset] = schemas.unset, + position_key: typing.Union[MetaOapg.properties.position_key, None, str, schemas.Unset] = schemas.unset, + nft_metadata: typing.Union[MetaOapg.properties.nft_metadata, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, + asset_standard: typing.Union[MetaOapg.properties.asset_standard, None, str, schemas.Unset] = schemas.unset, + apy: typing.Union[MetaOapg.properties.apy, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + is_debt: typing.Union[MetaOapg.properties.is_debt, None, bool, schemas.Unset] = schemas.unset, + is_variable_debt: typing.Union[MetaOapg.properties.is_variable_debt, None, bool, schemas.Unset] = schemas.unset, + is_stable_debt: typing.Union[MetaOapg.properties.is_stable_debt, None, bool, schemas.Unset] = schemas.unset, + shares: typing.Union[MetaOapg.properties.shares, None, str, schemas.Unset] = schemas.unset, + reserve0: typing.Union[MetaOapg.properties.reserve0, None, str, schemas.Unset] = schemas.unset, + reserve1: typing.Union[MetaOapg.properties.reserve1, None, str, schemas.Unset] = schemas.unset, + factory: typing.Union[MetaOapg.properties.factory, str, schemas.Unset] = schemas.unset, + pair: typing.Union[MetaOapg.properties.pair, None, str, schemas.Unset] = schemas.unset, + share_of_pool: typing.Union[MetaOapg.properties.share_of_pool, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + no_price_available: typing.Union[MetaOapg.properties.no_price_available, None, bool, schemas.Unset] = schemas.unset, + shares_in_strategy: typing.Union[MetaOapg.properties.shares_in_strategy, None, str, schemas.Unset] = schemas.unset, + strategy_address: typing.Union[MetaOapg.properties.strategy_address, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiPositionDetails': + return super().__new__( + cls, + *args, + fee_tier=fee_tier, + range_tnd=range_tnd, + reserves=reserves, + current_price=current_price, + is_in_range=is_in_range, + price_upper=price_upper, + price_lower=price_lower, + price_label=price_label, + liquidity=liquidity, + range_start=range_start, + pool_address=pool_address, + position_key=position_key, + nft_metadata=nft_metadata, + asset_standard=asset_standard, + apy=apy, + is_debt=is_debt, + is_variable_debt=is_variable_debt, + is_stable_debt=is_stable_debt, + shares=shares, + reserve0=reserve0, + reserve1=reserve1, + factory=factory, + pair=pair, + share_of_pool=share_of_pool, + no_price_available=no_price_available, + shares_in_strategy=shares_in_strategy, + strategy_address=strategy_address, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_position_details.pyi b/src/openapi_evm_api/model/defi_position_details.pyi new file mode 100644 index 0000000..ac0d74f --- /dev/null +++ b/src/openapi_evm_api/model/defi_position_details.pyi @@ -0,0 +1,850 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiPositionDetails( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class fee_tier( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'fee_tier': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class range_tnd( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'range_tnd': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserves( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + items = schemas.StrSchema + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserves': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class current_price( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_price': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_in_range( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_in_range': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_upper( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_upper': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_lower( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_lower': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class price_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'price_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class liquidity( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'liquidity': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class range_start( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'range_start': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class pool_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'pool_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class position_key( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'position_key': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class nft_metadata( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + additional_properties = schemas.AnyTypeSchema + + + def __getitem__(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + # dict_instance[name] accessor + return super().__getitem__(name) + + def get_item_oapg(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + return super().get_item_oapg(name) + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[MetaOapg.additional_properties, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + ) -> 'nft_metadata': + return super().__new__( + cls, + *args, + _configuration=_configuration, + **kwargs, + ) + + + class asset_standard( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'asset_standard': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class apy( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'apy': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_variable_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_variable_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class is_stable_debt( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'is_stable_debt': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class shares( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'shares': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserve0( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserve0': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class reserve1( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'reserve1': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + factory = schemas.StrSchema + + + class pair( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'pair': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class share_of_pool( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'share_of_pool': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class no_price_available( + schemas.BoolBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneBoolMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, bool, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'no_price_available': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class shares_in_strategy( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'shares_in_strategy': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class strategy_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'strategy_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "fee_tier": fee_tier, + "range_tnd": range_tnd, + "reserves": reserves, + "current_price": current_price, + "is_in_range": is_in_range, + "price_upper": price_upper, + "price_lower": price_lower, + "price_label": price_label, + "liquidity": liquidity, + "range_start": range_start, + "pool_address": pool_address, + "position_key": position_key, + "nft_metadata": nft_metadata, + "asset_standard": asset_standard, + "apy": apy, + "is_debt": is_debt, + "is_variable_debt": is_variable_debt, + "is_stable_debt": is_stable_debt, + "shares": shares, + "reserve0": reserve0, + "reserve1": reserve1, + "factory": factory, + "pair": pair, + "share_of_pool": share_of_pool, + "no_price_available": no_price_available, + "shares_in_strategy": shares_in_strategy, + "strategy_address": strategy_address, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["fee_tier"]) -> MetaOapg.properties.fee_tier: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["range_tnd"]) -> MetaOapg.properties.range_tnd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserves"]) -> MetaOapg.properties.reserves: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_price"]) -> MetaOapg.properties.current_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_in_range"]) -> MetaOapg.properties.is_in_range: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_upper"]) -> MetaOapg.properties.price_upper: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_lower"]) -> MetaOapg.properties.price_lower: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_label"]) -> MetaOapg.properties.price_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["liquidity"]) -> MetaOapg.properties.liquidity: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["range_start"]) -> MetaOapg.properties.range_start: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pool_address"]) -> MetaOapg.properties.pool_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position_key"]) -> MetaOapg.properties.position_key: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["nft_metadata"]) -> MetaOapg.properties.nft_metadata: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["asset_standard"]) -> MetaOapg.properties.asset_standard: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["apy"]) -> MetaOapg.properties.apy: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_debt"]) -> MetaOapg.properties.is_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_variable_debt"]) -> MetaOapg.properties.is_variable_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["is_stable_debt"]) -> MetaOapg.properties.is_stable_debt: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["shares"]) -> MetaOapg.properties.shares: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserve0"]) -> MetaOapg.properties.reserve0: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["reserve1"]) -> MetaOapg.properties.reserve1: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["factory"]) -> MetaOapg.properties.factory: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pair"]) -> MetaOapg.properties.pair: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["share_of_pool"]) -> MetaOapg.properties.share_of_pool: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["no_price_available"]) -> MetaOapg.properties.no_price_available: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["shares_in_strategy"]) -> MetaOapg.properties.shares_in_strategy: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["strategy_address"]) -> MetaOapg.properties.strategy_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["fee_tier", "range_tnd", "reserves", "current_price", "is_in_range", "price_upper", "price_lower", "price_label", "liquidity", "range_start", "pool_address", "position_key", "nft_metadata", "asset_standard", "apy", "is_debt", "is_variable_debt", "is_stable_debt", "shares", "reserve0", "reserve1", "factory", "pair", "share_of_pool", "no_price_available", "shares_in_strategy", "strategy_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["fee_tier"]) -> typing.Union[MetaOapg.properties.fee_tier, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["range_tnd"]) -> typing.Union[MetaOapg.properties.range_tnd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserves"]) -> typing.Union[MetaOapg.properties.reserves, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_price"]) -> typing.Union[MetaOapg.properties.current_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_in_range"]) -> typing.Union[MetaOapg.properties.is_in_range, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_upper"]) -> typing.Union[MetaOapg.properties.price_upper, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_lower"]) -> typing.Union[MetaOapg.properties.price_lower, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_label"]) -> typing.Union[MetaOapg.properties.price_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["liquidity"]) -> typing.Union[MetaOapg.properties.liquidity, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["range_start"]) -> typing.Union[MetaOapg.properties.range_start, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pool_address"]) -> typing.Union[MetaOapg.properties.pool_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position_key"]) -> typing.Union[MetaOapg.properties.position_key, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["nft_metadata"]) -> typing.Union[MetaOapg.properties.nft_metadata, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["asset_standard"]) -> typing.Union[MetaOapg.properties.asset_standard, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["apy"]) -> typing.Union[MetaOapg.properties.apy, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_debt"]) -> typing.Union[MetaOapg.properties.is_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_variable_debt"]) -> typing.Union[MetaOapg.properties.is_variable_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["is_stable_debt"]) -> typing.Union[MetaOapg.properties.is_stable_debt, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["shares"]) -> typing.Union[MetaOapg.properties.shares, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserve0"]) -> typing.Union[MetaOapg.properties.reserve0, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["reserve1"]) -> typing.Union[MetaOapg.properties.reserve1, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["factory"]) -> typing.Union[MetaOapg.properties.factory, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pair"]) -> typing.Union[MetaOapg.properties.pair, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["share_of_pool"]) -> typing.Union[MetaOapg.properties.share_of_pool, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["no_price_available"]) -> typing.Union[MetaOapg.properties.no_price_available, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["shares_in_strategy"]) -> typing.Union[MetaOapg.properties.shares_in_strategy, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["strategy_address"]) -> typing.Union[MetaOapg.properties.strategy_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["fee_tier", "range_tnd", "reserves", "current_price", "is_in_range", "price_upper", "price_lower", "price_label", "liquidity", "range_start", "pool_address", "position_key", "nft_metadata", "asset_standard", "apy", "is_debt", "is_variable_debt", "is_stable_debt", "shares", "reserve0", "reserve1", "factory", "pair", "share_of_pool", "no_price_available", "shares_in_strategy", "strategy_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + fee_tier: typing.Union[MetaOapg.properties.fee_tier, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + range_tnd: typing.Union[MetaOapg.properties.range_tnd, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + reserves: typing.Union[MetaOapg.properties.reserves, list, tuple, None, schemas.Unset] = schemas.unset, + current_price: typing.Union[MetaOapg.properties.current_price, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + is_in_range: typing.Union[MetaOapg.properties.is_in_range, None, bool, schemas.Unset] = schemas.unset, + price_upper: typing.Union[MetaOapg.properties.price_upper, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + price_lower: typing.Union[MetaOapg.properties.price_lower, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + price_label: typing.Union[MetaOapg.properties.price_label, None, str, schemas.Unset] = schemas.unset, + liquidity: typing.Union[MetaOapg.properties.liquidity, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + range_start: typing.Union[MetaOapg.properties.range_start, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + pool_address: typing.Union[MetaOapg.properties.pool_address, None, str, schemas.Unset] = schemas.unset, + position_key: typing.Union[MetaOapg.properties.position_key, None, str, schemas.Unset] = schemas.unset, + nft_metadata: typing.Union[MetaOapg.properties.nft_metadata, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, + asset_standard: typing.Union[MetaOapg.properties.asset_standard, None, str, schemas.Unset] = schemas.unset, + apy: typing.Union[MetaOapg.properties.apy, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + is_debt: typing.Union[MetaOapg.properties.is_debt, None, bool, schemas.Unset] = schemas.unset, + is_variable_debt: typing.Union[MetaOapg.properties.is_variable_debt, None, bool, schemas.Unset] = schemas.unset, + is_stable_debt: typing.Union[MetaOapg.properties.is_stable_debt, None, bool, schemas.Unset] = schemas.unset, + shares: typing.Union[MetaOapg.properties.shares, None, str, schemas.Unset] = schemas.unset, + reserve0: typing.Union[MetaOapg.properties.reserve0, None, str, schemas.Unset] = schemas.unset, + reserve1: typing.Union[MetaOapg.properties.reserve1, None, str, schemas.Unset] = schemas.unset, + factory: typing.Union[MetaOapg.properties.factory, str, schemas.Unset] = schemas.unset, + pair: typing.Union[MetaOapg.properties.pair, None, str, schemas.Unset] = schemas.unset, + share_of_pool: typing.Union[MetaOapg.properties.share_of_pool, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + no_price_available: typing.Union[MetaOapg.properties.no_price_available, None, bool, schemas.Unset] = schemas.unset, + shares_in_strategy: typing.Union[MetaOapg.properties.shares_in_strategy, None, str, schemas.Unset] = schemas.unset, + strategy_address: typing.Union[MetaOapg.properties.strategy_address, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiPositionDetails': + return super().__new__( + cls, + *args, + fee_tier=fee_tier, + range_tnd=range_tnd, + reserves=reserves, + current_price=current_price, + is_in_range=is_in_range, + price_upper=price_upper, + price_lower=price_lower, + price_label=price_label, + liquidity=liquidity, + range_start=range_start, + pool_address=pool_address, + position_key=position_key, + nft_metadata=nft_metadata, + asset_standard=asset_standard, + apy=apy, + is_debt=is_debt, + is_variable_debt=is_variable_debt, + is_stable_debt=is_stable_debt, + shares=shares, + reserve0=reserve0, + reserve1=reserve1, + factory=factory, + pair=pair, + share_of_pool=share_of_pool, + no_price_available=no_price_available, + shares_in_strategy=shares_in_strategy, + strategy_address=strategy_address, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_position_summary_response.py b/src/openapi_evm_api/model/defi_position_summary_response.py new file mode 100644 index 0000000..4444e53 --- /dev/null +++ b/src/openapi_evm_api/model/defi_position_summary_response.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiPositionSummaryResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + position = schemas.DictSchema + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "position": position, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position"]) -> MetaOapg.properties.position: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position"]) -> typing.Union[MetaOapg.properties.position, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + position: typing.Union[MetaOapg.properties.position, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiPositionSummaryResponse': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + position=position, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_position_summary_response.pyi b/src/openapi_evm_api/model/defi_position_summary_response.pyi new file mode 100644 index 0000000..4444e53 --- /dev/null +++ b/src/openapi_evm_api/model/defi_position_summary_response.pyi @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiPositionSummaryResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + position = schemas.DictSchema + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "position": position, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position"]) -> MetaOapg.properties.position: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position"]) -> typing.Union[MetaOapg.properties.position, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + position: typing.Union[MetaOapg.properties.position, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiPositionSummaryResponse': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + position=position, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_protocol_balance.py b/src/openapi_evm_api/model/defi_protocol_balance.py new file mode 100644 index 0000000..3b3e17b --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_balance.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolBalance( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "positions", + "total_usd_value", + } + + class properties: + total_usd_value = schemas.NumberSchema + positions = schemas.NumberSchema + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "total_usd_value": total_usd_value, + "positions": positions, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + positions: MetaOapg.properties.positions + total_usd_value: MetaOapg.properties.total_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + positions: typing.Union[MetaOapg.properties.positions, decimal.Decimal, int, float, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolBalance': + return super().__new__( + cls, + *args, + positions=positions, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_protocol_balance.pyi b/src/openapi_evm_api/model/defi_protocol_balance.pyi new file mode 100644 index 0000000..3b3e17b --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_balance.pyi @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolBalance( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "positions", + "total_usd_value", + } + + class properties: + total_usd_value = schemas.NumberSchema + positions = schemas.NumberSchema + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "total_usd_value": total_usd_value, + "positions": positions, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + positions: MetaOapg.properties.positions + total_usd_value: MetaOapg.properties.total_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + positions: typing.Union[MetaOapg.properties.positions, decimal.Decimal, int, float, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolBalance': + return super().__new__( + cls, + *args, + positions=positions, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_protocol_list.py b/src/openapi_evm_api/model/defi_protocol_list.py new file mode 100644 index 0000000..76ba445 --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_list.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolList( + schemas.EnumBase, + schemas.StrSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + enum_value_to_name = { + "uniswap-v2": "UNISWAPV2", + "uniswap-v3": "UNISWAPV3", + "pancakeswap-v2": "PANCAKESWAPV2", + "pancakeswap-v3": "PANCAKESWAPV3", + "quickswap-v2": "QUICKSWAPV2", + "sushiswap-v2": "SUSHISWAPV2", + "aave-v2": "AAVEV2", + "aave-v3": "AAVEV3", + "fraxswap-v1": "FRAXSWAPV1", + "fraxswap-v2": "FRAXSWAPV2", + "lido": "LIDO", + "makerdao": "MAKERDAO", + "eigenlayer": "EIGENLAYER", + } + + @schemas.classproperty + def UNISWAPV2(cls): + return cls("uniswap-v2") + + @schemas.classproperty + def UNISWAPV3(cls): + return cls("uniswap-v3") + + @schemas.classproperty + def PANCAKESWAPV2(cls): + return cls("pancakeswap-v2") + + @schemas.classproperty + def PANCAKESWAPV3(cls): + return cls("pancakeswap-v3") + + @schemas.classproperty + def QUICKSWAPV2(cls): + return cls("quickswap-v2") + + @schemas.classproperty + def SUSHISWAPV2(cls): + return cls("sushiswap-v2") + + @schemas.classproperty + def AAVEV2(cls): + return cls("aave-v2") + + @schemas.classproperty + def AAVEV3(cls): + return cls("aave-v3") + + @schemas.classproperty + def FRAXSWAPV1(cls): + return cls("fraxswap-v1") + + @schemas.classproperty + def FRAXSWAPV2(cls): + return cls("fraxswap-v2") + + @schemas.classproperty + def LIDO(cls): + return cls("lido") + + @schemas.classproperty + def MAKERDAO(cls): + return cls("makerdao") + + @schemas.classproperty + def EIGENLAYER(cls): + return cls("eigenlayer") diff --git a/src/openapi_evm_api/model/defi_protocol_list.pyi b/src/openapi_evm_api/model/defi_protocol_list.pyi new file mode 100644 index 0000000..45d2ebc --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_list.pyi @@ -0,0 +1,86 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolList( + schemas.EnumBase, + schemas.StrSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + @schemas.classproperty + def UNISWAPV2(cls): + return cls("uniswap-v2") + + @schemas.classproperty + def UNISWAPV3(cls): + return cls("uniswap-v3") + + @schemas.classproperty + def PANCAKESWAPV2(cls): + return cls("pancakeswap-v2") + + @schemas.classproperty + def PANCAKESWAPV3(cls): + return cls("pancakeswap-v3") + + @schemas.classproperty + def QUICKSWAPV2(cls): + return cls("quickswap-v2") + + @schemas.classproperty + def SUSHISWAPV2(cls): + return cls("sushiswap-v2") + + @schemas.classproperty + def AAVEV2(cls): + return cls("aave-v2") + + @schemas.classproperty + def AAVEV3(cls): + return cls("aave-v3") + + @schemas.classproperty + def FRAXSWAPV1(cls): + return cls("fraxswap-v1") + + @schemas.classproperty + def FRAXSWAPV2(cls): + return cls("fraxswap-v2") + + @schemas.classproperty + def LIDO(cls): + return cls("lido") + + @schemas.classproperty + def MAKERDAO(cls): + return cls("makerdao") + + @schemas.classproperty + def EIGENLAYER(cls): + return cls("eigenlayer") diff --git a/src/openapi_evm_api/model/defi_protocol_position.py b/src/openapi_evm_api/model/defi_protocol_position.py new file mode 100644 index 0000000..9f6bc77 --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_position.py @@ -0,0 +1,167 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolPosition( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "balance_usd", + "tokens", + "label", + "total_unclaimed_usd_value", + } + + class properties: + label = schemas.StrSchema + + + class tokens( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiTokenBalance']: + return DefiTokenBalance + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiTokenBalance'], typing.List['DefiTokenBalance']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'tokens': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiTokenBalance': + return super().__getitem__(i) + balance_usd = schemas.NumberSchema + total_unclaimed_usd_value = schemas.NumberSchema + address = schemas.StrSchema + position_details = schemas.DictSchema + __annotations__ = { + "label": label, + "tokens": tokens, + "balance_usd": balance_usd, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + "address": address, + "position_details": position_details, + } + + + balance_usd: MetaOapg.properties.balance_usd + tokens: MetaOapg.properties.tokens + label: MetaOapg.properties.label + total_unclaimed_usd_value: MetaOapg.properties.total_unclaimed_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["label"]) -> MetaOapg.properties.label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["tokens"]) -> MetaOapg.properties.tokens: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance_usd"]) -> MetaOapg.properties.balance_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position_details"]) -> MetaOapg.properties.position_details: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["label", "tokens", "balance_usd", "total_unclaimed_usd_value", "address", "position_details", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["label"]) -> MetaOapg.properties.label: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["tokens"]) -> MetaOapg.properties.tokens: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance_usd"]) -> MetaOapg.properties.balance_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position_details"]) -> typing.Union[MetaOapg.properties.position_details, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["label", "tokens", "balance_usd", "total_unclaimed_usd_value", "address", "position_details", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + balance_usd: typing.Union[MetaOapg.properties.balance_usd, decimal.Decimal, int, float, ], + tokens: typing.Union[MetaOapg.properties.tokens, list, tuple, ], + label: typing.Union[MetaOapg.properties.label, str, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + position_details: typing.Union[MetaOapg.properties.position_details, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolPosition': + return super().__new__( + cls, + *args, + balance_usd=balance_usd, + tokens=tokens, + label=label, + total_unclaimed_usd_value=total_unclaimed_usd_value, + address=address, + position_details=position_details, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_token_balance import DefiTokenBalance diff --git a/src/openapi_evm_api/model/defi_protocol_position.pyi b/src/openapi_evm_api/model/defi_protocol_position.pyi new file mode 100644 index 0000000..9f6bc77 --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_position.pyi @@ -0,0 +1,167 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolPosition( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "balance_usd", + "tokens", + "label", + "total_unclaimed_usd_value", + } + + class properties: + label = schemas.StrSchema + + + class tokens( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiTokenBalance']: + return DefiTokenBalance + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiTokenBalance'], typing.List['DefiTokenBalance']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'tokens': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiTokenBalance': + return super().__getitem__(i) + balance_usd = schemas.NumberSchema + total_unclaimed_usd_value = schemas.NumberSchema + address = schemas.StrSchema + position_details = schemas.DictSchema + __annotations__ = { + "label": label, + "tokens": tokens, + "balance_usd": balance_usd, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + "address": address, + "position_details": position_details, + } + + + balance_usd: MetaOapg.properties.balance_usd + tokens: MetaOapg.properties.tokens + label: MetaOapg.properties.label + total_unclaimed_usd_value: MetaOapg.properties.total_unclaimed_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["label"]) -> MetaOapg.properties.label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["tokens"]) -> MetaOapg.properties.tokens: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance_usd"]) -> MetaOapg.properties.balance_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position_details"]) -> MetaOapg.properties.position_details: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["label", "tokens", "balance_usd", "total_unclaimed_usd_value", "address", "position_details", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["label"]) -> MetaOapg.properties.label: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["tokens"]) -> MetaOapg.properties.tokens: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance_usd"]) -> MetaOapg.properties.balance_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position_details"]) -> typing.Union[MetaOapg.properties.position_details, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["label", "tokens", "balance_usd", "total_unclaimed_usd_value", "address", "position_details", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + balance_usd: typing.Union[MetaOapg.properties.balance_usd, decimal.Decimal, int, float, ], + tokens: typing.Union[MetaOapg.properties.tokens, list, tuple, ], + label: typing.Union[MetaOapg.properties.label, str, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + position_details: typing.Union[MetaOapg.properties.position_details, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolPosition': + return super().__new__( + cls, + *args, + balance_usd=balance_usd, + tokens=tokens, + label=label, + total_unclaimed_usd_value=total_unclaimed_usd_value, + address=address, + position_details=position_details, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_token_balance import DefiTokenBalance diff --git a/src/openapi_evm_api/model/defi_protocol_summary.py b/src/openapi_evm_api/model/defi_protocol_summary.py new file mode 100644 index 0000000..01866fa --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_summary.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolSummary( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + position = schemas.DictSchema + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "position": position, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position"]) -> MetaOapg.properties.position: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position"]) -> typing.Union[MetaOapg.properties.position, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + position: typing.Union[MetaOapg.properties.position, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolSummary': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + position=position, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_protocol_summary.pyi b/src/openapi_evm_api/model/defi_protocol_summary.pyi new file mode 100644 index 0000000..01866fa --- /dev/null +++ b/src/openapi_evm_api/model/defi_protocol_summary.pyi @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiProtocolSummary( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + position = schemas.DictSchema + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "position": position, + } + + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["position"]) -> MetaOapg.properties.position: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["position"]) -> typing.Union[MetaOapg.properties.position, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "position", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + position: typing.Union[MetaOapg.properties.position, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiProtocolSummary': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + position=position, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_token_balance.py b/src/openapi_evm_api/model/defi_token_balance.py new file mode 100644 index 0000000..fd4a809 --- /dev/null +++ b/src/openapi_evm_api/model/defi_token_balance.py @@ -0,0 +1,196 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiTokenBalance( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "symbol", + "balance", + "balance_formatted", + "decimals", + "name", + "contract_address", + "token_type", + } + + class properties: + token_type = schemas.StrSchema + name = schemas.StrSchema + symbol = schemas.StrSchema + contract_address = schemas.StrSchema + decimals = schemas.NumberSchema + balance = schemas.StrSchema + balance_formatted = schemas.StrSchema + logo = schemas.StrSchema + thumbnail = schemas.StrSchema + usd_price = schemas.NumberSchema + usd_value = schemas.NumberSchema + __annotations__ = { + "token_type": token_type, + "name": name, + "symbol": symbol, + "contract_address": contract_address, + "decimals": decimals, + "balance": balance, + "balance_formatted": balance_formatted, + "logo": logo, + "thumbnail": thumbnail, + "usd_price": usd_price, + "usd_value": usd_value, + } + + + symbol: MetaOapg.properties.symbol + balance: MetaOapg.properties.balance + balance_formatted: MetaOapg.properties.balance_formatted + decimals: MetaOapg.properties.decimals + name: MetaOapg.properties.name + contract_address: MetaOapg.properties.contract_address + token_type: MetaOapg.properties.token_type + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_type"]) -> MetaOapg.properties.token_type: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["contract_address"]) -> MetaOapg.properties.contract_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance"]) -> MetaOapg.properties.balance: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance_formatted"]) -> MetaOapg.properties.balance_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_value"]) -> MetaOapg.properties.usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_type", "name", "symbol", "contract_address", "decimals", "balance", "balance_formatted", "logo", "thumbnail", "usd_price", "usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_type"]) -> MetaOapg.properties.token_type: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["contract_address"]) -> MetaOapg.properties.contract_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance"]) -> MetaOapg.properties.balance: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance_formatted"]) -> MetaOapg.properties.balance_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> typing.Union[MetaOapg.properties.thumbnail, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_value"]) -> typing.Union[MetaOapg.properties.usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_type", "name", "symbol", "contract_address", "decimals", "balance", "balance_formatted", "logo", "thumbnail", "usd_price", "usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + symbol: typing.Union[MetaOapg.properties.symbol, str, ], + balance: typing.Union[MetaOapg.properties.balance, str, ], + balance_formatted: typing.Union[MetaOapg.properties.balance_formatted, str, ], + decimals: typing.Union[MetaOapg.properties.decimals, decimal.Decimal, int, float, ], + name: typing.Union[MetaOapg.properties.name, str, ], + contract_address: typing.Union[MetaOapg.properties.contract_address, str, ], + token_type: typing.Union[MetaOapg.properties.token_type, str, ], + logo: typing.Union[MetaOapg.properties.logo, str, schemas.Unset] = schemas.unset, + thumbnail: typing.Union[MetaOapg.properties.thumbnail, str, schemas.Unset] = schemas.unset, + usd_price: typing.Union[MetaOapg.properties.usd_price, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + usd_value: typing.Union[MetaOapg.properties.usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiTokenBalance': + return super().__new__( + cls, + *args, + symbol=symbol, + balance=balance, + balance_formatted=balance_formatted, + decimals=decimals, + name=name, + contract_address=contract_address, + token_type=token_type, + logo=logo, + thumbnail=thumbnail, + usd_price=usd_price, + usd_value=usd_value, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/defi_token_balance.pyi b/src/openapi_evm_api/model/defi_token_balance.pyi new file mode 100644 index 0000000..fd4a809 --- /dev/null +++ b/src/openapi_evm_api/model/defi_token_balance.pyi @@ -0,0 +1,196 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class DefiTokenBalance( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "symbol", + "balance", + "balance_formatted", + "decimals", + "name", + "contract_address", + "token_type", + } + + class properties: + token_type = schemas.StrSchema + name = schemas.StrSchema + symbol = schemas.StrSchema + contract_address = schemas.StrSchema + decimals = schemas.NumberSchema + balance = schemas.StrSchema + balance_formatted = schemas.StrSchema + logo = schemas.StrSchema + thumbnail = schemas.StrSchema + usd_price = schemas.NumberSchema + usd_value = schemas.NumberSchema + __annotations__ = { + "token_type": token_type, + "name": name, + "symbol": symbol, + "contract_address": contract_address, + "decimals": decimals, + "balance": balance, + "balance_formatted": balance_formatted, + "logo": logo, + "thumbnail": thumbnail, + "usd_price": usd_price, + "usd_value": usd_value, + } + + + symbol: MetaOapg.properties.symbol + balance: MetaOapg.properties.balance + balance_formatted: MetaOapg.properties.balance_formatted + decimals: MetaOapg.properties.decimals + name: MetaOapg.properties.name + contract_address: MetaOapg.properties.contract_address + token_type: MetaOapg.properties.token_type + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_type"]) -> MetaOapg.properties.token_type: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["contract_address"]) -> MetaOapg.properties.contract_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance"]) -> MetaOapg.properties.balance: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["balance_formatted"]) -> MetaOapg.properties.balance_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_value"]) -> MetaOapg.properties.usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_type", "name", "symbol", "contract_address", "decimals", "balance", "balance_formatted", "logo", "thumbnail", "usd_price", "usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_type"]) -> MetaOapg.properties.token_type: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["contract_address"]) -> MetaOapg.properties.contract_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance"]) -> MetaOapg.properties.balance: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["balance_formatted"]) -> MetaOapg.properties.balance_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> typing.Union[MetaOapg.properties.thumbnail, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_value"]) -> typing.Union[MetaOapg.properties.usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_type", "name", "symbol", "contract_address", "decimals", "balance", "balance_formatted", "logo", "thumbnail", "usd_price", "usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + symbol: typing.Union[MetaOapg.properties.symbol, str, ], + balance: typing.Union[MetaOapg.properties.balance, str, ], + balance_formatted: typing.Union[MetaOapg.properties.balance_formatted, str, ], + decimals: typing.Union[MetaOapg.properties.decimals, decimal.Decimal, int, float, ], + name: typing.Union[MetaOapg.properties.name, str, ], + contract_address: typing.Union[MetaOapg.properties.contract_address, str, ], + token_type: typing.Union[MetaOapg.properties.token_type, str, ], + logo: typing.Union[MetaOapg.properties.logo, str, schemas.Unset] = schemas.unset, + thumbnail: typing.Union[MetaOapg.properties.thumbnail, str, schemas.Unset] = schemas.unset, + usd_price: typing.Union[MetaOapg.properties.usd_price, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + usd_value: typing.Union[MetaOapg.properties.usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'DefiTokenBalance': + return super().__new__( + cls, + *args, + symbol=symbol, + balance=balance, + balance_formatted=balance_formatted, + decimals=decimals, + name=name, + contract_address=contract_address, + token_type=token_type, + logo=logo, + thumbnail=thumbnail, + usd_price=usd_price, + usd_value=usd_value, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/erc20_metadata.py b/src/openapi_evm_api/model/erc20_metadata.py index 8298a3f..3380c63 100644 --- a/src/openapi_evm_api/model/erc20_metadata.py +++ b/src/openapi_evm_api/model/erc20_metadata.py @@ -130,9 +130,69 @@ def __new__( *args, _configuration=_configuration, ) + total_supply = schemas.StrSchema + total_supply_formatted = schemas.StrSchema + fully_diluted_valuation = schemas.StrSchema block_number = schemas.StrSchema validated = schemas.NumberSchema verified_contract = schemas.BoolSchema + + + class categories( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + items = schemas.StrSchema + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'categories': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class links( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + additional_properties = schemas.StrSchema + + + def __getitem__(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + # dict_instance[name] accessor + return super().__getitem__(name) + + def get_item_oapg(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + return super().get_item_oapg(name) + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[MetaOapg.additional_properties, str, ], + ) -> 'links': + return super().__new__( + cls, + *args, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "address": address, "name": name, @@ -144,9 +204,14 @@ def __new__( "logo": logo, "logo_hash": logo_hash, "thumbnail": thumbnail, + "total_supply": total_supply, + "total_supply_formatted": total_supply_formatted, + "fully_diluted_valuation": fully_diluted_valuation, "block_number": block_number, "validated": validated, "verified_contract": verified_contract, + "categories": categories, + "links": links, } symbol: MetaOapg.properties.symbol @@ -186,6 +251,15 @@ def __getitem__(self, name: typing_extensions.Literal["logo_hash"]) -> MetaOapg. @typing.overload def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_supply"]) -> MetaOapg.properties.total_supply: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_supply_formatted"]) -> MetaOapg.properties.total_supply_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["fully_diluted_valuation"]) -> MetaOapg.properties.fully_diluted_valuation: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... @@ -195,10 +269,16 @@ def __getitem__(self, name: typing_extensions.Literal["validated"]) -> MetaOapg. @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> MetaOapg.properties.verified_contract: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["categories"]) -> MetaOapg.properties.categories: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["links"]) -> MetaOapg.properties.links: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "block_number", "validated", "verified_contract", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "total_supply", "total_supply_formatted", "fully_diluted_valuation", "block_number", "validated", "verified_contract", "categories", "links", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -233,6 +313,15 @@ def get_item_oapg(self, name: typing_extensions.Literal["logo_hash"]) -> typing. @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> typing.Union[MetaOapg.properties.thumbnail, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_supply"]) -> typing.Union[MetaOapg.properties.total_supply, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_supply_formatted"]) -> typing.Union[MetaOapg.properties.total_supply_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["fully_diluted_valuation"]) -> typing.Union[MetaOapg.properties.fully_diluted_valuation, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> typing.Union[MetaOapg.properties.block_number, schemas.Unset]: ... @@ -242,10 +331,16 @@ def get_item_oapg(self, name: typing_extensions.Literal["validated"]) -> typing. @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> typing.Union[MetaOapg.properties.verified_contract, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["categories"]) -> typing.Union[MetaOapg.properties.categories, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["links"]) -> typing.Union[MetaOapg.properties.links, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "block_number", "validated", "verified_contract", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "total_supply", "total_supply_formatted", "fully_diluted_valuation", "block_number", "validated", "verified_contract", "categories", "links", ], str]): return super().get_item_oapg(name) @@ -262,9 +357,14 @@ def __new__( logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, logo_hash: typing.Union[MetaOapg.properties.logo_hash, None, str, schemas.Unset] = schemas.unset, thumbnail: typing.Union[MetaOapg.properties.thumbnail, None, str, schemas.Unset] = schemas.unset, + total_supply: typing.Union[MetaOapg.properties.total_supply, str, schemas.Unset] = schemas.unset, + total_supply_formatted: typing.Union[MetaOapg.properties.total_supply_formatted, str, schemas.Unset] = schemas.unset, + fully_diluted_valuation: typing.Union[MetaOapg.properties.fully_diluted_valuation, str, schemas.Unset] = schemas.unset, block_number: typing.Union[MetaOapg.properties.block_number, str, schemas.Unset] = schemas.unset, validated: typing.Union[MetaOapg.properties.validated, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, schemas.Unset] = schemas.unset, + categories: typing.Union[MetaOapg.properties.categories, list, tuple, None, schemas.Unset] = schemas.unset, + links: typing.Union[MetaOapg.properties.links, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Erc20Metadata': @@ -281,9 +381,14 @@ def __new__( logo=logo, logo_hash=logo_hash, thumbnail=thumbnail, + total_supply=total_supply, + total_supply_formatted=total_supply_formatted, + fully_diluted_valuation=fully_diluted_valuation, block_number=block_number, validated=validated, verified_contract=verified_contract, + categories=categories, + links=links, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/erc20_metadata.pyi b/src/openapi_evm_api/model/erc20_metadata.pyi index 8298a3f..3380c63 100644 --- a/src/openapi_evm_api/model/erc20_metadata.pyi +++ b/src/openapi_evm_api/model/erc20_metadata.pyi @@ -130,9 +130,69 @@ class Erc20Metadata( *args, _configuration=_configuration, ) + total_supply = schemas.StrSchema + total_supply_formatted = schemas.StrSchema + fully_diluted_valuation = schemas.StrSchema block_number = schemas.StrSchema validated = schemas.NumberSchema verified_contract = schemas.BoolSchema + + + class categories( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + items = schemas.StrSchema + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'categories': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class links( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + additional_properties = schemas.StrSchema + + + def __getitem__(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + # dict_instance[name] accessor + return super().__getitem__(name) + + def get_item_oapg(self, name: typing.Union[str, ]) -> MetaOapg.additional_properties: + return super().get_item_oapg(name) + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[MetaOapg.additional_properties, str, ], + ) -> 'links': + return super().__new__( + cls, + *args, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "address": address, "name": name, @@ -144,9 +204,14 @@ class Erc20Metadata( "logo": logo, "logo_hash": logo_hash, "thumbnail": thumbnail, + "total_supply": total_supply, + "total_supply_formatted": total_supply_formatted, + "fully_diluted_valuation": fully_diluted_valuation, "block_number": block_number, "validated": validated, "verified_contract": verified_contract, + "categories": categories, + "links": links, } symbol: MetaOapg.properties.symbol @@ -186,6 +251,15 @@ class Erc20Metadata( @typing.overload def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_supply"]) -> MetaOapg.properties.total_supply: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_supply_formatted"]) -> MetaOapg.properties.total_supply_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["fully_diluted_valuation"]) -> MetaOapg.properties.fully_diluted_valuation: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... @@ -195,10 +269,16 @@ class Erc20Metadata( @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> MetaOapg.properties.verified_contract: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["categories"]) -> MetaOapg.properties.categories: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["links"]) -> MetaOapg.properties.links: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "block_number", "validated", "verified_contract", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "total_supply", "total_supply_formatted", "fully_diluted_valuation", "block_number", "validated", "verified_contract", "categories", "links", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -233,6 +313,15 @@ class Erc20Metadata( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> typing.Union[MetaOapg.properties.thumbnail, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_supply"]) -> typing.Union[MetaOapg.properties.total_supply, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_supply_formatted"]) -> typing.Union[MetaOapg.properties.total_supply_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["fully_diluted_valuation"]) -> typing.Union[MetaOapg.properties.fully_diluted_valuation, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> typing.Union[MetaOapg.properties.block_number, schemas.Unset]: ... @@ -242,10 +331,16 @@ class Erc20Metadata( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> typing.Union[MetaOapg.properties.verified_contract, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["categories"]) -> typing.Union[MetaOapg.properties.categories, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["links"]) -> typing.Union[MetaOapg.properties.links, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "block_number", "validated", "verified_contract", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "name", "symbol", "decimals", "created_at", "possible_spam", "address_label", "logo", "logo_hash", "thumbnail", "total_supply", "total_supply_formatted", "fully_diluted_valuation", "block_number", "validated", "verified_contract", "categories", "links", ], str]): return super().get_item_oapg(name) @@ -262,9 +357,14 @@ class Erc20Metadata( logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, logo_hash: typing.Union[MetaOapg.properties.logo_hash, None, str, schemas.Unset] = schemas.unset, thumbnail: typing.Union[MetaOapg.properties.thumbnail, None, str, schemas.Unset] = schemas.unset, + total_supply: typing.Union[MetaOapg.properties.total_supply, str, schemas.Unset] = schemas.unset, + total_supply_formatted: typing.Union[MetaOapg.properties.total_supply_formatted, str, schemas.Unset] = schemas.unset, + fully_diluted_valuation: typing.Union[MetaOapg.properties.fully_diluted_valuation, str, schemas.Unset] = schemas.unset, block_number: typing.Union[MetaOapg.properties.block_number, str, schemas.Unset] = schemas.unset, validated: typing.Union[MetaOapg.properties.validated, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, schemas.Unset] = schemas.unset, + categories: typing.Union[MetaOapg.properties.categories, list, tuple, None, schemas.Unset] = schemas.unset, + links: typing.Union[MetaOapg.properties.links, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Erc20Metadata': @@ -281,9 +381,14 @@ class Erc20Metadata( logo=logo, logo_hash=logo_hash, thumbnail=thumbnail, + total_supply=total_supply, + total_supply_formatted=total_supply_formatted, + fully_diluted_valuation=fully_diluted_valuation, block_number=block_number, validated=validated, verified_contract=verified_contract, + categories=categories, + links=links, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/erc20_price.py b/src/openapi_evm_api/model/erc20_price.py index 47edd9d..2a0e7e6 100644 --- a/src/openapi_evm_api/model/erc20_price.py +++ b/src/openapi_evm_api/model/erc20_price.py @@ -35,11 +35,15 @@ class Erc20Price( class MetaOapg: required = { + "verifiedContract", "usdPrice", + "possibleSpam", } class properties: usdPrice = schemas.Float64Schema + possibleSpam = schemas.BoolSchema + verifiedContract = schemas.BoolSchema tokenName = schemas.StrSchema tokenSymbol = schemas.StrSchema tokenLogo = schemas.StrSchema @@ -54,9 +58,12 @@ def nativePrice() -> typing.Type['NativeErc20Price']: exchangeName = schemas.StrSchema tokenAddress = schemas.StrSchema toBlock = schemas.StrSchema - verifiedContract = schemas.BoolSchema + pairAddress = schemas.StrSchema + pairTotalLiquidityUsd = schemas.StrSchema __annotations__ = { "usdPrice": usdPrice, + "possibleSpam": possibleSpam, + "verifiedContract": verifiedContract, "tokenName": tokenName, "tokenSymbol": tokenSymbol, "tokenLogo": tokenLogo, @@ -68,15 +75,24 @@ def nativePrice() -> typing.Type['NativeErc20Price']: "exchangeName": exchangeName, "tokenAddress": tokenAddress, "toBlock": toBlock, - "verifiedContract": verifiedContract, + "pairAddress": pairAddress, + "pairTotalLiquidityUsd": pairTotalLiquidityUsd, } + verifiedContract: MetaOapg.properties.verifiedContract usdPrice: MetaOapg.properties.usdPrice + possibleSpam: MetaOapg.properties.possibleSpam @typing.overload def __getitem__(self, name: typing_extensions.Literal["usdPrice"]) -> MetaOapg.properties.usdPrice: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possibleSpam"]) -> MetaOapg.properties.possibleSpam: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["tokenName"]) -> MetaOapg.properties.tokenName: ... @@ -111,12 +127,15 @@ def __getitem__(self, name: typing_extensions.Literal["tokenAddress"]) -> MetaOa def __getitem__(self, name: typing_extensions.Literal["toBlock"]) -> MetaOapg.properties.toBlock: ... @typing.overload - def __getitem__(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + def __getitem__(self, name: typing_extensions.Literal["pairAddress"]) -> MetaOapg.properties.pairAddress: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pairTotalLiquidityUsd"]) -> MetaOapg.properties.pairTotalLiquidityUsd: ... @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["usdPrice", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "verifiedContract", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["usdPrice", "possibleSpam", "verifiedContract", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "pairAddress", "pairTotalLiquidityUsd", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -124,6 +143,12 @@ def __getitem__(self, name: typing.Union[typing_extensions.Literal["usdPrice", " @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["usdPrice"]) -> MetaOapg.properties.usdPrice: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possibleSpam"]) -> MetaOapg.properties.possibleSpam: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["tokenName"]) -> typing.Union[MetaOapg.properties.tokenName, schemas.Unset]: ... @@ -158,19 +183,24 @@ def get_item_oapg(self, name: typing_extensions.Literal["tokenAddress"]) -> typi def get_item_oapg(self, name: typing_extensions.Literal["toBlock"]) -> typing.Union[MetaOapg.properties.toBlock, schemas.Unset]: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["verifiedContract"]) -> typing.Union[MetaOapg.properties.verifiedContract, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["pairAddress"]) -> typing.Union[MetaOapg.properties.pairAddress, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pairTotalLiquidityUsd"]) -> typing.Union[MetaOapg.properties.pairTotalLiquidityUsd, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["usdPrice", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "verifiedContract", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["usdPrice", "possibleSpam", "verifiedContract", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "pairAddress", "pairTotalLiquidityUsd", ], str]): return super().get_item_oapg(name) def __new__( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + verifiedContract: typing.Union[MetaOapg.properties.verifiedContract, bool, ], usdPrice: typing.Union[MetaOapg.properties.usdPrice, decimal.Decimal, int, float, ], + possibleSpam: typing.Union[MetaOapg.properties.possibleSpam, bool, ], tokenName: typing.Union[MetaOapg.properties.tokenName, str, schemas.Unset] = schemas.unset, tokenSymbol: typing.Union[MetaOapg.properties.tokenSymbol, str, schemas.Unset] = schemas.unset, tokenLogo: typing.Union[MetaOapg.properties.tokenLogo, str, schemas.Unset] = schemas.unset, @@ -181,14 +211,17 @@ def __new__( exchangeName: typing.Union[MetaOapg.properties.exchangeName, str, schemas.Unset] = schemas.unset, tokenAddress: typing.Union[MetaOapg.properties.tokenAddress, str, schemas.Unset] = schemas.unset, toBlock: typing.Union[MetaOapg.properties.toBlock, str, schemas.Unset] = schemas.unset, - verifiedContract: typing.Union[MetaOapg.properties.verifiedContract, bool, schemas.Unset] = schemas.unset, + pairAddress: typing.Union[MetaOapg.properties.pairAddress, str, schemas.Unset] = schemas.unset, + pairTotalLiquidityUsd: typing.Union[MetaOapg.properties.pairTotalLiquidityUsd, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Erc20Price': return super().__new__( cls, *args, + verifiedContract=verifiedContract, usdPrice=usdPrice, + possibleSpam=possibleSpam, tokenName=tokenName, tokenSymbol=tokenSymbol, tokenLogo=tokenLogo, @@ -199,7 +232,8 @@ def __new__( exchangeName=exchangeName, tokenAddress=tokenAddress, toBlock=toBlock, - verifiedContract=verifiedContract, + pairAddress=pairAddress, + pairTotalLiquidityUsd=pairTotalLiquidityUsd, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/erc20_price.pyi b/src/openapi_evm_api/model/erc20_price.pyi index 47edd9d..2a0e7e6 100644 --- a/src/openapi_evm_api/model/erc20_price.pyi +++ b/src/openapi_evm_api/model/erc20_price.pyi @@ -35,11 +35,15 @@ class Erc20Price( class MetaOapg: required = { + "verifiedContract", "usdPrice", + "possibleSpam", } class properties: usdPrice = schemas.Float64Schema + possibleSpam = schemas.BoolSchema + verifiedContract = schemas.BoolSchema tokenName = schemas.StrSchema tokenSymbol = schemas.StrSchema tokenLogo = schemas.StrSchema @@ -54,9 +58,12 @@ class Erc20Price( exchangeName = schemas.StrSchema tokenAddress = schemas.StrSchema toBlock = schemas.StrSchema - verifiedContract = schemas.BoolSchema + pairAddress = schemas.StrSchema + pairTotalLiquidityUsd = schemas.StrSchema __annotations__ = { "usdPrice": usdPrice, + "possibleSpam": possibleSpam, + "verifiedContract": verifiedContract, "tokenName": tokenName, "tokenSymbol": tokenSymbol, "tokenLogo": tokenLogo, @@ -68,15 +75,24 @@ class Erc20Price( "exchangeName": exchangeName, "tokenAddress": tokenAddress, "toBlock": toBlock, - "verifiedContract": verifiedContract, + "pairAddress": pairAddress, + "pairTotalLiquidityUsd": pairTotalLiquidityUsd, } + verifiedContract: MetaOapg.properties.verifiedContract usdPrice: MetaOapg.properties.usdPrice + possibleSpam: MetaOapg.properties.possibleSpam @typing.overload def __getitem__(self, name: typing_extensions.Literal["usdPrice"]) -> MetaOapg.properties.usdPrice: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possibleSpam"]) -> MetaOapg.properties.possibleSpam: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["tokenName"]) -> MetaOapg.properties.tokenName: ... @@ -111,12 +127,15 @@ class Erc20Price( def __getitem__(self, name: typing_extensions.Literal["toBlock"]) -> MetaOapg.properties.toBlock: ... @typing.overload - def __getitem__(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + def __getitem__(self, name: typing_extensions.Literal["pairAddress"]) -> MetaOapg.properties.pairAddress: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["pairTotalLiquidityUsd"]) -> MetaOapg.properties.pairTotalLiquidityUsd: ... @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["usdPrice", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "verifiedContract", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["usdPrice", "possibleSpam", "verifiedContract", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "pairAddress", "pairTotalLiquidityUsd", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -124,6 +143,12 @@ class Erc20Price( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["usdPrice"]) -> MetaOapg.properties.usdPrice: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possibleSpam"]) -> MetaOapg.properties.possibleSpam: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["verifiedContract"]) -> MetaOapg.properties.verifiedContract: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["tokenName"]) -> typing.Union[MetaOapg.properties.tokenName, schemas.Unset]: ... @@ -158,19 +183,24 @@ class Erc20Price( def get_item_oapg(self, name: typing_extensions.Literal["toBlock"]) -> typing.Union[MetaOapg.properties.toBlock, schemas.Unset]: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["verifiedContract"]) -> typing.Union[MetaOapg.properties.verifiedContract, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["pairAddress"]) -> typing.Union[MetaOapg.properties.pairAddress, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["pairTotalLiquidityUsd"]) -> typing.Union[MetaOapg.properties.pairTotalLiquidityUsd, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["usdPrice", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "verifiedContract", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["usdPrice", "possibleSpam", "verifiedContract", "tokenName", "tokenSymbol", "tokenLogo", "tokenDecimals", "nativePrice", "usdPriceFormatted", "24hrPercentChange", "exchangeAddress", "exchangeName", "tokenAddress", "toBlock", "pairAddress", "pairTotalLiquidityUsd", ], str]): return super().get_item_oapg(name) def __new__( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + verifiedContract: typing.Union[MetaOapg.properties.verifiedContract, bool, ], usdPrice: typing.Union[MetaOapg.properties.usdPrice, decimal.Decimal, int, float, ], + possibleSpam: typing.Union[MetaOapg.properties.possibleSpam, bool, ], tokenName: typing.Union[MetaOapg.properties.tokenName, str, schemas.Unset] = schemas.unset, tokenSymbol: typing.Union[MetaOapg.properties.tokenSymbol, str, schemas.Unset] = schemas.unset, tokenLogo: typing.Union[MetaOapg.properties.tokenLogo, str, schemas.Unset] = schemas.unset, @@ -181,14 +211,17 @@ class Erc20Price( exchangeName: typing.Union[MetaOapg.properties.exchangeName, str, schemas.Unset] = schemas.unset, tokenAddress: typing.Union[MetaOapg.properties.tokenAddress, str, schemas.Unset] = schemas.unset, toBlock: typing.Union[MetaOapg.properties.toBlock, str, schemas.Unset] = schemas.unset, - verifiedContract: typing.Union[MetaOapg.properties.verifiedContract, bool, schemas.Unset] = schemas.unset, + pairAddress: typing.Union[MetaOapg.properties.pairAddress, str, schemas.Unset] = schemas.unset, + pairTotalLiquidityUsd: typing.Union[MetaOapg.properties.pairTotalLiquidityUsd, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Erc20Price': return super().__new__( cls, *args, + verifiedContract=verifiedContract, usdPrice=usdPrice, + possibleSpam=possibleSpam, tokenName=tokenName, tokenSymbol=tokenSymbol, tokenLogo=tokenLogo, @@ -199,7 +232,8 @@ class Erc20Price( exchangeName=exchangeName, tokenAddress=tokenAddress, toBlock=toBlock, - verifiedContract=verifiedContract, + pairAddress=pairAddress, + pairTotalLiquidityUsd=pairTotalLiquidityUsd, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/erc20_transaction.py b/src/openapi_evm_api/model/erc20_transaction.py index 3a03778..2bb813a 100644 --- a/src/openapi_evm_api/model/erc20_transaction.py +++ b/src/openapi_evm_api/model/erc20_transaction.py @@ -38,7 +38,6 @@ class MetaOapg: "address", "block_hash", "block_number", - "to_address", "transaction_index", "log_index", "possible_spam", @@ -62,7 +61,6 @@ class properties: block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema value = schemas.StrSchema transaction_index = schemas.IntSchema @@ -70,6 +68,7 @@ class properties: possible_spam = schemas.BoolSchema verified_contract = schemas.BoolSchema token_logo = schemas.StrSchema + to_address = schemas.StrSchema class to_address_label( @@ -119,7 +118,6 @@ def __new__( "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, - "to_address": to_address, "from_address": from_address, "value": value, "transaction_index": transaction_index, @@ -127,6 +125,7 @@ def __new__( "possible_spam": possible_spam, "verified_contract": verified_contract, "token_logo": token_logo, + "to_address": to_address, "to_address_label": to_address_label, "from_address_label": from_address_label, } @@ -135,7 +134,6 @@ def __new__( address: MetaOapg.properties.address block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index log_index: MetaOapg.properties.log_index possible_spam: MetaOapg.properties.possible_spam @@ -173,9 +171,6 @@ def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOa @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -197,6 +192,9 @@ def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -206,7 +204,7 @@ def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address_label", "from_address_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address", "to_address_label", "from_address_label", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -235,9 +233,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> Meta @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -259,6 +254,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> typing.Union[MetaOapg.properties.token_logo, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -268,7 +266,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) - @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address_label", "from_address_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address", "to_address_label", "from_address_label", ], str]): return super().get_item_oapg(name) @@ -278,7 +276,6 @@ def __new__( address: typing.Union[MetaOapg.properties.address, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, decimal.Decimal, int, ], log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], @@ -292,6 +289,7 @@ def __new__( transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], value_decimal: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], token_logo: typing.Union[MetaOapg.properties.token_logo, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, @@ -303,7 +301,6 @@ def __new__( address=address, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, log_index=log_index, possible_spam=possible_spam, @@ -317,6 +314,7 @@ def __new__( transaction_hash=transaction_hash, value_decimal=value_decimal, token_logo=token_logo, + to_address=to_address, to_address_label=to_address_label, from_address_label=from_address_label, _configuration=_configuration, diff --git a/src/openapi_evm_api/model/erc20_transaction.pyi b/src/openapi_evm_api/model/erc20_transaction.pyi index 3a03778..2bb813a 100644 --- a/src/openapi_evm_api/model/erc20_transaction.pyi +++ b/src/openapi_evm_api/model/erc20_transaction.pyi @@ -38,7 +38,6 @@ class Erc20Transaction( "address", "block_hash", "block_number", - "to_address", "transaction_index", "log_index", "possible_spam", @@ -62,7 +61,6 @@ class Erc20Transaction( block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema value = schemas.StrSchema transaction_index = schemas.IntSchema @@ -70,6 +68,7 @@ class Erc20Transaction( possible_spam = schemas.BoolSchema verified_contract = schemas.BoolSchema token_logo = schemas.StrSchema + to_address = schemas.StrSchema class to_address_label( @@ -119,7 +118,6 @@ class Erc20Transaction( "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, - "to_address": to_address, "from_address": from_address, "value": value, "transaction_index": transaction_index, @@ -127,6 +125,7 @@ class Erc20Transaction( "possible_spam": possible_spam, "verified_contract": verified_contract, "token_logo": token_logo, + "to_address": to_address, "to_address_label": to_address_label, "from_address_label": from_address_label, } @@ -135,7 +134,6 @@ class Erc20Transaction( address: MetaOapg.properties.address block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index log_index: MetaOapg.properties.log_index possible_spam: MetaOapg.properties.possible_spam @@ -173,9 +171,6 @@ class Erc20Transaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -197,6 +192,9 @@ class Erc20Transaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -206,7 +204,7 @@ class Erc20Transaction( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address_label", "from_address_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address", "to_address_label", "from_address_label", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -235,9 +233,6 @@ class Erc20Transaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -259,6 +254,9 @@ class Erc20Transaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> typing.Union[MetaOapg.properties.token_logo, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -268,7 +266,7 @@ class Erc20Transaction( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address_label", "from_address_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_decimals", "transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "value", "transaction_index", "log_index", "possible_spam", "verified_contract", "token_logo", "to_address", "to_address_label", "from_address_label", ], str]): return super().get_item_oapg(name) @@ -278,7 +276,6 @@ class Erc20Transaction( address: typing.Union[MetaOapg.properties.address, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, decimal.Decimal, int, ], log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], @@ -292,6 +289,7 @@ class Erc20Transaction( transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], value_decimal: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], token_logo: typing.Union[MetaOapg.properties.token_logo, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, @@ -303,7 +301,6 @@ class Erc20Transaction( address=address, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, log_index=log_index, possible_spam=possible_spam, @@ -317,6 +314,7 @@ class Erc20Transaction( transaction_hash=transaction_hash, value_decimal=value_decimal, token_logo=token_logo, + to_address=to_address, to_address_label=to_address_label, from_address_label=from_address_label, _configuration=_configuration, diff --git a/src/openapi_evm_api/model/historical_nft_transfer.py b/src/openapi_evm_api/model/historical_nft_transfer.py index 0da7055..8401e30 100644 --- a/src/openapi_evm_api/model/historical_nft_transfer.py +++ b/src/openapi_evm_api/model/historical_nft_transfer.py @@ -42,7 +42,6 @@ class MetaOapg: "block_timestamp", "block_hash", "block_number", - "to_address", "from_address", "transaction_hash", } @@ -53,7 +52,6 @@ class properties: block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema @@ -102,17 +100,18 @@ def __new__( def __getitem__(self, i: int) -> MetaOapg.items: return super().__getitem__(i) contract_type = schemas.StrSchema + to_address = schemas.StrSchema __annotations__ = { "transaction_hash": transaction_hash, "address": address, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, - "to_address": to_address, "from_address": from_address, "token_ids": token_ids, "amounts": amounts, "contract_type": contract_type, + "to_address": to_address, } @@ -123,7 +122,6 @@ def __getitem__(self, i: int) -> MetaOapg.items: block_timestamp: MetaOapg.properties.block_timestamp block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address from_address: MetaOapg.properties.from_address transaction_hash: MetaOapg.properties.transaction_hash @@ -142,9 +140,6 @@ def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOa @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -157,10 +152,13 @@ def __getitem__(self, name: typing_extensions.Literal["amounts"]) -> MetaOapg.pr @typing.overload def __getitem__(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "token_ids", "amounts", "contract_type", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "token_ids", "amounts", "contract_type", "to_address", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -180,9 +178,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> Meta @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -195,10 +190,13 @@ def get_item_oapg(self, name: typing_extensions.Literal["amounts"]) -> MetaOapg. @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "token_ids", "amounts", "contract_type", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "token_ids", "amounts", "contract_type", "to_address", ], str]): return super().get_item_oapg(name) @@ -212,9 +210,9 @@ def __new__( block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'HistoricalNftTransfer': @@ -228,9 +226,9 @@ def __new__( block_timestamp=block_timestamp, block_hash=block_hash, block_number=block_number, - to_address=to_address, from_address=from_address, transaction_hash=transaction_hash, + to_address=to_address, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/historical_nft_transfer.pyi b/src/openapi_evm_api/model/historical_nft_transfer.pyi index 0da7055..8401e30 100644 --- a/src/openapi_evm_api/model/historical_nft_transfer.pyi +++ b/src/openapi_evm_api/model/historical_nft_transfer.pyi @@ -42,7 +42,6 @@ class HistoricalNftTransfer( "block_timestamp", "block_hash", "block_number", - "to_address", "from_address", "transaction_hash", } @@ -53,7 +52,6 @@ class HistoricalNftTransfer( block_timestamp = schemas.StrSchema block_number = schemas.StrSchema block_hash = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema @@ -102,17 +100,18 @@ class HistoricalNftTransfer( def __getitem__(self, i: int) -> MetaOapg.items: return super().__getitem__(i) contract_type = schemas.StrSchema + to_address = schemas.StrSchema __annotations__ = { "transaction_hash": transaction_hash, "address": address, "block_timestamp": block_timestamp, "block_number": block_number, "block_hash": block_hash, - "to_address": to_address, "from_address": from_address, "token_ids": token_ids, "amounts": amounts, "contract_type": contract_type, + "to_address": to_address, } @@ -123,7 +122,6 @@ class HistoricalNftTransfer( block_timestamp: MetaOapg.properties.block_timestamp block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address from_address: MetaOapg.properties.from_address transaction_hash: MetaOapg.properties.transaction_hash @@ -142,9 +140,6 @@ class HistoricalNftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -157,10 +152,13 @@ class HistoricalNftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "token_ids", "amounts", "contract_type", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "token_ids", "amounts", "contract_type", "to_address", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -180,9 +178,6 @@ class HistoricalNftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg.properties.block_hash: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -195,10 +190,13 @@ class HistoricalNftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "to_address", "from_address", "token_ids", "amounts", "contract_type", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "address", "block_timestamp", "block_number", "block_hash", "from_address", "token_ids", "amounts", "contract_type", "to_address", ], str]): return super().get_item_oapg(name) @@ -212,9 +210,9 @@ class HistoricalNftTransfer( block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'HistoricalNftTransfer': @@ -228,9 +226,9 @@ class HistoricalNftTransfer( block_timestamp=block_timestamp, block_hash=block_hash, block_number=block_number, - to_address=to_address, from_address=from_address, transaction_hash=transaction_hash, + to_address=to_address, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/net_worth_result.py b/src/openapi_evm_api/model/net_worth_result.py index b6d37b1..a0a7537 100644 --- a/src/openapi_evm_api/model/net_worth_result.py +++ b/src/openapi_evm_api/model/net_worth_result.py @@ -67,9 +67,33 @@ def __new__( def __getitem__(self, i: int) -> 'ChainNetWorth': return super().__getitem__(i) + + + class unsupported_chain_ids( + schemas.ListSchema + ): + + + class MetaOapg: + items = schemas.StrSchema + + def __new__( + cls, + arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, str, ]], typing.List[typing.Union[MetaOapg.items, str, ]]], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'unsupported_chain_ids': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> MetaOapg.items: + return super().__getitem__(i) __annotations__ = { "total_networth_usd": total_networth_usd, "chains": chains, + "unsupported_chain_ids": unsupported_chain_ids, } @@ -82,10 +106,13 @@ def __getitem__(self, name: typing_extensions.Literal["total_networth_usd"]) -> @typing.overload def __getitem__(self, name: typing_extensions.Literal["chains"]) -> MetaOapg.properties.chains: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["unsupported_chain_ids"]) -> MetaOapg.properties.unsupported_chain_ids: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", "unsupported_chain_ids", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -96,10 +123,13 @@ def get_item_oapg(self, name: typing_extensions.Literal["total_networth_usd"]) - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["chains"]) -> MetaOapg.properties.chains: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["unsupported_chain_ids"]) -> typing.Union[MetaOapg.properties.unsupported_chain_ids, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", "unsupported_chain_ids", ], str]): return super().get_item_oapg(name) @@ -108,6 +138,7 @@ def __new__( *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], chains: typing.Union[MetaOapg.properties.chains, list, tuple, ], total_networth_usd: typing.Union[MetaOapg.properties.total_networth_usd, str, ], + unsupported_chain_ids: typing.Union[MetaOapg.properties.unsupported_chain_ids, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'NetWorthResult': @@ -116,6 +147,7 @@ def __new__( *args, chains=chains, total_networth_usd=total_networth_usd, + unsupported_chain_ids=unsupported_chain_ids, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/net_worth_result.pyi b/src/openapi_evm_api/model/net_worth_result.pyi index b6d37b1..a0a7537 100644 --- a/src/openapi_evm_api/model/net_worth_result.pyi +++ b/src/openapi_evm_api/model/net_worth_result.pyi @@ -67,9 +67,33 @@ class NetWorthResult( def __getitem__(self, i: int) -> 'ChainNetWorth': return super().__getitem__(i) + + + class unsupported_chain_ids( + schemas.ListSchema + ): + + + class MetaOapg: + items = schemas.StrSchema + + def __new__( + cls, + arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, str, ]], typing.List[typing.Union[MetaOapg.items, str, ]]], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'unsupported_chain_ids': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> MetaOapg.items: + return super().__getitem__(i) __annotations__ = { "total_networth_usd": total_networth_usd, "chains": chains, + "unsupported_chain_ids": unsupported_chain_ids, } @@ -82,10 +106,13 @@ class NetWorthResult( @typing.overload def __getitem__(self, name: typing_extensions.Literal["chains"]) -> MetaOapg.properties.chains: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["unsupported_chain_ids"]) -> MetaOapg.properties.unsupported_chain_ids: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", "unsupported_chain_ids", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -96,10 +123,13 @@ class NetWorthResult( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["chains"]) -> MetaOapg.properties.chains: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["unsupported_chain_ids"]) -> typing.Union[MetaOapg.properties.unsupported_chain_ids, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_networth_usd", "chains", "unsupported_chain_ids", ], str]): return super().get_item_oapg(name) @@ -108,6 +138,7 @@ class NetWorthResult( *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], chains: typing.Union[MetaOapg.properties.chains, list, tuple, ], total_networth_usd: typing.Union[MetaOapg.properties.total_networth_usd, str, ], + unsupported_chain_ids: typing.Union[MetaOapg.properties.unsupported_chain_ids, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'NetWorthResult': @@ -116,6 +147,7 @@ class NetWorthResult( *args, chains=chains, total_networth_usd=total_networth_usd, + unsupported_chain_ids=unsupported_chain_ids, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/nft.py b/src/openapi_evm_api/model/nft.py index 7d93ca0..29d523b 100644 --- a/src/openapi_evm_api/model/nft.py +++ b/src/openapi_evm_api/model/nft.py @@ -69,6 +69,173 @@ def media() -> typing.Type['Media']: last_metadata_sync = schemas.StrSchema amount = schemas.StrSchema verified_collection = schemas.BoolSchema + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "price": price, + "price_formatted": price_formatted, + "usd_price": usd_price, + "buyer_address": buyer_address, + "seller_address": seller_address, + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price: typing.Union[MetaOapg.properties.usd_price, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price=usd_price, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "token_address": token_address, "token_id": token_id, @@ -89,6 +256,7 @@ def media() -> typing.Type['Media']: "last_metadata_sync": last_metadata_sync, "amount": amount, "verified_collection": verified_collection, + "last_sale": last_sale, } @@ -156,10 +324,13 @@ def __getitem__(self, name: typing_extensions.Literal["amount"]) -> MetaOapg.pro @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_collection"]) -> MetaOapg.properties.verified_collection: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", "last_sale", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -221,10 +392,13 @@ def get_item_oapg(self, name: typing_extensions.Literal["amount"]) -> typing.Uni @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_collection"]) -> typing.Union[MetaOapg.properties.verified_collection, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> typing.Union[MetaOapg.properties.last_sale, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", "last_sale", ], str]): return super().get_item_oapg(name) @@ -250,6 +424,7 @@ def __new__( last_metadata_sync: typing.Union[MetaOapg.properties.last_metadata_sync, str, schemas.Unset] = schemas.unset, amount: typing.Union[MetaOapg.properties.amount, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Nft': @@ -275,6 +450,7 @@ def __new__( last_metadata_sync=last_metadata_sync, amount=amount, verified_collection=verified_collection, + last_sale=last_sale, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/nft.pyi b/src/openapi_evm_api/model/nft.pyi index 7d93ca0..29d523b 100644 --- a/src/openapi_evm_api/model/nft.pyi +++ b/src/openapi_evm_api/model/nft.pyi @@ -69,6 +69,173 @@ class Nft( last_metadata_sync = schemas.StrSchema amount = schemas.StrSchema verified_collection = schemas.BoolSchema + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "price": price, + "price_formatted": price_formatted, + "usd_price": usd_price, + "buyer_address": buyer_address, + "seller_address": seller_address, + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price: typing.Union[MetaOapg.properties.usd_price, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price=usd_price, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "token_address": token_address, "token_id": token_id, @@ -89,6 +256,7 @@ class Nft( "last_metadata_sync": last_metadata_sync, "amount": amount, "verified_collection": verified_collection, + "last_sale": last_sale, } @@ -156,10 +324,13 @@ class Nft( @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_collection"]) -> MetaOapg.properties.verified_collection: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", "last_sale", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -221,10 +392,13 @@ class Nft( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_collection"]) -> typing.Union[MetaOapg.properties.verified_collection, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> typing.Union[MetaOapg.properties.last_sale, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "name", "symbol", "possible_spam", "owner_of", "token_hash", "block_number", "block_number_minted", "token_uri", "metadata", "normalized_metadata", "media", "minter_address", "last_token_uri_sync", "last_metadata_sync", "amount", "verified_collection", "last_sale", ], str]): return super().get_item_oapg(name) @@ -250,6 +424,7 @@ class Nft( last_metadata_sync: typing.Union[MetaOapg.properties.last_metadata_sync, str, schemas.Unset] = schemas.unset, amount: typing.Union[MetaOapg.properties.amount, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'Nft': @@ -275,6 +450,7 @@ class Nft( last_metadata_sync=last_metadata_sync, amount=amount, verified_collection=verified_collection, + last_sale=last_sale, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/nft_trades_chain_list.py b/src/openapi_evm_api/model/nft_trades_chain_list.py new file mode 100644 index 0000000..67f2c03 --- /dev/null +++ b/src/openapi_evm_api/model/nft_trades_chain_list.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class NftTradesChainList( + schemas.EnumBase, + schemas.StrSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + enum_value_to_name = { + "eth": "ETH", + "0x1": "X1", + "polygon": "POLYGON", + "0x89": "X89", + "bsc": "BSC", + "0x38": "X38", + "avalanche": "AVALANCHE", + "0xa86a": "XA86A", + "arbitrum": "ARBITRUM", + "0xa4b1": "XA4B1", + "base": "BASE", + "0x2105": "X2105", + "optimism": "OPTIMISM", + "0xa": "XA", + } + + @schemas.classproperty + def ETH(cls): + return cls("eth") + + @schemas.classproperty + def X1(cls): + return cls("0x1") + + @schemas.classproperty + def POLYGON(cls): + return cls("polygon") + + @schemas.classproperty + def X89(cls): + return cls("0x89") + + @schemas.classproperty + def BSC(cls): + return cls("bsc") + + @schemas.classproperty + def X38(cls): + return cls("0x38") + + @schemas.classproperty + def AVALANCHE(cls): + return cls("avalanche") + + @schemas.classproperty + def XA86A(cls): + return cls("0xa86a") + + @schemas.classproperty + def ARBITRUM(cls): + return cls("arbitrum") + + @schemas.classproperty + def XA4B1(cls): + return cls("0xa4b1") + + @schemas.classproperty + def BASE(cls): + return cls("base") + + @schemas.classproperty + def X2105(cls): + return cls("0x2105") + + @schemas.classproperty + def OPTIMISM(cls): + return cls("optimism") + + @schemas.classproperty + def XA(cls): + return cls("0xa") diff --git a/src/openapi_evm_api/model/nft_trades_chain_list.pyi b/src/openapi_evm_api/model/nft_trades_chain_list.pyi new file mode 100644 index 0000000..ed542ca --- /dev/null +++ b/src/openapi_evm_api/model/nft_trades_chain_list.pyi @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class NftTradesChainList( + schemas.EnumBase, + schemas.StrSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + @schemas.classproperty + def ETH(cls): + return cls("eth") + + @schemas.classproperty + def X1(cls): + return cls("0x1") + + @schemas.classproperty + def POLYGON(cls): + return cls("polygon") + + @schemas.classproperty + def X89(cls): + return cls("0x89") + + @schemas.classproperty + def BSC(cls): + return cls("bsc") + + @schemas.classproperty + def X38(cls): + return cls("0x38") + + @schemas.classproperty + def AVALANCHE(cls): + return cls("avalanche") + + @schemas.classproperty + def XA86A(cls): + return cls("0xa86a") + + @schemas.classproperty + def ARBITRUM(cls): + return cls("arbitrum") + + @schemas.classproperty + def XA4B1(cls): + return cls("0xa4b1") + + @schemas.classproperty + def BASE(cls): + return cls("base") + + @schemas.classproperty + def X2105(cls): + return cls("0x2105") + + @schemas.classproperty + def OPTIMISM(cls): + return cls("optimism") + + @schemas.classproperty + def XA(cls): + return cls("0xa") diff --git a/src/openapi_evm_api/model/nft_transfer.py b/src/openapi_evm_api/model/nft_transfer.py index 32b1b11..914035d 100644 --- a/src/openapi_evm_api/model/nft_transfer.py +++ b/src/openapi_evm_api/model/nft_transfer.py @@ -41,7 +41,6 @@ class MetaOapg: "block_timestamp", "block_hash", "block_number", - "to_address", "token_address", "log_index", "transaction_hash", @@ -50,7 +49,6 @@ class MetaOapg: class properties: token_address = schemas.StrSchema token_id = schemas.StrSchema - to_address = schemas.StrSchema contract_type = schemas.StrSchema block_number = schemas.StrSchema block_timestamp = schemas.StrSchema @@ -79,6 +77,7 @@ def __new__( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -105,10 +104,238 @@ def __new__( transaction_index = schemas.IntSchema operator = schemas.StrSchema verified_collection = schemas.BoolSchema + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "payment_token", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "price": price, + "price_formatted": price_formatted, + "usd_price": usd_price, + "buyer_address": buyer_address, + "seller_address": seller_address, + "payment_token": payment_token, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price: typing.Union[MetaOapg.properties.usd_price, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price=usd_price, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "token_address": token_address, "token_id": token_id, - "to_address": to_address, "contract_type": contract_type, "block_number": block_number, "block_timestamp": block_timestamp, @@ -118,6 +345,7 @@ def __new__( "possible_spam": possible_spam, "from_address": from_address, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "value": value, "amount": amount, @@ -125,6 +353,7 @@ def __new__( "transaction_index": transaction_index, "operator": operator, "verified_collection": verified_collection, + "last_sale": last_sale, } @@ -134,7 +363,6 @@ def __new__( block_timestamp: MetaOapg.properties.block_timestamp block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address token_address: MetaOapg.properties.token_address log_index: MetaOapg.properties.log_index transaction_hash: MetaOapg.properties.transaction_hash @@ -145,9 +373,6 @@ def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaO @typing.overload def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... @@ -175,6 +400,9 @@ def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOa @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -196,10 +424,13 @@ def __getitem__(self, name: typing_extensions.Literal["operator"]) -> MetaOapg.p @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_collection"]) -> MetaOapg.properties.verified_collection: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "to_address", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", "last_sale", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -210,9 +441,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> Met @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... @@ -240,6 +468,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> typi @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -261,10 +492,13 @@ def get_item_oapg(self, name: typing_extensions.Literal["operator"]) -> typing.U @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_collection"]) -> typing.Union[MetaOapg.properties.verified_collection, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> typing.Union[MetaOapg.properties.last_sale, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "to_address", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", "last_sale", ], str]): return super().get_item_oapg(name) @@ -277,12 +511,12 @@ def __new__( block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], token_address: typing.Union[MetaOapg.properties.token_address, str, ], log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, value: typing.Union[MetaOapg.properties.value, str, schemas.Unset] = schemas.unset, amount: typing.Union[MetaOapg.properties.amount, str, schemas.Unset] = schemas.unset, @@ -290,6 +524,7 @@ def __new__( transaction_index: typing.Union[MetaOapg.properties.transaction_index, decimal.Decimal, int, schemas.Unset] = schemas.unset, operator: typing.Union[MetaOapg.properties.operator, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'NftTransfer': @@ -302,12 +537,12 @@ def __new__( block_timestamp=block_timestamp, block_hash=block_hash, block_number=block_number, - to_address=to_address, token_address=token_address, log_index=log_index, transaction_hash=transaction_hash, from_address=from_address, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, value=value, amount=amount, @@ -315,6 +550,7 @@ def __new__( transaction_index=transaction_index, operator=operator, verified_collection=verified_collection, + last_sale=last_sale, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/nft_transfer.pyi b/src/openapi_evm_api/model/nft_transfer.pyi index 32b1b11..914035d 100644 --- a/src/openapi_evm_api/model/nft_transfer.pyi +++ b/src/openapi_evm_api/model/nft_transfer.pyi @@ -41,7 +41,6 @@ class NftTransfer( "block_timestamp", "block_hash", "block_number", - "to_address", "token_address", "log_index", "transaction_hash", @@ -50,7 +49,6 @@ class NftTransfer( class properties: token_address = schemas.StrSchema token_id = schemas.StrSchema - to_address = schemas.StrSchema contract_type = schemas.StrSchema block_number = schemas.StrSchema block_timestamp = schemas.StrSchema @@ -79,6 +77,7 @@ class NftTransfer( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -105,10 +104,238 @@ class NftTransfer( transaction_index = schemas.IntSchema operator = schemas.StrSchema verified_collection = schemas.BoolSchema + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "payment_token", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "price": price, + "price_formatted": price_formatted, + "usd_price": usd_price, + "buyer_address": buyer_address, + "seller_address": seller_address, + "payment_token": payment_token, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "price", "price_formatted", "usd_price", "buyer_address", "seller_address", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price: typing.Union[MetaOapg.properties.usd_price, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price=usd_price, + _configuration=_configuration, + **kwargs, + ) __annotations__ = { "token_address": token_address, "token_id": token_id, - "to_address": to_address, "contract_type": contract_type, "block_number": block_number, "block_timestamp": block_timestamp, @@ -118,6 +345,7 @@ class NftTransfer( "possible_spam": possible_spam, "from_address": from_address, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "value": value, "amount": amount, @@ -125,6 +353,7 @@ class NftTransfer( "transaction_index": transaction_index, "operator": operator, "verified_collection": verified_collection, + "last_sale": last_sale, } @@ -134,7 +363,6 @@ class NftTransfer( block_timestamp: MetaOapg.properties.block_timestamp block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address token_address: MetaOapg.properties.token_address log_index: MetaOapg.properties.log_index transaction_hash: MetaOapg.properties.transaction_hash @@ -145,9 +373,6 @@ class NftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... @@ -175,6 +400,9 @@ class NftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -196,10 +424,13 @@ class NftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["verified_collection"]) -> MetaOapg.properties.verified_collection: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "to_address", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", "last_sale", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -210,9 +441,6 @@ class NftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["contract_type"]) -> MetaOapg.properties.contract_type: ... @@ -240,6 +468,9 @@ class NftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -261,10 +492,13 @@ class NftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["verified_collection"]) -> typing.Union[MetaOapg.properties.verified_collection, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> typing.Union[MetaOapg.properties.last_sale, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "to_address", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "contract_type", "block_number", "block_timestamp", "block_hash", "transaction_hash", "log_index", "possible_spam", "from_address", "from_address_label", "to_address", "to_address_label", "value", "amount", "transaction_type", "transaction_index", "operator", "verified_collection", "last_sale", ], str]): return super().get_item_oapg(name) @@ -277,12 +511,12 @@ class NftTransfer( block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], token_address: typing.Union[MetaOapg.properties.token_address, str, ], log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, value: typing.Union[MetaOapg.properties.value, str, schemas.Unset] = schemas.unset, amount: typing.Union[MetaOapg.properties.amount, str, schemas.Unset] = schemas.unset, @@ -290,6 +524,7 @@ class NftTransfer( transaction_index: typing.Union[MetaOapg.properties.transaction_index, decimal.Decimal, int, schemas.Unset] = schemas.unset, operator: typing.Union[MetaOapg.properties.operator, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'NftTransfer': @@ -302,12 +537,12 @@ class NftTransfer( block_timestamp=block_timestamp, block_hash=block_hash, block_number=block_number, - to_address=to_address, token_address=token_address, log_index=log_index, transaction_hash=transaction_hash, from_address=from_address, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, value=value, amount=amount, @@ -315,6 +550,7 @@ class NftTransfer( transaction_index=transaction_index, operator=operator, verified_collection=verified_collection, + last_sale=last_sale, _configuration=_configuration, **kwargs, ) diff --git a/src/openapi_evm_api/model/ohlc_candles.py b/src/openapi_evm_api/model/ohlc_candles.py deleted file mode 100644 index 0f5eec9..0000000 --- a/src/openapi_evm_api/model/ohlc_candles.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 - - -class OhlcCandles( - schemas.ListSchema -): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - - class MetaOapg: - - - class items( - schemas.AnyTypeSchema, - ): - - - class MetaOapg: - required = { - "volume", - "high", - "low", - "trades", - "close", - "open", - "timestamp", - } - - class properties: - timestamp = schemas.StrSchema - open = schemas.NumberSchema - high = schemas.NumberSchema - low = schemas.NumberSchema - close = schemas.NumberSchema - volume = schemas.NumberSchema - trades = schemas.NumberSchema - __annotations__ = { - "timestamp": timestamp, - "open": open, - "high": high, - "low": low, - "close": close, - "volume": volume, - "trades": trades, - } - - - volume: MetaOapg.properties.volume - high: MetaOapg.properties.high - low: MetaOapg.properties.low - trades: MetaOapg.properties.trades - close: MetaOapg.properties.close - open: MetaOapg.properties.open - timestamp: MetaOapg.properties.timestamp - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["open"]) -> MetaOapg.properties.open: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["high"]) -> MetaOapg.properties.high: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["low"]) -> MetaOapg.properties.low: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["close"]) -> MetaOapg.properties.close: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["volume"]) -> MetaOapg.properties.volume: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["trades"]) -> MetaOapg.properties.trades: ... - - @typing.overload - def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - - def __getitem__(self, name: typing.Union[typing_extensions.Literal["timestamp", "open", "high", "low", "close", "volume", "trades", ], str]): - # dict_instance[name] accessor - return super().__getitem__(name) - - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["open"]) -> MetaOapg.properties.open: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["high"]) -> MetaOapg.properties.high: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["low"]) -> MetaOapg.properties.low: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["close"]) -> MetaOapg.properties.close: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["volume"]) -> MetaOapg.properties.volume: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["trades"]) -> MetaOapg.properties.trades: ... - - @typing.overload - def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["timestamp", "open", "high", "low", "close", "volume", "trades", ], str]): - return super().get_item_oapg(name) - - - def __new__( - cls, - *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - volume: typing.Union[MetaOapg.properties.volume, decimal.Decimal, int, float, ], - high: typing.Union[MetaOapg.properties.high, decimal.Decimal, int, float, ], - low: typing.Union[MetaOapg.properties.low, decimal.Decimal, int, float, ], - trades: typing.Union[MetaOapg.properties.trades, decimal.Decimal, int, float, ], - close: typing.Union[MetaOapg.properties.close, decimal.Decimal, int, float, ], - open: typing.Union[MetaOapg.properties.open, decimal.Decimal, int, float, ], - timestamp: typing.Union[MetaOapg.properties.timestamp, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'items': - return super().__new__( - cls, - *args, - volume=volume, - high=high, - low=low, - trades=trades, - close=close, - open=open, - timestamp=timestamp, - _configuration=_configuration, - **kwargs, - ) - - def __new__( - cls, - arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ]], typing.List[typing.Union[MetaOapg.items, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ]]], - _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'OhlcCandles': - return super().__new__( - cls, - arg, - _configuration=_configuration, - ) - - def __getitem__(self, i: int) -> MetaOapg.items: - return super().__getitem__(i) diff --git a/src/openapi_evm_api/model/ohlc_candles.pyi b/src/openapi_evm_api/model/ohlc_candles.pyi deleted file mode 100644 index 0f5eec9..0000000 --- a/src/openapi_evm_api/model/ohlc_candles.pyi +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 - - -class OhlcCandles( - schemas.ListSchema -): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - - class MetaOapg: - - - class items( - schemas.AnyTypeSchema, - ): - - - class MetaOapg: - required = { - "volume", - "high", - "low", - "trades", - "close", - "open", - "timestamp", - } - - class properties: - timestamp = schemas.StrSchema - open = schemas.NumberSchema - high = schemas.NumberSchema - low = schemas.NumberSchema - close = schemas.NumberSchema - volume = schemas.NumberSchema - trades = schemas.NumberSchema - __annotations__ = { - "timestamp": timestamp, - "open": open, - "high": high, - "low": low, - "close": close, - "volume": volume, - "trades": trades, - } - - - volume: MetaOapg.properties.volume - high: MetaOapg.properties.high - low: MetaOapg.properties.low - trades: MetaOapg.properties.trades - close: MetaOapg.properties.close - open: MetaOapg.properties.open - timestamp: MetaOapg.properties.timestamp - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["open"]) -> MetaOapg.properties.open: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["high"]) -> MetaOapg.properties.high: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["low"]) -> MetaOapg.properties.low: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["close"]) -> MetaOapg.properties.close: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["volume"]) -> MetaOapg.properties.volume: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["trades"]) -> MetaOapg.properties.trades: ... - - @typing.overload - def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - - def __getitem__(self, name: typing.Union[typing_extensions.Literal["timestamp", "open", "high", "low", "close", "volume", "trades", ], str]): - # dict_instance[name] accessor - return super().__getitem__(name) - - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["open"]) -> MetaOapg.properties.open: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["high"]) -> MetaOapg.properties.high: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["low"]) -> MetaOapg.properties.low: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["close"]) -> MetaOapg.properties.close: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["volume"]) -> MetaOapg.properties.volume: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["trades"]) -> MetaOapg.properties.trades: ... - - @typing.overload - def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["timestamp", "open", "high", "low", "close", "volume", "trades", ], str]): - return super().get_item_oapg(name) - - - def __new__( - cls, - *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - volume: typing.Union[MetaOapg.properties.volume, decimal.Decimal, int, float, ], - high: typing.Union[MetaOapg.properties.high, decimal.Decimal, int, float, ], - low: typing.Union[MetaOapg.properties.low, decimal.Decimal, int, float, ], - trades: typing.Union[MetaOapg.properties.trades, decimal.Decimal, int, float, ], - close: typing.Union[MetaOapg.properties.close, decimal.Decimal, int, float, ], - open: typing.Union[MetaOapg.properties.open, decimal.Decimal, int, float, ], - timestamp: typing.Union[MetaOapg.properties.timestamp, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'items': - return super().__new__( - cls, - *args, - volume=volume, - high=high, - low=low, - trades=trades, - close=close, - open=open, - timestamp=timestamp, - _configuration=_configuration, - **kwargs, - ) - - def __new__( - cls, - arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ]], typing.List[typing.Union[MetaOapg.items, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ]]], - _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'OhlcCandles': - return super().__new__( - cls, - arg, - _configuration=_configuration, - ) - - def __getitem__(self, i: int) -> MetaOapg.items: - return super().__getitem__(i) diff --git a/src/openapi_evm_api/model/ohlc_interval_list.py b/src/openapi_evm_api/model/ohlc_interval_list.py deleted file mode 100644 index e25c167..0000000 --- a/src/openapi_evm_api/model/ohlc_interval_list.py +++ /dev/null @@ -1,24 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 -OhlcIntervalList = schemas.StrSchema diff --git a/src/openapi_evm_api/model/ohlc_interval_list.pyi b/src/openapi_evm_api/model/ohlc_interval_list.pyi deleted file mode 100644 index e25c167..0000000 --- a/src/openapi_evm_api/model/ohlc_interval_list.pyi +++ /dev/null @@ -1,24 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 -OhlcIntervalList = schemas.StrSchema diff --git a/src/openapi_evm_api/model/ohlc_result.py b/src/openapi_evm_api/model/ohlc_result.py deleted file mode 100644 index b1c910d..0000000 --- a/src/openapi_evm_api/model/ohlc_result.py +++ /dev/null @@ -1,148 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 - - -class OhlcResult( - schemas.DictSchema -): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - - class MetaOapg: - required = { - "pair_label", - "candles", - "exchange", - "interval", - "quote_currency", - "pair_address", - } - - class properties: - pair_address = schemas.StrSchema - pair_label = schemas.StrSchema - exchange = schemas.StrSchema - quote_currency = schemas.StrSchema - interval = schemas.StrSchema - - @staticmethod - def candles() -> typing.Type['OhlcCandles']: - return OhlcCandles - __annotations__ = { - "pair_address": pair_address, - "pair_label": pair_label, - "exchange": exchange, - "quote_currency": quote_currency, - "interval": interval, - "candles": candles, - } - - pair_label: MetaOapg.properties.pair_label - candles: 'OhlcCandles' - exchange: MetaOapg.properties.exchange - interval: MetaOapg.properties.interval - quote_currency: MetaOapg.properties.quote_currency - pair_address: MetaOapg.properties.pair_address - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["pair_address"]) -> MetaOapg.properties.pair_address: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["pair_label"]) -> MetaOapg.properties.pair_label: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["exchange"]) -> MetaOapg.properties.exchange: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["quote_currency"]) -> MetaOapg.properties.quote_currency: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["interval"]) -> MetaOapg.properties.interval: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["candles"]) -> 'OhlcCandles': ... - - @typing.overload - def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - - def __getitem__(self, name: typing.Union[typing_extensions.Literal["pair_address", "pair_label", "exchange", "quote_currency", "interval", "candles", ], str]): - # dict_instance[name] accessor - return super().__getitem__(name) - - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["pair_address"]) -> MetaOapg.properties.pair_address: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["pair_label"]) -> MetaOapg.properties.pair_label: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["exchange"]) -> MetaOapg.properties.exchange: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["quote_currency"]) -> MetaOapg.properties.quote_currency: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["interval"]) -> MetaOapg.properties.interval: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["candles"]) -> 'OhlcCandles': ... - - @typing.overload - def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["pair_address", "pair_label", "exchange", "quote_currency", "interval", "candles", ], str]): - return super().get_item_oapg(name) - - - def __new__( - cls, - *args: typing.Union[dict, frozendict.frozendict, ], - pair_label: typing.Union[MetaOapg.properties.pair_label, str, ], - candles: 'OhlcCandles', - exchange: typing.Union[MetaOapg.properties.exchange, str, ], - interval: typing.Union[MetaOapg.properties.interval, str, ], - quote_currency: typing.Union[MetaOapg.properties.quote_currency, str, ], - pair_address: typing.Union[MetaOapg.properties.pair_address, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'OhlcResult': - return super().__new__( - cls, - *args, - pair_label=pair_label, - candles=candles, - exchange=exchange, - interval=interval, - quote_currency=quote_currency, - pair_address=pair_address, - _configuration=_configuration, - **kwargs, - ) - -from openapi_evm_api.model.ohlc_candles import OhlcCandles diff --git a/src/openapi_evm_api/model/ohlc_result.pyi b/src/openapi_evm_api/model/ohlc_result.pyi deleted file mode 100644 index b1c910d..0000000 --- a/src/openapi_evm_api/model/ohlc_result.pyi +++ /dev/null @@ -1,148 +0,0 @@ -# coding: utf-8 - -""" - EVM API - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: 2.2 - Generated by: https://openapi-generator.tech -""" - -from datetime import date, datetime # noqa: F401 -import decimal # noqa: F401 -import functools # noqa: F401 -import io # noqa: F401 -import re # noqa: F401 -import typing # noqa: F401 -import typing_extensions # noqa: F401 -import uuid # noqa: F401 - -import frozendict # noqa: F401 - -from openapi_evm_api import schemas # noqa: F401 - - -class OhlcResult( - schemas.DictSchema -): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - - class MetaOapg: - required = { - "pair_label", - "candles", - "exchange", - "interval", - "quote_currency", - "pair_address", - } - - class properties: - pair_address = schemas.StrSchema - pair_label = schemas.StrSchema - exchange = schemas.StrSchema - quote_currency = schemas.StrSchema - interval = schemas.StrSchema - - @staticmethod - def candles() -> typing.Type['OhlcCandles']: - return OhlcCandles - __annotations__ = { - "pair_address": pair_address, - "pair_label": pair_label, - "exchange": exchange, - "quote_currency": quote_currency, - "interval": interval, - "candles": candles, - } - - pair_label: MetaOapg.properties.pair_label - candles: 'OhlcCandles' - exchange: MetaOapg.properties.exchange - interval: MetaOapg.properties.interval - quote_currency: MetaOapg.properties.quote_currency - pair_address: MetaOapg.properties.pair_address - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["pair_address"]) -> MetaOapg.properties.pair_address: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["pair_label"]) -> MetaOapg.properties.pair_label: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["exchange"]) -> MetaOapg.properties.exchange: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["quote_currency"]) -> MetaOapg.properties.quote_currency: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["interval"]) -> MetaOapg.properties.interval: ... - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["candles"]) -> 'OhlcCandles': ... - - @typing.overload - def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - - def __getitem__(self, name: typing.Union[typing_extensions.Literal["pair_address", "pair_label", "exchange", "quote_currency", "interval", "candles", ], str]): - # dict_instance[name] accessor - return super().__getitem__(name) - - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["pair_address"]) -> MetaOapg.properties.pair_address: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["pair_label"]) -> MetaOapg.properties.pair_label: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["exchange"]) -> MetaOapg.properties.exchange: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["quote_currency"]) -> MetaOapg.properties.quote_currency: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["interval"]) -> MetaOapg.properties.interval: ... - - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["candles"]) -> 'OhlcCandles': ... - - @typing.overload - def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["pair_address", "pair_label", "exchange", "quote_currency", "interval", "candles", ], str]): - return super().get_item_oapg(name) - - - def __new__( - cls, - *args: typing.Union[dict, frozendict.frozendict, ], - pair_label: typing.Union[MetaOapg.properties.pair_label, str, ], - candles: 'OhlcCandles', - exchange: typing.Union[MetaOapg.properties.exchange, str, ], - interval: typing.Union[MetaOapg.properties.interval, str, ], - quote_currency: typing.Union[MetaOapg.properties.quote_currency, str, ], - pair_address: typing.Union[MetaOapg.properties.pair_address, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'OhlcResult': - return super().__new__( - cls, - *args, - pair_label=pair_label, - candles=candles, - exchange=exchange, - interval=interval, - quote_currency=quote_currency, - pair_address=pair_address, - _configuration=_configuration, - **kwargs, - ) - -from openapi_evm_api.model.ohlc_candles import OhlcCandles diff --git a/src/openapi_evm_api/model/resolve_contract_interaction_response.py b/src/openapi_evm_api/model/resolve_contract_interaction_response.py new file mode 100644 index 0000000..92298cf --- /dev/null +++ b/src/openapi_evm_api/model/resolve_contract_interaction_response.py @@ -0,0 +1,214 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ResolveContractInteractionResponse( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class approvals( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'approvals': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class revokes( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'revokes': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class approvalsAll( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'approvalsAll': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class revokesAll( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'revokesAll': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "approvals": approvals, + "revokes": revokes, + "approvalsAll": approvalsAll, + "revokesAll": revokesAll, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["approvals"]) -> MetaOapg.properties.approvals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["revokes"]) -> MetaOapg.properties.revokes: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["approvalsAll"]) -> MetaOapg.properties.approvalsAll: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["revokesAll"]) -> MetaOapg.properties.revokesAll: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["approvals", "revokes", "approvalsAll", "revokesAll", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["approvals"]) -> typing.Union[MetaOapg.properties.approvals, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["revokes"]) -> typing.Union[MetaOapg.properties.revokes, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["approvalsAll"]) -> typing.Union[MetaOapg.properties.approvalsAll, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["revokesAll"]) -> typing.Union[MetaOapg.properties.revokesAll, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["approvals", "revokes", "approvalsAll", "revokesAll", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + approvals: typing.Union[MetaOapg.properties.approvals, list, tuple, None, schemas.Unset] = schemas.unset, + revokes: typing.Union[MetaOapg.properties.revokes, list, tuple, None, schemas.Unset] = schemas.unset, + approvalsAll: typing.Union[MetaOapg.properties.approvalsAll, list, tuple, None, schemas.Unset] = schemas.unset, + revokesAll: typing.Union[MetaOapg.properties.revokesAll, list, tuple, None, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ResolveContractInteractionResponse': + return super().__new__( + cls, + *args, + approvals=approvals, + revokes=revokes, + approvalsAll=approvalsAll, + revokesAll=revokesAll, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.common_contract_data import CommonContractData diff --git a/src/openapi_evm_api/model/resolve_contract_interaction_response.pyi b/src/openapi_evm_api/model/resolve_contract_interaction_response.pyi new file mode 100644 index 0000000..92298cf --- /dev/null +++ b/src/openapi_evm_api/model/resolve_contract_interaction_response.pyi @@ -0,0 +1,214 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class ResolveContractInteractionResponse( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class approvals( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'approvals': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class revokes( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'revokes': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class approvalsAll( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'approvalsAll': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class revokesAll( + schemas.ListBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneTupleMixin + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['CommonContractData']: + return CommonContractData + + + def __new__( + cls, + *args: typing.Union[list, tuple, None, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'revokesAll': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "approvals": approvals, + "revokes": revokes, + "approvalsAll": approvalsAll, + "revokesAll": revokesAll, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["approvals"]) -> MetaOapg.properties.approvals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["revokes"]) -> MetaOapg.properties.revokes: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["approvalsAll"]) -> MetaOapg.properties.approvalsAll: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["revokesAll"]) -> MetaOapg.properties.revokesAll: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["approvals", "revokes", "approvalsAll", "revokesAll", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["approvals"]) -> typing.Union[MetaOapg.properties.approvals, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["revokes"]) -> typing.Union[MetaOapg.properties.revokes, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["approvalsAll"]) -> typing.Union[MetaOapg.properties.approvalsAll, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["revokesAll"]) -> typing.Union[MetaOapg.properties.revokesAll, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["approvals", "revokes", "approvalsAll", "revokesAll", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + approvals: typing.Union[MetaOapg.properties.approvals, list, tuple, None, schemas.Unset] = schemas.unset, + revokes: typing.Union[MetaOapg.properties.revokes, list, tuple, None, schemas.Unset] = schemas.unset, + approvalsAll: typing.Union[MetaOapg.properties.approvalsAll, list, tuple, None, schemas.Unset] = schemas.unset, + revokesAll: typing.Union[MetaOapg.properties.revokesAll, list, tuple, None, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'ResolveContractInteractionResponse': + return super().__new__( + cls, + *args, + approvals=approvals, + revokes=revokes, + approvalsAll=approvalsAll, + revokesAll=revokesAll, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.common_contract_data import CommonContractData diff --git a/src/openapi_evm_api/model/sold_price.py b/src/openapi_evm_api/model/sold_price.py new file mode 100644 index 0000000..308493d --- /dev/null +++ b/src/openapi_evm_api/model/sold_price.py @@ -0,0 +1,979 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class SoldPrice( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "last_sale", + "average_sale", + "highest_sale", + "lowest_sale", + } + + class properties: + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "payment_token", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class lowest_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "block_timestamp", + "payment_token", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> typing.Union[MetaOapg.properties.buyer_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> typing.Union[MetaOapg.properties.seller_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + buyer_address: typing.Union[MetaOapg.properties.buyer_address, str, schemas.Unset] = schemas.unset, + seller_address: typing.Union[MetaOapg.properties.seller_address, str, schemas.Unset] = schemas.unset, + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'lowest_sale': + return super().__new__( + cls, + *args, + buyer_address=buyer_address, + seller_address=seller_address, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class highest_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "block_timestamp", + "payment_token", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> typing.Union[MetaOapg.properties.buyer_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> typing.Union[MetaOapg.properties.seller_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + buyer_address: typing.Union[MetaOapg.properties.buyer_address, str, schemas.Unset] = schemas.unset, + seller_address: typing.Union[MetaOapg.properties.seller_address, str, schemas.Unset] = schemas.unset, + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'highest_sale': + return super().__new__( + cls, + *args, + buyer_address=buyer_address, + seller_address=seller_address, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class average_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "price_formatted", + } + + class properties: + price = schemas.StrSchema + price_formatted = schemas.StrSchema + current_usd_value = schemas.StrSchema + __annotations__ = { + "price": price, + "price_formatted": price_formatted, + "current_usd_value": current_usd_value, + } + + + price: MetaOapg.properties.price + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["price", "price_formatted", "current_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["price", "price_formatted", "current_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'average_sale': + return super().__new__( + cls, + *args, + current_usd_value=current_usd_value, + _configuration=_configuration, + **kwargs, + ) + + + class total_trades( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'total_trades': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + message = schemas.StrSchema + __annotations__ = { + "last_sale": last_sale, + "lowest_sale": lowest_sale, + "highest_sale": highest_sale, + "average_sale": average_sale, + "total_trades": total_trades, + "message": message, + } + + + last_sale: MetaOapg.properties.last_sale + average_sale: MetaOapg.properties.average_sale + highest_sale: MetaOapg.properties.highest_sale + lowest_sale: MetaOapg.properties.lowest_sale + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["lowest_sale"]) -> MetaOapg.properties.lowest_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["highest_sale"]) -> MetaOapg.properties.highest_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["average_sale"]) -> MetaOapg.properties.average_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_trades"]) -> MetaOapg.properties.total_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["message"]) -> MetaOapg.properties.message: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["last_sale", "lowest_sale", "highest_sale", "average_sale", "total_trades", "message", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["lowest_sale"]) -> MetaOapg.properties.lowest_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["highest_sale"]) -> MetaOapg.properties.highest_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["average_sale"]) -> MetaOapg.properties.average_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_trades"]) -> typing.Union[MetaOapg.properties.total_trades, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["message"]) -> typing.Union[MetaOapg.properties.message, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["last_sale", "lowest_sale", "highest_sale", "average_sale", "total_trades", "message", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, ], + average_sale: typing.Union[MetaOapg.properties.average_sale, dict, frozendict.frozendict, None, ], + highest_sale: typing.Union[MetaOapg.properties.highest_sale, dict, frozendict.frozendict, None, ], + lowest_sale: typing.Union[MetaOapg.properties.lowest_sale, dict, frozendict.frozendict, None, ], + total_trades: typing.Union[MetaOapg.properties.total_trades, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + message: typing.Union[MetaOapg.properties.message, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SoldPrice': + return super().__new__( + cls, + *args, + last_sale=last_sale, + average_sale=average_sale, + highest_sale=highest_sale, + lowest_sale=lowest_sale, + total_trades=total_trades, + message=message, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/sold_price.pyi b/src/openapi_evm_api/model/sold_price.pyi new file mode 100644 index 0000000..308493d --- /dev/null +++ b/src/openapi_evm_api/model/sold_price.pyi @@ -0,0 +1,979 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class SoldPrice( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "last_sale", + "average_sale", + "highest_sale", + "lowest_sale", + } + + class properties: + + + class last_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "buyer_address", + "price", + "block_timestamp", + "payment_token", + "seller_address", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + buyer_address: MetaOapg.properties.buyer_address + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + seller_address: MetaOapg.properties.seller_address + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'last_sale': + return super().__new__( + cls, + *args, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class lowest_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "block_timestamp", + "payment_token", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> typing.Union[MetaOapg.properties.buyer_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> typing.Union[MetaOapg.properties.seller_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + buyer_address: typing.Union[MetaOapg.properties.buyer_address, str, schemas.Unset] = schemas.unset, + seller_address: typing.Union[MetaOapg.properties.seller_address, str, schemas.Unset] = schemas.unset, + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'lowest_sale': + return super().__new__( + cls, + *args, + buyer_address=buyer_address, + seller_address=seller_address, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class highest_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "block_timestamp", + "payment_token", + "transaction_hash", + "price_formatted", + } + + class properties: + transaction_hash = schemas.StrSchema + block_timestamp = schemas.StrSchema + buyer_address = schemas.StrSchema + seller_address = schemas.StrSchema + price = schemas.StrSchema + price_formatted = schemas.StrSchema + usd_price_at_sale = schemas.StrSchema + current_usd_value = schemas.StrSchema + token_id = schemas.StrSchema + + + class payment_token( + schemas.DictSchema + ): + + + class MetaOapg: + required = { + "token_logo", + "token_name", + "token_address", + "token_decimals", + "token_symbol", + } + + class properties: + token_name = schemas.StrSchema + token_symbol = schemas.StrSchema + token_logo = schemas.StrSchema + token_decimals = schemas.StrSchema + token_address = schemas.StrSchema + __annotations__ = { + "token_name": token_name, + "token_symbol": token_symbol, + "token_logo": token_logo, + "token_decimals": token_decimals, + "token_address": token_address, + } + + token_logo: MetaOapg.properties.token_logo + token_name: MetaOapg.properties.token_name + token_address: MetaOapg.properties.token_address + token_decimals: MetaOapg.properties.token_decimals + token_symbol: MetaOapg.properties.token_symbol + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_name"]) -> MetaOapg.properties.token_name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_symbol"]) -> MetaOapg.properties.token_symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_logo"]) -> MetaOapg.properties.token_logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> MetaOapg.properties.token_decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "token_address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + token_logo: typing.Union[MetaOapg.properties.token_logo, str, ], + token_name: typing.Union[MetaOapg.properties.token_name, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], + token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'payment_token': + return super().__new__( + cls, + *args, + token_logo=token_logo, + token_name=token_name, + token_address=token_address, + token_decimals=token_decimals, + token_symbol=token_symbol, + _configuration=_configuration, + **kwargs, + ) + __annotations__ = { + "transaction_hash": transaction_hash, + "block_timestamp": block_timestamp, + "buyer_address": buyer_address, + "seller_address": seller_address, + "price": price, + "price_formatted": price_formatted, + "usd_price_at_sale": usd_price_at_sale, + "current_usd_value": current_usd_value, + "token_id": token_id, + "payment_token": payment_token, + } + + + price: MetaOapg.properties.price + block_timestamp: MetaOapg.properties.block_timestamp + payment_token: MetaOapg.properties.payment_token + transaction_hash: MetaOapg.properties.transaction_hash + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["buyer_address"]) -> MetaOapg.properties.buyer_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["seller_address"]) -> MetaOapg.properties.seller_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> MetaOapg.properties.usd_price_at_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.properties.token_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["buyer_address"]) -> typing.Union[MetaOapg.properties.buyer_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["seller_address"]) -> typing.Union[MetaOapg.properties.seller_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price_at_sale"]) -> typing.Union[MetaOapg.properties.usd_price_at_sale, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> typing.Union[MetaOapg.properties.token_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["payment_token"]) -> MetaOapg.properties.payment_token: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["transaction_hash", "block_timestamp", "buyer_address", "seller_address", "price", "price_formatted", "usd_price_at_sale", "current_usd_value", "token_id", "payment_token", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + buyer_address: typing.Union[MetaOapg.properties.buyer_address, str, schemas.Unset] = schemas.unset, + seller_address: typing.Union[MetaOapg.properties.seller_address, str, schemas.Unset] = schemas.unset, + usd_price_at_sale: typing.Union[MetaOapg.properties.usd_price_at_sale, str, schemas.Unset] = schemas.unset, + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + token_id: typing.Union[MetaOapg.properties.token_id, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'highest_sale': + return super().__new__( + cls, + *args, + buyer_address=buyer_address, + seller_address=seller_address, + usd_price_at_sale=usd_price_at_sale, + current_usd_value=current_usd_value, + token_id=token_id, + _configuration=_configuration, + **kwargs, + ) + + + class average_sale( + schemas.DictBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneFrozenDictMixin + ): + + + class MetaOapg: + required = { + "price", + "price_formatted", + } + + class properties: + price = schemas.StrSchema + price_formatted = schemas.StrSchema + current_usd_value = schemas.StrSchema + __annotations__ = { + "price": price, + "price_formatted": price_formatted, + "current_usd_value": current_usd_value, + } + + + price: MetaOapg.properties.price + price_formatted: MetaOapg.properties.price_formatted + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_usd_value"]) -> MetaOapg.properties.current_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["price", "price_formatted", "current_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price"]) -> MetaOapg.properties.price: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["price_formatted"]) -> MetaOapg.properties.price_formatted: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_usd_value"]) -> typing.Union[MetaOapg.properties.current_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["price", "price_formatted", "current_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, None, ], + current_usd_value: typing.Union[MetaOapg.properties.current_usd_value, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'average_sale': + return super().__new__( + cls, + *args, + current_usd_value=current_usd_value, + _configuration=_configuration, + **kwargs, + ) + + + class total_trades( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'total_trades': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + message = schemas.StrSchema + __annotations__ = { + "last_sale": last_sale, + "lowest_sale": lowest_sale, + "highest_sale": highest_sale, + "average_sale": average_sale, + "total_trades": total_trades, + "message": message, + } + + + last_sale: MetaOapg.properties.last_sale + average_sale: MetaOapg.properties.average_sale + highest_sale: MetaOapg.properties.highest_sale + lowest_sale: MetaOapg.properties.lowest_sale + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["lowest_sale"]) -> MetaOapg.properties.lowest_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["highest_sale"]) -> MetaOapg.properties.highest_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["average_sale"]) -> MetaOapg.properties.average_sale: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_trades"]) -> MetaOapg.properties.total_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["message"]) -> MetaOapg.properties.message: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["last_sale", "lowest_sale", "highest_sale", "average_sale", "total_trades", "message", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["last_sale"]) -> MetaOapg.properties.last_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["lowest_sale"]) -> MetaOapg.properties.lowest_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["highest_sale"]) -> MetaOapg.properties.highest_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["average_sale"]) -> MetaOapg.properties.average_sale: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_trades"]) -> typing.Union[MetaOapg.properties.total_trades, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["message"]) -> typing.Union[MetaOapg.properties.message, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["last_sale", "lowest_sale", "highest_sale", "average_sale", "total_trades", "message", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + last_sale: typing.Union[MetaOapg.properties.last_sale, dict, frozendict.frozendict, None, ], + average_sale: typing.Union[MetaOapg.properties.average_sale, dict, frozendict.frozendict, None, ], + highest_sale: typing.Union[MetaOapg.properties.highest_sale, dict, frozendict.frozendict, None, ], + lowest_sale: typing.Union[MetaOapg.properties.lowest_sale, dict, frozendict.frozendict, None, ], + total_trades: typing.Union[MetaOapg.properties.total_trades, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + message: typing.Union[MetaOapg.properties.message, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SoldPrice': + return super().__new__( + cls, + *args, + last_sale=last_sale, + average_sale=average_sale, + highest_sale=highest_sale, + lowest_sale=lowest_sale, + total_trades=total_trades, + message=message, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/token_approval.py b/src/openapi_evm_api/model/token_approval.py new file mode 100644 index 0000000..33ca009 --- /dev/null +++ b/src/openapi_evm_api/model/token_approval.py @@ -0,0 +1,585 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class TokenApproval( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "spender", + "block_number", + "value", + "token", + } + + class properties: + block_number = schemas.StrSchema + value = schemas.StrSchema + + + class token( + schemas.DictSchema + ): + + + class MetaOapg: + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class name( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'name': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class symbol( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'symbol': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class logo( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logo': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + possible_spam = schemas.BoolSchema + verified_contract = schemas.BoolSchema + + + class current_balance( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_balance': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class current_balance_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_balance_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class usd_price( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'usd_price': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class usd_at_risk( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'usd_at_risk': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + "name": name, + "symbol": symbol, + "logo": logo, + "possible_spam": possible_spam, + "verified_contract": verified_contract, + "current_balance": current_balance, + "current_balance_formatted": current_balance_formatted, + "usd_price": usd_price, + "usd_at_risk": usd_at_risk, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> MetaOapg.properties.verified_contract: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_balance"]) -> MetaOapg.properties.current_balance: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_balance_formatted"]) -> MetaOapg.properties.current_balance_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_at_risk"]) -> MetaOapg.properties.usd_at_risk: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", "possible_spam", "verified_contract", "current_balance", "current_balance_formatted", "usd_price", "usd_at_risk", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> typing.Union[MetaOapg.properties.name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> typing.Union[MetaOapg.properties.symbol, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> typing.Union[MetaOapg.properties.verified_contract, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_balance"]) -> typing.Union[MetaOapg.properties.current_balance, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_balance_formatted"]) -> typing.Union[MetaOapg.properties.current_balance_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_at_risk"]) -> typing.Union[MetaOapg.properties.usd_at_risk, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", "possible_spam", "verified_contract", "current_balance", "current_balance_formatted", "usd_price", "usd_at_risk", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + name: typing.Union[MetaOapg.properties.name, None, str, schemas.Unset] = schemas.unset, + symbol: typing.Union[MetaOapg.properties.symbol, None, str, schemas.Unset] = schemas.unset, + logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, + possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, + verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, schemas.Unset] = schemas.unset, + current_balance: typing.Union[MetaOapg.properties.current_balance, None, str, schemas.Unset] = schemas.unset, + current_balance_formatted: typing.Union[MetaOapg.properties.current_balance_formatted, None, str, schemas.Unset] = schemas.unset, + usd_price: typing.Union[MetaOapg.properties.usd_price, None, str, schemas.Unset] = schemas.unset, + usd_at_risk: typing.Union[MetaOapg.properties.usd_at_risk, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'token': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + name=name, + symbol=symbol, + logo=logo, + possible_spam=possible_spam, + verified_contract=verified_contract, + current_balance=current_balance, + current_balance_formatted=current_balance_formatted, + usd_price=usd_price, + usd_at_risk=usd_at_risk, + _configuration=_configuration, + **kwargs, + ) + + + class spender( + schemas.DictSchema + ): + + + class MetaOapg: + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'spender': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + _configuration=_configuration, + **kwargs, + ) + + + class block_timestamp( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'block_timestamp': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class transaction_hash( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'transaction_hash': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class value_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'value_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "block_number": block_number, + "value": value, + "token": token, + "spender": spender, + "block_timestamp": block_timestamp, + "transaction_hash": transaction_hash, + "value_formatted": value_formatted, + } + + spender: MetaOapg.properties.spender + block_number: MetaOapg.properties.block_number + value: MetaOapg.properties.value + token: MetaOapg.properties.token + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token"]) -> MetaOapg.properties.token: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["spender"]) -> MetaOapg.properties.spender: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value_formatted"]) -> MetaOapg.properties.value_formatted: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["block_number", "value", "token", "spender", "block_timestamp", "transaction_hash", "value_formatted", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token"]) -> MetaOapg.properties.token: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["spender"]) -> MetaOapg.properties.spender: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> typing.Union[MetaOapg.properties.block_timestamp, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> typing.Union[MetaOapg.properties.transaction_hash, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value_formatted"]) -> typing.Union[MetaOapg.properties.value_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["block_number", "value", "token", "spender", "block_timestamp", "transaction_hash", "value_formatted", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + spender: typing.Union[MetaOapg.properties.spender, dict, frozendict.frozendict, ], + block_number: typing.Union[MetaOapg.properties.block_number, str, ], + value: typing.Union[MetaOapg.properties.value, str, ], + token: typing.Union[MetaOapg.properties.token, dict, frozendict.frozendict, ], + block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, None, str, schemas.Unset] = schemas.unset, + transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, None, str, schemas.Unset] = schemas.unset, + value_formatted: typing.Union[MetaOapg.properties.value_formatted, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'TokenApproval': + return super().__new__( + cls, + *args, + spender=spender, + block_number=block_number, + value=value, + token=token, + block_timestamp=block_timestamp, + transaction_hash=transaction_hash, + value_formatted=value_formatted, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/token_approval.pyi b/src/openapi_evm_api/model/token_approval.pyi new file mode 100644 index 0000000..33ca009 --- /dev/null +++ b/src/openapi_evm_api/model/token_approval.pyi @@ -0,0 +1,585 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class TokenApproval( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "spender", + "block_number", + "value", + "token", + } + + class properties: + block_number = schemas.StrSchema + value = schemas.StrSchema + + + class token( + schemas.DictSchema + ): + + + class MetaOapg: + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class name( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'name': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class symbol( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'symbol': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class logo( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logo': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + possible_spam = schemas.BoolSchema + verified_contract = schemas.BoolSchema + + + class current_balance( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_balance': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class current_balance_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'current_balance_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class usd_price( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'usd_price': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class usd_at_risk( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'usd_at_risk': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + "name": name, + "symbol": symbol, + "logo": logo, + "possible_spam": possible_spam, + "verified_contract": verified_contract, + "current_balance": current_balance, + "current_balance_formatted": current_balance_formatted, + "usd_price": usd_price, + "usd_at_risk": usd_at_risk, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> MetaOapg.properties.verified_contract: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_balance"]) -> MetaOapg.properties.current_balance: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["current_balance_formatted"]) -> MetaOapg.properties.current_balance_formatted: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_price"]) -> MetaOapg.properties.usd_price: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["usd_at_risk"]) -> MetaOapg.properties.usd_at_risk: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", "possible_spam", "verified_contract", "current_balance", "current_balance_formatted", "usd_price", "usd_at_risk", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> typing.Union[MetaOapg.properties.name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> typing.Union[MetaOapg.properties.symbol, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> typing.Union[MetaOapg.properties.logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> typing.Union[MetaOapg.properties.verified_contract, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_balance"]) -> typing.Union[MetaOapg.properties.current_balance, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["current_balance_formatted"]) -> typing.Union[MetaOapg.properties.current_balance_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_price"]) -> typing.Union[MetaOapg.properties.usd_price, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["usd_at_risk"]) -> typing.Union[MetaOapg.properties.usd_at_risk, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", "name", "symbol", "logo", "possible_spam", "verified_contract", "current_balance", "current_balance_formatted", "usd_price", "usd_at_risk", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + name: typing.Union[MetaOapg.properties.name, None, str, schemas.Unset] = schemas.unset, + symbol: typing.Union[MetaOapg.properties.symbol, None, str, schemas.Unset] = schemas.unset, + logo: typing.Union[MetaOapg.properties.logo, None, str, schemas.Unset] = schemas.unset, + possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, + verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, schemas.Unset] = schemas.unset, + current_balance: typing.Union[MetaOapg.properties.current_balance, None, str, schemas.Unset] = schemas.unset, + current_balance_formatted: typing.Union[MetaOapg.properties.current_balance_formatted, None, str, schemas.Unset] = schemas.unset, + usd_price: typing.Union[MetaOapg.properties.usd_price, None, str, schemas.Unset] = schemas.unset, + usd_at_risk: typing.Union[MetaOapg.properties.usd_at_risk, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'token': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + name=name, + symbol=symbol, + logo=logo, + possible_spam=possible_spam, + verified_contract=verified_contract, + current_balance=current_balance, + current_balance_formatted=current_balance_formatted, + usd_price=usd_price, + usd_at_risk=usd_at_risk, + _configuration=_configuration, + **kwargs, + ) + + + class spender( + schemas.DictSchema + ): + + + class MetaOapg: + + class properties: + address = schemas.StrSchema + + + class address_label( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'address_label': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "address": address, + "address_label": address_label, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address_label"]) -> MetaOapg.properties.address_label: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["address", "address_label", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> typing.Union[MetaOapg.properties.address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address_label"]) -> typing.Union[MetaOapg.properties.address_label, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["address", "address_label", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + address: typing.Union[MetaOapg.properties.address, str, schemas.Unset] = schemas.unset, + address_label: typing.Union[MetaOapg.properties.address_label, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'spender': + return super().__new__( + cls, + *args, + address=address, + address_label=address_label, + _configuration=_configuration, + **kwargs, + ) + + + class block_timestamp( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'block_timestamp': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class transaction_hash( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'transaction_hash': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class value_formatted( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'value_formatted': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + __annotations__ = { + "block_number": block_number, + "value": value, + "token": token, + "spender": spender, + "block_timestamp": block_timestamp, + "transaction_hash": transaction_hash, + "value_formatted": value_formatted, + } + + spender: MetaOapg.properties.spender + block_number: MetaOapg.properties.block_number + value: MetaOapg.properties.value + token: MetaOapg.properties.token + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token"]) -> MetaOapg.properties.token: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["spender"]) -> MetaOapg.properties.spender: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_hash"]) -> MetaOapg.properties.transaction_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["value_formatted"]) -> MetaOapg.properties.value_formatted: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["block_number", "value", "token", "spender", "block_timestamp", "transaction_hash", "value_formatted", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_number"]) -> MetaOapg.properties.block_number: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token"]) -> MetaOapg.properties.token: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["spender"]) -> MetaOapg.properties.spender: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> typing.Union[MetaOapg.properties.block_timestamp, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_hash"]) -> typing.Union[MetaOapg.properties.transaction_hash, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["value_formatted"]) -> typing.Union[MetaOapg.properties.value_formatted, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["block_number", "value", "token", "spender", "block_timestamp", "transaction_hash", "value_formatted", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + spender: typing.Union[MetaOapg.properties.spender, dict, frozendict.frozendict, ], + block_number: typing.Union[MetaOapg.properties.block_number, str, ], + value: typing.Union[MetaOapg.properties.value, str, ], + token: typing.Union[MetaOapg.properties.token, dict, frozendict.frozendict, ], + block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, None, str, schemas.Unset] = schemas.unset, + transaction_hash: typing.Union[MetaOapg.properties.transaction_hash, None, str, schemas.Unset] = schemas.unset, + value_formatted: typing.Union[MetaOapg.properties.value_formatted, None, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'TokenApproval': + return super().__new__( + cls, + *args, + spender=spender, + block_number=block_number, + value=value, + token=token, + block_timestamp=block_timestamp, + transaction_hash=transaction_hash, + value_formatted=value_formatted, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.py b/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.py new file mode 100644 index 0000000..9d49540 --- /dev/null +++ b/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class TopProfitableWalletPerTokenResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "count_of_trades", + "avg_sell_price_usd", + "total_tokens_bought", + "total_usd_invested", + "address", + "realized_profit_usd", + "realized_profit_percentage", + "avg_buy_price_usd", + "total_tokens_sold", + "avg_cost_of_quantity_sold", + "total_sold_usd", + } + + class properties: + avg_buy_price_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + count_of_trades = schemas.NumberSchema + realized_profit_percentage = schemas.NumberSchema + realized_profit_usd = schemas.StrSchema + total_sold_usd = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_usd_invested = schemas.StrSchema + address = schemas.StrSchema + __annotations__ = { + "avg_buy_price_usd": avg_buy_price_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "avg_sell_price_usd": avg_sell_price_usd, + "count_of_trades": count_of_trades, + "realized_profit_percentage": realized_profit_percentage, + "realized_profit_usd": realized_profit_usd, + "total_sold_usd": total_sold_usd, + "total_tokens_bought": total_tokens_bought, + "total_tokens_sold": total_tokens_sold, + "total_usd_invested": total_usd_invested, + "address": address, + } + + + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_tokens_bought: MetaOapg.properties.total_tokens_bought + total_usd_invested: MetaOapg.properties.total_usd_invested + address: MetaOapg.properties.address + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + total_tokens_sold: MetaOapg.properties.total_tokens_sold + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", "address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", "address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, decimal.Decimal, int, float, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + address: typing.Union[MetaOapg.properties.address, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, decimal.Decimal, int, float, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'TopProfitableWalletPerTokenResponse': + return super().__new__( + cls, + *args, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_tokens_bought=total_tokens_bought, + total_usd_invested=total_usd_invested, + address=address, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + avg_buy_price_usd=avg_buy_price_usd, + total_tokens_sold=total_tokens_sold, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + total_sold_usd=total_sold_usd, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.pyi b/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.pyi new file mode 100644 index 0000000..9d49540 --- /dev/null +++ b/src/openapi_evm_api/model/top_profitable_wallet_per_token_response.pyi @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class TopProfitableWalletPerTokenResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "count_of_trades", + "avg_sell_price_usd", + "total_tokens_bought", + "total_usd_invested", + "address", + "realized_profit_usd", + "realized_profit_percentage", + "avg_buy_price_usd", + "total_tokens_sold", + "avg_cost_of_quantity_sold", + "total_sold_usd", + } + + class properties: + avg_buy_price_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + count_of_trades = schemas.NumberSchema + realized_profit_percentage = schemas.NumberSchema + realized_profit_usd = schemas.StrSchema + total_sold_usd = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_usd_invested = schemas.StrSchema + address = schemas.StrSchema + __annotations__ = { + "avg_buy_price_usd": avg_buy_price_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "avg_sell_price_usd": avg_sell_price_usd, + "count_of_trades": count_of_trades, + "realized_profit_percentage": realized_profit_percentage, + "realized_profit_usd": realized_profit_usd, + "total_sold_usd": total_sold_usd, + "total_tokens_bought": total_tokens_bought, + "total_tokens_sold": total_tokens_sold, + "total_usd_invested": total_usd_invested, + "address": address, + } + + + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_tokens_bought: MetaOapg.properties.total_tokens_bought + total_usd_invested: MetaOapg.properties.total_usd_invested + address: MetaOapg.properties.address + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + total_tokens_sold: MetaOapg.properties.total_tokens_sold + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", "address", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", "address", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, decimal.Decimal, int, float, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + address: typing.Union[MetaOapg.properties.address, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, decimal.Decimal, int, float, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'TopProfitableWalletPerTokenResponse': + return super().__new__( + cls, + *args, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_tokens_bought=total_tokens_bought, + total_usd_invested=total_usd_invested, + address=address, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + avg_buy_price_usd=avg_buy_price_usd, + total_tokens_sold=total_tokens_sold, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + total_sold_usd=total_sold_usd, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/transaction.py b/src/openapi_evm_api/model/transaction.py index 09a86a1..808d28c 100644 --- a/src/openapi_evm_api/model/transaction.py +++ b/src/openapi_evm_api/model/transaction.py @@ -41,7 +41,6 @@ class MetaOapg: "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", "transaction_index", "nonce", "input", @@ -59,7 +58,6 @@ class properties: nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas = schemas.StrSchema gas_price = schemas.StrSchema @@ -92,6 +90,7 @@ def __new__( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -112,6 +111,7 @@ def __new__( *args, _configuration=_configuration, ) + transaction_fee = schemas.StrSchema class internal_transactions( @@ -143,7 +143,6 @@ def __getitem__(self, i: int) -> 'InternalTransaction': "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas": gas, "gas_price": gas_price, @@ -157,7 +156,9 @@ def __getitem__(self, i: int) -> 'InternalTransaction': "block_number": block_number, "block_hash": block_hash, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, + "transaction_fee": transaction_fee, "internal_transactions": internal_transactions, } @@ -168,7 +169,6 @@ def __getitem__(self, i: int) -> 'InternalTransaction': receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce input: MetaOapg.properties.input @@ -192,9 +192,6 @@ def __getitem__(self, name: typing_extensions.Literal["transaction_index"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -234,16 +231,22 @@ def __getitem__(self, name: typing_extensions.Literal["block_hash"]) -> MetaOapg @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["internal_transactions"]) -> MetaOapg.properties.internal_transactions: ... @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "internal_transactions", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "transaction_fee", "internal_transactions", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -260,9 +263,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["transaction_index"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -302,16 +302,22 @@ def get_item_oapg(self, name: typing_extensions.Literal["block_hash"]) -> MetaOa @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> typing.Union[MetaOapg.properties.transaction_fee, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["internal_transactions"]) -> typing.Union[MetaOapg.properties.internal_transactions, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "internal_transactions", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "transaction_fee", "internal_transactions", ], str]): return super().get_item_oapg(name) @@ -324,7 +330,6 @@ def __new__( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], input: typing.Union[MetaOapg.properties.input, str, ], @@ -336,7 +341,9 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, schemas.Unset] = schemas.unset, internal_transactions: typing.Union[MetaOapg.properties.internal_transactions, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], @@ -350,7 +357,6 @@ def __new__( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, input=input, @@ -362,7 +368,9 @@ def __new__( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, + transaction_fee=transaction_fee, internal_transactions=internal_transactions, _configuration=_configuration, **kwargs, diff --git a/src/openapi_evm_api/model/transaction.pyi b/src/openapi_evm_api/model/transaction.pyi index 09a86a1..808d28c 100644 --- a/src/openapi_evm_api/model/transaction.pyi +++ b/src/openapi_evm_api/model/transaction.pyi @@ -41,7 +41,6 @@ class Transaction( "receipt_cumulative_gas_used", "block_hash", "block_number", - "to_address", "transaction_index", "nonce", "input", @@ -59,7 +58,6 @@ class Transaction( nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema gas = schemas.StrSchema gas_price = schemas.StrSchema @@ -92,6 +90,7 @@ class Transaction( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -112,6 +111,7 @@ class Transaction( *args, _configuration=_configuration, ) + transaction_fee = schemas.StrSchema class internal_transactions( @@ -143,7 +143,6 @@ class Transaction( "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas": gas, "gas_price": gas_price, @@ -157,7 +156,9 @@ class Transaction( "block_number": block_number, "block_hash": block_hash, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, + "transaction_fee": transaction_fee, "internal_transactions": internal_transactions, } @@ -168,7 +169,6 @@ class Transaction( receipt_cumulative_gas_used: MetaOapg.properties.receipt_cumulative_gas_used block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce input: MetaOapg.properties.input @@ -192,9 +192,6 @@ class Transaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -234,16 +231,22 @@ class Transaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["internal_transactions"]) -> MetaOapg.properties.internal_transactions: ... @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "internal_transactions", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "transaction_fee", "internal_transactions", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -260,9 +263,6 @@ class Transaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -302,16 +302,22 @@ class Transaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> typing.Union[MetaOapg.properties.transaction_fee, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["internal_transactions"]) -> typing.Union[MetaOapg.properties.internal_transactions, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address_label", "internal_transactions", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas", "gas_price", "input", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_contract_address", "receipt_root", "receipt_status", "block_timestamp", "block_number", "block_hash", "from_address_label", "to_address", "to_address_label", "transaction_fee", "internal_transactions", ], str]): return super().get_item_oapg(name) @@ -324,7 +330,6 @@ class Transaction( receipt_cumulative_gas_used: typing.Union[MetaOapg.properties.receipt_cumulative_gas_used, str, ], block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], input: typing.Union[MetaOapg.properties.input, str, ], @@ -336,7 +341,9 @@ class Transaction( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, schemas.Unset] = schemas.unset, internal_transactions: typing.Union[MetaOapg.properties.internal_transactions, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], @@ -350,7 +357,6 @@ class Transaction( receipt_cumulative_gas_used=receipt_cumulative_gas_used, block_hash=block_hash, block_number=block_number, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, input=input, @@ -362,7 +368,9 @@ class Transaction( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, + transaction_fee=transaction_fee, internal_transactions=internal_transactions, _configuration=_configuration, **kwargs, diff --git a/src/openapi_evm_api/model/ohlc_response.py b/src/openapi_evm_api/model/wallet_approvals.py similarity index 65% rename from src/openapi_evm_api/model/ohlc_response.py rename to src/openapi_evm_api/model/wallet_approvals.py index 3c6d52a..fac19f3 100644 --- a/src/openapi_evm_api/model/ohlc_response.py +++ b/src/openapi_evm_api/model/wallet_approvals.py @@ -23,7 +23,7 @@ from openapi_evm_api import schemas # noqa: F401 -class OhlcResponse( +class WalletApprovals( schemas.AnyTypeSchema, ): """NOTE: This class is auto generated by OpenAPI Generator. @@ -35,29 +35,54 @@ class OhlcResponse( class MetaOapg: required = { + "cursor", "result", + "page", + "page_size", } class properties: - - @staticmethod - def result() -> typing.Type['OhlcResult']: - return OhlcResult page = schemas.IntSchema page_size = schemas.IntSchema cursor = schemas.StrSchema + + + class result( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['TokenApproval']: + return TokenApproval + + def __new__( + cls, + arg: typing.Union[typing.Tuple['TokenApproval'], typing.List['TokenApproval']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'result': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'TokenApproval': + return super().__getitem__(i) __annotations__ = { - "result": result, "page": page, "page_size": page_size, "cursor": cursor, + "result": result, } - result: 'OhlcResult' - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["result"]) -> 'OhlcResult': ... + cursor: MetaOapg.properties.cursor + result: MetaOapg.properties.result + page: MetaOapg.properties.page + page_size: MetaOapg.properties.page_size @typing.overload def __getitem__(self, name: typing_extensions.Literal["page"]) -> MetaOapg.properties.page: ... @@ -68,52 +93,55 @@ def __getitem__(self, name: typing_extensions.Literal["page_size"]) -> MetaOapg. @typing.overload def __getitem__(self, name: typing_extensions.Literal["cursor"]) -> MetaOapg.properties.cursor: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["result", "page", "page_size", "cursor", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["page", "page_size", "cursor", "result", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> 'OhlcResult': ... + def get_item_oapg(self, name: typing_extensions.Literal["page"]) -> MetaOapg.properties.page: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["page"]) -> typing.Union[MetaOapg.properties.page, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["page_size"]) -> MetaOapg.properties.page_size: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["page_size"]) -> typing.Union[MetaOapg.properties.page_size, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["cursor"]) -> MetaOapg.properties.cursor: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["cursor"]) -> typing.Union[MetaOapg.properties.cursor, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["result", "page", "page_size", "cursor", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["page", "page_size", "cursor", "result", ], str]): return super().get_item_oapg(name) def __new__( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - result: 'OhlcResult', - page: typing.Union[MetaOapg.properties.page, decimal.Decimal, int, schemas.Unset] = schemas.unset, - page_size: typing.Union[MetaOapg.properties.page_size, decimal.Decimal, int, schemas.Unset] = schemas.unset, - cursor: typing.Union[MetaOapg.properties.cursor, str, schemas.Unset] = schemas.unset, + cursor: typing.Union[MetaOapg.properties.cursor, str, ], + result: typing.Union[MetaOapg.properties.result, list, tuple, ], + page: typing.Union[MetaOapg.properties.page, decimal.Decimal, int, ], + page_size: typing.Union[MetaOapg.properties.page_size, decimal.Decimal, int, ], _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'OhlcResponse': + ) -> 'WalletApprovals': return super().__new__( cls, *args, + cursor=cursor, result=result, page=page, page_size=page_size, - cursor=cursor, _configuration=_configuration, **kwargs, ) -from openapi_evm_api.model.ohlc_result import OhlcResult +from openapi_evm_api.model.token_approval import TokenApproval diff --git a/src/openapi_evm_api/model/ohlc_response.pyi b/src/openapi_evm_api/model/wallet_approvals.pyi similarity index 65% rename from src/openapi_evm_api/model/ohlc_response.pyi rename to src/openapi_evm_api/model/wallet_approvals.pyi index 3c6d52a..fac19f3 100644 --- a/src/openapi_evm_api/model/ohlc_response.pyi +++ b/src/openapi_evm_api/model/wallet_approvals.pyi @@ -23,7 +23,7 @@ import frozendict # noqa: F401 from openapi_evm_api import schemas # noqa: F401 -class OhlcResponse( +class WalletApprovals( schemas.AnyTypeSchema, ): """NOTE: This class is auto generated by OpenAPI Generator. @@ -35,29 +35,54 @@ class OhlcResponse( class MetaOapg: required = { + "cursor", "result", + "page", + "page_size", } class properties: - - @staticmethod - def result() -> typing.Type['OhlcResult']: - return OhlcResult page = schemas.IntSchema page_size = schemas.IntSchema cursor = schemas.StrSchema + + + class result( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['TokenApproval']: + return TokenApproval + + def __new__( + cls, + arg: typing.Union[typing.Tuple['TokenApproval'], typing.List['TokenApproval']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'result': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'TokenApproval': + return super().__getitem__(i) __annotations__ = { - "result": result, "page": page, "page_size": page_size, "cursor": cursor, + "result": result, } - result: 'OhlcResult' - - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["result"]) -> 'OhlcResult': ... + cursor: MetaOapg.properties.cursor + result: MetaOapg.properties.result + page: MetaOapg.properties.page + page_size: MetaOapg.properties.page_size @typing.overload def __getitem__(self, name: typing_extensions.Literal["page"]) -> MetaOapg.properties.page: ... @@ -68,52 +93,55 @@ class OhlcResponse( @typing.overload def __getitem__(self, name: typing_extensions.Literal["cursor"]) -> MetaOapg.properties.cursor: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["result", "page", "page_size", "cursor", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["page", "page_size", "cursor", "result", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> 'OhlcResult': ... + def get_item_oapg(self, name: typing_extensions.Literal["page"]) -> MetaOapg.properties.page: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["page"]) -> typing.Union[MetaOapg.properties.page, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["page_size"]) -> MetaOapg.properties.page_size: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["page_size"]) -> typing.Union[MetaOapg.properties.page_size, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["cursor"]) -> MetaOapg.properties.cursor: ... @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["cursor"]) -> typing.Union[MetaOapg.properties.cursor, schemas.Unset]: ... + def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["result", "page", "page_size", "cursor", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["page", "page_size", "cursor", "result", ], str]): return super().get_item_oapg(name) def __new__( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - result: 'OhlcResult', - page: typing.Union[MetaOapg.properties.page, decimal.Decimal, int, schemas.Unset] = schemas.unset, - page_size: typing.Union[MetaOapg.properties.page_size, decimal.Decimal, int, schemas.Unset] = schemas.unset, - cursor: typing.Union[MetaOapg.properties.cursor, str, schemas.Unset] = schemas.unset, + cursor: typing.Union[MetaOapg.properties.cursor, str, ], + result: typing.Union[MetaOapg.properties.result, list, tuple, ], + page: typing.Union[MetaOapg.properties.page, decimal.Decimal, int, ], + page_size: typing.Union[MetaOapg.properties.page_size, decimal.Decimal, int, ], _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], - ) -> 'OhlcResponse': + ) -> 'WalletApprovals': return super().__new__( cls, *args, + cursor=cursor, result=result, page=page, page_size=page_size, - cursor=cursor, _configuration=_configuration, **kwargs, ) -from openapi_evm_api.model.ohlc_result import OhlcResult +from openapi_evm_api.model.token_approval import TokenApproval diff --git a/src/openapi_evm_api/model/wallet_defi_protocol_position.py b/src/openapi_evm_api/model/wallet_defi_protocol_position.py new file mode 100644 index 0000000..72d93af --- /dev/null +++ b/src/openapi_evm_api/model/wallet_defi_protocol_position.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletDefiProtocolPosition( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "positions", + "total_usd_value", + } + + class properties: + total_usd_value = schemas.NumberSchema + + + class positions( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolPosition']: + return DefiProtocolPosition + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolPosition'], typing.List['DefiProtocolPosition']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'positions': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolPosition': + return super().__getitem__(i) + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "total_usd_value": total_usd_value, + "positions": positions, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + positions: MetaOapg.properties.positions + total_usd_value: MetaOapg.properties.total_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + positions: typing.Union[MetaOapg.properties.positions, list, tuple, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletDefiProtocolPosition': + return super().__new__( + cls, + *args, + positions=positions, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition diff --git a/src/openapi_evm_api/model/wallet_defi_protocol_position.pyi b/src/openapi_evm_api/model/wallet_defi_protocol_position.pyi new file mode 100644 index 0000000..72d93af --- /dev/null +++ b/src/openapi_evm_api/model/wallet_defi_protocol_position.pyi @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletDefiProtocolPosition( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "positions", + "total_usd_value", + } + + class properties: + total_usd_value = schemas.NumberSchema + + + class positions( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolPosition']: + return DefiProtocolPosition + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolPosition'], typing.List['DefiProtocolPosition']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'positions': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolPosition': + return super().__getitem__(i) + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "total_usd_value": total_usd_value, + "positions": positions, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + positions: MetaOapg.properties.positions + total_usd_value: MetaOapg.properties.total_usd_value + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_usd_value", "positions", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + positions: typing.Union[MetaOapg.properties.positions, list, tuple, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletDefiProtocolPosition': + return super().__new__( + cls, + *args, + positions=positions, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition diff --git a/src/openapi_evm_api/model/wallet_defi_summary.py b/src/openapi_evm_api/model/wallet_defi_summary.py new file mode 100644 index 0000000..4c8d220 --- /dev/null +++ b/src/openapi_evm_api/model/wallet_defi_summary.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletDefiSummary( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "active_protocols", + "total_usd_value", + "protocols", + "total_positions", + } + + class properties: + active_protocols = schemas.NumberSchema + total_positions = schemas.NumberSchema + total_usd_value = schemas.NumberSchema + + + class protocols( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolBalance']: + return DefiProtocolBalance + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolBalance'], typing.List['DefiProtocolBalance']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'protocols': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolBalance': + return super().__getitem__(i) + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "active_protocols": active_protocols, + "total_positions": total_positions, + "total_usd_value": total_usd_value, + "protocols": protocols, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + active_protocols: MetaOapg.properties.active_protocols + total_usd_value: MetaOapg.properties.total_usd_value + protocols: MetaOapg.properties.protocols + total_positions: MetaOapg.properties.total_positions + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["active_protocols"]) -> MetaOapg.properties.active_protocols: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_positions"]) -> MetaOapg.properties.total_positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocols"]) -> MetaOapg.properties.protocols: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["active_protocols", "total_positions", "total_usd_value", "protocols", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["active_protocols"]) -> MetaOapg.properties.active_protocols: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_positions"]) -> MetaOapg.properties.total_positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocols"]) -> MetaOapg.properties.protocols: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["active_protocols", "total_positions", "total_usd_value", "protocols", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + active_protocols: typing.Union[MetaOapg.properties.active_protocols, decimal.Decimal, int, float, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + protocols: typing.Union[MetaOapg.properties.protocols, list, tuple, ], + total_positions: typing.Union[MetaOapg.properties.total_positions, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletDefiSummary': + return super().__new__( + cls, + *args, + active_protocols=active_protocols, + total_usd_value=total_usd_value, + protocols=protocols, + total_positions=total_positions, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_protocol_balance import DefiProtocolBalance diff --git a/src/openapi_evm_api/model/wallet_defi_summary.pyi b/src/openapi_evm_api/model/wallet_defi_summary.pyi new file mode 100644 index 0000000..4c8d220 --- /dev/null +++ b/src/openapi_evm_api/model/wallet_defi_summary.pyi @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletDefiSummary( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "active_protocols", + "total_usd_value", + "protocols", + "total_positions", + } + + class properties: + active_protocols = schemas.NumberSchema + total_positions = schemas.NumberSchema + total_usd_value = schemas.NumberSchema + + + class protocols( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolBalance']: + return DefiProtocolBalance + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolBalance'], typing.List['DefiProtocolBalance']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'protocols': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolBalance': + return super().__getitem__(i) + total_unclaimed_usd_value = schemas.NumberSchema + __annotations__ = { + "active_protocols": active_protocols, + "total_positions": total_positions, + "total_usd_value": total_usd_value, + "protocols": protocols, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + } + + + active_protocols: MetaOapg.properties.active_protocols + total_usd_value: MetaOapg.properties.total_usd_value + protocols: MetaOapg.properties.protocols + total_positions: MetaOapg.properties.total_positions + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["active_protocols"]) -> MetaOapg.properties.active_protocols: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_positions"]) -> MetaOapg.properties.total_positions: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocols"]) -> MetaOapg.properties.protocols: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["active_protocols", "total_positions", "total_usd_value", "protocols", "total_unclaimed_usd_value", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["active_protocols"]) -> MetaOapg.properties.active_protocols: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_positions"]) -> MetaOapg.properties.total_positions: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocols"]) -> MetaOapg.properties.protocols: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["active_protocols", "total_positions", "total_usd_value", "protocols", "total_unclaimed_usd_value", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + active_protocols: typing.Union[MetaOapg.properties.active_protocols, decimal.Decimal, int, float, ], + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, ], + protocols: typing.Union[MetaOapg.properties.protocols, list, tuple, ], + total_positions: typing.Union[MetaOapg.properties.total_positions, decimal.Decimal, int, float, ], + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletDefiSummary': + return super().__new__( + cls, + *args, + active_protocols=active_protocols, + total_usd_value=total_usd_value, + protocols=protocols, + total_positions=total_positions, + total_unclaimed_usd_value=total_unclaimed_usd_value, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.defi_protocol_balance import DefiProtocolBalance diff --git a/src/openapi_evm_api/model/wallet_history_erc20_transfer.py b/src/openapi_evm_api/model/wallet_history_erc20_transfer.py index 422676f..dda00b4 100644 --- a/src/openapi_evm_api/model/wallet_history_erc20_transfer.py +++ b/src/openapi_evm_api/model/wallet_history_erc20_transfer.py @@ -36,9 +36,6 @@ class WalletHistoryErc20Transfer( class MetaOapg: required = { "address", - "to_address", - "transaction_index", - "log_index", "possible_spam", "verified_contract", "value_formatted", @@ -46,7 +43,9 @@ class MetaOapg: "token_name", "token_decimals", "token_symbol", + "transaction_index", "from_address", + "log_index", "value", } @@ -56,7 +55,6 @@ class properties: token_logo = schemas.StrSchema token_decimals = schemas.StrSchema address = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema value = schemas.StrSchema value_formatted = schemas.StrSchema @@ -64,6 +62,7 @@ class properties: possible_spam = schemas.BoolSchema verified_contract = schemas.BoolSchema block_timestamp = schemas.StrSchema + to_address = schemas.StrSchema class to_address_label( @@ -110,7 +109,6 @@ def __new__( "token_logo": token_logo, "token_decimals": token_decimals, "address": address, - "to_address": to_address, "from_address": from_address, "value": value, "value_formatted": value_formatted, @@ -118,15 +116,13 @@ def __new__( "possible_spam": possible_spam, "verified_contract": verified_contract, "block_timestamp": block_timestamp, + "to_address": to_address, "to_address_label": to_address_label, "from_address_label": from_address_label, } address: MetaOapg.properties.address - to_address: MetaOapg.properties.to_address - transaction_index: schemas.AnyTypeSchema - log_index: MetaOapg.properties.log_index possible_spam: MetaOapg.properties.possible_spam verified_contract: MetaOapg.properties.verified_contract value_formatted: MetaOapg.properties.value_formatted @@ -134,7 +130,9 @@ def __new__( token_name: MetaOapg.properties.token_name token_decimals: MetaOapg.properties.token_decimals token_symbol: MetaOapg.properties.token_symbol + transaction_index: schemas.AnyTypeSchema from_address: MetaOapg.properties.from_address + log_index: MetaOapg.properties.log_index value: MetaOapg.properties.value @typing.overload @@ -152,9 +150,6 @@ def __getitem__(self, name: typing_extensions.Literal["token_decimals"]) -> Meta @typing.overload def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -176,6 +171,9 @@ def __getitem__(self, name: typing_extensions.Literal["verified_contract"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -185,7 +183,7 @@ def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "to_address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address_label", "from_address_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address", "to_address_label", "from_address_label", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -205,9 +203,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["token_decimals"]) -> Me @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -229,6 +224,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["verified_contract"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> typing.Union[MetaOapg.properties.block_timestamp, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -238,7 +236,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) - @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "to_address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address_label", "from_address_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address", "to_address_label", "from_address_label", ], str]): return super().get_item_oapg(name) @@ -246,9 +244,6 @@ def __new__( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], address: typing.Union[MetaOapg.properties.address, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], - transaction_index: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, ], value_formatted: typing.Union[MetaOapg.properties.value_formatted, str, ], @@ -256,9 +251,12 @@ def __new__( token_name: typing.Union[MetaOapg.properties.token_name, str, ], token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + transaction_index: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], + log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], value: typing.Union[MetaOapg.properties.value, str, ], block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, @@ -268,9 +266,6 @@ def __new__( cls, *args, address=address, - to_address=to_address, - transaction_index=transaction_index, - log_index=log_index, possible_spam=possible_spam, verified_contract=verified_contract, value_formatted=value_formatted, @@ -278,9 +273,12 @@ def __new__( token_name=token_name, token_decimals=token_decimals, token_symbol=token_symbol, + transaction_index=transaction_index, from_address=from_address, + log_index=log_index, value=value, block_timestamp=block_timestamp, + to_address=to_address, to_address_label=to_address_label, from_address_label=from_address_label, _configuration=_configuration, diff --git a/src/openapi_evm_api/model/wallet_history_erc20_transfer.pyi b/src/openapi_evm_api/model/wallet_history_erc20_transfer.pyi index 422676f..dda00b4 100644 --- a/src/openapi_evm_api/model/wallet_history_erc20_transfer.pyi +++ b/src/openapi_evm_api/model/wallet_history_erc20_transfer.pyi @@ -36,9 +36,6 @@ class WalletHistoryErc20Transfer( class MetaOapg: required = { "address", - "to_address", - "transaction_index", - "log_index", "possible_spam", "verified_contract", "value_formatted", @@ -46,7 +43,9 @@ class WalletHistoryErc20Transfer( "token_name", "token_decimals", "token_symbol", + "transaction_index", "from_address", + "log_index", "value", } @@ -56,7 +55,6 @@ class WalletHistoryErc20Transfer( token_logo = schemas.StrSchema token_decimals = schemas.StrSchema address = schemas.StrSchema - to_address = schemas.StrSchema from_address = schemas.StrSchema value = schemas.StrSchema value_formatted = schemas.StrSchema @@ -64,6 +62,7 @@ class WalletHistoryErc20Transfer( possible_spam = schemas.BoolSchema verified_contract = schemas.BoolSchema block_timestamp = schemas.StrSchema + to_address = schemas.StrSchema class to_address_label( @@ -110,7 +109,6 @@ class WalletHistoryErc20Transfer( "token_logo": token_logo, "token_decimals": token_decimals, "address": address, - "to_address": to_address, "from_address": from_address, "value": value, "value_formatted": value_formatted, @@ -118,15 +116,13 @@ class WalletHistoryErc20Transfer( "possible_spam": possible_spam, "verified_contract": verified_contract, "block_timestamp": block_timestamp, + "to_address": to_address, "to_address_label": to_address_label, "from_address_label": from_address_label, } address: MetaOapg.properties.address - to_address: MetaOapg.properties.to_address - transaction_index: schemas.AnyTypeSchema - log_index: MetaOapg.properties.log_index possible_spam: MetaOapg.properties.possible_spam verified_contract: MetaOapg.properties.verified_contract value_formatted: MetaOapg.properties.value_formatted @@ -134,7 +130,9 @@ class WalletHistoryErc20Transfer( token_name: MetaOapg.properties.token_name token_decimals: MetaOapg.properties.token_decimals token_symbol: MetaOapg.properties.token_symbol + transaction_index: schemas.AnyTypeSchema from_address: MetaOapg.properties.from_address + log_index: MetaOapg.properties.log_index value: MetaOapg.properties.value @typing.overload @@ -152,9 +150,6 @@ class WalletHistoryErc20Transfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -176,6 +171,9 @@ class WalletHistoryErc20Transfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["block_timestamp"]) -> MetaOapg.properties.block_timestamp: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -185,7 +183,7 @@ class WalletHistoryErc20Transfer( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "to_address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address_label", "from_address_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address", "to_address_label", "from_address_label", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -205,9 +203,6 @@ class WalletHistoryErc20Transfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["address"]) -> MetaOapg.properties.address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... @@ -229,6 +224,9 @@ class WalletHistoryErc20Transfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["block_timestamp"]) -> typing.Union[MetaOapg.properties.block_timestamp, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -238,7 +236,7 @@ class WalletHistoryErc20Transfer( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "to_address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address_label", "from_address_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_name", "token_symbol", "token_logo", "token_decimals", "address", "from_address", "value", "value_formatted", "log_index", "possible_spam", "verified_contract", "block_timestamp", "to_address", "to_address_label", "from_address_label", ], str]): return super().get_item_oapg(name) @@ -246,9 +244,6 @@ class WalletHistoryErc20Transfer( cls, *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], address: typing.Union[MetaOapg.properties.address, str, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], - transaction_index: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], verified_contract: typing.Union[MetaOapg.properties.verified_contract, bool, ], value_formatted: typing.Union[MetaOapg.properties.value_formatted, str, ], @@ -256,9 +251,12 @@ class WalletHistoryErc20Transfer( token_name: typing.Union[MetaOapg.properties.token_name, str, ], token_decimals: typing.Union[MetaOapg.properties.token_decimals, str, ], token_symbol: typing.Union[MetaOapg.properties.token_symbol, str, ], + transaction_index: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], + log_index: typing.Union[MetaOapg.properties.log_index, decimal.Decimal, int, ], value: typing.Union[MetaOapg.properties.value, str, ], block_timestamp: typing.Union[MetaOapg.properties.block_timestamp, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, @@ -268,9 +266,6 @@ class WalletHistoryErc20Transfer( cls, *args, address=address, - to_address=to_address, - transaction_index=transaction_index, - log_index=log_index, possible_spam=possible_spam, verified_contract=verified_contract, value_formatted=value_formatted, @@ -278,9 +273,12 @@ class WalletHistoryErc20Transfer( token_name=token_name, token_decimals=token_decimals, token_symbol=token_symbol, + transaction_index=transaction_index, from_address=from_address, + log_index=log_index, value=value, block_timestamp=block_timestamp, + to_address=to_address, to_address_label=to_address_label, from_address_label=from_address_label, _configuration=_configuration, diff --git a/src/openapi_evm_api/model/wallet_history_nft_transfer.py b/src/openapi_evm_api/model/wallet_history_nft_transfer.py index f806fcc..4480d24 100644 --- a/src/openapi_evm_api/model/wallet_history_nft_transfer.py +++ b/src/openapi_evm_api/model/wallet_history_nft_transfer.py @@ -40,7 +40,6 @@ class MetaOapg: "possible_spam", "token_id", "verified", - "to_address", "token_address", "transaction_type", "from_address", @@ -53,7 +52,6 @@ class properties: token_address = schemas.StrSchema token_id = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema amount = schemas.StrSchema contract_type = schemas.StrSchema @@ -81,6 +79,7 @@ def __new__( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -113,7 +112,6 @@ def normalized_metadata() -> typing.Type['NormalizedMetadata']: "token_address": token_address, "token_id": token_id, "from_address": from_address, - "to_address": to_address, "value": value, "amount": amount, "contract_type": contract_type, @@ -122,6 +120,7 @@ def normalized_metadata() -> typing.Type['NormalizedMetadata']: "possible_spam": possible_spam, "direction": direction, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "operator": operator, "verified_collection": verified_collection, @@ -136,7 +135,6 @@ def normalized_metadata() -> typing.Type['NormalizedMetadata']: possible_spam: MetaOapg.properties.possible_spam token_id: MetaOapg.properties.token_id verified: schemas.AnyTypeSchema - to_address: MetaOapg.properties.to_address token_address: MetaOapg.properties.token_address transaction_type: MetaOapg.properties.transaction_type from_address: MetaOapg.properties.from_address @@ -153,9 +151,6 @@ def __getitem__(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg.p @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -180,6 +175,9 @@ def __getitem__(self, name: typing_extensions.Literal["direction"]) -> MetaOapg. @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -201,7 +199,7 @@ def __getitem__(self, name: typing_extensions.Literal["normalized_metadata"]) -> @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "to_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -215,9 +213,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["token_id"]) -> MetaOapg @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -242,6 +237,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["direction"]) -> MetaOap @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -263,7 +261,7 @@ def get_item_oapg(self, name: typing_extensions.Literal["normalized_metadata"]) @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "to_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): return super().get_item_oapg(name) @@ -275,7 +273,6 @@ def __new__( possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], token_id: typing.Union[MetaOapg.properties.token_id, str, ], verified: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], token_address: typing.Union[MetaOapg.properties.token_address, str, ], transaction_type: typing.Union[MetaOapg.properties.transaction_type, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], @@ -283,6 +280,7 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], direction: typing.Union[MetaOapg.properties.direction, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, operator: typing.Union[MetaOapg.properties.operator, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, @@ -300,7 +298,6 @@ def __new__( possible_spam=possible_spam, token_id=token_id, verified=verified, - to_address=to_address, token_address=token_address, transaction_type=transaction_type, from_address=from_address, @@ -308,6 +305,7 @@ def __new__( value=value, direction=direction, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, operator=operator, verified_collection=verified_collection, diff --git a/src/openapi_evm_api/model/wallet_history_nft_transfer.pyi b/src/openapi_evm_api/model/wallet_history_nft_transfer.pyi index f806fcc..4480d24 100644 --- a/src/openapi_evm_api/model/wallet_history_nft_transfer.pyi +++ b/src/openapi_evm_api/model/wallet_history_nft_transfer.pyi @@ -40,7 +40,6 @@ class WalletHistoryNftTransfer( "possible_spam", "token_id", "verified", - "to_address", "token_address", "transaction_type", "from_address", @@ -53,7 +52,6 @@ class WalletHistoryNftTransfer( token_address = schemas.StrSchema token_id = schemas.StrSchema from_address = schemas.StrSchema - to_address = schemas.StrSchema value = schemas.StrSchema amount = schemas.StrSchema contract_type = schemas.StrSchema @@ -81,6 +79,7 @@ class WalletHistoryNftTransfer( *args, _configuration=_configuration, ) + to_address = schemas.StrSchema class to_address_label( @@ -113,7 +112,6 @@ class WalletHistoryNftTransfer( "token_address": token_address, "token_id": token_id, "from_address": from_address, - "to_address": to_address, "value": value, "amount": amount, "contract_type": contract_type, @@ -122,6 +120,7 @@ class WalletHistoryNftTransfer( "possible_spam": possible_spam, "direction": direction, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "operator": operator, "verified_collection": verified_collection, @@ -136,7 +135,6 @@ class WalletHistoryNftTransfer( possible_spam: MetaOapg.properties.possible_spam token_id: MetaOapg.properties.token_id verified: schemas.AnyTypeSchema - to_address: MetaOapg.properties.to_address token_address: MetaOapg.properties.token_address transaction_type: MetaOapg.properties.transaction_type from_address: MetaOapg.properties.from_address @@ -153,9 +151,6 @@ class WalletHistoryNftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -180,6 +175,9 @@ class WalletHistoryNftTransfer( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -201,7 +199,7 @@ class WalletHistoryNftTransfer( @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "to_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -215,9 +213,6 @@ class WalletHistoryNftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -242,6 +237,9 @@ class WalletHistoryNftTransfer( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -263,7 +261,7 @@ class WalletHistoryNftTransfer( @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "to_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "token_id", "from_address", "value", "amount", "contract_type", "transaction_type", "log_index", "possible_spam", "direction", "from_address_label", "to_address", "to_address_label", "operator", "verified_collection", "collection_logo", "collection_banner_image", "normalized_metadata", ], str]): return super().get_item_oapg(name) @@ -275,7 +273,6 @@ class WalletHistoryNftTransfer( possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, ], token_id: typing.Union[MetaOapg.properties.token_id, str, ], verified: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - to_address: typing.Union[MetaOapg.properties.to_address, str, ], token_address: typing.Union[MetaOapg.properties.token_address, str, ], transaction_type: typing.Union[MetaOapg.properties.transaction_type, str, ], from_address: typing.Union[MetaOapg.properties.from_address, str, ], @@ -283,6 +280,7 @@ class WalletHistoryNftTransfer( value: typing.Union[MetaOapg.properties.value, str, ], direction: typing.Union[MetaOapg.properties.direction, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, operator: typing.Union[MetaOapg.properties.operator, str, schemas.Unset] = schemas.unset, verified_collection: typing.Union[MetaOapg.properties.verified_collection, bool, schemas.Unset] = schemas.unset, @@ -300,7 +298,6 @@ class WalletHistoryNftTransfer( possible_spam=possible_spam, token_id=token_id, verified=verified, - to_address=to_address, token_address=token_address, transaction_type=transaction_type, from_address=from_address, @@ -308,6 +305,7 @@ class WalletHistoryNftTransfer( value=value, direction=direction, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, operator=operator, verified_collection=verified_collection, diff --git a/src/openapi_evm_api/model/wallet_history_transaction.py b/src/openapi_evm_api/model/wallet_history_transaction.py index cd0421e..5ee08cd 100644 --- a/src/openapi_evm_api/model/wallet_history_transaction.py +++ b/src/openapi_evm_api/model/wallet_history_transaction.py @@ -42,7 +42,6 @@ class MetaOapg: "block_hash", "block_number", "native_transfers", - "to_address", "transaction_index", "nonce", "erc20_transfers", @@ -60,26 +59,6 @@ class properties: nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - - - class to_address( - schemas.StrBase, - schemas.NoneBase, - schemas.Schema, - schemas.NoneStrMixin - ): - - - def __new__( - cls, - *args: typing.Union[None, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'to_address': - return super().__new__( - cls, - *args, - _configuration=_configuration, - ) value = schemas.StrSchema gas_price = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema @@ -193,6 +172,26 @@ def __new__( ) + class to_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'to_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + class to_address_label( schemas.StrBase, schemas.NoneBase, @@ -215,6 +214,27 @@ def __new__( input = schemas.StrSchema + class receipt_contract_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'receipt_contract_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + transaction_fee = schemas.StrSchema + + class internal_transactions( schemas.ListSchema ): @@ -239,14 +259,43 @@ def __new__( def __getitem__(self, i: int) -> 'InternalTransaction': return super().__getitem__(i) + + @staticmethod + def contract_interactions() -> typing.Type['ResolveContractInteractionResponse']: + return ResolveContractInteractionResponse possible_spam = schemas.BoolSchema method_label = schemas.StrSchema + + + class logs( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['Log']: + return Log + + def __new__( + cls, + arg: typing.Union[typing.Tuple['Log'], typing.List['Log']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logs': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'Log': + return super().__getitem__(i) __annotations__ = { "hash": hash, "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, @@ -261,12 +310,17 @@ def __getitem__(self, i: int) -> 'InternalTransaction': "erc20_transfers": erc20_transfers, "native_transfers": native_transfers, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "input": input, + "receipt_contract_address": receipt_contract_address, + "transaction_fee": transaction_fee, "internal_transactions": internal_transactions, + "contract_interactions": contract_interactions, "possible_spam": possible_spam, "method_label": method_label, + "logs": logs, } gas_price: MetaOapg.properties.gas_price @@ -276,7 +330,6 @@ def __getitem__(self, i: int) -> 'InternalTransaction': block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number native_transfers: MetaOapg.properties.native_transfers - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce erc20_transfers: MetaOapg.properties.erc20_transfers @@ -300,9 +353,6 @@ def __getitem__(self, name: typing_extensions.Literal["transaction_index"]) -> M @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -345,6 +395,9 @@ def __getitem__(self, name: typing_extensions.Literal["native_transfers"]) -> Me @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -354,19 +407,31 @@ def __getitem__(self, name: typing_extensions.Literal["gas"]) -> MetaOapg.proper @typing.overload def __getitem__(self, name: typing_extensions.Literal["input"]) -> MetaOapg.properties.input: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["receipt_contract_address"]) -> MetaOapg.properties.receipt_contract_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["internal_transactions"]) -> MetaOapg.properties.internal_transactions: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["contract_interactions"]) -> 'ResolveContractInteractionResponse': ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... @typing.overload def __getitem__(self, name: typing_extensions.Literal["method_label"]) -> MetaOapg.properties.method_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logs"]) -> MetaOapg.properties.logs: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address_label", "gas", "input", "internal_transactions", "possible_spam", "method_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address", "to_address_label", "gas", "input", "receipt_contract_address", "transaction_fee", "internal_transactions", "contract_interactions", "possible_spam", "method_label", "logs", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -383,9 +448,6 @@ def get_item_oapg(self, name: typing_extensions.Literal["transaction_index"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -428,6 +490,9 @@ def get_item_oapg(self, name: typing_extensions.Literal["native_transfers"]) -> @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -437,19 +502,31 @@ def get_item_oapg(self, name: typing_extensions.Literal["gas"]) -> typing.Union[ @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["input"]) -> typing.Union[MetaOapg.properties.input, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["receipt_contract_address"]) -> typing.Union[MetaOapg.properties.receipt_contract_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> typing.Union[MetaOapg.properties.transaction_fee, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["internal_transactions"]) -> typing.Union[MetaOapg.properties.internal_transactions, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["contract_interactions"]) -> typing.Union['ResolveContractInteractionResponse', schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["method_label"]) -> typing.Union[MetaOapg.properties.method_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logs"]) -> typing.Union[MetaOapg.properties.logs, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address_label", "gas", "input", "internal_transactions", "possible_spam", "method_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address", "to_address_label", "gas", "input", "receipt_contract_address", "transaction_fee", "internal_transactions", "contract_interactions", "possible_spam", "method_label", "logs", ], str]): return super().get_item_oapg(name) @@ -463,7 +540,6 @@ def __new__( block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], native_transfers: typing.Union[MetaOapg.properties.native_transfers, list, tuple, ], - to_address: typing.Union[MetaOapg.properties.to_address, None, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], erc20_transfers: typing.Union[MetaOapg.properties.erc20_transfers, list, tuple, ], @@ -475,12 +551,17 @@ def __new__( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, None, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, input: typing.Union[MetaOapg.properties.input, str, schemas.Unset] = schemas.unset, + receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, None, str, schemas.Unset] = schemas.unset, + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, schemas.Unset] = schemas.unset, internal_transactions: typing.Union[MetaOapg.properties.internal_transactions, list, tuple, schemas.Unset] = schemas.unset, + contract_interactions: typing.Union['ResolveContractInteractionResponse', schemas.Unset] = schemas.unset, possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, method_label: typing.Union[MetaOapg.properties.method_label, str, schemas.Unset] = schemas.unset, + logs: typing.Union[MetaOapg.properties.logs, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'WalletHistoryTransaction': @@ -494,7 +575,6 @@ def __new__( block_hash=block_hash, block_number=block_number, native_transfers=native_transfers, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, erc20_transfers=erc20_transfers, @@ -506,18 +586,25 @@ def __new__( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, input=input, + receipt_contract_address=receipt_contract_address, + transaction_fee=transaction_fee, internal_transactions=internal_transactions, + contract_interactions=contract_interactions, possible_spam=possible_spam, method_label=method_label, + logs=logs, _configuration=_configuration, **kwargs, ) from openapi_evm_api.model.e_transaction_category import ETransactionCategory from openapi_evm_api.model.internal_transaction import InternalTransaction +from openapi_evm_api.model.log import Log from openapi_evm_api.model.native_transfer import NativeTransfer +from openapi_evm_api.model.resolve_contract_interaction_response import ResolveContractInteractionResponse from openapi_evm_api.model.wallet_history_erc20_transfer import WalletHistoryErc20Transfer from openapi_evm_api.model.wallet_history_nft_transfer import WalletHistoryNftTransfer diff --git a/src/openapi_evm_api/model/wallet_history_transaction.pyi b/src/openapi_evm_api/model/wallet_history_transaction.pyi index cd0421e..5ee08cd 100644 --- a/src/openapi_evm_api/model/wallet_history_transaction.pyi +++ b/src/openapi_evm_api/model/wallet_history_transaction.pyi @@ -42,7 +42,6 @@ class WalletHistoryTransaction( "block_hash", "block_number", "native_transfers", - "to_address", "transaction_index", "nonce", "erc20_transfers", @@ -60,26 +59,6 @@ class WalletHistoryTransaction( nonce = schemas.StrSchema transaction_index = schemas.StrSchema from_address = schemas.StrSchema - - - class to_address( - schemas.StrBase, - schemas.NoneBase, - schemas.Schema, - schemas.NoneStrMixin - ): - - - def __new__( - cls, - *args: typing.Union[None, str, ], - _configuration: typing.Optional[schemas.Configuration] = None, - ) -> 'to_address': - return super().__new__( - cls, - *args, - _configuration=_configuration, - ) value = schemas.StrSchema gas_price = schemas.StrSchema receipt_cumulative_gas_used = schemas.StrSchema @@ -193,6 +172,26 @@ class WalletHistoryTransaction( ) + class to_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'to_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + class to_address_label( schemas.StrBase, schemas.NoneBase, @@ -215,6 +214,27 @@ class WalletHistoryTransaction( input = schemas.StrSchema + class receipt_contract_address( + schemas.StrBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneStrMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'receipt_contract_address': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + transaction_fee = schemas.StrSchema + + class internal_transactions( schemas.ListSchema ): @@ -239,14 +259,43 @@ class WalletHistoryTransaction( def __getitem__(self, i: int) -> 'InternalTransaction': return super().__getitem__(i) + + @staticmethod + def contract_interactions() -> typing.Type['ResolveContractInteractionResponse']: + return ResolveContractInteractionResponse possible_spam = schemas.BoolSchema method_label = schemas.StrSchema + + + class logs( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['Log']: + return Log + + def __new__( + cls, + arg: typing.Union[typing.Tuple['Log'], typing.List['Log']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'logs': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'Log': + return super().__getitem__(i) __annotations__ = { "hash": hash, "nonce": nonce, "transaction_index": transaction_index, "from_address": from_address, - "to_address": to_address, "value": value, "gas_price": gas_price, "receipt_cumulative_gas_used": receipt_cumulative_gas_used, @@ -261,12 +310,17 @@ class WalletHistoryTransaction( "erc20_transfers": erc20_transfers, "native_transfers": native_transfers, "from_address_label": from_address_label, + "to_address": to_address, "to_address_label": to_address_label, "gas": gas, "input": input, + "receipt_contract_address": receipt_contract_address, + "transaction_fee": transaction_fee, "internal_transactions": internal_transactions, + "contract_interactions": contract_interactions, "possible_spam": possible_spam, "method_label": method_label, + "logs": logs, } gas_price: MetaOapg.properties.gas_price @@ -276,7 +330,6 @@ class WalletHistoryTransaction( block_hash: MetaOapg.properties.block_hash block_number: MetaOapg.properties.block_number native_transfers: MetaOapg.properties.native_transfers - to_address: MetaOapg.properties.to_address transaction_index: MetaOapg.properties.transaction_index nonce: MetaOapg.properties.nonce erc20_transfers: MetaOapg.properties.erc20_transfers @@ -300,9 +353,6 @@ class WalletHistoryTransaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def __getitem__(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -345,6 +395,9 @@ class WalletHistoryTransaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["from_address_label"]) -> MetaOapg.properties.from_address_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["to_address_label"]) -> MetaOapg.properties.to_address_label: ... @@ -354,19 +407,31 @@ class WalletHistoryTransaction( @typing.overload def __getitem__(self, name: typing_extensions.Literal["input"]) -> MetaOapg.properties.input: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["receipt_contract_address"]) -> MetaOapg.properties.receipt_contract_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["transaction_fee"]) -> MetaOapg.properties.transaction_fee: ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["internal_transactions"]) -> MetaOapg.properties.internal_transactions: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["contract_interactions"]) -> 'ResolveContractInteractionResponse': ... + @typing.overload def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... @typing.overload def __getitem__(self, name: typing_extensions.Literal["method_label"]) -> MetaOapg.properties.method_label: ... + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logs"]) -> MetaOapg.properties.logs: ... + @typing.overload def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... - def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address_label", "gas", "input", "internal_transactions", "possible_spam", "method_label", ], str]): + def __getitem__(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address", "to_address_label", "gas", "input", "receipt_contract_address", "transaction_fee", "internal_transactions", "contract_interactions", "possible_spam", "method_label", "logs", ], str]): # dict_instance[name] accessor return super().__getitem__(name) @@ -383,9 +448,6 @@ class WalletHistoryTransaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address"]) -> MetaOapg.properties.from_address: ... - @typing.overload - def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> MetaOapg.properties.to_address: ... - @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["value"]) -> MetaOapg.properties.value: ... @@ -428,6 +490,9 @@ class WalletHistoryTransaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["from_address_label"]) -> typing.Union[MetaOapg.properties.from_address_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["to_address"]) -> typing.Union[MetaOapg.properties.to_address, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["to_address_label"]) -> typing.Union[MetaOapg.properties.to_address_label, schemas.Unset]: ... @@ -437,19 +502,31 @@ class WalletHistoryTransaction( @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["input"]) -> typing.Union[MetaOapg.properties.input, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["receipt_contract_address"]) -> typing.Union[MetaOapg.properties.receipt_contract_address, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["transaction_fee"]) -> typing.Union[MetaOapg.properties.transaction_fee, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["internal_transactions"]) -> typing.Union[MetaOapg.properties.internal_transactions, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["contract_interactions"]) -> typing.Union['ResolveContractInteractionResponse', schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... @typing.overload def get_item_oapg(self, name: typing_extensions.Literal["method_label"]) -> typing.Union[MetaOapg.properties.method_label, schemas.Unset]: ... + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logs"]) -> typing.Union[MetaOapg.properties.logs, schemas.Unset]: ... + @typing.overload def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... - def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "to_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address_label", "gas", "input", "internal_transactions", "possible_spam", "method_label", ], str]): + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["hash", "nonce", "transaction_index", "from_address", "value", "gas_price", "receipt_cumulative_gas_used", "receipt_gas_used", "receipt_status", "block_timestamp", "block_number", "block_hash", "category", "summary", "nft_transfers", "erc20_transfers", "native_transfers", "from_address_label", "to_address", "to_address_label", "gas", "input", "receipt_contract_address", "transaction_fee", "internal_transactions", "contract_interactions", "possible_spam", "method_label", "logs", ], str]): return super().get_item_oapg(name) @@ -463,7 +540,6 @@ class WalletHistoryTransaction( block_hash: typing.Union[MetaOapg.properties.block_hash, str, ], block_number: typing.Union[MetaOapg.properties.block_number, str, ], native_transfers: typing.Union[MetaOapg.properties.native_transfers, list, tuple, ], - to_address: typing.Union[MetaOapg.properties.to_address, None, str, ], transaction_index: typing.Union[MetaOapg.properties.transaction_index, str, ], nonce: typing.Union[MetaOapg.properties.nonce, str, ], erc20_transfers: typing.Union[MetaOapg.properties.erc20_transfers, list, tuple, ], @@ -475,12 +551,17 @@ class WalletHistoryTransaction( value: typing.Union[MetaOapg.properties.value, str, ], hash: typing.Union[MetaOapg.properties.hash, str, ], from_address_label: typing.Union[MetaOapg.properties.from_address_label, None, str, schemas.Unset] = schemas.unset, + to_address: typing.Union[MetaOapg.properties.to_address, None, str, schemas.Unset] = schemas.unset, to_address_label: typing.Union[MetaOapg.properties.to_address_label, None, str, schemas.Unset] = schemas.unset, gas: typing.Union[MetaOapg.properties.gas, str, schemas.Unset] = schemas.unset, input: typing.Union[MetaOapg.properties.input, str, schemas.Unset] = schemas.unset, + receipt_contract_address: typing.Union[MetaOapg.properties.receipt_contract_address, None, str, schemas.Unset] = schemas.unset, + transaction_fee: typing.Union[MetaOapg.properties.transaction_fee, str, schemas.Unset] = schemas.unset, internal_transactions: typing.Union[MetaOapg.properties.internal_transactions, list, tuple, schemas.Unset] = schemas.unset, + contract_interactions: typing.Union['ResolveContractInteractionResponse', schemas.Unset] = schemas.unset, possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, method_label: typing.Union[MetaOapg.properties.method_label, str, schemas.Unset] = schemas.unset, + logs: typing.Union[MetaOapg.properties.logs, list, tuple, schemas.Unset] = schemas.unset, _configuration: typing.Optional[schemas.Configuration] = None, **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], ) -> 'WalletHistoryTransaction': @@ -494,7 +575,6 @@ class WalletHistoryTransaction( block_hash=block_hash, block_number=block_number, native_transfers=native_transfers, - to_address=to_address, transaction_index=transaction_index, nonce=nonce, erc20_transfers=erc20_transfers, @@ -506,18 +586,25 @@ class WalletHistoryTransaction( value=value, hash=hash, from_address_label=from_address_label, + to_address=to_address, to_address_label=to_address_label, gas=gas, input=input, + receipt_contract_address=receipt_contract_address, + transaction_fee=transaction_fee, internal_transactions=internal_transactions, + contract_interactions=contract_interactions, possible_spam=possible_spam, method_label=method_label, + logs=logs, _configuration=_configuration, **kwargs, ) from openapi_evm_api.model.e_transaction_category import ETransactionCategory from openapi_evm_api.model.internal_transaction import InternalTransaction +from openapi_evm_api.model.log import Log from openapi_evm_api.model.native_transfer import NativeTransfer +from openapi_evm_api.model.resolve_contract_interaction_response import ResolveContractInteractionResponse from openapi_evm_api.model.wallet_history_erc20_transfer import WalletHistoryErc20Transfer from openapi_evm_api.model.wallet_history_nft_transfer import WalletHistoryNftTransfer diff --git a/src/openapi_evm_api/model/wallet_profitability_response.py b/src/openapi_evm_api/model/wallet_profitability_response.py new file mode 100644 index 0000000..18c580b --- /dev/null +++ b/src/openapi_evm_api/model/wallet_profitability_response.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletProfitabilityResponse( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class result( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['WalletProfitabilityTokenData']: + return WalletProfitabilityTokenData + + def __new__( + cls, + arg: typing.Union[typing.Tuple['WalletProfitabilityTokenData'], typing.List['WalletProfitabilityTokenData']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'result': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'WalletProfitabilityTokenData': + return super().__getitem__(i) + __annotations__ = { + "result": result, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["result", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> typing.Union[MetaOapg.properties.result, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["result", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + result: typing.Union[MetaOapg.properties.result, list, tuple, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletProfitabilityResponse': + return super().__new__( + cls, + *args, + result=result, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.wallet_profitability_token_data import WalletProfitabilityTokenData diff --git a/src/openapi_evm_api/model/wallet_profitability_response.pyi b/src/openapi_evm_api/model/wallet_profitability_response.pyi new file mode 100644 index 0000000..18c580b --- /dev/null +++ b/src/openapi_evm_api/model/wallet_profitability_response.pyi @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletProfitabilityResponse( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + + class properties: + + + class result( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['WalletProfitabilityTokenData']: + return WalletProfitabilityTokenData + + def __new__( + cls, + arg: typing.Union[typing.Tuple['WalletProfitabilityTokenData'], typing.List['WalletProfitabilityTokenData']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'result': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'WalletProfitabilityTokenData': + return super().__getitem__(i) + __annotations__ = { + "result": result, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["result"]) -> MetaOapg.properties.result: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["result", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["result"]) -> typing.Union[MetaOapg.properties.result, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["result", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + result: typing.Union[MetaOapg.properties.result, list, tuple, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletProfitabilityResponse': + return super().__new__( + cls, + *args, + result=result, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.wallet_profitability_token_data import WalletProfitabilityTokenData diff --git a/src/openapi_evm_api/model/wallet_profitability_token_data.py b/src/openapi_evm_api/model/wallet_profitability_token_data.py new file mode 100644 index 0000000..839ba8e --- /dev/null +++ b/src/openapi_evm_api/model/wallet_profitability_token_data.py @@ -0,0 +1,309 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletProfitabilityTokenData( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "symbol", + "total_tokens_bought", + "thumbnail", + "total_buys", + "total_sells", + "avg_cost_of_quantity_sold", + "token_address", + "count_of_trades", + "avg_sell_price_usd", + "total_usd_invested", + "realized_profit_usd", + "realized_profit_percentage", + "decimals", + "avg_buy_price_usd", + "name", + "total_tokens_sold", + "logo", + "logo_hash", + "total_sold_usd", + } + + class properties: + token_address = schemas.StrSchema + avg_buy_price_usd = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + total_usd_invested = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_sold_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + count_of_trades = schemas.NumberSchema + realized_profit_usd = schemas.StrSchema + realized_profit_percentage = schemas.NumberSchema + total_buys = schemas.NumberSchema + total_sells = schemas.NumberSchema + name = schemas.StrSchema + symbol = schemas.StrSchema + decimals = schemas.StrSchema + logo = schemas.StrSchema + logo_hash = schemas.StrSchema + thumbnail = schemas.StrSchema + possible_spam = schemas.BoolSchema + __annotations__ = { + "token_address": token_address, + "avg_buy_price_usd": avg_buy_price_usd, + "avg_sell_price_usd": avg_sell_price_usd, + "total_usd_invested": total_usd_invested, + "total_tokens_sold": total_tokens_sold, + "total_tokens_bought": total_tokens_bought, + "total_sold_usd": total_sold_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "count_of_trades": count_of_trades, + "realized_profit_usd": realized_profit_usd, + "realized_profit_percentage": realized_profit_percentage, + "total_buys": total_buys, + "total_sells": total_sells, + "name": name, + "symbol": symbol, + "decimals": decimals, + "logo": logo, + "logo_hash": logo_hash, + "thumbnail": thumbnail, + "possible_spam": possible_spam, + } + + symbol: MetaOapg.properties.symbol + total_tokens_bought: MetaOapg.properties.total_tokens_bought + thumbnail: MetaOapg.properties.thumbnail + total_buys: MetaOapg.properties.total_buys + total_sells: MetaOapg.properties.total_sells + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + token_address: MetaOapg.properties.token_address + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_usd_invested: MetaOapg.properties.total_usd_invested + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + decimals: MetaOapg.properties.decimals + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + name: MetaOapg.properties.name + total_tokens_sold: MetaOapg.properties.total_tokens_sold + logo: MetaOapg.properties.logo + logo_hash: MetaOapg.properties.logo_hash + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo_hash"]) -> MetaOapg.properties.logo_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "avg_buy_price_usd", "avg_sell_price_usd", "total_usd_invested", "total_tokens_sold", "total_tokens_bought", "total_sold_usd", "avg_cost_of_quantity_sold", "count_of_trades", "realized_profit_usd", "realized_profit_percentage", "total_buys", "total_sells", "name", "symbol", "decimals", "logo", "logo_hash", "thumbnail", "possible_spam", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo_hash"]) -> MetaOapg.properties.logo_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "avg_buy_price_usd", "avg_sell_price_usd", "total_usd_invested", "total_tokens_sold", "total_tokens_bought", "total_sold_usd", "avg_cost_of_quantity_sold", "count_of_trades", "realized_profit_usd", "realized_profit_percentage", "total_buys", "total_sells", "name", "symbol", "decimals", "logo", "logo_hash", "thumbnail", "possible_spam", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + symbol: typing.Union[MetaOapg.properties.symbol, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + thumbnail: typing.Union[MetaOapg.properties.thumbnail, str, ], + total_buys: typing.Union[MetaOapg.properties.total_buys, decimal.Decimal, int, float, ], + total_sells: typing.Union[MetaOapg.properties.total_sells, decimal.Decimal, int, float, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, decimal.Decimal, int, float, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, decimal.Decimal, int, float, ], + decimals: typing.Union[MetaOapg.properties.decimals, str, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + name: typing.Union[MetaOapg.properties.name, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + logo: typing.Union[MetaOapg.properties.logo, str, ], + logo_hash: typing.Union[MetaOapg.properties.logo_hash, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletProfitabilityTokenData': + return super().__new__( + cls, + *args, + symbol=symbol, + total_tokens_bought=total_tokens_bought, + thumbnail=thumbnail, + total_buys=total_buys, + total_sells=total_sells, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + token_address=token_address, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_usd_invested=total_usd_invested, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + decimals=decimals, + avg_buy_price_usd=avg_buy_price_usd, + name=name, + total_tokens_sold=total_tokens_sold, + logo=logo, + logo_hash=logo_hash, + total_sold_usd=total_sold_usd, + possible_spam=possible_spam, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/wallet_profitability_token_data.pyi b/src/openapi_evm_api/model/wallet_profitability_token_data.pyi new file mode 100644 index 0000000..839ba8e --- /dev/null +++ b/src/openapi_evm_api/model/wallet_profitability_token_data.pyi @@ -0,0 +1,309 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletProfitabilityTokenData( + schemas.DictSchema +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "symbol", + "total_tokens_bought", + "thumbnail", + "total_buys", + "total_sells", + "avg_cost_of_quantity_sold", + "token_address", + "count_of_trades", + "avg_sell_price_usd", + "total_usd_invested", + "realized_profit_usd", + "realized_profit_percentage", + "decimals", + "avg_buy_price_usd", + "name", + "total_tokens_sold", + "logo", + "logo_hash", + "total_sold_usd", + } + + class properties: + token_address = schemas.StrSchema + avg_buy_price_usd = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + total_usd_invested = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_sold_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + count_of_trades = schemas.NumberSchema + realized_profit_usd = schemas.StrSchema + realized_profit_percentage = schemas.NumberSchema + total_buys = schemas.NumberSchema + total_sells = schemas.NumberSchema + name = schemas.StrSchema + symbol = schemas.StrSchema + decimals = schemas.StrSchema + logo = schemas.StrSchema + logo_hash = schemas.StrSchema + thumbnail = schemas.StrSchema + possible_spam = schemas.BoolSchema + __annotations__ = { + "token_address": token_address, + "avg_buy_price_usd": avg_buy_price_usd, + "avg_sell_price_usd": avg_sell_price_usd, + "total_usd_invested": total_usd_invested, + "total_tokens_sold": total_tokens_sold, + "total_tokens_bought": total_tokens_bought, + "total_sold_usd": total_sold_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "count_of_trades": count_of_trades, + "realized_profit_usd": realized_profit_usd, + "realized_profit_percentage": realized_profit_percentage, + "total_buys": total_buys, + "total_sells": total_sells, + "name": name, + "symbol": symbol, + "decimals": decimals, + "logo": logo, + "logo_hash": logo_hash, + "thumbnail": thumbnail, + "possible_spam": possible_spam, + } + + symbol: MetaOapg.properties.symbol + total_tokens_bought: MetaOapg.properties.total_tokens_bought + thumbnail: MetaOapg.properties.thumbnail + total_buys: MetaOapg.properties.total_buys + total_sells: MetaOapg.properties.total_sells + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + token_address: MetaOapg.properties.token_address + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_usd_invested: MetaOapg.properties.total_usd_invested + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + decimals: MetaOapg.properties.decimals + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + name: MetaOapg.properties.name + total_tokens_sold: MetaOapg.properties.total_tokens_sold + logo: MetaOapg.properties.logo + logo_hash: MetaOapg.properties.logo_hash + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["logo_hash"]) -> MetaOapg.properties.logo_hash: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["possible_spam"]) -> MetaOapg.properties.possible_spam: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["token_address", "avg_buy_price_usd", "avg_sell_price_usd", "total_usd_invested", "total_tokens_sold", "total_tokens_bought", "total_sold_usd", "avg_cost_of_quantity_sold", "count_of_trades", "realized_profit_usd", "realized_profit_percentage", "total_buys", "total_sells", "name", "symbol", "decimals", "logo", "logo_hash", "thumbnail", "possible_spam", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["token_address"]) -> MetaOapg.properties.token_address: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["symbol"]) -> MetaOapg.properties.symbol: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["decimals"]) -> MetaOapg.properties.decimals: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo"]) -> MetaOapg.properties.logo: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["logo_hash"]) -> MetaOapg.properties.logo_hash: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["thumbnail"]) -> MetaOapg.properties.thumbnail: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["possible_spam"]) -> typing.Union[MetaOapg.properties.possible_spam, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["token_address", "avg_buy_price_usd", "avg_sell_price_usd", "total_usd_invested", "total_tokens_sold", "total_tokens_bought", "total_sold_usd", "avg_cost_of_quantity_sold", "count_of_trades", "realized_profit_usd", "realized_profit_percentage", "total_buys", "total_sells", "name", "symbol", "decimals", "logo", "logo_hash", "thumbnail", "possible_spam", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + symbol: typing.Union[MetaOapg.properties.symbol, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + thumbnail: typing.Union[MetaOapg.properties.thumbnail, str, ], + total_buys: typing.Union[MetaOapg.properties.total_buys, decimal.Decimal, int, float, ], + total_sells: typing.Union[MetaOapg.properties.total_sells, decimal.Decimal, int, float, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + token_address: typing.Union[MetaOapg.properties.token_address, str, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, decimal.Decimal, int, float, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, decimal.Decimal, int, float, ], + decimals: typing.Union[MetaOapg.properties.decimals, str, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + name: typing.Union[MetaOapg.properties.name, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + logo: typing.Union[MetaOapg.properties.logo, str, ], + logo_hash: typing.Union[MetaOapg.properties.logo_hash, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + possible_spam: typing.Union[MetaOapg.properties.possible_spam, bool, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletProfitabilityTokenData': + return super().__new__( + cls, + *args, + symbol=symbol, + total_tokens_bought=total_tokens_bought, + thumbnail=thumbnail, + total_buys=total_buys, + total_sells=total_sells, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + token_address=token_address, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_usd_invested=total_usd_invested, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + decimals=decimals, + avg_buy_price_usd=avg_buy_price_usd, + name=name, + total_tokens_sold=total_tokens_sold, + logo=logo, + logo_hash=logo_hash, + total_sold_usd=total_sold_usd, + possible_spam=possible_spam, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/wallet_token_profitability_response.py b/src/openapi_evm_api/model/wallet_token_profitability_response.py new file mode 100644 index 0000000..1682bcd --- /dev/null +++ b/src/openapi_evm_api/model/wallet_token_profitability_response.py @@ -0,0 +1,192 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletTokenProfitabilityResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "count_of_trades", + "avg_sell_price_usd", + "total_tokens_bought", + "total_usd_invested", + "realized_profit_usd", + "realized_profit_percentage", + "avg_buy_price_usd", + "total_tokens_sold", + "avg_cost_of_quantity_sold", + "total_sold_usd", + } + + class properties: + avg_buy_price_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + count_of_trades = schemas.StrSchema + realized_profit_percentage = schemas.StrSchema + realized_profit_usd = schemas.StrSchema + total_sold_usd = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_usd_invested = schemas.StrSchema + __annotations__ = { + "avg_buy_price_usd": avg_buy_price_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "avg_sell_price_usd": avg_sell_price_usd, + "count_of_trades": count_of_trades, + "realized_profit_percentage": realized_profit_percentage, + "realized_profit_usd": realized_profit_usd, + "total_sold_usd": total_sold_usd, + "total_tokens_bought": total_tokens_bought, + "total_tokens_sold": total_tokens_sold, + "total_usd_invested": total_usd_invested, + } + + + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_tokens_bought: MetaOapg.properties.total_tokens_bought + total_usd_invested: MetaOapg.properties.total_usd_invested + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + total_tokens_sold: MetaOapg.properties.total_tokens_sold + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, str, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, str, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletTokenProfitabilityResponse': + return super().__new__( + cls, + *args, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_tokens_bought=total_tokens_bought, + total_usd_invested=total_usd_invested, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + avg_buy_price_usd=avg_buy_price_usd, + total_tokens_sold=total_tokens_sold, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + total_sold_usd=total_sold_usd, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/wallet_token_profitability_response.pyi b/src/openapi_evm_api/model/wallet_token_profitability_response.pyi new file mode 100644 index 0000000..1682bcd --- /dev/null +++ b/src/openapi_evm_api/model/wallet_token_profitability_response.pyi @@ -0,0 +1,192 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletTokenProfitabilityResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "count_of_trades", + "avg_sell_price_usd", + "total_tokens_bought", + "total_usd_invested", + "realized_profit_usd", + "realized_profit_percentage", + "avg_buy_price_usd", + "total_tokens_sold", + "avg_cost_of_quantity_sold", + "total_sold_usd", + } + + class properties: + avg_buy_price_usd = schemas.StrSchema + avg_cost_of_quantity_sold = schemas.StrSchema + avg_sell_price_usd = schemas.StrSchema + count_of_trades = schemas.StrSchema + realized_profit_percentage = schemas.StrSchema + realized_profit_usd = schemas.StrSchema + total_sold_usd = schemas.StrSchema + total_tokens_bought = schemas.StrSchema + total_tokens_sold = schemas.StrSchema + total_usd_invested = schemas.StrSchema + __annotations__ = { + "avg_buy_price_usd": avg_buy_price_usd, + "avg_cost_of_quantity_sold": avg_cost_of_quantity_sold, + "avg_sell_price_usd": avg_sell_price_usd, + "count_of_trades": count_of_trades, + "realized_profit_percentage": realized_profit_percentage, + "realized_profit_usd": realized_profit_usd, + "total_sold_usd": total_sold_usd, + "total_tokens_bought": total_tokens_bought, + "total_tokens_sold": total_tokens_sold, + "total_usd_invested": total_usd_invested, + } + + + count_of_trades: MetaOapg.properties.count_of_trades + avg_sell_price_usd: MetaOapg.properties.avg_sell_price_usd + total_tokens_bought: MetaOapg.properties.total_tokens_bought + total_usd_invested: MetaOapg.properties.total_usd_invested + realized_profit_usd: MetaOapg.properties.realized_profit_usd + realized_profit_percentage: MetaOapg.properties.realized_profit_percentage + avg_buy_price_usd: MetaOapg.properties.avg_buy_price_usd + total_tokens_sold: MetaOapg.properties.total_tokens_sold + avg_cost_of_quantity_sold: MetaOapg.properties.avg_cost_of_quantity_sold + total_sold_usd: MetaOapg.properties.total_sold_usd + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_buy_price_usd"]) -> MetaOapg.properties.avg_buy_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_cost_of_quantity_sold"]) -> MetaOapg.properties.avg_cost_of_quantity_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["avg_sell_price_usd"]) -> MetaOapg.properties.avg_sell_price_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["count_of_trades"]) -> MetaOapg.properties.count_of_trades: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_percentage"]) -> MetaOapg.properties.realized_profit_percentage: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["realized_profit_usd"]) -> MetaOapg.properties.realized_profit_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_usd"]) -> MetaOapg.properties.total_sold_usd: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_bought"]) -> MetaOapg.properties.total_tokens_bought: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_tokens_sold"]) -> MetaOapg.properties.total_tokens_sold: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_invested"]) -> MetaOapg.properties.total_usd_invested: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["avg_buy_price_usd", "avg_cost_of_quantity_sold", "avg_sell_price_usd", "count_of_trades", "realized_profit_percentage", "realized_profit_usd", "total_sold_usd", "total_tokens_bought", "total_tokens_sold", "total_usd_invested", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + count_of_trades: typing.Union[MetaOapg.properties.count_of_trades, str, ], + avg_sell_price_usd: typing.Union[MetaOapg.properties.avg_sell_price_usd, str, ], + total_tokens_bought: typing.Union[MetaOapg.properties.total_tokens_bought, str, ], + total_usd_invested: typing.Union[MetaOapg.properties.total_usd_invested, str, ], + realized_profit_usd: typing.Union[MetaOapg.properties.realized_profit_usd, str, ], + realized_profit_percentage: typing.Union[MetaOapg.properties.realized_profit_percentage, str, ], + avg_buy_price_usd: typing.Union[MetaOapg.properties.avg_buy_price_usd, str, ], + total_tokens_sold: typing.Union[MetaOapg.properties.total_tokens_sold, str, ], + avg_cost_of_quantity_sold: typing.Union[MetaOapg.properties.avg_cost_of_quantity_sold, str, ], + total_sold_usd: typing.Union[MetaOapg.properties.total_sold_usd, str, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletTokenProfitabilityResponse': + return super().__new__( + cls, + *args, + count_of_trades=count_of_trades, + avg_sell_price_usd=avg_sell_price_usd, + total_tokens_bought=total_tokens_bought, + total_usd_invested=total_usd_invested, + realized_profit_usd=realized_profit_usd, + realized_profit_percentage=realized_profit_percentage, + avg_buy_price_usd=avg_buy_price_usd, + total_tokens_sold=total_tokens_sold, + avg_cost_of_quantity_sold=avg_cost_of_quantity_sold, + total_sold_usd=total_sold_usd, + _configuration=_configuration, + **kwargs, + ) diff --git a/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.py b/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.py new file mode 100644 index 0000000..815e949 --- /dev/null +++ b/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletTopProfitableWalletPerTokenResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "wallets", + } + + class properties: + + + class wallets( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['TopProfitableWalletPerTokenResponse']: + return TopProfitableWalletPerTokenResponse + + def __new__( + cls, + arg: typing.Union[typing.Tuple['TopProfitableWalletPerTokenResponse'], typing.List['TopProfitableWalletPerTokenResponse']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'wallets': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'TopProfitableWalletPerTokenResponse': + return super().__getitem__(i) + __annotations__ = { + "wallets": wallets, + } + + + wallets: MetaOapg.properties.wallets + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["wallets"]) -> MetaOapg.properties.wallets: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["wallets", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["wallets"]) -> MetaOapg.properties.wallets: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["wallets", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + wallets: typing.Union[MetaOapg.properties.wallets, list, tuple, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletTopProfitableWalletPerTokenResponse': + return super().__new__( + cls, + *args, + wallets=wallets, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.top_profitable_wallet_per_token_response import TopProfitableWalletPerTokenResponse diff --git a/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.pyi b/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.pyi new file mode 100644 index 0000000..815e949 --- /dev/null +++ b/src/openapi_evm_api/model/wallet_top_profitable_wallet_per_token_response.pyi @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + + +class WalletTopProfitableWalletPerTokenResponse( + schemas.AnyTypeSchema, +): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + + class MetaOapg: + required = { + "wallets", + } + + class properties: + + + class wallets( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['TopProfitableWalletPerTokenResponse']: + return TopProfitableWalletPerTokenResponse + + def __new__( + cls, + arg: typing.Union[typing.Tuple['TopProfitableWalletPerTokenResponse'], typing.List['TopProfitableWalletPerTokenResponse']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'wallets': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'TopProfitableWalletPerTokenResponse': + return super().__getitem__(i) + __annotations__ = { + "wallets": wallets, + } + + + wallets: MetaOapg.properties.wallets + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["wallets"]) -> MetaOapg.properties.wallets: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["wallets", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["wallets"]) -> MetaOapg.properties.wallets: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["wallets", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + wallets: typing.Union[MetaOapg.properties.wallets, list, tuple, ], + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'WalletTopProfitableWalletPerTokenResponse': + return super().__new__( + cls, + *args, + wallets=wallets, + _configuration=_configuration, + **kwargs, + ) + +from openapi_evm_api.model.top_profitable_wallet_per_token_response import TopProfitableWalletPerTokenResponse diff --git a/src/openapi_evm_api/models/__init__.py b/src/openapi_evm_api/models/__init__.py index 75fa834..06a32c9 100644 --- a/src/openapi_evm_api/models/__init__.py +++ b/src/openapi_evm_api/models/__init__.py @@ -19,10 +19,20 @@ from openapi_evm_api.model.block_transaction_verbose import BlockTransactionVerbose from openapi_evm_api.model.chain_list import ChainList from openapi_evm_api.model.chain_net_worth import ChainNetWorth +from openapi_evm_api.model.common_contract_data import CommonContractData +from openapi_evm_api.model.contract_spender_details import ContractSpenderDetails +from openapi_evm_api.model.contract_token_details import ContractTokenDetails from openapi_evm_api.model.contracts_review_dto import ContractsReviewDto from openapi_evm_api.model.contracts_review_item import ContractsReviewItem from openapi_evm_api.model.decoded_call import DecodedCall from openapi_evm_api.model.decoded_event import DecodedEvent +from openapi_evm_api.model.defi_position_details import DefiPositionDetails +from openapi_evm_api.model.defi_position_summary_response import DefiPositionSummaryResponse +from openapi_evm_api.model.defi_protocol_balance import DefiProtocolBalance +from openapi_evm_api.model.defi_protocol_list import DefiProtocolList +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition +from openapi_evm_api.model.defi_protocol_summary import DefiProtocolSummary +from openapi_evm_api.model.defi_token_balance import DefiTokenBalance from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList from openapi_evm_api.model.discovery_supported_time_frames import DiscoverySupportedTimeFrames from openapi_evm_api.model.discovery_token import DiscoveryToken @@ -78,24 +88,25 @@ from openapi_evm_api.model.nft_owner import NftOwner from openapi_evm_api.model.nft_owner_collection import NftOwnerCollection from openapi_evm_api.model.nft_token_stat import NftTokenStat +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList from openapi_evm_api.model.nft_transfer import NftTransfer from openapi_evm_api.model.nft_transfer_collection import NftTransferCollection from openapi_evm_api.model.nft_wallet_collections import NftWalletCollections from openapi_evm_api.model.normalized_metadata import NormalizedMetadata from openapi_evm_api.model.normalized_metadata_attribute import NormalizedMetadataAttribute -from openapi_evm_api.model.ohlc_candles import OhlcCandles -from openapi_evm_api.model.ohlc_interval_list import OhlcIntervalList -from openapi_evm_api.model.ohlc_response import OhlcResponse -from openapi_evm_api.model.ohlc_result import OhlcResult from openapi_evm_api.model.order_list import OrderList from openapi_evm_api.model.reserves_collection import ReservesCollection from openapi_evm_api.model.reserves_pair import ReservesPair from openapi_evm_api.model.resolve import Resolve +from openapi_evm_api.model.resolve_contract_interaction_response import ResolveContractInteractionResponse from openapi_evm_api.model.run_contract_dto import RunContractDto +from openapi_evm_api.model.sold_price import SoldPrice from openapi_evm_api.model.time_frames import TimeFrames +from openapi_evm_api.model.token_approval import TokenApproval from openapi_evm_api.model.token_item import TokenItem from openapi_evm_api.model.token_price_item import TokenPriceItem from openapi_evm_api.model.token_timestamp import TokenTimestamp +from openapi_evm_api.model.top_profitable_wallet_per_token_response import TopProfitableWalletPerTokenResponse from openapi_evm_api.model.trade import Trade from openapi_evm_api.model.trade_collection import TradeCollection from openapi_evm_api.model.transaction import Transaction @@ -105,9 +116,16 @@ from openapi_evm_api.model.unstoppable_domain import UnstoppableDomain from openapi_evm_api.model.wallet_active_chain import WalletActiveChain from openapi_evm_api.model.wallet_active_chains import WalletActiveChains +from openapi_evm_api.model.wallet_approvals import WalletApprovals +from openapi_evm_api.model.wallet_defi_protocol_position import WalletDefiProtocolPosition +from openapi_evm_api.model.wallet_defi_summary import WalletDefiSummary from openapi_evm_api.model.wallet_history import WalletHistory from openapi_evm_api.model.wallet_history_erc20_transfer import WalletHistoryErc20Transfer from openapi_evm_api.model.wallet_history_nft_transfer import WalletHistoryNftTransfer from openapi_evm_api.model.wallet_history_transaction import WalletHistoryTransaction +from openapi_evm_api.model.wallet_profitability_response import WalletProfitabilityResponse +from openapi_evm_api.model.wallet_profitability_token_data import WalletProfitabilityTokenData from openapi_evm_api.model.wallet_stat import WalletStat +from openapi_evm_api.model.wallet_token_profitability_response import WalletTokenProfitabilityResponse +from openapi_evm_api.model.wallet_top_profitable_wallet_per_token_response import WalletTopProfitableWalletPerTokenResponse from openapi_evm_api.model.web3version import Web3version diff --git a/src/openapi_evm_api/paths/__init__.py b/src/openapi_evm_api/paths/__init__.py index aeabcf1..e7ef3f9 100644 --- a/src/openapi_evm_api/paths/__init__.py +++ b/src/openapi_evm_api/paths/__init__.py @@ -16,6 +16,8 @@ class PathValues(str, enum.Enum): NFT_TRANSFERS = "/nft/transfers" BLOCK_BLOCK_NUMBER_OR_HASH_NFT_TRANSFERS = "/block/{block_number_or_hash}/nft/transfers" NFT_ADDRESS_TRADES = "/nft/{address}/trades" + NFT_ADDRESS_TOKEN_ID_TRADES = "/nft/{address}/{token_id}/trades" + WALLETS_ADDRESS_NFTS_TRADES = "/wallets/{address}/nfts/trades" NFT_ADDRESS_METADATA = "/nft/{address}/metadata" NFT_METADATA = "/nft/metadata" NFT_ADDRESS_TOKEN_ID = "/nft/{address}/{token_id}" @@ -24,6 +26,8 @@ class PathValues(str, enum.Enum): NFT_ADDRESS_SYNC = "/nft/{address}/sync" NFT_ADDRESS_TOKEN_ID_METADATA_RESYNC = "/nft/{address}/{token_id}/metadata/resync" NFT_ADDRESS_LOWESTPRICE = "/nft/{address}/lowestprice" + NFT_ADDRESS_PRICE = "/nft/{address}/price" + NFT_ADDRESS_TOKEN_ID_PRICE = "/nft/{address}/{token_id}/price" ERC20_ADDRESS_PRICE = "/erc20/{address}/price" ERC20_PRICES = "/erc20/prices" ERC20_TOKEN_ADDRESS_OWNERS = "/erc20/{token_address}/owners" @@ -65,6 +69,9 @@ class PathValues(str, enum.Enum): MARKETDATA_GLOBAL_MARKETCAP = "/market-data/global/market-cap" MARKETDATA_GLOBAL_VOLUME = "/market-data/global/volume" CONTRACTSREVIEW = "/contracts-review" + WALLETS_ADDRESS_DEFI_SUMMARY = "/wallets/{address}/defi/summary" + WALLETS_ADDRESS_DEFI_PROTOCOL_POSITIONS = "/wallets/{address}/defi/{protocol}/positions" + WALLETS_ADDRESS_DEFI_POSITIONS = "/wallets/{address}/defi/positions" WALLETS_ADDRESS_CHAINS = "/wallets/{address}/chains" WALLETS_ADDRESS_STATS = "/wallets/{address}/stats" NFT_ADDRESS_STATS = "/nft/{address}/stats" @@ -81,4 +88,6 @@ class PathValues(str, enum.Enum): DISCOVERY_TOKENS_TOPLOSERS = "/discovery/tokens/top-losers" DISCOVERY_TOKENS_TRENDING = "/discovery/tokens/trending" DISCOVERY_TOKEN = "/discovery/token" - TOKEN0_TOKEN1_OHLC = "/{token0}/{token1}/ohlc" + WALLETS_ADDRESS_PROFITABILITY_SUMMARY = "/wallets/{address}/profitability/summary" + WALLETS_ADDRESS_PROFITABILITY = "/wallets/{address}/profitability" + ERC20_ADDRESS_TOPGAINERS = "/erc20/{address}/top-gainers" diff --git a/src/openapi_evm_api/paths/erc20_address_top_gainers/__init__.py b/src/openapi_evm_api/paths/erc20_address_top_gainers/__init__.py new file mode 100644 index 0000000..ae8fd8f --- /dev/null +++ b/src/openapi_evm_api/paths/erc20_address_top_gainers/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.erc20_address_top_gainers import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.ERC20_ADDRESS_TOPGAINERS \ No newline at end of file diff --git a/src/openapi_evm_api/paths/erc20_address_top_gainers/get.py b/src/openapi_evm_api/paths/erc20_address_top_gainers/get.py new file mode 100644 index 0000000..d28f246 --- /dev/null +++ b/src/openapi_evm_api/paths/erc20_address_top_gainers/get.py @@ -0,0 +1,357 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList +from openapi_evm_api.model.wallet_top_profitable_wallet_per_token_response import WalletTopProfitableWalletPerTokenResponse + +from . import path + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = WalletTopProfitableWalletPerTokenResponse + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Top Profitable Wallets for a Token + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetTopProfitableWalletPerToken(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_top_profitable_wallet_per_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_top_profitable_wallet_per_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/erc20_address_top_gainers/get.pyi b/src/openapi_evm_api/paths/erc20_address_top_gainers/get.pyi new file mode 100644 index 0000000..ed1912b --- /dev/null +++ b/src/openapi_evm_api/paths/erc20_address_top_gainers/get.pyi @@ -0,0 +1,349 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList +from openapi_evm_api.model.wallet_top_profitable_wallet_per_token_response import WalletTopProfitableWalletPerTokenResponse + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = WalletTopProfitableWalletPerTokenResponse + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_top_profitable_wallet_per_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Top Profitable Wallets for a Token + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetTopProfitableWalletPerToken(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_top_profitable_wallet_per_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_top_profitable_wallet_per_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_top_profitable_wallet_per_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/nft_address_lowestprice/get.py b/src/openapi_evm_api/paths/nft_address_lowestprice/get.py index 3eae15e..f485f9c 100644 --- a/src/openapi_evm_api/paths/nft_address_lowestprice/get.py +++ b/src/openapi_evm_api/paths/nft_address_lowestprice/get.py @@ -25,13 +25,13 @@ from openapi_evm_api import schemas # noqa: F401 -from openapi_evm_api.model.chain_list import ChainList from openapi_evm_api.model.trade import Trade +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList from . import path # Query params -ChainSchema = ChainList +ChainSchema = NftTradesChainList class DaysSchema( @@ -52,11 +52,32 @@ class MarketplaceSchema( class MetaOapg: enum_value_to_name = { "opensea": "OPENSEA", + "blur": "BLUR", + "looksrare": "LOOKSRARE", + "x2y2": "X2Y2", + "0xprotocol": "XPROTOCOL", } @schemas.classproperty def OPENSEA(cls): return cls("opensea") + + @schemas.classproperty + def BLUR(cls): + return cls("blur") + + @schemas.classproperty + def LOOKSRARE(cls): + return cls("looksrare") + + @schemas.classproperty + def X2Y2(cls): + return cls("x2y2") + + @schemas.classproperty + def XPROTOCOL(cls): + return cls("0xprotocol") +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { @@ -68,6 +89,7 @@ def OPENSEA(cls): 'chain': typing.Union[ChainSchema, ], 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], 'marketplace': typing.Union[MarketplaceSchema, str, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -95,6 +117,12 @@ class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams) schema=MarketplaceSchema, explode=True, ) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) # Path params AddressSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( @@ -227,6 +255,7 @@ class instances request_query_chain, request_query_days, request_query_marketplace, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: diff --git a/src/openapi_evm_api/paths/nft_address_lowestprice/get.pyi b/src/openapi_evm_api/paths/nft_address_lowestprice/get.pyi index 44ddca4..8327e95 100644 --- a/src/openapi_evm_api/paths/nft_address_lowestprice/get.pyi +++ b/src/openapi_evm_api/paths/nft_address_lowestprice/get.pyi @@ -25,11 +25,11 @@ import frozendict # noqa: F401 from openapi_evm_api import schemas # noqa: F401 -from openapi_evm_api.model.chain_list import ChainList from openapi_evm_api.model.trade import Trade +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList # Query params -ChainSchema = ChainList +ChainSchema = NftTradesChainList class DaysSchema( @@ -46,6 +46,23 @@ class MarketplaceSchema( @schemas.classproperty def OPENSEA(cls): return cls("opensea") + + @schemas.classproperty + def BLUR(cls): + return cls("blur") + + @schemas.classproperty + def LOOKSRARE(cls): + return cls("looksrare") + + @schemas.classproperty + def X2Y2(cls): + return cls("x2y2") + + @schemas.classproperty + def XPROTOCOL(cls): + return cls("0xprotocol") +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { @@ -57,6 +74,7 @@ RequestOptionalQueryParams = typing_extensions.TypedDict( 'chain': typing.Union[ChainSchema, ], 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], 'marketplace': typing.Union[MarketplaceSchema, str, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -84,6 +102,12 @@ request_query_marketplace = api_client.QueryParameter( schema=MarketplaceSchema, explode=True, ) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) # Path params AddressSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( @@ -210,6 +234,7 @@ class BaseApi(api_client.Api): request_query_chain, request_query_days, request_query_marketplace, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: diff --git a/src/openapi_evm_api/paths/token0_token1_ohlc/__init__.py b/src/openapi_evm_api/paths/nft_address_price/__init__.py similarity index 70% rename from src/openapi_evm_api/paths/token0_token1_ohlc/__init__.py rename to src/openapi_evm_api/paths/nft_address_price/__init__.py index ab52299..60a5bc7 100644 --- a/src/openapi_evm_api/paths/token0_token1_ohlc/__init__.py +++ b/src/openapi_evm_api/paths/nft_address_price/__init__.py @@ -1,7 +1,7 @@ # do not import all endpoints into this module because that uses a lot of memory and stack frames # if you need the ability to import all endpoints from this module, import them with -# from openapi_evm_api.paths.token0_token1_ohlc import Api +# from openapi_evm_api.paths.nft_address_price import Api from openapi_evm_api.paths import PathValues -path = PathValues.TOKEN0_TOKEN1_OHLC \ No newline at end of file +path = PathValues.NFT_ADDRESS_PRICE \ No newline at end of file diff --git a/src/openapi_evm_api/paths/nft_address_price/get.py b/src/openapi_evm_api/paths/nft_address_price/get.py new file mode 100644 index 0000000..3c95390 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_price/get.py @@ -0,0 +1,365 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.sold_price import SoldPrice +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +from . import path + +# Query params +ChainSchema = NftTradesChainList + + +class DaysSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = SoldPrice + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT sold price by collection + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_days, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftContractSalePrices(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_contract_sale_prices( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_contract_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_contract_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/nft_address_price/get.pyi b/src/openapi_evm_api/paths/nft_address_price/get.pyi new file mode 100644 index 0000000..ca171e3 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_price/get.pyi @@ -0,0 +1,354 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.sold_price import SoldPrice +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +# Query params +ChainSchema = NftTradesChainList + + +class DaysSchema( + schemas.IntSchema +): + pass +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = SoldPrice + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_contract_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT sold price by collection + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_days, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftContractSalePrices(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_contract_sale_prices( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_contract_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_contract_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_contract_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/nft_address_token_id_price/__init__.py b/src/openapi_evm_api/paths/nft_address_token_id_price/__init__.py new file mode 100644 index 0000000..f7b5ec9 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_token_id_price/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.nft_address_token_id_price import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.NFT_ADDRESS_TOKEN_ID_PRICE \ No newline at end of file diff --git a/src/openapi_evm_api/paths/nft_address_token_id_price/get.py b/src/openapi_evm_api/paths/nft_address_token_id_price/get.py new file mode 100644 index 0000000..d6dcdd1 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_token_id_price/get.py @@ -0,0 +1,374 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.sold_price import SoldPrice +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +from . import path + +# Query params +ChainSchema = NftTradesChainList + + +class DaysSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +TokenIdSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + 'token_id': typing.Union[TokenIdSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +request_path_token_id = api_client.PathParameter( + name="token_id", + style=api_client.ParameterStyle.SIMPLE, + schema=TokenIdSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = SoldPrice + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_sale_prices_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT sold price by token + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + request_path_token_id, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_days, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftSalePrices(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_sale_prices( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/nft_address_token_id_price/get.pyi b/src/openapi_evm_api/paths/nft_address_token_id_price/get.pyi new file mode 100644 index 0000000..54da120 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_token_id_price/get.pyi @@ -0,0 +1,363 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.sold_price import SoldPrice +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +# Query params +ChainSchema = NftTradesChainList + + +class DaysSchema( + schemas.IntSchema +): + pass +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'days': typing.Union[DaysSchema, decimal.Decimal, int, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +TokenIdSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + 'token_id': typing.Union[TokenIdSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +request_path_token_id = api_client.PathParameter( + name="token_id", + style=api_client.ParameterStyle.SIMPLE, + schema=TokenIdSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = SoldPrice + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_sale_prices_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_sale_prices_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT sold price by token + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + request_path_token_id, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_days, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftSalePrices(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_sale_prices( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_sale_prices( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_sale_prices_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/nft_address_token_id_trades/__init__.py b/src/openapi_evm_api/paths/nft_address_token_id_trades/__init__.py new file mode 100644 index 0000000..2e30e39 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_token_id_trades/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.nft_address_token_id_trades import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.NFT_ADDRESS_TOKEN_ID_TRADES \ No newline at end of file diff --git a/src/openapi_evm_api/paths/nft_address_token_id_trades/get.py b/src/openapi_evm_api/paths/nft_address_token_id_trades/get.py new file mode 100644 index 0000000..f397340 --- /dev/null +++ b/src/openapi_evm_api/paths/nft_address_token_id_trades/get.py @@ -0,0 +1,436 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.trade_collection import TradeCollection +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +from . import path + +# Query params +ChainSchema = NftTradesChainList + + +class FromBlockSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +ToBlockSchema = schemas.StrSchema +FromDateSchema = schemas.StrSchema +ToDateSchema = schemas.StrSchema +CursorSchema = schemas.StrSchema + + +class LimitSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +NftMetadataSchema = schemas.BoolSchema +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'from_block': typing.Union[FromBlockSchema, decimal.Decimal, int, ], + 'to_block': typing.Union[ToBlockSchema, str, ], + 'from_date': typing.Union[FromDateSchema, str, ], + 'to_date': typing.Union[ToDateSchema, str, ], + 'cursor': typing.Union[CursorSchema, str, ], + 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_from_block = api_client.QueryParameter( + name="from_block", + style=api_client.ParameterStyle.FORM, + schema=FromBlockSchema, + explode=True, +) +request_query_to_block = api_client.QueryParameter( + name="to_block", + style=api_client.ParameterStyle.FORM, + schema=ToBlockSchema, + explode=True, +) +request_query_from_date = api_client.QueryParameter( + name="from_date", + style=api_client.ParameterStyle.FORM, + schema=FromDateSchema, + explode=True, +) +request_query_to_date = api_client.QueryParameter( + name="to_date", + style=api_client.ParameterStyle.FORM, + schema=ToDateSchema, + explode=True, +) +request_query_cursor = api_client.QueryParameter( + name="cursor", + style=api_client.ParameterStyle.FORM, + schema=CursorSchema, + explode=True, +) +request_query_limit = api_client.QueryParameter( + name="limit", + style=api_client.ParameterStyle.FORM, + schema=LimitSchema, + explode=True, +) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +TokenIdSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + 'token_id': typing.Union[TokenIdSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +request_path_token_id = api_client.PathParameter( + name="token_id", + style=api_client.ParameterStyle.SIMPLE, + schema=TokenIdSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = TradeCollection + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_trades_by_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_trades_by_token_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_trades_by_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_trades_by_token_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT trades by token + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + request_path_token_id, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_from_block, + request_query_to_block, + request_query_from_date, + request_query_to_date, + request_query_cursor, + request_query_limit, + request_query_nft_metadata, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftTradesByToken(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_trades_by_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_trades_by_token( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_trades_by_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_trades_by_token( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_trades_by_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_trades_by_token_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/token0_token1_ohlc/get.pyi b/src/openapi_evm_api/paths/nft_address_token_id_trades/get.pyi similarity index 86% rename from src/openapi_evm_api/paths/token0_token1_ohlc/get.pyi rename to src/openapi_evm_api/paths/nft_address_token_id_trades/get.pyi index 8827088..8c3adcf 100644 --- a/src/openapi_evm_api/paths/token0_token1_ohlc/get.pyi +++ b/src/openapi_evm_api/paths/nft_address_token_id_trades/get.pyi @@ -25,34 +25,44 @@ import frozendict # noqa: F401 from openapi_evm_api import schemas # noqa: F401 -from openapi_evm_api.model.ohlc_response import OhlcResponse -from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.trade_collection import TradeCollection +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList # Query params -ChainSchema = ChainList -ExchangeSchema = schemas.StrSchema -IntervalSchema = schemas.StrSchema -PriceFormatSchema = schemas.StrSchema +ChainSchema = NftTradesChainList + + +class FromBlockSchema( + schemas.IntSchema +): + pass +ToBlockSchema = schemas.StrSchema FromDateSchema = schemas.StrSchema ToDateSchema = schemas.StrSchema -LimitSchema = schemas.IntSchema CursorSchema = schemas.StrSchema + + +class LimitSchema( + schemas.IntSchema +): + pass +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { - 'exchange': typing.Union[ExchangeSchema, str, ], - 'interval': typing.Union[IntervalSchema, str, ], - 'price_format': typing.Union[PriceFormatSchema, str, ], - 'from_date': typing.Union[FromDateSchema, str, ], - 'to_date': typing.Union[ToDateSchema, str, ], } ) RequestOptionalQueryParams = typing_extensions.TypedDict( 'RequestOptionalQueryParams', { 'chain': typing.Union[ChainSchema, ], - 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'from_block': typing.Union[FromBlockSchema, decimal.Decimal, int, ], + 'to_block': typing.Union[ToBlockSchema, str, ], + 'from_date': typing.Union[FromDateSchema, str, ], + 'to_date': typing.Union[ToDateSchema, str, ], 'cursor': typing.Union[CursorSchema, str, ], + 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -68,39 +78,34 @@ request_query_chain = api_client.QueryParameter( schema=ChainSchema, explode=True, ) -request_query_exchange = api_client.QueryParameter( - name="exchange", +request_query_from_block = api_client.QueryParameter( + name="from_block", style=api_client.ParameterStyle.FORM, - schema=ExchangeSchema, - required=True, + schema=FromBlockSchema, explode=True, ) -request_query_interval = api_client.QueryParameter( - name="interval", +request_query_to_block = api_client.QueryParameter( + name="to_block", style=api_client.ParameterStyle.FORM, - schema=IntervalSchema, - required=True, - explode=True, -) -request_query_price_format = api_client.QueryParameter( - name="price_format", - style=api_client.ParameterStyle.FORM, - schema=PriceFormatSchema, - required=True, + schema=ToBlockSchema, explode=True, ) request_query_from_date = api_client.QueryParameter( name="from_date", style=api_client.ParameterStyle.FORM, schema=FromDateSchema, - required=True, explode=True, ) request_query_to_date = api_client.QueryParameter( name="to_date", style=api_client.ParameterStyle.FORM, schema=ToDateSchema, - required=True, + explode=True, +) +request_query_cursor = api_client.QueryParameter( + name="cursor", + style=api_client.ParameterStyle.FORM, + schema=CursorSchema, explode=True, ) request_query_limit = api_client.QueryParameter( @@ -109,20 +114,20 @@ request_query_limit = api_client.QueryParameter( schema=LimitSchema, explode=True, ) -request_query_cursor = api_client.QueryParameter( - name="cursor", +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", style=api_client.ParameterStyle.FORM, - schema=CursorSchema, + schema=NftMetadataSchema, explode=True, ) # Path params -Token0Schema = schemas.StrSchema -Token1Schema = schemas.StrSchema +AddressSchema = schemas.StrSchema +TokenIdSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( 'RequestRequiredPathParams', { - 'token0': typing.Union[Token0Schema, str, ], - 'token1': typing.Union[Token1Schema, str, ], + 'address': typing.Union[AddressSchema, str, ], + 'token_id': typing.Union[TokenIdSchema, str, ], } ) RequestOptionalPathParams = typing_extensions.TypedDict( @@ -137,19 +142,19 @@ class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): pass -request_path_token0 = api_client.PathParameter( - name="token0", +request_path_address = api_client.PathParameter( + name="address", style=api_client.ParameterStyle.SIMPLE, - schema=Token0Schema, + schema=AddressSchema, required=True, ) -request_path_token1 = api_client.PathParameter( - name="token1", +request_path_token_id = api_client.PathParameter( + name="token_id", style=api_client.ParameterStyle.SIMPLE, - schema=Token1Schema, + schema=TokenIdSchema, required=True, ) -SchemaFor200ResponseBodyApplicationJson = OhlcResponse +SchemaFor200ResponseBodyApplicationJson = TradeCollection @dataclass @@ -175,7 +180,7 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_token_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -188,7 +193,7 @@ class BaseApi(api_client.Api): ]: ... @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_token_oapg( self, skip_deserialization: typing_extensions.Literal[True], query_params: RequestQueryParams = frozendict.frozendict(), @@ -199,7 +204,7 @@ class BaseApi(api_client.Api): ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_token_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -212,7 +217,7 @@ class BaseApi(api_client.Api): api_client.ApiResponseWithoutDeserialization, ]: ... - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_token_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -222,7 +227,7 @@ class BaseApi(api_client.Api): skip_deserialization: bool = False, ): """ - Get OHLC candle sticks of token pair + Get NFT trades by token :param skip_deserialization: If true then api_response.response will be set but api_response.body and api_response.headers will not be deserialized into schema class instances @@ -233,8 +238,8 @@ class BaseApi(api_client.Api): _path_params = {} for parameter in ( - request_path_token0, - request_path_token1, + request_path_address, + request_path_token_id, ): parameter_data = path_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: @@ -248,13 +253,13 @@ class BaseApi(api_client.Api): prefix_separator_iterator = None for parameter in ( request_query_chain, - request_query_exchange, - request_query_interval, - request_query_price_format, + request_query_from_block, + request_query_to_block, request_query_from_date, request_query_to_date, - request_query_limit, request_query_cursor, + request_query_limit, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: @@ -295,11 +300,11 @@ class BaseApi(api_client.Api): return api_response -class GetTokenPairOhlc(BaseApi): +class GetNftTradesByToken(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_token( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -312,7 +317,7 @@ class GetTokenPairOhlc(BaseApi): ]: ... @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_token( self, skip_deserialization: typing_extensions.Literal[True], query_params: RequestQueryParams = frozendict.frozendict(), @@ -323,7 +328,7 @@ class GetTokenPairOhlc(BaseApi): ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_token( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -336,7 +341,7 @@ class GetTokenPairOhlc(BaseApi): api_client.ApiResponseWithoutDeserialization, ]: ... - def get_token_pair_ohlc( + def get_nft_trades_by_token( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -345,7 +350,7 @@ class GetTokenPairOhlc(BaseApi): timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, ): - return self._get_token_pair_ohlc_oapg( + return self._get_nft_trades_by_token_oapg( query_params=query_params, path_params=path_params, accept_content_types=accept_content_types, @@ -405,7 +410,7 @@ class ApiForget(BaseApi): timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, ): - return self._get_token_pair_ohlc_oapg( + return self._get_nft_trades_by_token_oapg( query_params=query_params, path_params=path_params, accept_content_types=accept_content_types, diff --git a/src/openapi_evm_api/paths/nft_address_trades/get.py b/src/openapi_evm_api/paths/nft_address_trades/get.py index 66f6332..677b7e4 100644 --- a/src/openapi_evm_api/paths/nft_address_trades/get.py +++ b/src/openapi_evm_api/paths/nft_address_trades/get.py @@ -26,12 +26,12 @@ from openapi_evm_api import schemas # noqa: F401 from openapi_evm_api.model.trade_collection import TradeCollection -from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList from . import path # Query params -ChainSchema = ChainList +ChainSchema = NftTradesChainList class FromBlockSchema( @@ -55,11 +55,31 @@ class MarketplaceSchema( class MetaOapg: enum_value_to_name = { "opensea": "OPENSEA", + "blur": "BLUR", + "looksrare": "LOOKSRARE", + "x2y2": "X2Y2", + "0xprotocol": "XPROTOCOL", } @schemas.classproperty def OPENSEA(cls): return cls("opensea") + + @schemas.classproperty + def BLUR(cls): + return cls("blur") + + @schemas.classproperty + def LOOKSRARE(cls): + return cls("looksrare") + + @schemas.classproperty + def X2Y2(cls): + return cls("x2y2") + + @schemas.classproperty + def XPROTOCOL(cls): + return cls("0xprotocol") CursorSchema = schemas.StrSchema @@ -70,6 +90,7 @@ class LimitSchema( class MetaOapg: inclusive_minimum = 0 +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { @@ -86,6 +107,7 @@ class MetaOapg: 'marketplace': typing.Union[MarketplaceSchema, str, ], 'cursor': typing.Union[CursorSchema, str, ], 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -143,6 +165,12 @@ class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams) schema=LimitSchema, explode=True, ) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) # Path params AddressSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( @@ -248,7 +276,7 @@ def _get_nft_trades_oapg( skip_deserialization: bool = False, ): """ - Get NFT trades by marketplace + Get NFT trades by collection :param skip_deserialization: If true then api_response.response will be set but api_response.body and api_response.headers will not be deserialized into schema class instances @@ -280,6 +308,7 @@ class instances request_query_marketplace, request_query_cursor, request_query_limit, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: diff --git a/src/openapi_evm_api/paths/nft_address_trades/get.pyi b/src/openapi_evm_api/paths/nft_address_trades/get.pyi index 6ea05ec..1133495 100644 --- a/src/openapi_evm_api/paths/nft_address_trades/get.pyi +++ b/src/openapi_evm_api/paths/nft_address_trades/get.pyi @@ -26,10 +26,10 @@ import frozendict # noqa: F401 from openapi_evm_api import schemas # noqa: F401 from openapi_evm_api.model.trade_collection import TradeCollection -from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList # Query params -ChainSchema = ChainList +ChainSchema = NftTradesChainList class FromBlockSchema( @@ -49,6 +49,22 @@ class MarketplaceSchema( @schemas.classproperty def OPENSEA(cls): return cls("opensea") + + @schemas.classproperty + def BLUR(cls): + return cls("blur") + + @schemas.classproperty + def LOOKSRARE(cls): + return cls("looksrare") + + @schemas.classproperty + def X2Y2(cls): + return cls("x2y2") + + @schemas.classproperty + def XPROTOCOL(cls): + return cls("0xprotocol") CursorSchema = schemas.StrSchema @@ -56,6 +72,7 @@ class LimitSchema( schemas.IntSchema ): pass +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { @@ -72,6 +89,7 @@ RequestOptionalQueryParams = typing_extensions.TypedDict( 'marketplace': typing.Union[MarketplaceSchema, str, ], 'cursor': typing.Union[CursorSchema, str, ], 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -129,6 +147,12 @@ request_query_limit = api_client.QueryParameter( schema=LimitSchema, explode=True, ) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) # Path params AddressSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( @@ -228,7 +252,7 @@ class BaseApi(api_client.Api): skip_deserialization: bool = False, ): """ - Get NFT trades by marketplace + Get NFT trades by collection :param skip_deserialization: If true then api_response.response will be set but api_response.body and api_response.headers will not be deserialized into schema class instances @@ -260,6 +284,7 @@ class BaseApi(api_client.Api): request_query_marketplace, request_query_cursor, request_query_limit, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: diff --git a/src/openapi_evm_api/paths/wallets_address_defi_positions/__init__.py b/src/openapi_evm_api/paths/wallets_address_defi_positions/__init__.py new file mode 100644 index 0000000..f20fe0d --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_positions/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_defi_positions import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_DEFI_POSITIONS \ No newline at end of file diff --git a/src/openapi_evm_api/paths/wallets_address_defi_positions/get.py b/src/openapi_evm_api/paths/wallets_address_defi_positions/get.py new file mode 100644 index 0000000..7b34d43 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_positions/get.py @@ -0,0 +1,373 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.defi_position_summary_response import DefiPositionSummaryResponse +from openapi_evm_api.model.chain_list import ChainList + +from . import path + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.ListSchema +): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiPositionSummaryResponse']: + return DefiPositionSummaryResponse + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiPositionSummaryResponse'], typing.List['DefiPositionSummaryResponse']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiPositionSummaryResponse': + return super().__getitem__(i) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_positions_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get the positions summary of a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiPositionsSummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_positions_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_defi_positions/get.pyi b/src/openapi_evm_api/paths/wallets_address_defi_positions/get.pyi new file mode 100644 index 0000000..ee621a5 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_positions/get.pyi @@ -0,0 +1,365 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.defi_position_summary_response import DefiPositionSummaryResponse +from openapi_evm_api.model.chain_list import ChainList + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.ListSchema +): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiPositionSummaryResponse']: + return DefiPositionSummaryResponse + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiPositionSummaryResponse'], typing.List['DefiPositionSummaryResponse']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiPositionSummaryResponse': + return super().__getitem__(i) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_positions_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_positions_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get the positions summary of a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiPositionsSummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_positions_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_positions_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/__init__.py b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/__init__.py new file mode 100644 index 0000000..7dcac17 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_defi_protocol_positions import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_DEFI_PROTOCOL_POSITIONS \ No newline at end of file diff --git a/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.py b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.py new file mode 100644 index 0000000..03ad041 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.py @@ -0,0 +1,511 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition +from openapi_evm_api.model.defi_protocol_list import DefiProtocolList + +from . import path + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +ProtocolSchema = DefiProtocolList +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + 'protocol': typing.Union[ProtocolSchema, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +request_path_protocol = api_client.PathParameter( + name="protocol", + style=api_client.ParameterStyle.SIMPLE, + schema=ProtocolSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.DictSchema +): + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + total_usd_value = schemas.NumberSchema + + + class total_unclaimed_usd_value( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'total_unclaimed_usd_value': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class positions( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolPosition']: + return DefiProtocolPosition + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolPosition'], typing.List['DefiProtocolPosition']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'positions': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolPosition': + return super().__getitem__(i) + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "total_usd_value": total_usd_value, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + "positions": positions, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "total_usd_value", "total_unclaimed_usd_value", "positions", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> typing.Union[MetaOapg.properties.total_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> typing.Union[MetaOapg.properties.positions, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "total_usd_value", "total_unclaimed_usd_value", "positions", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + positions: typing.Union[MetaOapg.properties.positions, list, tuple, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + positions=positions, + _configuration=_configuration, + **kwargs, + ) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get detailed defi positions by protocol for a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + request_path_protocol, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiPositionsByProtocol(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_positions_by_protocol( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_by_protocol_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_by_protocol_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.pyi b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.pyi new file mode 100644 index 0000000..851d854 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_protocol_positions/get.pyi @@ -0,0 +1,503 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition +from openapi_evm_api.model.defi_protocol_list import DefiProtocolList + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +ProtocolSchema = DefiProtocolList +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + 'protocol': typing.Union[ProtocolSchema, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +request_path_protocol = api_client.PathParameter( + name="protocol", + style=api_client.ParameterStyle.SIMPLE, + schema=ProtocolSchema, + required=True, +) + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.DictSchema +): + + + class MetaOapg: + + class properties: + protocol_name = schemas.StrSchema + protocol_id = schemas.StrSchema + protocol_url = schemas.StrSchema + protocol_logo = schemas.StrSchema + total_usd_value = schemas.NumberSchema + + + class total_unclaimed_usd_value( + schemas.NumberBase, + schemas.NoneBase, + schemas.Schema, + schemas.NoneDecimalMixin + ): + + + def __new__( + cls, + *args: typing.Union[None, decimal.Decimal, int, float, ], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'total_unclaimed_usd_value': + return super().__new__( + cls, + *args, + _configuration=_configuration, + ) + + + class positions( + schemas.ListSchema + ): + + + class MetaOapg: + + @staticmethod + def items() -> typing.Type['DefiProtocolPosition']: + return DefiProtocolPosition + + def __new__( + cls, + arg: typing.Union[typing.Tuple['DefiProtocolPosition'], typing.List['DefiProtocolPosition']], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'positions': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> 'DefiProtocolPosition': + return super().__getitem__(i) + __annotations__ = { + "protocol_name": protocol_name, + "protocol_id": protocol_id, + "protocol_url": protocol_url, + "protocol_logo": protocol_logo, + "total_usd_value": total_usd_value, + "total_unclaimed_usd_value": total_unclaimed_usd_value, + "positions": positions, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_name"]) -> MetaOapg.properties.protocol_name: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_id"]) -> MetaOapg.properties.protocol_id: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_url"]) -> MetaOapg.properties.protocol_url: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["protocol_logo"]) -> MetaOapg.properties.protocol_logo: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_usd_value"]) -> MetaOapg.properties.total_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> MetaOapg.properties.total_unclaimed_usd_value: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["positions"]) -> MetaOapg.properties.positions: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "total_usd_value", "total_unclaimed_usd_value", "positions", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_name"]) -> typing.Union[MetaOapg.properties.protocol_name, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_id"]) -> typing.Union[MetaOapg.properties.protocol_id, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_url"]) -> typing.Union[MetaOapg.properties.protocol_url, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["protocol_logo"]) -> typing.Union[MetaOapg.properties.protocol_logo, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_usd_value"]) -> typing.Union[MetaOapg.properties.total_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_unclaimed_usd_value"]) -> typing.Union[MetaOapg.properties.total_unclaimed_usd_value, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["positions"]) -> typing.Union[MetaOapg.properties.positions, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["protocol_name", "protocol_id", "protocol_url", "protocol_logo", "total_usd_value", "total_unclaimed_usd_value", "positions", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + protocol_name: typing.Union[MetaOapg.properties.protocol_name, str, schemas.Unset] = schemas.unset, + protocol_id: typing.Union[MetaOapg.properties.protocol_id, str, schemas.Unset] = schemas.unset, + protocol_url: typing.Union[MetaOapg.properties.protocol_url, str, schemas.Unset] = schemas.unset, + protocol_logo: typing.Union[MetaOapg.properties.protocol_logo, str, schemas.Unset] = schemas.unset, + total_usd_value: typing.Union[MetaOapg.properties.total_usd_value, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_unclaimed_usd_value: typing.Union[MetaOapg.properties.total_unclaimed_usd_value, None, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + positions: typing.Union[MetaOapg.properties.positions, list, tuple, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + *args, + protocol_name=protocol_name, + protocol_id=protocol_id, + protocol_url=protocol_url, + protocol_logo=protocol_logo, + total_usd_value=total_usd_value, + total_unclaimed_usd_value=total_unclaimed_usd_value, + positions=positions, + _configuration=_configuration, + **kwargs, + ) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_positions_by_protocol_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get detailed defi positions by protocol for a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + request_path_protocol, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiPositionsByProtocol(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_positions_by_protocol( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_positions_by_protocol( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_by_protocol_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_positions_by_protocol_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_defi_summary/__init__.py b/src/openapi_evm_api/paths/wallets_address_defi_summary/__init__.py new file mode 100644 index 0000000..24b681a --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_summary/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_defi_summary import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_DEFI_SUMMARY \ No newline at end of file diff --git a/src/openapi_evm_api/paths/wallets_address_defi_summary/get.py b/src/openapi_evm_api/paths/wallets_address_defi_summary/get.py new file mode 100644 index 0000000..f146de9 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_summary/get.py @@ -0,0 +1,348 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.wallet_defi_summary import WalletDefiSummary + +from . import path + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = WalletDefiSummary + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get the defi summary of a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiSummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_defi_summary/get.pyi b/src/openapi_evm_api/paths/wallets_address_defi_summary/get.pyi new file mode 100644 index 0000000..c0869b8 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_defi_summary/get.pyi @@ -0,0 +1,340 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.wallet_defi_summary import WalletDefiSummary + +# Query params +ChainSchema = ChainList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = WalletDefiSummary + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_defi_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_defi_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get the defi summary of a wallet + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetDefiSummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_defi_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_defi_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_defi_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_history/get.py b/src/openapi_evm_api/paths/wallets_address_history/get.py index e9f4894..923c406 100644 --- a/src/openapi_evm_api/paths/wallets_address_history/get.py +++ b/src/openapi_evm_api/paths/wallets_address_history/get.py @@ -55,6 +55,7 @@ class MetaOapg: ToDateSchema = schemas.StrSchema IncludeInternalTransactionsSchema = schemas.BoolSchema IncludeInputDataSchema = schemas.BoolSchema +IncludeLogsDataSchema = schemas.BoolSchema NftMetadataSchema = schemas.BoolSchema CursorSchema = schemas.StrSchema OrderSchema = OrderList @@ -82,6 +83,7 @@ class MetaOapg: 'to_date': typing.Union[ToDateSchema, str, ], 'include_internal_transactions': typing.Union[IncludeInternalTransactionsSchema, bool, ], 'include_input_data': typing.Union[IncludeInputDataSchema, bool, ], + 'include_logs_data': typing.Union[IncludeLogsDataSchema, bool, ], 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], 'cursor': typing.Union[CursorSchema, str, ], 'order': typing.Union[OrderSchema, ], @@ -137,6 +139,12 @@ class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams) schema=IncludeInputDataSchema, explode=True, ) +request_query_include_logs_data = api_client.QueryParameter( + name="include_logs_data", + style=api_client.ParameterStyle.FORM, + schema=IncludeLogsDataSchema, + explode=True, +) request_query_nft_metadata = api_client.QueryParameter( name="nft_metadata", style=api_client.ParameterStyle.FORM, @@ -297,6 +305,7 @@ class instances request_query_to_date, request_query_include_internal_transactions, request_query_include_input_data, + request_query_include_logs_data, request_query_nft_metadata, request_query_cursor, request_query_order, diff --git a/src/openapi_evm_api/paths/wallets_address_history/get.pyi b/src/openapi_evm_api/paths/wallets_address_history/get.pyi index fb7c73d..297c67e 100644 --- a/src/openapi_evm_api/paths/wallets_address_history/get.pyi +++ b/src/openapi_evm_api/paths/wallets_address_history/get.pyi @@ -47,6 +47,7 @@ FromDateSchema = schemas.StrSchema ToDateSchema = schemas.StrSchema IncludeInternalTransactionsSchema = schemas.BoolSchema IncludeInputDataSchema = schemas.BoolSchema +IncludeLogsDataSchema = schemas.BoolSchema NftMetadataSchema = schemas.BoolSchema CursorSchema = schemas.StrSchema OrderSchema = OrderList @@ -71,6 +72,7 @@ RequestOptionalQueryParams = typing_extensions.TypedDict( 'to_date': typing.Union[ToDateSchema, str, ], 'include_internal_transactions': typing.Union[IncludeInternalTransactionsSchema, bool, ], 'include_input_data': typing.Union[IncludeInputDataSchema, bool, ], + 'include_logs_data': typing.Union[IncludeLogsDataSchema, bool, ], 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], 'cursor': typing.Union[CursorSchema, str, ], 'order': typing.Union[OrderSchema, ], @@ -126,6 +128,12 @@ request_query_include_input_data = api_client.QueryParameter( schema=IncludeInputDataSchema, explode=True, ) +request_query_include_logs_data = api_client.QueryParameter( + name="include_logs_data", + style=api_client.ParameterStyle.FORM, + schema=IncludeLogsDataSchema, + explode=True, +) request_query_nft_metadata = api_client.QueryParameter( name="nft_metadata", style=api_client.ParameterStyle.FORM, @@ -280,6 +288,7 @@ class BaseApi(api_client.Api): request_query_to_date, request_query_include_internal_transactions, request_query_include_input_data, + request_query_include_logs_data, request_query_nft_metadata, request_query_cursor, request_query_order, diff --git a/src/openapi_evm_api/paths/wallets_address_nfts_trades/__init__.py b/src/openapi_evm_api/paths/wallets_address_nfts_trades/__init__.py new file mode 100644 index 0000000..65469fd --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_nfts_trades/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_nfts_trades import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_NFTS_TRADES \ No newline at end of file diff --git a/src/openapi_evm_api/paths/token0_token1_ohlc/get.py b/src/openapi_evm_api/paths/wallets_address_nfts_trades/get.py similarity index 86% rename from src/openapi_evm_api/paths/token0_token1_ohlc/get.py rename to src/openapi_evm_api/paths/wallets_address_nfts_trades/get.py index e55bf7d..5380630 100644 --- a/src/openapi_evm_api/paths/token0_token1_ohlc/get.py +++ b/src/openapi_evm_api/paths/wallets_address_nfts_trades/get.py @@ -25,36 +25,52 @@ from openapi_evm_api import schemas # noqa: F401 -from openapi_evm_api.model.ohlc_response import OhlcResponse -from openapi_evm_api.model.chain_list import ChainList +from openapi_evm_api.model.trade_collection import TradeCollection +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList from . import path # Query params -ChainSchema = ChainList -ExchangeSchema = schemas.StrSchema -IntervalSchema = schemas.StrSchema -PriceFormatSchema = schemas.StrSchema +ChainSchema = NftTradesChainList + + +class FromBlockSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +ToBlockSchema = schemas.StrSchema FromDateSchema = schemas.StrSchema ToDateSchema = schemas.StrSchema -LimitSchema = schemas.IntSchema CursorSchema = schemas.StrSchema + + +class LimitSchema( + schemas.IntSchema +): + + + class MetaOapg: + inclusive_minimum = 0 +NftMetadataSchema = schemas.BoolSchema RequestRequiredQueryParams = typing_extensions.TypedDict( 'RequestRequiredQueryParams', { - 'exchange': typing.Union[ExchangeSchema, str, ], - 'interval': typing.Union[IntervalSchema, str, ], - 'price_format': typing.Union[PriceFormatSchema, str, ], - 'from_date': typing.Union[FromDateSchema, str, ], - 'to_date': typing.Union[ToDateSchema, str, ], } ) RequestOptionalQueryParams = typing_extensions.TypedDict( 'RequestOptionalQueryParams', { 'chain': typing.Union[ChainSchema, ], - 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'from_block': typing.Union[FromBlockSchema, decimal.Decimal, int, ], + 'to_block': typing.Union[ToBlockSchema, str, ], + 'from_date': typing.Union[FromDateSchema, str, ], + 'to_date': typing.Union[ToDateSchema, str, ], 'cursor': typing.Union[CursorSchema, str, ], + 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], }, total=False ) @@ -70,39 +86,34 @@ class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams) schema=ChainSchema, explode=True, ) -request_query_exchange = api_client.QueryParameter( - name="exchange", - style=api_client.ParameterStyle.FORM, - schema=ExchangeSchema, - required=True, - explode=True, -) -request_query_interval = api_client.QueryParameter( - name="interval", +request_query_from_block = api_client.QueryParameter( + name="from_block", style=api_client.ParameterStyle.FORM, - schema=IntervalSchema, - required=True, + schema=FromBlockSchema, explode=True, ) -request_query_price_format = api_client.QueryParameter( - name="price_format", +request_query_to_block = api_client.QueryParameter( + name="to_block", style=api_client.ParameterStyle.FORM, - schema=PriceFormatSchema, - required=True, + schema=ToBlockSchema, explode=True, ) request_query_from_date = api_client.QueryParameter( name="from_date", style=api_client.ParameterStyle.FORM, schema=FromDateSchema, - required=True, explode=True, ) request_query_to_date = api_client.QueryParameter( name="to_date", style=api_client.ParameterStyle.FORM, schema=ToDateSchema, - required=True, + explode=True, +) +request_query_cursor = api_client.QueryParameter( + name="cursor", + style=api_client.ParameterStyle.FORM, + schema=CursorSchema, explode=True, ) request_query_limit = api_client.QueryParameter( @@ -111,20 +122,18 @@ class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams) schema=LimitSchema, explode=True, ) -request_query_cursor = api_client.QueryParameter( - name="cursor", +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", style=api_client.ParameterStyle.FORM, - schema=CursorSchema, + schema=NftMetadataSchema, explode=True, ) # Path params -Token0Schema = schemas.StrSchema -Token1Schema = schemas.StrSchema +AddressSchema = schemas.StrSchema RequestRequiredPathParams = typing_extensions.TypedDict( 'RequestRequiredPathParams', { - 'token0': typing.Union[Token0Schema, str, ], - 'token1': typing.Union[Token1Schema, str, ], + 'address': typing.Union[AddressSchema, str, ], } ) RequestOptionalPathParams = typing_extensions.TypedDict( @@ -139,22 +148,16 @@ class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): pass -request_path_token0 = api_client.PathParameter( - name="token0", +request_path_address = api_client.PathParameter( + name="address", style=api_client.ParameterStyle.SIMPLE, - schema=Token0Schema, - required=True, -) -request_path_token1 = api_client.PathParameter( - name="token1", - style=api_client.ParameterStyle.SIMPLE, - schema=Token1Schema, + schema=AddressSchema, required=True, ) _auth = [ 'ApiKeyAuth', ] -SchemaFor200ResponseBodyApplicationJson = OhlcResponse +SchemaFor200ResponseBodyApplicationJson = TradeCollection @dataclass @@ -183,7 +186,7 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_wallet_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -196,7 +199,7 @@ def _get_token_pair_ohlc_oapg( ]: ... @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_wallet_oapg( self, skip_deserialization: typing_extensions.Literal[True], query_params: RequestQueryParams = frozendict.frozendict(), @@ -207,7 +210,7 @@ def _get_token_pair_ohlc_oapg( ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_wallet_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -220,7 +223,7 @@ def _get_token_pair_ohlc_oapg( api_client.ApiResponseWithoutDeserialization, ]: ... - def _get_token_pair_ohlc_oapg( + def _get_nft_trades_by_wallet_oapg( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -230,7 +233,7 @@ def _get_token_pair_ohlc_oapg( skip_deserialization: bool = False, ): """ - Get OHLC candle sticks of token pair + Get NFT trades by wallet address :param skip_deserialization: If true then api_response.response will be set but api_response.body and api_response.headers will not be deserialized into schema class instances @@ -241,8 +244,7 @@ class instances _path_params = {} for parameter in ( - request_path_token0, - request_path_token1, + request_path_address, ): parameter_data = path_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: @@ -256,13 +258,13 @@ class instances prefix_separator_iterator = None for parameter in ( request_query_chain, - request_query_exchange, - request_query_interval, - request_query_price_format, + request_query_from_block, + request_query_to_block, request_query_from_date, request_query_to_date, - request_query_limit, request_query_cursor, + request_query_limit, + request_query_nft_metadata, ): parameter_data = query_params.get(parameter.name, schemas.unset) if parameter_data is schemas.unset: @@ -303,11 +305,11 @@ class instances return api_response -class GetTokenPairOhlc(BaseApi): +class GetNftTradesByWallet(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_wallet( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -320,7 +322,7 @@ def get_token_pair_ohlc( ]: ... @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_wallet( self, skip_deserialization: typing_extensions.Literal[True], query_params: RequestQueryParams = frozendict.frozendict(), @@ -331,7 +333,7 @@ def get_token_pair_ohlc( ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload - def get_token_pair_ohlc( + def get_nft_trades_by_wallet( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -344,7 +346,7 @@ def get_token_pair_ohlc( api_client.ApiResponseWithoutDeserialization, ]: ... - def get_token_pair_ohlc( + def get_nft_trades_by_wallet( self, query_params: RequestQueryParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), @@ -353,7 +355,7 @@ def get_token_pair_ohlc( timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, ): - return self._get_token_pair_ohlc_oapg( + return self._get_nft_trades_by_wallet_oapg( query_params=query_params, path_params=path_params, accept_content_types=accept_content_types, @@ -413,7 +415,7 @@ def get( timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, ): - return self._get_token_pair_ohlc_oapg( + return self._get_nft_trades_by_wallet_oapg( query_params=query_params, path_params=path_params, accept_content_types=accept_content_types, diff --git a/src/openapi_evm_api/paths/wallets_address_nfts_trades/get.pyi b/src/openapi_evm_api/paths/wallets_address_nfts_trades/get.pyi new file mode 100644 index 0000000..bdd99ef --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_nfts_trades/get.pyi @@ -0,0 +1,413 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.trade_collection import TradeCollection +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList + +# Query params +ChainSchema = NftTradesChainList + + +class FromBlockSchema( + schemas.IntSchema +): + pass +ToBlockSchema = schemas.StrSchema +FromDateSchema = schemas.StrSchema +ToDateSchema = schemas.StrSchema +CursorSchema = schemas.StrSchema + + +class LimitSchema( + schemas.IntSchema +): + pass +NftMetadataSchema = schemas.BoolSchema +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'chain': typing.Union[ChainSchema, ], + 'from_block': typing.Union[FromBlockSchema, decimal.Decimal, int, ], + 'to_block': typing.Union[ToBlockSchema, str, ], + 'from_date': typing.Union[FromDateSchema, str, ], + 'to_date': typing.Union[ToDateSchema, str, ], + 'cursor': typing.Union[CursorSchema, str, ], + 'limit': typing.Union[LimitSchema, decimal.Decimal, int, ], + 'nft_metadata': typing.Union[NftMetadataSchema, bool, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_from_block = api_client.QueryParameter( + name="from_block", + style=api_client.ParameterStyle.FORM, + schema=FromBlockSchema, + explode=True, +) +request_query_to_block = api_client.QueryParameter( + name="to_block", + style=api_client.ParameterStyle.FORM, + schema=ToBlockSchema, + explode=True, +) +request_query_from_date = api_client.QueryParameter( + name="from_date", + style=api_client.ParameterStyle.FORM, + schema=FromDateSchema, + explode=True, +) +request_query_to_date = api_client.QueryParameter( + name="to_date", + style=api_client.ParameterStyle.FORM, + schema=ToDateSchema, + explode=True, +) +request_query_cursor = api_client.QueryParameter( + name="cursor", + style=api_client.ParameterStyle.FORM, + schema=CursorSchema, + explode=True, +) +request_query_limit = api_client.QueryParameter( + name="limit", + style=api_client.ParameterStyle.FORM, + schema=LimitSchema, + explode=True, +) +request_query_nft_metadata = api_client.QueryParameter( + name="nft_metadata", + style=api_client.ParameterStyle.FORM, + schema=NftMetadataSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = TradeCollection + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_nft_trades_by_wallet_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_nft_trades_by_wallet_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_nft_trades_by_wallet_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_nft_trades_by_wallet_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get NFT trades by wallet address + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_chain, + request_query_from_block, + request_query_to_block, + request_query_from_date, + request_query_to_date, + request_query_cursor, + request_query_limit, + request_query_nft_metadata, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetNftTradesByWallet(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_nft_trades_by_wallet( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_nft_trades_by_wallet( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_nft_trades_by_wallet( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_nft_trades_by_wallet( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_trades_by_wallet_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_nft_trades_by_wallet_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_profitability/__init__.py b/src/openapi_evm_api/paths/wallets_address_profitability/__init__.py new file mode 100644 index 0000000..f3f90fa --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_profitability import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_PROFITABILITY \ No newline at end of file diff --git a/src/openapi_evm_api/paths/wallets_address_profitability/get.py b/src/openapi_evm_api/paths/wallets_address_profitability/get.py new file mode 100644 index 0000000..2fb8bdd --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability/get.py @@ -0,0 +1,389 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.wallet_profitability_response import WalletProfitabilityResponse +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList + +from . import path + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList + + +class TokenAddressesSchema( + schemas.ListSchema +): + + + class MetaOapg: + max_items = 25 + items = schemas.StrSchema + + def __new__( + cls, + arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, str, ]], typing.List[typing.Union[MetaOapg.items, str, ]]], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'TokenAddressesSchema': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> MetaOapg.items: + return super().__getitem__(i) +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + 'token_addresses': typing.Union[TokenAddressesSchema, list, tuple, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_token_addresses = api_client.QueryParameter( + name="token_addresses", + style=api_client.ParameterStyle.FORM, + schema=TokenAddressesSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] +SchemaFor200ResponseBodyApplicationJson = WalletProfitabilityResponse + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_wallet_profitability_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Wallet Profitability + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + request_query_token_addresses, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetWalletProfitability(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_wallet_profitability( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_profitability/get.pyi b/src/openapi_evm_api/paths/wallets_address_profitability/get.pyi new file mode 100644 index 0000000..81bf799 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability/get.pyi @@ -0,0 +1,380 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.wallet_profitability_response import WalletProfitabilityResponse +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList + + +class TokenAddressesSchema( + schemas.ListSchema +): + + + class MetaOapg: + items = schemas.StrSchema + + def __new__( + cls, + arg: typing.Union[typing.Tuple[typing.Union[MetaOapg.items, str, ]], typing.List[typing.Union[MetaOapg.items, str, ]]], + _configuration: typing.Optional[schemas.Configuration] = None, + ) -> 'TokenAddressesSchema': + return super().__new__( + cls, + arg, + _configuration=_configuration, + ) + + def __getitem__(self, i: int) -> MetaOapg.items: + return super().__getitem__(i) +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + 'token_addresses': typing.Union[TokenAddressesSchema, list, tuple, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +request_query_token_addresses = api_client.QueryParameter( + name="token_addresses", + style=api_client.ParameterStyle.FORM, + schema=TokenAddressesSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +SchemaFor200ResponseBodyApplicationJson = WalletProfitabilityResponse + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_wallet_profitability_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_wallet_profitability_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Wallet Profitability + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + request_query_token_addresses, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetWalletProfitability(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_wallet_profitability( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_wallet_profitability( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_profitability_summary/__init__.py b/src/openapi_evm_api/paths/wallets_address_profitability_summary/__init__.py new file mode 100644 index 0000000..4fdcb93 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability_summary/__init__.py @@ -0,0 +1,7 @@ +# do not import all endpoints into this module because that uses a lot of memory and stack frames +# if you need the ability to import all endpoints from this module, import them with +# from openapi_evm_api.paths.wallets_address_profitability_summary import Api + +from openapi_evm_api.paths import PathValues + +path = PathValues.WALLETS_ADDRESS_PROFITABILITY_SUMMARY \ No newline at end of file diff --git a/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.py b/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.py new file mode 100644 index 0000000..7628130 --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.py @@ -0,0 +1,475 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList + +from . import path + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) +_auth = [ + 'ApiKeyAuth', +] + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.DictSchema +): + + + class MetaOapg: + + class properties: + total_count_of_trades = schemas.NumberSchema + total_trade_volume = schemas.StrSchema + total_realized_profit_usd = schemas.StrSchema + total_realized_profit_percentage = schemas.NumberSchema + total_buys = schemas.NumberSchema + total_sells = schemas.NumberSchema + total_sold_volume_usd = schemas.StrSchema + total_bought_volume_usd = schemas.StrSchema + __annotations__ = { + "total_count_of_trades": total_count_of_trades, + "total_trade_volume": total_trade_volume, + "total_realized_profit_usd": total_realized_profit_usd, + "total_realized_profit_percentage": total_realized_profit_percentage, + "total_buys": total_buys, + "total_sells": total_sells, + "total_sold_volume_usd": total_sold_volume_usd, + "total_bought_volume_usd": total_bought_volume_usd, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_count_of_trades"]) -> MetaOapg.properties.total_count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_trade_volume"]) -> MetaOapg.properties.total_trade_volume: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_realized_profit_usd"]) -> MetaOapg.properties.total_realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_realized_profit_percentage"]) -> MetaOapg.properties.total_realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_volume_usd"]) -> MetaOapg.properties.total_sold_volume_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_bought_volume_usd"]) -> MetaOapg.properties.total_bought_volume_usd: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_count_of_trades", "total_trade_volume", "total_realized_profit_usd", "total_realized_profit_percentage", "total_buys", "total_sells", "total_sold_volume_usd", "total_bought_volume_usd", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_count_of_trades"]) -> typing.Union[MetaOapg.properties.total_count_of_trades, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_trade_volume"]) -> typing.Union[MetaOapg.properties.total_trade_volume, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_realized_profit_usd"]) -> typing.Union[MetaOapg.properties.total_realized_profit_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_realized_profit_percentage"]) -> typing.Union[MetaOapg.properties.total_realized_profit_percentage, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_buys"]) -> typing.Union[MetaOapg.properties.total_buys, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sells"]) -> typing.Union[MetaOapg.properties.total_sells, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_volume_usd"]) -> typing.Union[MetaOapg.properties.total_sold_volume_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_bought_volume_usd"]) -> typing.Union[MetaOapg.properties.total_bought_volume_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_count_of_trades", "total_trade_volume", "total_realized_profit_usd", "total_realized_profit_percentage", "total_buys", "total_sells", "total_sold_volume_usd", "total_bought_volume_usd", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + total_count_of_trades: typing.Union[MetaOapg.properties.total_count_of_trades, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_trade_volume: typing.Union[MetaOapg.properties.total_trade_volume, str, schemas.Unset] = schemas.unset, + total_realized_profit_usd: typing.Union[MetaOapg.properties.total_realized_profit_usd, str, schemas.Unset] = schemas.unset, + total_realized_profit_percentage: typing.Union[MetaOapg.properties.total_realized_profit_percentage, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_buys: typing.Union[MetaOapg.properties.total_buys, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_sells: typing.Union[MetaOapg.properties.total_sells, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_sold_volume_usd: typing.Union[MetaOapg.properties.total_sold_volume_usd, str, schemas.Unset] = schemas.unset, + total_bought_volume_usd: typing.Union[MetaOapg.properties.total_bought_volume_usd, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + *args, + total_count_of_trades=total_count_of_trades, + total_trade_volume=total_trade_volume, + total_realized_profit_usd=total_realized_profit_usd, + total_realized_profit_percentage=total_realized_profit_percentage, + total_buys=total_buys, + total_sells=total_sells, + total_sold_volume_usd=total_sold_volume_usd, + total_bought_volume_usd=total_bought_volume_usd, + _configuration=_configuration, + **kwargs, + ) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_status_code_to_response = { + '200': _response_for_200, +} +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Wallet Profitability Summary + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetWalletProfitabilitySummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_wallet_profitability_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.pyi b/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.pyi new file mode 100644 index 0000000..e809e1a --- /dev/null +++ b/src/openapi_evm_api/paths/wallets_address_profitability_summary/get.pyi @@ -0,0 +1,467 @@ +# coding: utf-8 + +""" + + + Generated by: https://openapi-generator.tech +""" + +from dataclasses import dataclass +import typing_extensions +import urllib3 +from urllib3._collections import HTTPHeaderDict + +from openapi_evm_api import api_client, exceptions +from datetime import date, datetime # noqa: F401 +import decimal # noqa: F401 +import functools # noqa: F401 +import io # noqa: F401 +import re # noqa: F401 +import typing # noqa: F401 +import typing_extensions # noqa: F401 +import uuid # noqa: F401 + +import frozendict # noqa: F401 + +from openapi_evm_api import schemas # noqa: F401 + +from openapi_evm_api.model.discovery_api_chains_list import DiscoveryApiChainsList + +# Query params +DaysSchema = schemas.StrSchema +ChainSchema = DiscoveryApiChainsList +RequestRequiredQueryParams = typing_extensions.TypedDict( + 'RequestRequiredQueryParams', + { + } +) +RequestOptionalQueryParams = typing_extensions.TypedDict( + 'RequestOptionalQueryParams', + { + 'days': typing.Union[DaysSchema, str, ], + 'chain': typing.Union[ChainSchema, ], + }, + total=False +) + + +class RequestQueryParams(RequestRequiredQueryParams, RequestOptionalQueryParams): + pass + + +request_query_days = api_client.QueryParameter( + name="days", + style=api_client.ParameterStyle.FORM, + schema=DaysSchema, + explode=True, +) +request_query_chain = api_client.QueryParameter( + name="chain", + style=api_client.ParameterStyle.FORM, + schema=ChainSchema, + explode=True, +) +# Path params +AddressSchema = schemas.StrSchema +RequestRequiredPathParams = typing_extensions.TypedDict( + 'RequestRequiredPathParams', + { + 'address': typing.Union[AddressSchema, str, ], + } +) +RequestOptionalPathParams = typing_extensions.TypedDict( + 'RequestOptionalPathParams', + { + }, + total=False +) + + +class RequestPathParams(RequestRequiredPathParams, RequestOptionalPathParams): + pass + + +request_path_address = api_client.PathParameter( + name="address", + style=api_client.ParameterStyle.SIMPLE, + schema=AddressSchema, + required=True, +) + + +class SchemaFor200ResponseBodyApplicationJson( + schemas.DictSchema +): + + + class MetaOapg: + + class properties: + total_count_of_trades = schemas.NumberSchema + total_trade_volume = schemas.StrSchema + total_realized_profit_usd = schemas.StrSchema + total_realized_profit_percentage = schemas.NumberSchema + total_buys = schemas.NumberSchema + total_sells = schemas.NumberSchema + total_sold_volume_usd = schemas.StrSchema + total_bought_volume_usd = schemas.StrSchema + __annotations__ = { + "total_count_of_trades": total_count_of_trades, + "total_trade_volume": total_trade_volume, + "total_realized_profit_usd": total_realized_profit_usd, + "total_realized_profit_percentage": total_realized_profit_percentage, + "total_buys": total_buys, + "total_sells": total_sells, + "total_sold_volume_usd": total_sold_volume_usd, + "total_bought_volume_usd": total_bought_volume_usd, + } + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_count_of_trades"]) -> MetaOapg.properties.total_count_of_trades: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_trade_volume"]) -> MetaOapg.properties.total_trade_volume: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_realized_profit_usd"]) -> MetaOapg.properties.total_realized_profit_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_realized_profit_percentage"]) -> MetaOapg.properties.total_realized_profit_percentage: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_buys"]) -> MetaOapg.properties.total_buys: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sells"]) -> MetaOapg.properties.total_sells: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_sold_volume_usd"]) -> MetaOapg.properties.total_sold_volume_usd: ... + + @typing.overload + def __getitem__(self, name: typing_extensions.Literal["total_bought_volume_usd"]) -> MetaOapg.properties.total_bought_volume_usd: ... + + @typing.overload + def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ... + + def __getitem__(self, name: typing.Union[typing_extensions.Literal["total_count_of_trades", "total_trade_volume", "total_realized_profit_usd", "total_realized_profit_percentage", "total_buys", "total_sells", "total_sold_volume_usd", "total_bought_volume_usd", ], str]): + # dict_instance[name] accessor + return super().__getitem__(name) + + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_count_of_trades"]) -> typing.Union[MetaOapg.properties.total_count_of_trades, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_trade_volume"]) -> typing.Union[MetaOapg.properties.total_trade_volume, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_realized_profit_usd"]) -> typing.Union[MetaOapg.properties.total_realized_profit_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_realized_profit_percentage"]) -> typing.Union[MetaOapg.properties.total_realized_profit_percentage, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_buys"]) -> typing.Union[MetaOapg.properties.total_buys, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sells"]) -> typing.Union[MetaOapg.properties.total_sells, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_sold_volume_usd"]) -> typing.Union[MetaOapg.properties.total_sold_volume_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: typing_extensions.Literal["total_bought_volume_usd"]) -> typing.Union[MetaOapg.properties.total_bought_volume_usd, schemas.Unset]: ... + + @typing.overload + def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ... + + def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["total_count_of_trades", "total_trade_volume", "total_realized_profit_usd", "total_realized_profit_percentage", "total_buys", "total_sells", "total_sold_volume_usd", "total_bought_volume_usd", ], str]): + return super().get_item_oapg(name) + + + def __new__( + cls, + *args: typing.Union[dict, frozendict.frozendict, ], + total_count_of_trades: typing.Union[MetaOapg.properties.total_count_of_trades, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_trade_volume: typing.Union[MetaOapg.properties.total_trade_volume, str, schemas.Unset] = schemas.unset, + total_realized_profit_usd: typing.Union[MetaOapg.properties.total_realized_profit_usd, str, schemas.Unset] = schemas.unset, + total_realized_profit_percentage: typing.Union[MetaOapg.properties.total_realized_profit_percentage, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_buys: typing.Union[MetaOapg.properties.total_buys, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_sells: typing.Union[MetaOapg.properties.total_sells, decimal.Decimal, int, float, schemas.Unset] = schemas.unset, + total_sold_volume_usd: typing.Union[MetaOapg.properties.total_sold_volume_usd, str, schemas.Unset] = schemas.unset, + total_bought_volume_usd: typing.Union[MetaOapg.properties.total_bought_volume_usd, str, schemas.Unset] = schemas.unset, + _configuration: typing.Optional[schemas.Configuration] = None, + **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes], + ) -> 'SchemaFor200ResponseBodyApplicationJson': + return super().__new__( + cls, + *args, + total_count_of_trades=total_count_of_trades, + total_trade_volume=total_trade_volume, + total_realized_profit_usd=total_realized_profit_usd, + total_realized_profit_percentage=total_realized_profit_percentage, + total_buys=total_buys, + total_sells=total_sells, + total_sold_volume_usd=total_sold_volume_usd, + total_bought_volume_usd=total_bought_volume_usd, + _configuration=_configuration, + **kwargs, + ) + + +@dataclass +class ApiResponseFor200(api_client.ApiResponse): + response: urllib3.HTTPResponse + body: typing.Union[ + SchemaFor200ResponseBodyApplicationJson, + ] + headers: schemas.Unset = schemas.unset + + +_response_for_200 = api_client.OpenApiResponse( + response_cls=ApiResponseFor200, + content={ + 'application/json': api_client.MediaType( + schema=SchemaFor200ResponseBodyApplicationJson), + }, +) +_all_accept_content_types = ( + 'application/json', +) + + +class BaseApi(api_client.Api): + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def _get_wallet_profitability_summary_oapg( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + """ + Get Wallet Profitability Summary + :param skip_deserialization: If true then api_response.response will be set but + api_response.body and api_response.headers will not be deserialized into schema + class instances + """ + self._verify_typed_dict_inputs_oapg(RequestQueryParams, query_params) + self._verify_typed_dict_inputs_oapg(RequestPathParams, path_params) + used_path = path.value + + _path_params = {} + for parameter in ( + request_path_address, + ): + parameter_data = path_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + serialized_data = parameter.serialize(parameter_data) + _path_params.update(serialized_data) + + for k, v in _path_params.items(): + used_path = used_path.replace('{%s}' % k, v) + + prefix_separator_iterator = None + for parameter in ( + request_query_days, + request_query_chain, + ): + parameter_data = query_params.get(parameter.name, schemas.unset) + if parameter_data is schemas.unset: + continue + if prefix_separator_iterator is None: + prefix_separator_iterator = parameter.get_prefix_separator_iterator() + serialized_data = parameter.serialize(parameter_data, prefix_separator_iterator) + for serialized_value in serialized_data.values(): + used_path += serialized_value + + _headers = HTTPHeaderDict() + # TODO add cookie handling + if accept_content_types: + for accept_content_type in accept_content_types: + _headers.add('Accept', accept_content_type) + + response = self.api_client.call_api( + resource_path=used_path, + method='get'.upper(), + headers=_headers, + auth_settings=_auth, + stream=stream, + timeout=timeout, + ) + + if skip_deserialization: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + else: + response_for_status = _status_code_to_response.get(str(response.status)) + if response_for_status: + api_response = response_for_status.deserialize(response, self.api_client.configuration) + else: + api_response = api_client.ApiResponseWithoutDeserialization(response=response) + + if not 200 <= response.status <= 299: + raise exceptions.ApiException(api_response=api_response) + + return api_response + + +class GetWalletProfitabilitySummary(BaseApi): + # this class is used by api classes that refer to endpoints with operationId fn names + + @typing.overload + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get_wallet_profitability_summary( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get_wallet_profitability_summary( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + +class ApiForget(BaseApi): + # this class is used by api classes that refer to endpoints by path and http method names + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + skip_deserialization: typing_extensions.Literal[True], + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + ) -> api_client.ApiResponseWithoutDeserialization: ... + + @typing.overload + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = ..., + ) -> typing.Union[ + ApiResponseFor200, + api_client.ApiResponseWithoutDeserialization, + ]: ... + + def get( + self, + query_params: RequestQueryParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: bool = False, + ): + return self._get_wallet_profitability_summary_oapg( + query_params=query_params, + path_params=path_params, + accept_content_types=accept_content_types, + stream=stream, + timeout=timeout, + skip_deserialization=skip_deserialization + ) + + diff --git a/src/openapi_evm_api/test/test_models/test_common_contract_data.py b/src/openapi_evm_api/test/test_models/test_common_contract_data.py new file mode 100644 index 0000000..c4de2fe --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_common_contract_data.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.common_contract_data import CommonContractData +from openapi_evm_api import configuration + + +class TestCommonContractData(unittest.TestCase): + """CommonContractData unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_contract_spender_details.py b/src/openapi_evm_api/test/test_models/test_contract_spender_details.py new file mode 100644 index 0000000..44c458a --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_contract_spender_details.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.contract_spender_details import ContractSpenderDetails +from openapi_evm_api import configuration + + +class TestContractSpenderDetails(unittest.TestCase): + """ContractSpenderDetails unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_contract_token_details.py b/src/openapi_evm_api/test/test_models/test_contract_token_details.py new file mode 100644 index 0000000..48f762f --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_contract_token_details.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.contract_token_details import ContractTokenDetails +from openapi_evm_api import configuration + + +class TestContractTokenDetails(unittest.TestCase): + """ContractTokenDetails unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_defi_position_details.py b/src/openapi_evm_api/test/test_models/test_defi_position_details.py new file mode 100644 index 0000000..05dc88d --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_position_details.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_position_details import DefiPositionDetails +from openapi_evm_api import configuration + + +class TestDefiPositionDetails(unittest.TestCase): + """DefiPositionDetails unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_defi_position_summary_response.py b/src/openapi_evm_api/test/test_models/test_defi_position_summary_response.py new file mode 100644 index 0000000..b081017 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_position_summary_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_position_summary_response import DefiPositionSummaryResponse +from openapi_evm_api import configuration + + +class TestDefiPositionSummaryResponse(unittest.TestCase): + """DefiPositionSummaryResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_defi_protocol_balance.py b/src/openapi_evm_api/test/test_models/test_defi_protocol_balance.py new file mode 100644 index 0000000..016e57c --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_protocol_balance.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_protocol_balance import DefiProtocolBalance +from openapi_evm_api import configuration + + +class TestDefiProtocolBalance(unittest.TestCase): + """DefiProtocolBalance unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_ohlc_interval_list.py b/src/openapi_evm_api/test/test_models/test_defi_protocol_list.py similarity index 74% rename from src/openapi_evm_api/test/test_models/test_ohlc_interval_list.py rename to src/openapi_evm_api/test/test_models/test_defi_protocol_list.py index cbb94cd..1551c2b 100644 --- a/src/openapi_evm_api/test/test_models/test_ohlc_interval_list.py +++ b/src/openapi_evm_api/test/test_models/test_defi_protocol_list.py @@ -12,12 +12,12 @@ import unittest import openapi_evm_api -from openapi_evm_api.model.ohlc_interval_list import OhlcIntervalList +from openapi_evm_api.model.defi_protocol_list import DefiProtocolList from openapi_evm_api import configuration -class TestOhlcIntervalList(unittest.TestCase): - """OhlcIntervalList unit test stubs""" +class TestDefiProtocolList(unittest.TestCase): + """DefiProtocolList unit test stubs""" _configuration = configuration.Configuration() diff --git a/src/openapi_evm_api/test/test_models/test_defi_protocol_position.py b/src/openapi_evm_api/test/test_models/test_defi_protocol_position.py new file mode 100644 index 0000000..aa27751 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_protocol_position.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_protocol_position import DefiProtocolPosition +from openapi_evm_api import configuration + + +class TestDefiProtocolPosition(unittest.TestCase): + """DefiProtocolPosition unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_defi_protocol_summary.py b/src/openapi_evm_api/test/test_models/test_defi_protocol_summary.py new file mode 100644 index 0000000..9c53a1a --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_protocol_summary.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_protocol_summary import DefiProtocolSummary +from openapi_evm_api import configuration + + +class TestDefiProtocolSummary(unittest.TestCase): + """DefiProtocolSummary unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_defi_token_balance.py b/src/openapi_evm_api/test/test_models/test_defi_token_balance.py new file mode 100644 index 0000000..c1a6493 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_defi_token_balance.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.defi_token_balance import DefiTokenBalance +from openapi_evm_api import configuration + + +class TestDefiTokenBalance(unittest.TestCase): + """DefiTokenBalance unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_nft_trades_chain_list.py b/src/openapi_evm_api/test/test_models/test_nft_trades_chain_list.py new file mode 100644 index 0000000..edb4f5a --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_nft_trades_chain_list.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.nft_trades_chain_list import NftTradesChainList +from openapi_evm_api import configuration + + +class TestNftTradesChainList(unittest.TestCase): + """NftTradesChainList unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_resolve_contract_interaction_response.py b/src/openapi_evm_api/test/test_models/test_resolve_contract_interaction_response.py new file mode 100644 index 0000000..3634850 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_resolve_contract_interaction_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.resolve_contract_interaction_response import ResolveContractInteractionResponse +from openapi_evm_api import configuration + + +class TestResolveContractInteractionResponse(unittest.TestCase): + """ResolveContractInteractionResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_ohlc_result.py b/src/openapi_evm_api/test/test_models/test_sold_price.py similarity index 76% rename from src/openapi_evm_api/test/test_models/test_ohlc_result.py rename to src/openapi_evm_api/test/test_models/test_sold_price.py index aee5b32..7b2f695 100644 --- a/src/openapi_evm_api/test/test_models/test_ohlc_result.py +++ b/src/openapi_evm_api/test/test_models/test_sold_price.py @@ -12,12 +12,12 @@ import unittest import openapi_evm_api -from openapi_evm_api.model.ohlc_result import OhlcResult +from openapi_evm_api.model.sold_price import SoldPrice from openapi_evm_api import configuration -class TestOhlcResult(unittest.TestCase): - """OhlcResult unit test stubs""" +class TestSoldPrice(unittest.TestCase): + """SoldPrice unit test stubs""" _configuration = configuration.Configuration() diff --git a/src/openapi_evm_api/test/test_models/test_ohlc_response.py b/src/openapi_evm_api/test/test_models/test_token_approval.py similarity index 75% rename from src/openapi_evm_api/test/test_models/test_ohlc_response.py rename to src/openapi_evm_api/test/test_models/test_token_approval.py index df79c5a..8b17430 100644 --- a/src/openapi_evm_api/test/test_models/test_ohlc_response.py +++ b/src/openapi_evm_api/test/test_models/test_token_approval.py @@ -12,12 +12,12 @@ import unittest import openapi_evm_api -from openapi_evm_api.model.ohlc_response import OhlcResponse +from openapi_evm_api.model.token_approval import TokenApproval from openapi_evm_api import configuration -class TestOhlcResponse(unittest.TestCase): - """OhlcResponse unit test stubs""" +class TestTokenApproval(unittest.TestCase): + """TokenApproval unit test stubs""" _configuration = configuration.Configuration() diff --git a/src/openapi_evm_api/test/test_models/test_top_profitable_wallet_per_token_response.py b/src/openapi_evm_api/test/test_models/test_top_profitable_wallet_per_token_response.py new file mode 100644 index 0000000..1bedade --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_top_profitable_wallet_per_token_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.top_profitable_wallet_per_token_response import TopProfitableWalletPerTokenResponse +from openapi_evm_api import configuration + + +class TestTopProfitableWalletPerTokenResponse(unittest.TestCase): + """TopProfitableWalletPerTokenResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_ohlc_candles.py b/src/openapi_evm_api/test/test_models/test_wallet_approvals.py similarity index 74% rename from src/openapi_evm_api/test/test_models/test_ohlc_candles.py rename to src/openapi_evm_api/test/test_models/test_wallet_approvals.py index 4f36501..a902c6a 100644 --- a/src/openapi_evm_api/test/test_models/test_ohlc_candles.py +++ b/src/openapi_evm_api/test/test_models/test_wallet_approvals.py @@ -12,12 +12,12 @@ import unittest import openapi_evm_api -from openapi_evm_api.model.ohlc_candles import OhlcCandles +from openapi_evm_api.model.wallet_approvals import WalletApprovals from openapi_evm_api import configuration -class TestOhlcCandles(unittest.TestCase): - """OhlcCandles unit test stubs""" +class TestWalletApprovals(unittest.TestCase): + """WalletApprovals unit test stubs""" _configuration = configuration.Configuration() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_defi_protocol_position.py b/src/openapi_evm_api/test/test_models/test_wallet_defi_protocol_position.py new file mode 100644 index 0000000..4ea0f06 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_defi_protocol_position.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_defi_protocol_position import WalletDefiProtocolPosition +from openapi_evm_api import configuration + + +class TestWalletDefiProtocolPosition(unittest.TestCase): + """WalletDefiProtocolPosition unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_defi_summary.py b/src/openapi_evm_api/test/test_models/test_wallet_defi_summary.py new file mode 100644 index 0000000..0ea26f5 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_defi_summary.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_defi_summary import WalletDefiSummary +from openapi_evm_api import configuration + + +class TestWalletDefiSummary(unittest.TestCase): + """WalletDefiSummary unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_profitability_response.py b/src/openapi_evm_api/test/test_models/test_wallet_profitability_response.py new file mode 100644 index 0000000..994299c --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_profitability_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_profitability_response import WalletProfitabilityResponse +from openapi_evm_api import configuration + + +class TestWalletProfitabilityResponse(unittest.TestCase): + """WalletProfitabilityResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_profitability_token_data.py b/src/openapi_evm_api/test/test_models/test_wallet_profitability_token_data.py new file mode 100644 index 0000000..e6fbb7f --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_profitability_token_data.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_profitability_token_data import WalletProfitabilityTokenData +from openapi_evm_api import configuration + + +class TestWalletProfitabilityTokenData(unittest.TestCase): + """WalletProfitabilityTokenData unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_token_profitability_response.py b/src/openapi_evm_api/test/test_models/test_wallet_token_profitability_response.py new file mode 100644 index 0000000..fa6ea36 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_token_profitability_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_token_profitability_response import WalletTokenProfitabilityResponse +from openapi_evm_api import configuration + + +class TestWalletTokenProfitabilityResponse(unittest.TestCase): + """WalletTokenProfitabilityResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main() diff --git a/src/openapi_evm_api/test/test_models/test_wallet_top_profitable_wallet_per_token_response.py b/src/openapi_evm_api/test/test_models/test_wallet_top_profitable_wallet_per_token_response.py new file mode 100644 index 0000000..b389fe8 --- /dev/null +++ b/src/openapi_evm_api/test/test_models/test_wallet_top_profitable_wallet_per_token_response.py @@ -0,0 +1,25 @@ +# coding: utf-8 + +""" + EVM API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: 2.2 + Generated by: https://openapi-generator.tech +""" + +import unittest + +import openapi_evm_api +from openapi_evm_api.model.wallet_top_profitable_wallet_per_token_response import WalletTopProfitableWalletPerTokenResponse +from openapi_evm_api import configuration + + +class TestWalletTopProfitableWalletPerTokenResponse(unittest.TestCase): + """WalletTopProfitableWalletPerTokenResponse unit test stubs""" + _configuration = configuration.Configuration() + + +if __name__ == '__main__': + unittest.main()