Token Denoms
Queries the available token denoms for the specified token Id on the specified chains.
query Token_denoms($denom: String, $tokenId: String, $chainUids: [String!]) {
token {
token_denoms(denom: $denom, token_id: $tokenId, chain_uids: $chainUids) {
denoms {
id
chain_uid
token_type {
... on NativeTokenType {
native {
denom
}
}
... on SmartTokenType {
smart {
contract_address
}
}
... on VoucherTokenType {
voucher
}
}
chain_type
}
id
token_id
}
}
}
Example
curl --request POST \
--header 'content-type: application/json' \
--url 'https://api.euclidprotocol.com/graphql' \
--data '{"query":"query Token_denoms($denom: String, $tokenId: String, $chainUids: [String!]) {\n token {\n token_denoms(denom: $denom, token_id: $tokenId, chain_uids: $chainUids) {\n denoms {\n id\n chain_uid\n token_type {\n ... on NativeTokenType {\n native {\n denom\n }\n }\n ... on SmartTokenType {\n smart {\n contract_address\n }\n }\n ... on VoucherTokenType {\n voucher\n }\n }\n chain_type\n }\n id\n token_id\n }\n }\n}","variables":{"denom":"eth","tokenId":null,"chainUids":null}}'
Example Response
{
"data": {
"token": {
"token_denoms": [
{
"denoms": [
{
"id": "TokenDenomWithChainType:ethereum:evm:native:eth",
"chain_uid": "ethereum",
"token_type": {
"native": {
"denom": "eth"
}
},
"chain_type": "evm"
},
{
"id": "TokenDenomWithChainType:arbitrum:evm:native:eth",
"chain_uid": "arbitrum",
"token_type": {
"native": {
"denom": "eth"
}
},
"chain_type": "evm"
},
{
"id": "TokenDenomWithChainType:optimism:evm:native:eth",
"chain_uid": "optimism",
"token_type": {
"native": {
"denom": "eth"
}
},
"chain_type": "evm"
},
{
"id": "TokenDenomWithChainType:base:evm:native:eth",
"chain_uid": "base",
"token_type": {
"native": {
"denom": "eth"
}
},
"chain_type": "evm"
}
],
"id": "TokenDenomWithTokenIDResponse:eth",
"token_id": "eth"
}
]
}
}
}
Arguments
| Argument | Type | Description |
|---|---|---|
denom | String | Optional filter to match a specific token denomination. |
tokenId | String | Optional filter to match a specific token identifier. |
chainUids | [String!] | Optional list of chain UIDs to filter the token denoms by chain. |
Return Fields
| Field | Type | Description |
|---|---|---|
id | String | Unique identifier for the token denom response object. |
token_id | String | The token identifier being queried. |
denoms | [Denom] | Token representations available across the matching chains. |
Denom
| Field | Type | Description |
|---|---|---|
id | String | Unique identifier for the denom entry. |
chain_uid | String | The chain UID where this token representation exists. |
token_type | TokenType | The token representation on that chain. |
chain_type | String | The chain family for this denom entry, for example evm or cosmwasm. |
TokenType
| Field | Type | Description |
|---|---|---|
native | Native | Details of native token denoms. |
smart | Smart | Details of smart-token contract addresses. |
voucher | String | Voucher marker for voucher token representations. |
Native
| Field | Type | Description |
|---|---|---|
denom | String | The denomination of the native token. |
Smart
| Field | Type | Description |
|---|---|---|
contractAddress | String | The contract address of the smart token. |