Magickbase - Godwoken Explorer GraphQL API
Welcome to the Godwoken Explorer GraphQL API!
Contact
Magickbase Team
API Endpoints
# testnet-prod:
http://api.v1.betanet.gwscan.com/graphql
# mainnet-prod:
http://api.v1.gwscan.com/graphql
Queries
account
Description
function: get account by account addresses request-with-address-example:
query {
account(input: {address: "0x59b670e9fa9d0a427751af201d676719a970857b"}){
... on Account{
type
eth_address
}
}
}
{
"data": {
"account": {
"eth_address": "0x59b670e9fa9d0a427751af201d676719a970857b",
"type": "POLYJUICE_CONTRACT"
}
}
}
request-with-script-hash-example:
query {
account(input: {script_hash: "0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e"}){
... on Account{
type
eth_address
script_hash
}
}
}
{
"data": {
"account": {
"eth_address": null,
"script_hash": "0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e",
"type": "ETH_ADDR_REG"
}
}
}
query {
account(
input: {
script_hash: "0x946d08cc356c4fe13bc49929f1f709611fe0a2aaa336efb579dad4ca197d1551"
}
) {
... on Account{
type
eth_address
script_hash
script
}
}
}
{
"data": {
"account": {
"eth_address": null,
"script": {
"account_merkle_state": {
"account_count": 33776,
"account_merkle_root": "0x2a3fc6ea37bf17b717630f1f8f02a18ef9e96edf7461d6f8df5d4e115f6eb9dd"
},
"args": "0x702359ea7f073558921eb50d8c1c77e92f760c8f8656bde4995f26b8963e2dd8",
"block_merkle_state": {
"block_count": 103767,
"block_merkle_root": "0xb6b6d9befa9012b750b666df8522e8d164b222924028a4b91d0ba4eb2f1578cb"
},
"code_hash": "0x37b25df86ca495856af98dff506e49f2380d673b0874e13d29f7197712d735e8",
"hash_type": "type",
"last_finalized_block_number": 103666,
"reverted_block_root": "0000000000000000000000000000000000000000000000000000000000000000",
"status": "running"
},
"script_hash": "0x946d08cc356c4fe13bc49929f1f709611fe0a2aaa336efb579dad4ca197d1551",
"type": "META_CONTRACT"
}
}
}
query {
account(
input: {
script_hash: "0x64050af0d25c38ddf9455b8108654f7c5cc30fe6d871a303d83b1020edddd7a7"
}
) {
... on Account {
type
script_hash
script
udt {
id
name
decimal
}
}
}
}
{
"data": {
"account": {
"script": {
"args": "0x702359ea7f073558921eb50d8c1c77e92f760c8f8656bde4995f26b8963e2dd8dac0c53c572f451e56c092fdb520aec82f5f4bf8a5c02e1c4843f40c15f84c55",
"code_hash": "0xb6176a6170ea33f8468d61f934c45c57d29cdc775bcd3ecaaec183f04b9f33d9",
"hash_type": "type"
},
"script_hash": "0x64050af0d25c38ddf9455b8108654f7c5cc30fe6d871a303d83b1020edddd7a7",
"type": "UDT",
"udt": {
"decimal": 18,
"id": "80",
"name": "USD Coin"
}
}
}
}
query {
account(
input: {
script_hash: "0x829cc5785a4d8ac642ede32cb3cb5cb9dc389d5892f2fc2afc760691445be194"
}
) {
... on Account {
type
eth_address
script_hash
script
}
}
}
{
"data": {
"account": {
"eth_address": "0x2f760c8f8656bde4995f26b8963e2dd801000000",
"script": {
"args": "0x702359ea7f073558921eb50d8c1c77e92f760c8f8656bde4995f26b8963e2dd801000000",
"code_hash": "0x1629b04b49ded9e5747481f985b11cba6cdd4ffc167971a585e96729455ca736",
"hash_type": "type"
},
"script_hash": "0x829cc5785a4d8ac642ede32cb3cb5cb9dc389d5892f2fc2afc760691445be194",
"type": "POLYJUICE_CREATOR"
}
}
}
query {
account(
input: {
script_hash: "0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e"
}
) {
... on Account{
type
eth_address
script_hash
script
}
}
}
{
"data": {
"account": {
"eth_address": null,
"script": {
"args": "0x702359ea7f073558921eb50d8c1c77e92f760c8f8656bde4995f26b8963e2dd8",
"code_hash": "0xa30dcbb83ebe571f49122d8d1ce4537679ebf511261c8ffaaa6679bf9fdea3a4",
"hash_type": "type"
},
"script_hash": "0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e",
"type": "ETH_ADDR_REG"
}
}
}
query {
account(
input: {
script_hash: "0x495D9CFB7B6FAEAEB0F5A7ED81A830A477F7AEEA8D53EF73ABDC2EC2F5FED07C"
}
) {
... on Account{
type
eth_address
script
script_hash
smart_contract {
id
account_id
name
}
}
}
}
{
"data": {
"eth_address": "0x715ab282b873b79a7be8b0e8c13c4e8966a52040",
"script": {
"args": "0x702359ea7f073558921eb50d8c1c77e92f760c8f8656bde4995f26b8963e2dd8715ab282b873b79a7be8b0e8c13c4e8966a52040",
"code_hash": "0x07521d0aa8e66ef441ebc31204d86bb23fc83e9edc58c19dbb1b0ebe64336ec0",
"hash_type": "type"
},
"script_hash": "0x495d9cfb7b6faeaeb0f5a7ed81a830a477f7aeea8d53ef73abdc2ec2f5fed07c",
"smart_contract": null,
"type": "ETH_USER"
}
}
}
bridge-account-udt-example:
query {
account(
input: {
script_hash: "0x3E1301E759261B676CE68D0D97936CD431A4AF2A34072AA94E44655909765EB4"
}
) {
... on Account{
udt {
id
name
bridge_account_id
type
}
bridged_udt {
id
name
bridge_account_id
type
}
}
}
}
{
"data": {
"account": {
"bridged_udt": {
"bridge_account_id": 36050,
"id": "6571",
"name": "GodwokenToken on testnet_v1",
"type": "BRIDGE"
},
"udt": {
"bridge_account_id": null,
"id": "36050",
"name": "GodwokenToken on testnet_v1",
"type": "NATIVE"
}
}
}
}
Response
Returns an
AccountOrAddress
Arguments
| Name | Description |
|---|---|
input -
AccountInput!
|
Example
Query
query Account($input: AccountInput!) {
account(input: $input) {
... on Account {
...AccountFragment
}
... on Address {
...AddressFragment
}
}
}
Variables
{"input": AccountInput}
Response
{"data": {"account": Account}}
account_bridged_udts_by_script_hash
Description
request-result-example:
query {
account_bridged_udts_by_script_hash(
input: {
udt_script_hash: "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
sort_type: ASC
page_size: 1
}
) {
block_number
id
udt_script_hash
value
value_fetched_at
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_bridged_udts_by_script_hash": [
{
"account": {
"eth_address": null,
"id": 1,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"block_number": 6135,
"id": 49,
"udt": {
"bridge_account_id": null,
"decimal": null,
"id": "1",
"name": null,
"script_hash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"value": null
},
"udt_script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca",
"value": "0",
"value_fetched_at": null
}
]
}
}
Response
Returns
[AccountCurrentBridgedUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountBridgedUdtsByScriptHashInput!
|
Example
Query
query Account_bridged_udts_by_script_hash($input: AccountBridgedUdtsByScriptHashInput!) {
account_bridged_udts_by_script_hash(input: $input) {
account {
...AccountFragment
}
address_hash
block_number
id
inserted_at
layer1_block_number
udt {
...UdtFragment
}
udt_script_hash
updated_at
value
value_fetched_at
}
}
Variables
{"input": AccountBridgedUdtsByScriptHashInput}
Response
{
"data": {
"account_bridged_udts_by_script_hash": [
{
"account": Account,
"address_hash": HashAddress,
"block_number": 123,
"id": 987,
"inserted_at": "2007-12-03T10:15:30Z",
"layer1_block_number": 123,
"udt": Udt,
"udt_script_hash": HashFull,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
]
}
}
account_ckbs
Description
request-result-example:
query {
account_ckbs(
input: { address_hashes: ["0x715AB282B873B79A7BE8B0E8C13C4E8966A52040"] }
) {
udt_script_hash
value
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_ckbs": [
{
"account": {
"eth_address": null,
"id": 1,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"udt": {
"bridge_account_id": 375,
"decimal": 18,
"id": "1",
"name": "pCKB",
"script_hash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"value": null
},
"udt_script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca",
"value": "1165507481400061309833"
}
]
}
}
Response
Returns
[AccountUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountCkbsInput!
|
Example
Query
query Account_ckbs($input: AccountCkbsInput!) {
account_ckbs(input: $input) {
account {
...AccountFragment
}
address_hash
token_contract_address_hash
udt {
...UdtFragment
}
udt_script_hash
uniq_id
value
}
}
Variables
{"input": AccountCkbsInput}
Response
{
"data": {
"account_ckbs": [
{
"account": Account,
"address_hash": HashAddress,
"token_contract_address_hash": HashAddress,
"udt": Udt,
"udt_script_hash": HashFull,
"uniq_id": 987,
"value": Bigint
}
]
}
}
account_current_bridged_udts
Description
request-result-example:
query {
account_current_bridged_udts(
input: {
address_hashes: ["0x715AB282B873B79A7BE8B0E8C13C4E8966A52040"]
udt_script_hash: "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
}
) {
block_number
id
udt_script_hash
value
value_fetched_at
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_current_bridged_udts": [
{
"account": {
"eth_address": null,
"id": 1,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"block_number": null,
"id": 1,
"udt": {
"bridge_account_id": null,
"decimal": null,
"id": "1",
"name": null,
"script_hash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"value": null
},
"udt_script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca",
"value": "1165507481400061309833",
"value_fetched_at": null
}
]
}
}
Response
Returns
[AccountCurrentBridgedUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountCurrentBridgedUdtsInput!
|
Example
Query
query Account_current_bridged_udts($input: AccountCurrentBridgedUdtsInput!) {
account_current_bridged_udts(input: $input) {
account {
...AccountFragment
}
address_hash
block_number
id
inserted_at
layer1_block_number
udt {
...UdtFragment
}
udt_script_hash
updated_at
value
value_fetched_at
}
}
Variables
{"input": AccountCurrentBridgedUdtsInput}
Response
{
"data": {
"account_current_bridged_udts": [
{
"account": Account,
"address_hash": HashAddress,
"block_number": 987,
"id": 123,
"inserted_at": "2007-12-03T10:15:30Z",
"layer1_block_number": 123,
"udt": Udt,
"udt_script_hash": HashFull,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
]
}
}
account_current_udts
Description
erc20 udts request-result-example:
query {
account_current_udts(
input: {
address_hashes: ["0xC6A44E4D2216A98B3A5086A64A33D94FBCC8FEC3"]
token_contract_address_hash: "0xbb30e8691f6ffd5b4c0b2f73d17847e1e289ea80"
}
) {
block_number
id
token_contract_address_hash
value
value_fetched_at
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_current_udts": []
}
}
Response
Returns
[AccountCurrentUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountCurrentUdtsInput!
|
Example
Query
query Account_current_udts($input: AccountCurrentUdtsInput!) {
account_current_udts(input: $input) {
account {
...AccountFragment
}
address_hash
block_number
id
inserted_at
token_contract_address_hash
udt {
...UdtFragment
}
updated_at
value
value_fetched_at
}
}
Variables
{"input": AccountCurrentUdtsInput}
Response
{
"data": {
"account_current_udts": [
{
"account": Account,
"address_hash": HashAddress,
"block_number": 987,
"id": 123,
"inserted_at": "2007-12-03T10:15:30Z",
"token_contract_address_hash": HashAddress,
"udt": Udt,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
]
}
}
account_udt_holders
Description
erc20 udt holders list or bridged erc20 udt holders list example:
query {
account_udt_holders(input: {udt_id: 1}) {
entries {
bit_alias
eth_address
balance
tx_count
}
}
}
Response
Returns a
PaginateAccountUdtHolders
Arguments
| Name | Description |
|---|---|
input -
AccountUdtHoldersInput!
|
Example
Query
query Account_udt_holders($input: AccountUdtHoldersInput!) {
account_udt_holders(input: $input) {
entries {
...UdtHolderItemFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": AccountUdtHoldersInput}
Response
{
"data": {
"account_udt_holders": {
"entries": [UdtHolderItem],
"metadata": PaginateMetadata
}
}
}
account_udts
Description
erc20 udts request-result-example:
query {
account_udts(
input: {
address_hashes: ["0x715AB282B873B79A7BE8B0E8C13C4E8966A52040"],
udt_script_hash: "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
}
) {
udt_script_hash
value
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_udts": [
{
"account": {
"eth_address": null,
"id": 1,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"udt": {
"bridge_account_id": 375,
"decimal": 18,
"id": "1",
"name": "pCKB",
"script_hash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"value": null
},
"udt_script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca",
"value": "1165507481400061309833"
}
]
}
}
Response
Returns
[AccountUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountUdtsInput!
|
Example
Query
query Account_udts($input: AccountUdtsInput!) {
account_udts(input: $input) {
account {
...AccountFragment
}
address_hash
token_contract_address_hash
udt {
...UdtFragment
}
udt_script_hash
uniq_id
value
}
}
Variables
{"input": AccountUdtsInput}
Response
{
"data": {
"account_udts": [
{
"account": Account,
"address_hash": HashAddress,
"token_contract_address_hash": HashAddress,
"udt": Udt,
"udt_script_hash": HashFull,
"uniq_id": 987,
"value": Bigint
}
]
}
}
account_udts_by_contract_address
Description
erc20 udts request-result-example:
query {
account_udts_by_contract_address(
input: {
token_contract_address_hash: "0xD1556D3FE220B6EB816536AB448DE4E4EDC3E439"
sort_type: ASC
page_size: 1
}
) {
block_number
id
token_contract_address_hash
value
value_fetched_at
udt {
id
name
bridge_account_id
script_hash
decimal
value
}
account {
id
eth_address
script_hash
}
}
}
{
"data": {
"account_udts_by_contract_address": [
{
"account": {
"eth_address": "0xd1556d3fe220b6eb816536ab448de4e4edc3e439",
"id": 70,
"script_hash": "0x66fb5a40e0bb9c62a68770b77393e2c5cc8428503025d9478550e99d0bed5138"
},
"block_number": 2857,
"id": 5,
"token_contract_address_hash": "0xd1556d3fe220b6eb816536ab448de4e4edc3e439",
"udt": null,
"value": "4",
"value_fetched_at": "2022-06-01T06:03:53.730509Z"
}
]
}
}
Response
Returns
[AccountCurrentUdt]
Arguments
| Name | Description |
|---|---|
input -
AccountUdtsByContractAddressInput!
|
Example
Query
query Account_udts_by_contract_address($input: AccountUdtsByContractAddressInput!) {
account_udts_by_contract_address(input: $input) {
account {
...AccountFragment
}
address_hash
block_number
id
inserted_at
token_contract_address_hash
udt {
...UdtFragment
}
updated_at
value
value_fetched_at
}
}
Variables
{"input": AccountUdtsByContractAddressInput}
Response
{
"data": {
"account_udts_by_contract_address": [
{
"account": Account,
"address_hash": HashAddress,
"block_number": 123,
"id": 123,
"inserted_at": "2007-12-03T10:15:30Z",
"token_contract_address_hash": HashAddress,
"udt": Udt,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
]
}
}
address
Description
function: get address by addresses request-with-address-example:
query {
address(input: {address: "0x59b670e9fa9d0a427751af201d676719a970857b"}){
eth_address
bit_alias
token_transfer_count
}
}
{
"data": {
"address": {
"eth_address": "0x59b670e9fa9d0a427751af201d676719a970857b",
"bit_alias": "test.bit",
token_transfer_count: 0
}
}
}
Response
Returns an
Address
Arguments
| Name | Description |
|---|---|
input -
AddressInput!
|
Example
Query
query Address($input: AddressInput!) {
address(input: $input) {
bit_alias
eth_address
token_transfer_count
}
}
Variables
{"input": AddressInput}
Response
{
"data": {
"address": {
"bit_alias": "abc123",
"eth_address": HashFull,
"token_transfer_count": 987
}
}
}
batch_fetch_addresses_by_aliases
Description
query{
batch_fetch_addresses_by_aliases(
input: {
bit_aliases: ["freder.bit"]
}
)
{
address
bit_alias
}
}
Response
Returns
[AddressBitAlias]
Arguments
| Name | Description |
|---|---|
input -
BatchFetchAddressesByAliasInput!
|
Example
Query
query Batch_fetch_addresses_by_aliases($input: BatchFetchAddressesByAliasInput!) {
batch_fetch_addresses_by_aliases(input: $input) {
address
bit_alias
}
}
Variables
{"input": BatchFetchAddressesByAliasInput}
Response
{
"data": {
"batch_fetch_addresses_by_aliases": [
{
"address": HashAddress,
"bit_alias": "xyz789"
}
]
}
}
batch_fetch_aliases_by_addresses
Description
query{
batch_fetch_aliases_by_addresses(
input: {
addresses: ["0xcc0af0af911dd40853b8c8dfee90b32f8d1ecad6"]
}
)
{
address
bit_alias
}
}
Response
Returns
[AddressBitAlias]
Arguments
| Name | Description |
|---|---|
input -
BatchFetchAliasesByAddressesInput!
|
Example
Query
query Batch_fetch_aliases_by_addresses($input: BatchFetchAliasesByAddressesInput!) {
batch_fetch_aliases_by_addresses(input: $input) {
address
bit_alias
}
}
Variables
{"input": BatchFetchAliasesByAddressesInput}
Response
{
"data": {
"batch_fetch_aliases_by_addresses": [
{
"address": HashAddress,
"bit_alias": "xyz789"
}
]
}
}
block
Description
function: get block by block number or block hash request-result-example:
query {
block(input: {number: 1}){
hash
parent_hash
number
gas_used
gas_limit
account{
id
eth_address
}
}
}
{
"data": {
"block": {
"account": null,
"gas_limit": "12500000",
"gas_used": "0",
"hash": "0x4ac339b063e52dac1b845d935788f379ebcdb0e33ecce077519f39929dbc8829",
"number": 1,
"parent_hash": "0x61bcff6f20e8be09bbe8e36092a9cc05dd3fa67e3841e206e8c30ae0dd7032df"
}
}
}
Response
Returns a
Block
Arguments
| Name | Description |
|---|---|
input -
BlockInput
|
Example
Query
query Block($input: BlockInput) {
block(input: $input) {
account {
...AccountFragment
}
gas_limit
gas_used
hash
layer1_block_number
layer1_tx_hash
logs_bloom
number
parent_hash
producer_address
registry_id
size
status
timestamp
transaction_count
}
}
Variables
{"input": BlockInput}
Response
{
"data": {
"block": {
"account": Account,
"gas_limit": Decimal,
"gas_used": Decimal,
"hash": HashFull,
"layer1_block_number": 987,
"layer1_tx_hash": HashFull,
"logs_bloom": "abc123",
"number": 987,
"parent_hash": HashFull,
"producer_address": HashAddress,
"registry_id": 987,
"size": 123,
"status": "COMMITTED",
"timestamp": "2007-12-03T10:15:30Z",
"transaction_count": 123
}
}
}
blocks
Description
function: get list of block sort by block number request-example:
query {
blocks(input: {}){
hash
parent_hash
number
gas_used
gas_limit
producer_address
account{
eth_address
}
}
}
result-example:
{
"data": {
"block": {
"account": null,
"gas_limit": "12500000",
"gas_used": "0",
"hash": "0x089f36f4f1eb1060e12ade101e4a6326423fa6cd11915d9bf1ef4bacafdbe663",
"number": 14938,
"parent_hash": "0xa552df86bad0233d0acb183056b095ac50abfa93161ff6b62ebe52bac2e53776",
"producer_address": "715ab282b873b79a7be8b0e8c13c4e8966a52040"
}
}
}
Response
Returns
[Block]
Arguments
| Name | Description |
|---|---|
input -
BlocksInput
|
Default = {page: 1, page_size: 10, sort_type: DESC} |
Example
Query
query Blocks($input: BlocksInput) {
blocks(input: $input) {
account {
...AccountFragment
}
gas_limit
gas_used
hash
layer1_block_number
layer1_tx_hash
logs_bloom
number
parent_hash
producer_address
registry_id
size
status
timestamp
transaction_count
}
}
Variables
{"input": {"page": 1, "page_size": 10, "sort_type": "DESC"}}
Response
{
"data": {
"blocks": [
{
"account": Account,
"gas_limit": Decimal,
"gas_used": Decimal,
"hash": HashFull,
"layer1_block_number": 987,
"layer1_tx_hash": HashFull,
"logs_bloom": "abc123",
"number": 987,
"parent_hash": HashFull,
"producer_address": HashAddress,
"registry_id": 987,
"size": 987,
"status": "COMMITTED",
"timestamp": "2007-12-03T10:15:30Z",
"transaction_count": 987
}
]
}
}
deposit_withdrawal_histories
Description
function: get deposit withdrawal histories
query {
deposit_withdrawal_histories(input: {udt_id: 1, limit: 1}) {
entries {
script_hash
eth_address
value
}
}
}
{
"data": {
"deposit_withdrawal_histories": {
"entries": [
{
"eth_address": "0x202bb8e620dfaf22e243232855a9f0ddb34b17ee",
"script_hash": "0x9ab1ede9789fe76e04f4f78fb0b2e7f4126f203311ae7fd73fed5c37c61cfe3f",
"value": "959999998703"
}
]
}
}
}
block number example
query {
deposit_withdrawal_histories(
input: {
start_block_number: 1
limit: 2
}
) {
entries {
script_hash
block_number
eth_address
value
}
}
}
{
"data": {
"deposit_withdrawal_histories": {
"entries": [
{
"block_number": 1357466,
"eth_address": "0xd1667cbf1cc60da94c1cf6c9cfb261e71b6047f7",
"script_hash": "0xaea8e18bfd509331b6a6414c9335adfac35f0da8d474d3f8fa422cb6e54a7f0f",
"value": "100000000000000"
},
{
"block_number": 1357233,
"eth_address": "0x49efbd0f15526da037a0a51476bb80f4ce373fc5",
"script_hash": "0x6a12ccba19f20ae12d4b68fb6868ac8b1a0873509557c71ae6b6aaad6684167a",
"value": "40000000000"
}
]
}
}
}
Response
Returns a
PaginateDepositWithdrawalHistories
Arguments
| Name | Description |
|---|---|
input -
HistoriesInput
|
Example
Query
query Deposit_withdrawal_histories($input: HistoriesInput) {
deposit_withdrawal_histories(input: $input) {
entries {
...DepositWithdrawalHistoryFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": HistoriesInput}
Response
{
"data": {
"deposit_withdrawal_histories": {
"entries": [DepositWithdrawalHistory],
"metadata": PaginateMetadata
}
}
}
erc1155_holders
Description
query {
erc1155_holders(
input: {
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
limit: 1
}
) {
entries {
rank
address_hash
token_contract_address_hash
quantity
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_holders": {
"entries": [
{
"address_hash": "0x46b6f87debd8f7607d00df47c31d2dc6d9999999",
"quantity": "21002",
"rank": 1,
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABRGtvh969j3YH0A30fDHS3G2ZmZmWgCZAAHaG9sZGVyc2QACHF1YW50aXR5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAAUgpkAANleHBhAGQABHNpZ25hAQ==",
"before": null,
"total_count": 5
}
}
}
}
query {
erc1155_holders(
input: {
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
limit: 1
after: "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABRGtvh969j3YH0A30fDHS3G2ZmZmWgCZAAHaG9sZGVyc2QACHF1YW50aXR5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAAUgpkAANleHBhAGQABHNpZ25hAQ=="
}
) {
entries {
rank
address_hash
token_contract_address_hash
quantity
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_holders": {
"entries": [
{
"address_hash": "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c",
"quantity": "1204",
"rank": 2,
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABTG5Y-0r_tquKOSt8wjzT_vdFF_bGgCZAAHaG9sZGVyc2QACHF1YW50aXR5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAABLRkAANleHBhAGQABHNpZ25hAQ==",
"before": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABTG5Y-0r_tquKOSt8wjzT_vdFF_bGgCZAAHaG9sZGVyc2QACHF1YW50aXR5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAABLRkAANleHBhAGQABHNpZ25hAQ==",
"total_count": 5
}
}
}
}
query {
erc1155_holders(
input: {
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
token_id: 1
limit: 1
}
) {
entries {
rank
address_hash
token_contract_address_hash
quantity
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_holders": {
"entries": [
{
"address_hash": "0x46b6f87debd8f7607d00df47c31d2dc6d9999999",
"quantity": "10001",
"rank": 1,
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABRGtvh969j3YH0A30fDHS3G2ZmZmWgCZAAHaG9sZGVyc2QACHF1YW50aXR5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAAJxFkAANleHBhAGQABHNpZ25hAQ==",
"before": null,
"total_count": 3
}
}
}
}
Response
Returns a
PaginateErc721Erc1155Holders
Arguments
| Name | Description |
|---|---|
input -
Erc1155HoldersInput!
|
Example
Query
query Erc1155_holders($input: Erc1155HoldersInput!) {
erc1155_holders(input: $input) {
entries {
...Erc721Erc1155HolderItemFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": Erc1155HoldersInput}
Response
{
"data": {
"erc1155_holders": {
"entries": [Erc721Erc1155HolderItem],
"metadata": PaginateMetadata
}
}
}
erc1155_inventory
Description
query {
erc1155_inventory(
input: {
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
limit: 1
after: "g3QAAAACaAJkAAlpbnZlbnRvcnlkABVjb250cmFjdF9hZGRyZXNzX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEUZAAFYnl0ZXNtAAAAFOaQPhJOW9roeEZ062JfHCEu_HieaAJkAAlpbnZlbnRvcnlkAAZjb3VudHN0AAAABGQACl9fc3RydWN0X19kAA5FbGl4aXIuRGVjaW1hbGQABGNvZWZiAAArVWQAA2V4cGEAZAAEc2lnbmEB"
}
) {
entries {
contract_address_hash
token_id
counts
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_inventory": {
"entries": [
{
"contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e",
"counts": "10103",
"token_id": "1"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAlpbnZlbnRvcnlkABVjb250cmFjdF9hZGRyZXNzX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEUZAAFYnl0ZXNtAAAAFOaQPhJOW9roeEZ062JfHCEu_HieaAJkAAlpbnZlbnRvcnlkAAZjb3VudHN0AAAABGQACl9fc3RydWN0X19kAA5FbGl4aXIuRGVjaW1hbGQABGNvZWZiAAAnd2QAA2V4cGEAZAAEc2lnbmEB",
"before": "g3QAAAACaAJkAAlpbnZlbnRvcnlkABVjb250cmFjdF9hZGRyZXNzX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEUZAAFYnl0ZXNtAAAAFOaQPhJOW9roeEZ062JfHCEu_HieaAJkAAlpbnZlbnRvcnlkAAZjb3VudHN0AAAABGQACl9fc3RydWN0X19kAA5FbGl4aXIuRGVjaW1hbGQABGNvZWZiAAAnd2QAA2V4cGEAZAAEc2lnbmEB",
"total_count": 6
}
}
}
}
Response
Returns a
PaginateErc1155Inventory
Arguments
| Name | Description |
|---|---|
input -
Erc721Erc1155InventoryInput!
|
Example
Query
query Erc1155_inventory($input: Erc721Erc1155InventoryInput!) {
erc1155_inventory(input: $input) {
entries {
...Erc1155InventoryFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": Erc721Erc1155InventoryInput}
Response
{
"data": {
"erc1155_inventory": {
"entries": [Erc1155Inventory],
"metadata": PaginateMetadata
}
}
}
erc1155_token_transfers
Description
query {
erc1155_token_transfers(
input: {
to_address: "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c"
start_block_number: 0
end_block_number: 909999
limit: 1
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: TRANSACTION_HASH }
{ sort_type: ASC, sort_value: LOG_INDEX }
]
}
) {
entries {
block {
timestamp
}
transaction_hash
block_number
to_account {
eth_address
}
to_address
from_account {
eth_address
}
token_id
token_ids
udt{
id
name
eth_type
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"erc1155_token_transfers": {
"entries": [
{
"block": {
"timestamp": "2022-07-16T13:47:10.511000Z"
},
"block_number": 195916,
"from_account": null,
"to_account": {
"eth_address": "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c"
},
"to_address": "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c",
"token_id": "0",
"token_ids": null,
"transaction_hash": "0x9fa88935cd93531dedec0c1b6dd79a0de3e754b5600714d410a85abc3035e7e4",
"udt": {
"eth_type": "ERC1155",
"id": 48435,
"name": null
}
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYgAC_UxkAAlsb2dfaW5kZXhhAGQAEHRyYW5zYWN0aW9uX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEgZAAFYnl0ZXNtAAAAIJ-oiTXNk1Md7ewMG23Xmg3j51S1YAcU1BCoWrwwNefk",
"before": null,
"total_count": 10
}
}
}
}
query {
erc1155_token_transfers(
input: {
to_address: "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c"
start_block_number: 0
end_block_number: 909999
limit: 1
token_id: "0"
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: TRANSACTION_HASH }
{ sort_type: ASC, sort_value: LOG_INDEX }
]
}
) {
entries {
token_contract_address_hash
block_number
token_id
token_ids
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"erc1155_token_transfers": {
"entries": [
{
"block_number": 195916,
"token_contract_address_hash": "0x6e45a282f2176d95a2bccc1a369fc9cb3f0584a0",
"token_id": "0",
"token_ids": null
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYgAC_UxkAAlsb2dfaW5kZXhhAGQAEHRyYW5zYWN0aW9uX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEgZAAFYnl0ZXNtAAAAIJ-oiTXNk1Md7ewMG23Xmg3j51S1YAcU1BCoWrwwNefk",
"before": null,
"total_count": 5
}
}
}
}
Response
Returns a
PaginateTokenTransfers
Arguments
| Name | Description |
|---|---|
input -
Erc721Erc1155TokenTransfersInput!
|
Default = {} |
Example
Query
query Erc1155_token_transfers($input: Erc721Erc1155TokenTransfersInput!) {
erc1155_token_transfers(input: $input) {
entries {
...TokenTransferFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"erc1155_token_transfers": {
"entries": [TokenTransfer],
"metadata": PaginateMetadata
}
}
}
erc1155_udts
Description
query {
erc1155_udts(
input: {
contract_address: "0xa87071a188e3e8d3e30f53a335ecc329d88026b7"
limit: 1
sorter: [{ sort_type: DESC, sort_value: EX_HOLDERS_COUNT }]
}
) {
entries {
id
name
contract_address_hash
eth_type
holders_count
token_type_count
minted_count
}
metadata {
total_count
after
before
}
}
udt(
input: { contract_address: "0xa87071a188e3e8d3e30f53a335ecc329d88026b7" }
) {
id
name
script_hash
eth_type
}
}
{
"data": {
"erc1155_udts": {
"entries": [
{
"contract_address_hash": "0xa87071a188e3e8d3e30f53a335ecc329d88026b7",
"eth_type": "ERC1155",
"holders_count": 4,
"id": 53717,
"minted_count": 31,
"name": null,
"token_type_count": 31
}
],
"metadata": {
"after": null,
"before": null,
"total_count": 1
}
},
"udt": {
"eth_type": "ERC1155",
"id": 53717,
"name": null,
"script_hash": null
}
}
}
query {
erc1155_udts(
input: {
limit: 1
sorter: [{ sort_type: DESC, sort_value: EX_HOLDERS_COUNT }]
}
) {
entries {
id
name
contract_address_hash
eth_type
holders_count
token_type_count
minted_count
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_udts": {
"entries": [
{
"contract_address_hash": "0xb53f9c79eca97291c51a918779fc7a500fbb9e42",
"eth_type": "ERC1155",
"holders_count": 7,
"id": 24008,
"minted_count": 30,
"name": null,
"token_type_count": 30
}
],
"metadata": {
"after": "g3QAAAACZAACaWRiAABdyGgCZAAJdV9ob2xkZXJzZAANaG9sZGVyc19jb3VudGEH",
"before": null,
"total_count": 524
}
}
}
}
query {
erc1155_udts(
input: {
limit: 1
sorter: [{ sort_type: DESC, sort_value: EX_HOLDERS_COUNT }]
after: "g3QAAAACZAACaWRiAABdyGgCZAAJdV9ob2xkZXJzZAANaG9sZGVyc19jb3VudGEH"
}
) {
entries {
id
name
contract_address_hash
eth_type
holders_count
token_type_count
minted_count
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_udts": {
"entries": [
{
"contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e",
"eth_type": "ERC1155",
"holders_count": 5,
"id": 48472,
"minted_count": 28,
"name": null,
"token_type_count": 6
}
],
"metadata": {
"after": "g3QAAAACZAACaWRiAAC9WGgCZAAJdV9ob2xkZXJzZAANaG9sZGVyc19jb3VudGEF",
"before": "g3QAAAACZAACaWRiAAC9WGgCZAAJdV9ob2xkZXJzZAANaG9sZGVyc19jb3VudGEF",
"total_count": 524
}
}
}
}
Response
Returns a
PaginateErc1155Udts
Arguments
| Name | Description |
|---|---|
input -
Erc1155UdtsInput!
|
Default = {} |
Example
Query
query Erc1155_udts($input: Erc1155UdtsInput!) {
erc1155_udts(input: $input) {
entries {
...Erc1155UdtFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"erc1155_udts": {
"entries": [Erc1155Udt],
"metadata": PaginateMetadata
}
}
}
erc1155_user_inventory
Description
query {
erc1155_user_inventory(
input: {
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
token_id: 0
limit: 1
}
) {
entries {
token_id
address_hash
token_contract_address_hash
value
udt {
id
name
eth_type
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc1155_user_inventory": {
"entries": [
{
"address_hash": "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c",
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e",
"token_id": "0",
"udt": {
"eth_type": "ERC1155",
"id": 48472,
"name": null
},
"value": "73"
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYgAEU89kAAJpZGIAHgmxZAAIdG9rZW5faWR0AAAABGQACl9fc3RydWN0X19kAA5FbGl4aXIuRGVjaW1hbGQABGNvZWZhAGQAA2V4cGEAZAAEc2lnbmEB",
"before": null,
"total_count": 4
}
}
}
}
Response
Returns a
PaginateErc1155UserInventory
Arguments
| Name | Description |
|---|---|
input -
Erc721Erc1155InventoryInput!
|
Example
Query
query Erc1155_user_inventory($input: Erc721Erc1155InventoryInput!) {
erc1155_user_inventory(input: $input) {
entries {
...Erc1155UserTokenFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": Erc721Erc1155InventoryInput}
Response
{
"data": {
"erc1155_user_inventory": {
"entries": [Erc1155UserToken],
"metadata": PaginateMetadata
}
}
}
erc1155_user_token
Description
query {
erc1155_user_token(
input: {
user_address: "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c"
contract_address: "0xe6903e124e5bdae8784674eb625f1c212efc789e"
token_id: 0
}
) {
value
token_type
token_id
token_contract_address_hash
}
}
{
"data": {
"erc1155_user_token": {
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e",
"token_id": "0",
"token_type": "ERC1155",
"value": "73"
}
}
}
Response
Returns an
Erc1155UserToken
Arguments
| Name | Description |
|---|---|
input -
Erc1155UserTokenInput!
|
Example
Query
query Erc1155_user_token($input: Erc1155UserTokenInput!) {
erc1155_user_token(input: $input) {
account {
...AccountFragment
}
address_hash
counts
token_contract_address_hash
token_id
token_instance {
...TokenInstanceFragment
}
token_type
udt {
...Erc7211155CommonUdtFragment
}
value
}
}
Variables
{"input": Erc1155UserTokenInput}
Response
{
"data": {
"erc1155_user_token": {
"account": Account,
"address_hash": HashAddress,
"counts": Decimal,
"token_contract_address_hash": HashAddress,
"token_id": Decimal,
"token_instance": TokenInstance,
"token_type": "ERC1155",
"udt": Erc7211155CommonUdt,
"value": Decimal
}
}
}
erc721_holders
Description
query {
erc721_holders(
input: {
contract_address: "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd"
limit: 1
}
) {
entries {
rank
address_hash
token_contract_address_hash
quantity
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc721_holders": {
"entries": [
{
"address_hash": "0xd8939812d27b0cfaa78e6925fba92bd2d61430ef",
"quantity": "16",
"rank": 1,
"token_contract_address_hash": "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABTYk5gS0nsM-qeOaSX7qSvS1hQw72gCZAAHaG9sZGVyc2QACHF1YW50aXR5YRA=",
"before": null,
"total_count": 308
}
}
}
}
query {
erc721_holders(
input: {
contract_address: "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd"
limit: 1
after: "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABTYk5gS0nsM-qeOaSX7qSvS1hQw72gCZAAHaG9sZGVyc2QACHF1YW50aXR5YRA="
}
) {
entries {
rank
address_hash
token_contract_address_hash
quantity
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc721_holders": {
"entries": [
{
"address_hash": "0x129ee9091f6017ee8cfd249402e3275fa3bc75e6",
"quantity": "10",
"rank": 2,
"token_contract_address_hash": "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd"
}
],
"metadata": {
"after": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABQSnukJH2AX7oz9JJQC4ydfo7x15mgCZAAHaG9sZGVyc2QACHF1YW50aXR5YQo=",
"before": "g3QAAAACaAJkAAdob2xkZXJzZAAMYWRkcmVzc19oYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhFGQABWJ5dGVzbQAAABQSnukJH2AX7oz9JJQC4ydfo7x15mgCZAAHaG9sZGVyc2QACHF1YW50aXR5YQo=",
"total_count": 308
}
}
}
}
Response
Returns a
PaginateErc721Erc1155Holders
Arguments
| Name | Description |
|---|---|
input -
Erc721HoldersInput!
|
Example
Query
query Erc721_holders($input: Erc721HoldersInput!) {
erc721_holders(input: $input) {
entries {
...Erc721Erc1155HolderItemFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": Erc721HoldersInput}
Response
{
"data": {
"erc721_holders": {
"entries": [Erc721Erc1155HolderItem],
"metadata": PaginateMetadata
}
}
}
erc721_inventory
Description
query {
erc721_inventory(
input: {
contract_address: "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd"
limit: 1
}
) {
entries {
token_id
address_hash
token_contract_address_hash
value
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc721_inventory": {
"entries": [
{
"address_hash": "0x7ec331e53da2ad677a7636b2da07d8dbea427ab7",
"token_contract_address_hash": "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd",
"token_id": "2000",
"value": "1"
}
],
"metadata": {
"after": "g3QAAAACZAACaWRiABXtp2QACHRva2VuX2lkdAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmYgAAB9BkAANleHBhAGQABHNpZ25hAQ==",
"before": null,
"total_count": 2000
}
}
}
}
Response
Returns a
PaginateErc721Inventory
Arguments
| Name | Description |
|---|---|
input -
Erc721Erc1155InventoryInput!
|
Example
Query
query Erc721_inventory($input: Erc721Erc1155InventoryInput!) {
erc721_inventory(input: $input) {
entries {
...Erc721UserTokenFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": Erc721Erc1155InventoryInput}
Response
{
"data": {
"erc721_inventory": {
"entries": [Erc721UserToken],
"metadata": PaginateMetadata
}
}
}
erc721_token_transfers
Description
query {
erc721_token_transfers(
input: {
to_address: "0x0000000000ce6d8c1fba76f26d6cc5db71432710"
start_block_number: 90
end_block_number: 909999
limit: 1
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: TRANSACTION_HASH }
{ sort_type: ASC, sort_value: LOG_INDEX }
]
}
) {
entries {
block {
timestamp
}
transaction_hash
block_number
to_account {
eth_address
}
to_address
from_account {
eth_address
}
token_id
token_ids
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"erc721_token_transfers": {
"entries": [
{
"block": {
"timestamp": "2022-08-28T05:15:00.300000Z"
},
"block_number": 320956,
"from_account": null,
"to_account": {
"eth_address": "0x0000000000ce6d8c1fba76f26d6cc5db71432710"
},
"to_address": "0x0000000000ce6d8c1fba76f26d6cc5db71432710",
"token_id": "558",
"token_ids": null,
"transaction_hash": "0xe10b9659f948de345ab4aa95d8a2ed20e2ac014c44ad7aa7862485973ef3d08f"
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYgAE5bxkAAlsb2dfaW5kZXhhAGQAEHRyYW5zYWN0aW9uX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEgZAAFYnl0ZXNtAAAAIOELlln5SN40WrSqldii7SDirAFMRK16p4YkhZc-89CP",
"before": null,
"total_count": 4
}
}
}
}
Response
Returns a
PaginateTokenTransfers
Arguments
| Name | Description |
|---|---|
input -
Erc721Erc1155TokenTransfersInput!
|
Default = {} |
Example
Query
query Erc721_token_transfers($input: Erc721Erc1155TokenTransfersInput!) {
erc721_token_transfers(input: $input) {
entries {
...TokenTransferFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"erc721_token_transfers": {
"entries": [TokenTransfer],
"metadata": PaginateMetadata
}
}
}
erc721_udts
Description
query {
erc721_udts(
input: { contract_address: "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd" }
) {
entries {
id
name
contract_address_hash
eth_type
holders_count
minted_count
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc721_udts": {
"entries": [
{
"contract_address_hash": "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd",
"eth_type": "ERC721",
"holders_count": 308,
"id": 58460,
"minted_count": 2000,
"name": null
}
],
"metadata": {
"after": null,
"before": null,
"total_count": 1
}
}
}
}
query {
erc721_udts(
input: {
limit: 1
sorter: [{ sort_type: DESC, sort_value: EX_HOLDERS_COUNT }]
after: "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAB9A="
}
) {
entries {
id
name
contract_address_hash
eth_type
holders_count
minted_count
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"erc721_udts": {
"entries": [
{
"contract_address_hash": "0x310a1f73379a658ef0eb9c4e5bd1006a24a5ad79",
"eth_type": "ERC721",
"holders_count": 1003,
"id": 5845,
"minted_count": 1000,
"name": null
}
],
"metadata": {
"after": "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAA-s=",
"before": "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAA-s=",
"total_count": 3193
}
}
}
}
Response
Returns a
PaginateErc721Udts
Arguments
| Name | Description |
|---|---|
input -
Erc721UdtsInput!
|
Default = {} |
Example
Query
query Erc721_udts($input: Erc721UdtsInput!) {
erc721_udts(input: $input) {
entries {
...Erc721UdtFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"erc721_udts": {
"entries": [Erc721Udt],
"metadata": PaginateMetadata
}
}
}
logs
Description
function: get list of logs by filter or conditions request-example:
query {
logs(input: {first_topic: "0x95e0325a2d4f803db1237b0e454f7d9a09ec46941e478e3e98c510d8f1506031",end_block_number: 9988, page: 1, page_size: 1}) {
transaction_hash
block_number
address_hash
data
first_topic
second_topic
third_topic
fourth_topic
}
}
{
"data": {
"logs": [
{
"address_hash": "0x6589f40e144a03da53234dc98a47da36160dbf77",
"block_number": 9988,
"data": "0x00000000000000000000000000000000000000000000000000000000000027040000000000000000000000000000000000000000000000000000000000000000",
"first_topic": "0x95e0325a2d4f803db1237b0e454f7d9a09ec46941e478e3e98c510d8f1506031",
"fourth_topic": null,
"second_topic": null,
"third_topic": null,
"transaction_hash": "0xeaf751c7eb86b679b7138fac22c603fccb0ca397bccce5a74e5372da7ea12c22"
}
]
}
}
Response
Returns a
PaginateLogs
Arguments
| Name | Description |
|---|---|
input -
LogInput!
|
Example
Query
query Logs($input: LogInput!) {
logs(input: $input) {
entries {
...LogFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": LogInput}
Response
{
"data": {
"logs": {
"entries": [Log],
"metadata": PaginateMetadata
}
}
}
reverse_search_bit_alias
Description
query {
reverse_search_bit_alias(
input: {
address: "0xcc0af0af911dd40853b8c8dfee90b32f8d1ecad6"
}
)
}
{
"data": {
"reverse_search_bit_alias": "freder.bit"
}
}
Response
Returns a
String
Arguments
| Name | Description |
|---|---|
input -
ReverseSearchBitAliasInput!
|
Example
Query
query Reverse_search_bit_alias($input: ReverseSearchBitAliasInput!) {
reverse_search_bit_alias(input: $input)
}
Variables
{"input": ReverseSearchBitAliasInput}
Response
{
"data": {
"reverse_search_bit_alias": "xyz789"
}
}
search_bit_alias
Description
query {
search_bit_alias(
input: {
bit_alias: "freder.bit"
}
)
}
{
"data": {
"search_bit_alias": "0xcc0af0af911dd40853b8c8dfee90b32f8d1ecad6"
}
}
Response
Returns a
HashAddress
Arguments
| Name | Description |
|---|---|
input -
SearchBitAliasInput!
|
Example
Query
query Search_bit_alias($input: SearchBitAliasInput!) {
search_bit_alias(input: $input)
}
Variables
{"input": SearchBitAliasInput}
Response
{"data": {"search_bit_alias": HashAddress}}
search_keyword
Description
keyword can be: udt name| account eth_address | address | transaction hash | block number
query {
search_keyword(input: { keyword: "UDT"}){
type
id
}
}
Response
Returns a
SearchResult
Arguments
| Name | Description |
|---|---|
input -
SearchKeywordInput!
|
Example
Query
query Search_keyword($input: SearchKeywordInput!) {
search_keyword(input: $input) {
id
type
}
}
Variables
{"input": SearchKeywordInput}
Response
{
"data": {
"search_keyword": {
"id": "abc123",
"type": "ACCOUNT"
}
}
}
search_udt
Description
search_udt example:
query {
search_udt(input: { fuzzy_name: "%ERC%", limit: 1 }) {
entries {
id
name
symbol
type
contract_address_hash
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"search_udt": {
"entries": [
{
"contract_address_hash": "0x8e82245c50864754654d2fae31367444e10b990e",
"id": 89001,
"name": "testERC20",
"symbol": "testERC20",
"type": "NATIVE"
}
],
"metadata": {
"after": "g3QAAAABaAJkAARkZXNjZAACaWRiAAFbqQ==",
"before": null,
"total_count": 715
}
}
}
}
Response
Returns a
PaginateSearchUdts
Arguments
| Name | Description |
|---|---|
input -
SearchUdtInput!
|
Default = {} |
Example
Query
query Search_udt($input: SearchUdtInput!) {
search_udt(input: $input) {
entries {
...SearchUdtResultFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"search_udt": {
"entries": [SearchUdtResult],
"metadata": PaginateMetadata
}
}
}
smart_contract
Description
function: get smart contract by address request-result-example:
query {
smart_contract(
input: { contract_address: "0x2503A1A79A443F3961EE96A8C5EC513638129614" }
) {
name
account_id
account {
eth_address
}
}
}
{
"data": {
"smart_contract": {
"account": {
"eth_address": "0x2503a1a79a443f3961ee96a8c5ec513638129614"
},
"account_id": "6841",
"name": "EIP20"
}
}
}
request-result-example2:
query {
smart_contract(
input: { script_hash: "0x9B55204439C78D3B9CBCC62C03F31E47C8457FD39CA9A9EB805B364B45C26C38" }
) {
name
account_id
account {
eth_address
}
}
}
{
"data": {
"smart_contract": {
"account": {
"eth_address": "0x2503a1a79a443f3961ee96a8c5ec513638129614"
},
"account_id": "6841",
"name": "EIP20"
}
}
}
Response
Returns a
SmartContract
Arguments
| Name | Description |
|---|---|
input -
SmartContractInput!
|
Example
Query
query Smart_contract($input: SmartContractInput!) {
smart_contract(input: $input) {
abi
account {
...AccountFragment
}
account_id
address_hash
ckb_balance
compiler_file_format
compiler_version
constructor_arguments
contract_source_code
deployment_tx_hash
id
implementation_abi
implementation_address_hash
implementation_fetched_at
implementation_name
name
other_info
sourcify_metadata
}
}
Variables
{"input": SmartContractInput}
Response
{
"data": {
"smart_contract": {
"abi": [Json],
"account": Account,
"account_id": 987,
"address_hash": HashAddress,
"ckb_balance": Decimal,
"compiler_file_format": "abc123",
"compiler_version": "abc123",
"constructor_arguments": "xyz789",
"contract_source_code": "xyz789",
"deployment_tx_hash": HashFull,
"id": 987,
"implementation_abi": [Json],
"implementation_address_hash": HashAddress,
"implementation_fetched_at": "2007-12-03T10:15:30Z",
"implementation_name": "abc123",
"name": "abc123",
"other_info": "abc123",
"sourcify_metadata": Json
}
}
}
smart_contracts
Description
function: get list of smart contracts request-result-example:
query {
smart_contracts(input: { sorter: [{ sort_type: ASC, sort_value: ID }] }) {
entries {
name
account_id
account {
eth_address
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"smart_contracts": {
"entries": [
{
"account": {
"eth_address": "0x2503a1a79a443f3961ee96a8c5ec513638129614"
},
"account_id": "6841",
"name": "EIP20"
}
],
"metadata": {
"after": null,
"before": null,
"total_count": 1
}
}
}
}
multi-table-sorter-example:
query {
smart_contracts(
input: { sorter: [{ sort_type: ASC, sort_value: EX_TX_COUNT }] }
) {
entries {
name
account_id
account {
eth_address
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"smart_contracts": {
"entries": [
{
"account": {
"eth_address": "0x2503a1a79a443f3961ee96a8c5ec513638129614"
},
"account_id": "6841",
"name": "EIP20"
}
],
"metadata": {
"after": null,
"before": null,
"total_count": 1
}
}
}
}
Response
Returns a
PaginateSmartContracts
Arguments
| Name | Description |
|---|---|
input -
SmartContractsInput
|
Example
Query
query Smart_contracts($input: SmartContractsInput) {
smart_contracts(input: $input) {
entries {
...SmartContractFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": SmartContractsInput}
Response
{
"data": {
"smart_contracts": {
"entries": [SmartContract],
"metadata": PaginateMetadata
}
}
}
sourcify_check_by_addresses
Description
check by addresses example:
query {
sourcify_check_by_addresses(
input: { addresses: ["0x7A4a65Db21864384d2D21a60367d7Fd5c86F8Fba"] }
) {
address
status
chain_ids
}
}
{
"data": {
"sourcify_check_by_addresses": [
{
"address": "0x7a4a65db21864384d2d21a60367d7fd5c86f8fba",
"chain_ids": [
"71401"
],
"status": "perfect"
}
]
}
}
Response
Returns
[SourcifyCheckByAddresses]
Arguments
| Name | Description |
|---|---|
input -
SourcifyCheckByAddressesInput!
|
Example
Query
query Sourcify_check_by_addresses($input: SourcifyCheckByAddressesInput!) {
sourcify_check_by_addresses(input: $input) {
address
chain_ids
status
}
}
Variables
{"input": SourcifyCheckByAddressesInput}
Response
{
"data": {
"sourcify_check_by_addresses": [
{
"address": HashAddress,
"chain_ids": ["abc123"],
"status": "abc123"
}
]
}
}
token_approvals
Description
function: get list of token approvals by filter example:
query {
token_approvals(
input: {
address: "0x966b30e576a4d6731996748b48dd67c94ef29067"
token_type: ERC20
limit: 2
sorter: [
{ sort_type: DESC, sort_value: BLOCK_NUMBER },
{ sort_type: DESC, sort_value: ID }
]
}
) {
entries {
transaction_hash
udt {
id
name
eth_type
}
block {
timestamp
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"token_approvals": {
"entries": [
{
"block": {
"timestamp": "2022-05-08T05:19:15.637000Z"
},
"transaction_hash": "0xa22dc752ce79bc923ea86d0135b39074c6fc56a7c10cb60879180bcfd81142c7",
"udt": {
"eth_type": "ERC20",
"id": 22,
"name": "testERC20"
}
}
],
"metadata": {
"after": "g3QAAAABZAAMYmxvY2tfbnVtYmVyYVk=",
"before": null,
"total_count": 6
}
}
}
}
Response
Returns a
PaginateTokenApprovals
Arguments
| Name | Description |
|---|---|
input -
TokenApprovalInput!
|
Default = {} |
Example
Query
query Token_approvals($input: TokenApprovalInput!) {
token_approvals(input: $input) {
entries {
...TokenApprovalFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"token_approvals": {
"entries": [TokenApproval],
"metadata": PaginateMetadata
}
}
}
token_transfers
Description
function: get list of token transfers by filter example:
query {
token_transfers(
input: {
from_address: "0x966b30e576a4d6731996748b48dd67c94ef29067"
to_address: "0xbd6250d17fc557dfe39a9eb3882c421d4c7f6413"
start_block_number: 90
end_block_number: 90
limit: 2
combine_from_to: true
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: TRANSACTION_HASH }
{ sort_type: ASC, sort_value: LOG_INDEX }
]
}
) {
entries {
transaction_hash
block_number
to_account {
eth_address
}
to_address
from_account {
eth_address
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"token_transfers": {
"entries": [
{
"block_number": 90,
"from_account": {
"eth_address": "0x966b30e576a4d6731996748b48dd67c94ef29067"
},
"to_account": {
"eth_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3"
},
"to_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3",
"transaction_hash": "0x65ea60c7291f5aec6e9f86f6b4af97f6287409fc72f66975af6203721d10d409"
},
{
"block_number": 90,
"from_account": {
"eth_address": "0x966b30e576a4d6731996748b48dd67c94ef29067"
},
"to_account": {
"eth_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3"
},
"to_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3",
"transaction_hash": "0xc3c63aa91100e6c14cea294559eacea33d6a12ed3be89f303247e63f670c2c34"
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYVpkAAlsb2dfaW5kZXhhAWQAEHRyYW5zYWN0aW9uX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEgZAAFYnl0ZXNtAAAAIMPGOqkRAObBTOopRVnqzqM9ahLtO-ifMDJH5j9nDCw0",
"before": null,
"total_count": 3
}
}
}
}
example2:
query {
token_transfers(
input: {
from_address: "0x966b30e576a4d6731996748b48dd67c94ef29067"
to_address: "0xbd6250d17fc557dfe39a9eb3882c421d4c7f6413"
start_block_number: 90
end_block_number: 909999
age_range_end: "2022-05-08T05:19:26.237000Z"
limit: 1
combine_from_to: true
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: TRANSACTION_HASH }
{ sort_type: ASC, sort_value: LOG_INDEX }
]
}
) {
entries {
block {
timestamp
}
transaction_hash
block_number
to_account {
eth_address
}
to_address
from_account {
eth_address
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"token_transfers": {
"entries": [
{
"block": {
"timestamp": "2022-05-08T05:19:25.237000Z"
},
"block_number": 90,
"from_account": {
"eth_address": "0x966b30e576a4d6731996748b48dd67c94ef29067"
},
"to_account": {
"eth_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3"
},
"to_address": "0xc6a44e4d2216a98b3a5086a64a33d94fbcc8fec3",
"transaction_hash": "0x65ea60c7291f5aec6e9f86f6b4af97f6287409fc72f66975af6203721d10d409"
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYVpkAAlsb2dfaW5kZXhhAWQAEHRyYW5zYWN0aW9uX2hhc2h0AAAAA2QACl9fc3RydWN0X19kACJFbGl4aXIuR29kd29rZW5FeHBsb3Jlci5DaGFpbi5IYXNoZAAKYnl0ZV9jb3VudGEgZAAFYnl0ZXNtAAAAIGXqYMcpH1rsbp-G9rSvl_YodAn8cvZpda9iA3IdENQJ",
"before": null,
"total_count": 3
}
}
}
}
Response
Returns a
PaginateTokenTransfers
Arguments
| Name | Description |
|---|---|
input -
Erc20TokenTransfersInput!
|
Default = {} |
Example
Query
query Token_transfers($input: Erc20TokenTransfersInput!) {
token_transfers(input: $input) {
entries {
...TokenTransferFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"token_transfers": {
"entries": [TokenTransfer],
"metadata": PaginateMetadata
}
}
}
transaction
Description
function: get transaction by transaction_hash request-example:
query {
transaction(
input: {
eth_hash: "0xcdbda9ec578e73e886446d3bd5ca070d77a908be4187fc0e835c7c1598a3fcfa"
}
) {
hash
nonce
type
index
from_account {
eth_address
type
}
to_account {
eth_address
type
}
polyjuice {
is_create
value
status
input
created_contract_address_hash
gas_used
gas_limit
gas_price
}
block {
number
hash
timestamp
status
layer1_block_number
}
}
}
{
"data": {
"transaction": {
"block": {
"hash": "0x08b5d6747151e7cc0a2ffd81505d3db39af268c9c1c753a22e7c80890e3b94c5",
"layer1_block_number": 5293647,
"number": 81,
"status": "FINALIZED",
"timestamp": "2022-05-08T05:15:14.234000Z"
},
"from_account": {
"eth_address": "0x966b30e576a4d6731996748b48dd67c94ef29067",
"type": "ETH_USER"
},
"hash": "0xc7ab89121ab5727b09e007cc04176216e4d5fab1fb0ebe33320b7075e7e54533",
"index": 0,
"nonce": 0,
"polyjuice": {
"created_contract_address_hash": "0xf9f9bd767dd10ad384182769d47d9e239f281bcd",
"gas_limit": "245",
"gas_price": "1",
"gas_used": "245",
"input": "0x608060405234801561001057600080fd5b506103e2806100206000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c80636fd902e11161005b5780636fd902e114610105578063796b89b9146101235780637c0dacdb14610141578063ee82ac5e1461014b57610088565b806312e05dd11461008d5780632df8e949146100ab5780633408e470146100c957806342cbb15c146100e7575b600080fd5b61009561017b565b6040516100a291906102a3565b60405180910390f35b6100b3610183565b6040516100c0919061026d565b60405180910390f35b6100d161018b565b6040516100de91906102a3565b60405180910390f35b6100ef610193565b6040516100fc91906102a3565b60405180910390f35b61010d6101a7565b60405161011a91906102a3565b60405180910390f35b61012b6101af565b60405161013891906102a3565b60405180910390f35b6101496101b7565b005b61016560048036038101906101609190610213565b6101f3565b6040516101729190610288565b60405180910390f35b600044905090565b600041905090565b600046905090565b60006001436101a291906102e7565b905090565b600043905090565b600042905090565b7f95e0325a2d4f803db1237b0e454f7d9a09ec46941e478e3e98c510d8f15060314343406040516101e99291906102be565b60405180910390a1565b600081409050919050565b60008135905061020d81610395565b92915050565b60006020828403121561022957610228610390565b5b6000610237848285016101fe565b91505092915050565b6102498161031b565b82525050565b6102588161032d565b82525050565b61026781610357565b82525050565b60006020820190506102826000830184610240565b92915050565b600060208201905061029d600083018461024f565b92915050565b60006020820190506102b8600083018461025e565b92915050565b60006040820190506102d3600083018561025e565b6102e0602083018461024f565b9392505050565b60006102f282610357565b91506102fd83610357565b9250828210156103105761030f610361565b5b828203905092915050565b600061032682610337565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600080fd5b61039e81610357565b81146103a957600080fd5b5056fea2646970667358221220d273a25c31e711ab76ca9928e49a2f327bab9ac3707697ef7567ca28d6673d3a64736f6c63430008060033",
"is_create": true,
"status": "SUCCEED",
"value": "0"
},
"to_account": {
"eth_address": "0x2f760c8f8656bde4995f26b8963e2dd801000000",
"type": "POLYJUICE_CREATOR"
},
"type": "POLYJUICE"
}
}
}
Response
Returns a
Transaction
Arguments
| Name | Description |
|---|---|
input -
TransactionInput!
|
Example
Query
query Transaction($input: TransactionInput!) {
transaction(input: $input) {
args
block {
...BlockFragment
}
block_hash
block_number
eth_hash
from_account {
...AccountFragment
}
from_account_id
hash
index
method_id
method_name
nonce
polyjuice {
...PolyjuiceFragment
}
polyjuice_creator {
...PolyjuiceCreatorFragment
}
to_account {
...AccountFragment
}
to_account_id
type
}
}
Variables
{"input": TransactionInput}
Response
{
"data": {
"transaction": {
"args": ChainData,
"block": Block,
"block_hash": HashFull,
"block_number": 987,
"eth_hash": HashFull,
"from_account": Account,
"from_account_id": 123,
"hash": HashFull,
"index": 987,
"method_id": ChainData,
"method_name": "xyz789",
"nonce": 123,
"polyjuice": Polyjuice,
"polyjuice_creator": PolyjuiceCreator,
"to_account": Account,
"to_account_id": 987,
"type": "ETH_ADDRESS_REGISTRY"
}
}
}
transactions
Description
sorter-example:
query {
transactions(
input: {
limit: 1
sorter: [
{ sort_type: ASC, sort_value: BLOCK_NUMBER }
{ sort_type: ASC, sort_value: HASH }
{ sort_type: ASC, sort_value: INDEX }
]
}
) {
entries {
hash
eth_hash
block_hash
block_number
type
from_account_id
from_account {
script_hash
id
eth_address
}
to_account_id
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"transactions": {
"entries": [
{
"block_hash": "0x4ed214a4aa0085da12c80468ea299d85ea043d04b38b93e26218bab7849f5e40",
"block_number": 6,
"eth_hash": null,
"from_account": {
"eth_address": "0x715ab282b873b79a7be8b0e8c13c4e8966a52040",
"id": 3,
"script_hash": "0x495d9cfb7b6faeaeb0f5a7ed81a830a477f7aeea8d53ef73abdc2ec2f5fed07c"
},
"from_account_id": 3,
"hash": "0xc621e5cd5a7d49c32e87b59956886c3747be77ecf7a7942ebaa5e2de96e9aad3",
"to_account_id": 0,
"type": "POLYJUICE_CREATOR"
}
],
"metadata": {
"after": "g3QAAAADZAAMYmxvY2tfbnVtYmVyYQZkAARoYXNodAAAAANkAApfX3N0cnVjdF9fZAAiRWxpeGlyLkdvZHdva2VuRXhwbG9yZXIuQ2hhaW4uSGFzaGQACmJ5dGVfY291bnRhIGQABWJ5dGVzbQAAACDGIeXNWn1Jwy6HtZlWiGw3R7537PenlC66peLelumq02QABWluZGV4YQA=",
"before": null,
"total_count": 10000
}
}
}
}
block-number-and-age-range-example:
query {
transactions(
input: {
to_script_hash: "0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e"
start_block_number: 1
end_block_number: 2624399
limit: 1
age_range_start: "2022-06-11T16:28:47Z"
age_range_end: "2022-06-11T16:29:01.455000Z"
sorter: [{ sort_type: ASC, sort_value: BLOCK_NUMBER }]
}
) {
entries {
block_hash
block {
timestamp
}
block_number
type
from_account_id
from_account {
script_hash
id
eth_address
}
to_account_id
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"transactions": {
"entries": [
{
"block": {
"timestamp": "2022-06-11T16:28:47.111000Z"
},
"block_hash": "0xa89010460abfb53bf85fc74ae98480d3d6c1708c2ce8586aac549544289e5a23",
"block_number": 95494,
"from_account": {
"eth_address": "0x2088d0e35c23e7c344f96e57be19043d6e2a44f3",
"id": 14578,
"script_hash": "0x07cb90b74c9b22a6ff8357332b589e8dbfc3cb119d4535c76cc51c43ab9c5f9d"
},
"from_account_id": 14578,
"to_account_id": 2,
"type": "ETH_ADDRESS_REGISTRY"
}
],
"metadata": {
"after": "g3QAAAABZAAMYmxvY2tfbnVtYmVyYgABdQY=",
"before": null,
"total_count": 3
}
}
}
}
from-to-example:
query {
transactions(
input: {
from_eth_address: "0x2088d0e35c23e7c344f96e57be19043d6e2a44f3"
start_block_number: 1
end_block_number: 2624399
limit: 1
sorter: [{sort_type: ASC, sort_value: BLOCK_NUMBER}]
}
) {
entries {
block_hash
block_number
type
from_account_id
from_account {
script_hash
id
eth_address
}
to_account_id
to_account {
script_hash
id
eth_address
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"transactions": {
"entries": [
{
"block_hash": "0x9e12e1de57b66f0d84c95a6a9369715f82d21bbf1ff943ae891739c6343ea781",
"block_number": 61049,
"from_account": {
"eth_address": "0x2088d0e35c23e7c344f96e57be19043d6e2a44f3",
"id": 14578,
"script_hash": "0x07cb90b74c9b22a6ff8357332b589e8dbfc3cb119d4535c76cc51c43ab9c5f9d"
},
"from_account_id": 14578,
"to_account": {
"eth_address": "0x07fc54ff9f92bfa3679104778252a1c42f7b48d9",
"id": 18576,
"script_hash": "0xaae0058ff21c2d8e2fc02821e12ef074f846ff66c0f1689020c48fbcc481677f"
},
"to_account_id": 18576,
"type": "POLYJUICE"
}
],
"metadata": {
"after": "g3QAAAABZAAMYmxvY2tfbnVtYmVyYgAA7nk=",
"before": null,
"total_count": 962
}
}
}
}
combine-example:
query {
transactions(
input: {
from_eth_address: "0x2088d0e35c23e7c344f96e57be19043d6e2a44f3"
to_eth_address: "0x2088d0e35c23e7c344f96e57be19043d6e2a44f3"
combine_from_to: false
start_block_number: 1
end_block_number: 2624399
limit: 1
sorter: [{ sort_type: ASC, sort_value: BLOCK_NUMBER }]
}
) {
entries {
block_hash
block_number
type
from_account_id
from_account {
script_hash
id
eth_address
}
to_account_id
to_account {
script_hash
id
eth_address
}
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"transactions": {
"entries": [],
"metadata": {
"after": null,
"before": null,
"total_count": 0
}
}
}
}
pending-transaction-example:
query {
transactions(
input: {
status: PENDING
sorter: [{ sort_type: DESC, sort_value: BLOCK_NUMBER }]
}
) {
entries {
block_hash
hash
}
metadata {
total_count
before
after
}
}
}
{
"data": {
"transactions": {
"entries": [
{
"block_hash": null,
"hash": "0xc8e2bea0d8f779ea10e97f9139540e3c6dee8b2267285c71559477a1e5c33507"
},
],
"metadata": {
"after": null,
"before": null,
"total_count": 0
}
}
}
}
Response
Returns a
PaginateTrasactions
Arguments
| Name | Description |
|---|---|
input -
TransactionsInput
|
Default = {} |
Example
Query
query Transactions($input: TransactionsInput) {
transactions(input: $input) {
entries {
...TransactionFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"transactions": {
"entries": [Transaction],
"metadata": PaginateMetadata
}
}
}
udt
Description
function: get udt by contract address contract address example:
query {
udt(
input: { contract_address: "0x2275AFE815DE66BEABE7A2C03005537AB843AFB2" }
) {
id
name
script_hash
contract_address_hash
}
}
{
"data": {
"udt": {
"contract_address_hash": "0x2275afe815de66beabe7a2c03005537ab843afb2",
"id": "36050",
"name": "GodwokenToken on testnet_v1",
"script_hash": null
}
}
}
id example:
query {
udt(
input: {
id: 36050
contract_address: "0x2275AFE815DE66BEABE7A2C03005537AB843AFB2"
}
) {
id
bridge_account_id
name
script_hash
contract_address_hash
}
}
{
"data": {
"udt": {
"bridge_account_id": null,
"contract_address_hash": "0x2275afe815de66beabe7a2c03005537ab843afb2",
"id": "36050",
"name": "GodwokenToken on testnet_v1",
"script_hash": null
}
}
}
Example
Query
query Udt($input: UdtInput!) {
udt(input: $input) {
account {
...AccountFragment
}
bridge_account_id
contract_address_hash
decimal
description
display_name
eth_type
holders_count
icon
id
minted_count
name
official_site
price
rank
script_hash
supply
symbol
token_exchange_rate {
...TokenExchangeRateFragment
}
type
type_script
uan
value
}
}
Variables
{"input": UdtInput}
Response
{
"data": {
"udt": {
"account": Account,
"bridge_account_id": 987,
"contract_address_hash": HashAddress,
"decimal": 987,
"description": "xyz789",
"display_name": "abc123",
"eth_type": "ERC1155",
"holders_count": 987,
"icon": "abc123",
"id": 123,
"minted_count": Decimal,
"name": "xyz789",
"official_site": "abc123",
"price": Decimal,
"rank": 123,
"script_hash": HashFull,
"supply": Decimal,
"symbol": "xyz789",
"token_exchange_rate": TokenExchangeRate,
"type": "BRIDGE",
"type_script": Json,
"uan": "xyz789",
"value": Decimal
}
}
}
udts
Description
function: get list of udts pagination-example:
query {
udts(
input: {
limit: 1
after: "g3QAAAABZAACaWRhAQ=="
sorter: [{ sort_type: ASC, sort_value: ID }]
}
) {
entries {
id
name
type
supply
account {
eth_address
script_hash
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"udts": {
"entries": [
{
"account": {
"eth_address": null,
"script_hash": "0x64050af0d25c38ddf9455b8108654f7c5cc30fe6d871a303d83b1020edddd7a7"
},
"id": "80",
"name": null,
"supply": null,
"type": "BRIDGE"
}
],
"metadata": {
"after": "g3QAAAABZAACaWRhUA==",
"before": "g3QAAAABZAACaWRhUA==",
"total_count": 14
}
}
}
}
fuzzy-name-example: fuzzy name use postgresql ilike keyword, pattern matching docs like: https://www.postgresql.org/docs/current/functions-matching.html#FUNCTIONS-LIKE
query {
udts(
input: {
limit: 1
fuzzy_name: "%ckb%"
sorter: [{ sort_type: ASC, sort_value: ID }]
}
) {
entries {
id
name
type
supply
account {
eth_address
script_hash
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"udts": {
"entries": [
{
"account": {
"eth_address": null,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"id": "1",
"name": "pCKB",
"supply": "12800091655514882421855103",
"type": "BRIDGE"
}
],
"metadata": {
"after": null,
"before": null,
"total_count": 1
}
}
}
}
sorter-example:
query {
udts(
input: {
limit: 3
sorter: [{ sort_type: ASC, sort_value: SUPPLY }]
}
) {
entries {
id
name
type
supply
account {
eth_address
script_hash
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"udts": {
"entries": [
{
"account": {
"eth_address": "0x2503a1a79a443f3961ee96a8c5ec513638129614",
"script_hash": "0x9b55204439c78d3b9cbcc62c03f31e47c8457fd39ca9a9eb805b364b45c26c38"
},
"id": "6841",
"name": "test",
"supply": "111",
"type": "NATIVE"
},
{
"account": {
"eth_address": null,
"script_hash": "0x3e1301e759261b676ce68d0d97936cd431a4af2a34072aa94e44655909765eb4"
},
"id": "6571",
"name": "GodwokenToken on testnet_v1",
"supply": "3247",
"type": "BRIDGE"
},
{
"account": {
"eth_address": "0xd3ecf26a4a1e99c8717d7d8e365933fffa7d74d6",
"script_hash": "0xb9150cbee429e205f9c956da7def16344232f50c851d9a5b0f7ef6f211c91cbf"
},
"id": "20021",
"name": " My Hardhat Token",
"supply": "100000000000000000000",
"type": "NATIVE"
}
],
"metadata": {
"after": "g3QAAAABZAAGc3VwcGx5dAAAAARkAApfX3N0cnVjdF9fZAAORWxpeGlyLkRlY2ltYWxkAARjb2VmbgkAAAAQYy1ex2sFZAADZXhwYQBkAARzaWduYQE=",
"before": null,
"total_count": 16
}
}
}
}
sorter-example:
query {
udts(
input: {
limit: 3
sorter: [{ sort_type: ASC, sort_value: NAME }]
}
) {
entries {
id
name
type
supply
account {
eth_address
script_hash
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"udts": {
"entries": [
{
"account": {
"eth_address": null,
"script_hash": "0x3e1301e759261b676ce68d0d97936cd431a4af2a34072aa94e44655909765eb4"
},
"id": "6571",
"name": "GodwokenToken on testnet_v1",
"supply": "3247",
"type": "BRIDGE"
},
{
"account": {
"eth_address": "0xd3ecf26a4a1e99c8717d7d8e365933fffa7d74d6",
"script_hash": "0xb9150cbee429e205f9c956da7def16344232f50c851d9a5b0f7ef6f211c91cbf"
},
"id": "20021",
"name": " My Hardhat Token",
"supply": "100000000000000000000",
"type": "NATIVE"
},
{
"account": {
"eth_address": null,
"script_hash": "0x595cc14e574a708dc70a320d2026f79374246ed4659261131cdda7dd5814b5ca"
},
"id": "1",
"name": "pCKB",
"supply": "12800091655514882421855103",
"type": "BRIDGE"
}
],
"metadata": {
"after": "g3QAAAABZAAEbmFtZW0AAAAEcENLQg==",
"before": null,
"total_count": 16
}
}
}
}
holders example:
query {
udts(
input: {
limit: 1
sorter: [{ sort_type: DESC, sort_value: EX_HOLDERS_COUNT }]
after: "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAB9A="
}
) {
entries {
id
name
type
supply
holders_count
account {
eth_address
script_hash
}
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"udts": {
"entries": [
{
"account": {
"eth_address": "0x975ab64f4901af5f0c96636dea0b9de3419d0c2f",
"script_hash": "0xb01d03bbed4d9b55cfc484a3329875df13832c64e53c554233e18231026da891"
},
"holders_count": 1981,
"id": 63191,
"name": "CKB",
"supply": "31236920264242650421855103",
"type": "NATIVE"
}
],
"metadata": {
"after": "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAB70=",
"before": "g3QAAAABaAJkAAl1X2hvbGRlcnNkAA1ob2xkZXJzX2NvdW50YgAAB70=",
"total_count": 3758
}
}
}
}
Response
Returns a
PaginateUdts
Arguments
| Name | Description |
|---|---|
input -
UdtsInput
|
Default = {} |
Example
Query
query Udts($input: UdtsInput) {
udts(input: $input) {
entries {
...UdtFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": {}}
Response
{
"data": {
"udts": {
"entries": [Udt],
"metadata": PaginateMetadata
}
}
}
user_erc1155_assets
Description
query {
user_erc1155_assets(
input: {
user_address: "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c"
limit: 1
}
) {
entries {
token_id
address_hash
token_contract_address_hash
value
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"user_erc1155_assets": {
"entries": [
{
"address_hash": "0xc6e58fb4affb6ab8a392b7cc23cd3fef74517f6c",
"token_contract_address_hash": "0xe6903e124e5bdae8784674eb625f1c212efc789e",
"token_id": "0",
"value": "73"
}
],
"metadata": {
"after": "g3QAAAACZAAMYmxvY2tfbnVtYmVyYgAEU89kABB2YWx1ZV9mZXRjaGVkX2F0dAAAAA1kAApfX3N0cnVjdF9fZAAPRWxpeGlyLkRhdGVUaW1lZAAIY2FsZW5kYXJkABNFbGl4aXIuQ2FsZW5kYXIuSVNPZAADZGF5YQJkAARob3VyYQNkAAttaWNyb3NlY29uZGgCYgAK0UlhBmQABm1pbnV0ZWEwZAAFbW9udGhhCWQABnNlY29uZGEvZAAKc3RkX29mZnNldGEAZAAJdGltZV96b25lbQAAAAdFdGMvVVRDZAAKdXRjX29mZnNldGEAZAAEeWVhcmIAAAfmZAAJem9uZV9hYmJybQAAAANVVEM=",
"before": null,
"total_count": 6
}
}
}
}
Response
Returns a
PaginateUserErc1155Assets
Arguments
| Name | Description |
|---|---|
input -
UserErc721Erc1155AssetsInput!
|
Example
Query
query User_erc1155_assets($input: UserErc721Erc1155AssetsInput!) {
user_erc1155_assets(input: $input) {
entries {
...Erc1155UserTokenFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": UserErc721Erc1155AssetsInput}
Response
{
"data": {
"user_erc1155_assets": {
"entries": [Erc1155UserToken],
"metadata": PaginateMetadata
}
}
}
user_erc721_assets
Description
query {
user_erc721_assets(
input: {
user_address: "0x0000000000ce6d8c1fba76f26d6cc5db71432710"
limit: 1
}
) {
entries {
token_id
address_hash
token_contract_address_hash
value
}
metadata {
total_count
after
before
}
}
}
{
"data": {
"user_erc721_assets": {
"entries": [
{
"address_hash": "0x0000000000ce6d8c1fba76f26d6cc5db71432710",
"token_contract_address_hash": "0x784cd3c52813098763c371df8fbe8ed27d2c1ebd",
"token_id": "641",
"value": "4"
}
],
"metadata": {
"after": "g3QAAAACZAAMYmxvY2tfbnVtYmVyYgAE5cVkABB2YWx1ZV9mZXRjaGVkX2F0dAAAAA1kAApfX3N0cnVjdF9fZAAPRWxpeGlyLkRhdGVUaW1lZAAIY2FsZW5kYXJkABNFbGl4aXIuQ2FsZW5kYXIuSVNPZAADZGF5YR9kAARob3VyYRBkAAttaWNyb3NlY29uZGgCYgAEVUxhBmQABm1pbnV0ZWEUZAAFbW9udGhhCGQABnNlY29uZGEcZAAKc3RkX29mZnNldGEAZAAJdGltZV96b25lbQAAAAdFdGMvVVRDZAAKdXRjX29mZnNldGEAZAAEeWVhcmIAAAfmZAAJem9uZV9hYmJybQAAAANVVEM=",
"before": null,
"total_count": 4
}
}
}
}
Response
Returns a
PaginateUserErc721Assets
Arguments
| Name | Description |
|---|---|
input -
UserErc721Erc1155AssetsInput!
|
Example
Query
query User_erc721_assets($input: UserErc721Erc1155AssetsInput!) {
user_erc721_assets(input: $input) {
entries {
...Erc721UserTokenFragment
}
metadata {
...PaginateMetadataFragment
}
}
}
Variables
{"input": UserErc721Erc1155AssetsInput}
Response
{
"data": {
"user_erc721_assets": {
"entries": [Erc721UserToken],
"metadata": PaginateMetadata
}
}
}
Mutations
verify_and_update_from_sourcify
Description
example:
mutation {
verify_and_update_from_sourcify(
input: { address: "0x7A4a65Db21864384d2D21a60367d7Fd5c86F8Fba" }
) {
id
account_id
# contract_source_code
# abi
compiler_version
deployment_tx_hash
name
}
}
{
"data": {
"verify_and_update_from_sourcify": {
"account_id": "43012",
"compiler_version": "v0.8.9+commit.e5eed63a",
"deployment_tx_hash": "0x505e25885828c847102af40848ba9cdaf7974d2046e7949ed46e2024494f33cd",
"id": 4,
"name": "Bridge"
}
}
}
Response
Returns a
SmartContract
Arguments
| Name | Description |
|---|---|
input -
VerifyAndUpdateFromSourcifyInput!
|
Example
Query
mutation Verify_and_update_from_sourcify($input: VerifyAndUpdateFromSourcifyInput!) {
verify_and_update_from_sourcify(input: $input) {
abi
account {
...AccountFragment
}
account_id
address_hash
ckb_balance
compiler_file_format
compiler_version
constructor_arguments
contract_source_code
deployment_tx_hash
id
implementation_abi
implementation_address_hash
implementation_fetched_at
implementation_name
name
other_info
sourcify_metadata
}
}
Variables
{"input": VerifyAndUpdateFromSourcifyInput}
Response
{
"data": {
"verify_and_update_from_sourcify": {
"abi": [Json],
"account": Account,
"account_id": 123,
"address_hash": HashAddress,
"ckb_balance": Decimal,
"compiler_file_format": "xyz789",
"compiler_version": "abc123",
"constructor_arguments": "abc123",
"contract_source_code": "xyz789",
"deployment_tx_hash": HashFull,
"id": 123,
"implementation_abi": [Json],
"implementation_address_hash": HashAddress,
"implementation_fetched_at": "2007-12-03T10:15:30Z",
"implementation_name": "abc123",
"name": "xyz789",
"other_info": "xyz789",
"sourcify_metadata": Json
}
}
}
Types
Account
Fields
| Field Name | Description |
|---|---|
bit_alias -
String
|
.bit alias. |
bridged_udt -
Udt
|
The bridge udt object of account if account is udt account. |
contract_code -
String
|
The contract's bytecode. |
eth_address -
HashFull
|
The polyjuice account's address |
id -
Int
|
ID of account. |
nonce -
Int
|
The account invokes contract's times. |
registry_address -
String
|
This account's register's address. |
script -
Json
|
Godwoken chain script. |
script_hash -
HashAddress
|
Godwoken chain script hash. |
smart_contract -
SmartContract
|
The mapping smart_contract of account. |
token_transfer_count -
Int
|
The account cached token transfer count. |
transaction_count -
Int
|
The account cached transction count. |
type -
AccountType
|
Account type. |
udt -
Udt
|
The mapping udt or bridge udt object of account if account is udt account or bridge udt account. |
Example
{
"bit_alias": "abc123",
"bridged_udt": Udt,
"contract_code": "abc123",
"eth_address": HashFull,
"id": 987,
"nonce": 987,
"registry_address": "xyz789",
"script": Json,
"script_hash": HashAddress,
"smart_contract": SmartContract,
"token_transfer_count": 123,
"transaction_count": 123,
"type": "ETH_ADDR_REG",
"udt": Udt
}
AccountBridgedUdtsByScriptHashInput
Fields
| Input Field | Description |
|---|---|
page -
Int
|
|
page_size -
Int
|
|
sort_type -
SortType
|
|
udt_script_hash -
HashFull!
|
Example
{
"page": 123,
"page_size": 987,
"sort_type": "ASC",
"udt_script_hash": HashFull
}
AccountCkbsInput
Fields
| Input Field | Description |
|---|---|
address_hashes -
[HashAddress]
|
|
script_hashes -
[HashFull]
|
Example
{
"address_hashes": [HashAddress],
"script_hashes": [HashFull]
}
AccountCurrentBridgedUdt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of balance. |
address_hash -
HashAddress
|
The balance's owner. |
block_number -
Int
|
The layer2 block's number that the transfer took place. |
id -
Int
|
ID of balance's table |
inserted_at -
DateTime
|
Current record inserted time. |
layer1_block_number -
Int
|
The layer1 block's number that the transfer took place. |
udt -
Udt
|
The udt info of balance. |
udt_script_hash -
HashFull
|
The layer2 udt account script hash. |
updated_at -
DateTime
|
Current record last updated time |
value -
Bigint
|
The value that's represents the balance. |
value_fetched_at -
DateTime
|
The time that fetch udt balance. |
Example
{
"account": Account,
"address_hash": HashAddress,
"block_number": 987,
"id": 123,
"inserted_at": "2007-12-03T10:15:30Z",
"layer1_block_number": 123,
"udt": Udt,
"udt_script_hash": HashFull,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
AccountCurrentBridgedUdtsInput
Fields
| Input Field | Description |
|---|---|
address_hashes -
[HashAddress]
|
argument: the list of account eth address example: ["0x15ca4f2165ff0e798d9c7434010eaacc4d768d85"] |
page -
Int
|
|
page_size -
Int
|
|
script_hashes -
[HashAddress]
|
argument: the list of account script hash example: ["0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e"] |
udt_script_hash -
HashFull
|
Example
{
"address_hashes": [HashAddress],
"page": 123,
"page_size": 987,
"script_hashes": [HashAddress],
"udt_script_hash": HashFull
}
AccountCurrentUdt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of balance. |
address_hash -
HashAddress
|
The balance's owner. |
block_number -
Int
|
The block's number that the transfer took place. |
id -
Int
|
ID of balance's table |
inserted_at -
DateTime
|
Current record inserted time. |
token_contract_address_hash -
HashAddress
|
The contract address hash foreign key. |
udt -
Udt
|
The udt info of balance. |
updated_at -
DateTime
|
Current record last updated time |
value -
Bigint
|
The value that's represents the balance. |
value_fetched_at -
DateTime
|
The time that fetch udt balance. |
Example
{
"account": Account,
"address_hash": HashAddress,
"block_number": 123,
"id": 123,
"inserted_at": "2007-12-03T10:15:30Z",
"token_contract_address_hash": HashAddress,
"udt": Udt,
"updated_at": "2007-12-03T10:15:30Z",
"value": Bigint,
"value_fetched_at": "2007-12-03T10:15:30Z"
}
AccountCurrentUdtsInput
Fields
| Input Field | Description |
|---|---|
address_hashes -
[HashAddress]
|
argument: the list of account eth address example: ["0x15ca4f2165ff0e798d9c7434010eaacc4d768d85"] |
page -
Int
|
|
page_size -
Int
|
|
script_hashes -
[HashFull]
|
argument: the list of account script hash example: ["0x08c9937e412e135928fd6dec7255965ddd7df4d5a163564b60895100bb3b2f9e"] |
token_contract_address_hash -
HashAddress
|
argument: the address of smart contract which supply udts example: "0xbf1f27daea43849b67f839fd101569daaa321e2c" |
Example
{
"address_hashes": [HashAddress],
"page": 987,
"page_size": 987,
"script_hashes": [HashFull],
"token_contract_address_hash": HashAddress
}
AccountInput
Fields
| Input Field | Description |
|---|---|
address -
HashAddress
|
|
script_hash -
HashFull
|
Example
{
"address": HashAddress,
"script_hash": HashFull
}
AccountOrAddress
AccountType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Example
"ETH_ADDR_REG"
AccountUdt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of token. |
address_hash -
HashAddress
|
The balance's owner address. |
token_contract_address_hash -
HashAddress
|
The contract address hash foreign key. |
udt -
Udt
|
The udt info of token. |
udt_script_hash -
HashFull
|
The layer2 udt account script hash. |
uniq_id -
Int
|
The token's layer2 native token id |
value -
Bigint
|
The value that's represents the balance. |
Example
{
"account": Account,
"address_hash": HashAddress,
"token_contract_address_hash": HashAddress,
"udt": Udt,
"udt_script_hash": HashFull,
"uniq_id": 123,
"value": Bigint
}
AccountUdtHoldersInput
Example
{
"after": "xyz789",
"before": "abc123",
"limit": 987,
"udt_id": 987
}
AccountUdtsByContractAddressInput
Fields
| Input Field | Description |
|---|---|
page -
Int
|
|
page_size -
Int
|
|
sort_type -
SortType
|
|
token_contract_address_hash -
HashAddress!
|
Example
{
"page": 123,
"page_size": 987,
"sort_type": "ASC",
"token_contract_address_hash": HashAddress
}
AccountUdtsInput
Fields
| Input Field | Description |
|---|---|
address_hashes -
[HashAddress]
|
|
script_hashes -
[HashFull]
|
|
token_contract_address_hash -
HashAddress
|
|
udt_script_hash -
HashFull
|
Example
{
"address_hashes": [HashAddress],
"script_hashes": [HashFull],
"token_contract_address_hash": HashAddress,
"udt_script_hash": HashFull
}
Address
AddressBitAlias
Fields
| Field Name | Description |
|---|---|
address -
HashAddress
|
|
bit_alias -
String
|
Example
{
"address": HashAddress,
"bit_alias": "abc123"
}
AddressInput
Fields
| Input Field | Description |
|---|---|
address -
HashAddress
|
|
Example
{"address": HashAddress}
ApprovalType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"APPROVAL"
BatchFetchAddressesByAliasInput
Fields
| Input Field | Description |
|---|---|
bit_aliases -
[String]!
|
Example
{"bit_aliases": ["abc123"]}
BatchFetchAliasesByAddressesInput
Fields
| Input Field | Description |
|---|---|
addresses -
[HashAddress]!
|
Example
{"addresses": [HashAddress]}
Bigint
Description
The bigint scalar type represents signed big integer values parsed by the elixir Decimal library(which support big integer scenario). The BigInt appears in a JSON response as a string to preserve Big Interger.
Formally: sign ::= '+' | '-' digit ::= '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' digits ::= digit [digit]... numeric-string ::= [sign] digits| [sign] digit
Examples:
Some numeric strings are:
"0" -- zero
"12" -- a whole number
"-76" -- a signed whole number
Example
Bigint
Block
Fields
| Field Name | Description |
|---|---|
account -
Account
|
|
gas_limit -
Decimal
|
Gas limit of this block. |
gas_used -
Decimal
|
Actual used gas. |
hash -
HashFull
|
The current block hash. |
layer1_block_number -
Int
|
Finalized at which layer1 block number. |
layer1_tx_hash -
HashFull
|
Finalized at which layer1 transaction hash. |
logs_bloom -
String
|
the Bloom filter for the logs of the block. |
number -
Int
|
The block number, start with 0. |
parent_hash -
HashFull
|
The parent block hash. |
producer_address -
HashAddress
|
The block produced by which account. |
registry_id -
Int
|
The block producer registers by which account id. |
size -
Int
|
The size of the block in bytes. |
status -
BlockStatus
|
Committed means block submit to layer1(CKB) and can be challenged;Finalized means block can't be challenged. |
timestamp -
DateTime
|
When the block was collated. |
transaction_count -
Int
|
The block contains transaction count. |
Example
{
"account": Account,
"gas_limit": Decimal,
"gas_used": Decimal,
"hash": HashFull,
"layer1_block_number": 987,
"layer1_tx_hash": HashFull,
"logs_bloom": "abc123",
"number": 987,
"parent_hash": HashFull,
"producer_address": HashAddress,
"registry_id": 987,
"size": 987,
"status": "COMMITTED",
"timestamp": "2007-12-03T10:15:30Z",
"transaction_count": 123
}
BlockInput
BlockStatus
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"COMMITTED"
BlocksInput
Fields
| Input Field | Description |
|---|---|
page -
Int
|
|
page_size -
Int
|
|
sort_type -
SortType
|
|
Example
{"page": 987, "page_size": 987, "sort_type": "ASC"}
Boolean
Description
The Boolean scalar type represents true or false.
Example
true
ChainData
Description
chain data is an unpadded hexadecimal number with 0 or more digits. Each pair of digits maps directly to a byte in the underlying binary representation. When interpreted as a number, it should be treated as big-endian.
Example
ChainData
DateTime
Description
The DateTime scalar type represents a date and time in the UTC timezone. The DateTime appears in a JSON response as an ISO8601 formatted string, including UTC timezone ("Z"). The parsed date and time string will be converted to UTC if there is an offset.
Example
"2007-12-03T10:15:30Z"
Decimal
Description
The Decimal scalar type represents signed double-precision fractional values parsed by the Decimal library. The Decimal appears in a JSON response as a string to preserve precision.
Formally: sign ::= '+' | '-' digit ::= '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' indicator ::= 'e' | 'E' digits ::= digit [digit]... decimal-part ::= digits '.' [digits] | ['.'] digits exponent-part ::= indicator [sign] digits infinity ::= 'Infinity' | 'Inf' nan ::= 'NaN' [digits] | 'sNaN' [digits] numeric-value ::= decimal-part [exponent-part] | infinity numeric-string ::= [sign] numeric-value | [sign] nan
Examples:
Some numeric strings are:
"0" -- zero
"12" -- a whole number
"-76" -- a signed whole number
"12.70" -- some decimal places
"+0.003" -- a plus sign is allowed, too
"017." -- the same as 17
".5" -- the same as 0.5
"4E+9" -- exponential notation
"0.73e-7" -- exponential notation, negative power
"Inf" -- the same as Infinity
"-infinity" -- the same as -Inf
"NaN" -- not-a-Number
"NaN8275" -- diagnostic NaN
Example
Decimal
DepositWithdrawalHistory
Fields
| Field Name | Description |
|---|---|
block_hash -
HashFull
|
|
block_number -
Int
|
|
capacity -
Decimal
|
|
ckb_lock_hash -
HashFull
|
|
eth_address -
HashAddress
|
|
layer1_block_number -
Int
|
|
layer1_output_index -
Int
|
|
layer1_tx_hash -
HashFull
|
|
owner_lock_hash -
HashFull
|
|
script_hash -
HashFull
|
|
state -
WithdrawalHistoryState
|
|
sudt_script_hash -
HashFull
|
|
timestamp -
DateTime
|
|
type -
String
|
|
udt -
Udt
|
|
value -
Decimal
|
Example
{
"block_hash": HashFull,
"block_number": 123,
"capacity": Decimal,
"ckb_lock_hash": HashFull,
"eth_address": HashAddress,
"layer1_block_number": 987,
"layer1_output_index": 987,
"layer1_tx_hash": HashFull,
"owner_lock_hash": HashFull,
"script_hash": HashFull,
"state": "AVAILABLE",
"sudt_script_hash": HashFull,
"timestamp": "2007-12-03T10:15:30Z",
"type": "abc123",
"udt": Udt,
"value": Decimal
}
Erc1155HoldersInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress!
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
token_id -
Decimal
|
Example
{
"after": "abc123",
"before": "abc123",
"contract_address": HashAddress,
"limit": 987,
"token_id": Decimal
}
Erc1155Inventory
Fields
| Field Name | Description |
|---|---|
contract_address_hash -
HashAddress
|
The erc1155 contract address. |
counts -
Decimal
|
Count of erc1155 with the token id. |
token_id -
Decimal
|
The erc1155 token id. |
token_instance -
TokenInstance
|
The mapping token instance of erc1155. |
Example
{
"contract_address_hash": HashAddress,
"counts": Decimal,
"token_id": Decimal,
"token_instance": TokenInstance
}
Erc1155Udt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of udt. |
contract_address_hash -
HashAddress
|
For type is native, it have contract address hash. |
description -
String
|
UDT's description. |
eth_type -
EthType
|
EVM token type. |
holders_count -
Int
|
Count holders of udt. |
icon -
String
|
UDT icon url. |
id -
Int
|
UDT ID is same with account id. |
minted_count -
Decimal
|
Count minted of erc1155 udt. |
name -
String
|
UAN. |
official_site -
String
|
UDT's official site. |
rank -
Int
|
rank number of current returns |
symbol -
String
|
UAN. |
token_type_count -
Int
|
Count token type of udt. |
Example
{
"account": Account,
"contract_address_hash": HashAddress,
"description": "abc123",
"eth_type": "ERC1155",
"holders_count": 987,
"icon": "xyz789",
"id": 987,
"minted_count": Decimal,
"name": "abc123",
"official_site": "abc123",
"rank": 987,
"symbol": "abc123",
"token_type_count": 123
}
Erc1155UdtsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress
|
|
fuzzy_name -
String
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[Erc1155UdtsSorterInput]
|
Example
{
"after": "xyz789",
"before": "abc123",
"contract_address": HashAddress,
"fuzzy_name": "xyz789",
"limit": 987,
"sorter": [Erc1155UdtsSorterInput]
}
Erc1155UdtsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Example
"EX_HOLDERS_COUNT"
Erc1155UdtsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType!
|
|
sort_value -
Erc1155UdtsSorter!
|
Example
{"sort_type": "ASC", "sort_value": "EX_HOLDERS_COUNT"}
Erc1155UserToken
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping owner account. |
address_hash -
HashAddress
|
Owner of token. |
counts -
Decimal
|
Count value of token id |
token_contract_address_hash -
HashAddress
|
Contract of token. |
token_id -
Decimal
|
Token id of erc1155/erc721. |
token_instance -
TokenInstance
|
The token instance info of token id |
token_type -
EthType
|
Token type of erc1155/erc721. |
udt -
Erc7211155CommonUdt
|
|
value -
Decimal
|
Example
{
"account": Account,
"address_hash": HashAddress,
"counts": Decimal,
"token_contract_address_hash": HashAddress,
"token_id": Decimal,
"token_instance": TokenInstance,
"token_type": "ERC1155",
"udt": Erc7211155CommonUdt,
"value": Decimal
}
Erc1155UserTokenInput
Fields
| Input Field | Description |
|---|---|
contract_address -
HashAddress!
|
|
token_id -
Decimal!
|
|
user_address -
HashAddress!
|
Example
{
"contract_address": HashAddress,
"token_id": Decimal,
"user_address": HashAddress
}
Erc20TokenTransfersInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
age_range_end -
DateTime
|
|
age_range_start -
DateTime
|
|
before -
String
|
Fetch the records before this cursor. |
combine_from_to -
Boolean
|
if combine_from_to is true, then from_address and to_address are combined into query condition like |
end_block_number -
Int
|
argument: the end of block number(inclusive) for search query |
from_address -
HashAddress
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[TokenTransfersSorterInput]
|
|
start_block_number -
Int
|
argument: the start of block number(inclusive) for search query |
to_address -
HashAddress
|
|
token_contract_address_hash -
HashAddress
|
|
transaction_hash -
HashFull
|
Example
{
"after": "abc123",
"age_range_end": "2007-12-03T10:15:30Z",
"age_range_start": "2007-12-03T10:15:30Z",
"before": "xyz789",
"combine_from_to": true,
"end_block_number": 123,
"from_address": HashAddress,
"limit": 987,
"sorter": [TokenTransfersSorterInput],
"start_block_number": 123,
"to_address": HashAddress,
"token_contract_address_hash": HashAddress,
"transaction_hash": HashFull
}
Erc7211155CommonUdt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of udt. |
contract_address_hash -
HashAddress
|
For type is native, it have contract address hash. |
description -
String
|
UDT's description. |
eth_type -
EthType
|
EVM token type. |
icon -
String
|
UDT icon url. |
id -
Int
|
UDT ID is same with account id. |
name -
String
|
UAN. |
official_site -
String
|
UDT's official site. |
rank -
Int
|
rank number of current returns |
symbol -
String
|
UAN. |
Example
{
"account": Account,
"contract_address_hash": HashAddress,
"description": "xyz789",
"eth_type": "ERC1155",
"icon": "xyz789",
"id": 123,
"name": "abc123",
"official_site": "xyz789",
"rank": 123,
"symbol": "xyz789"
}
Erc721Erc1155HolderItem
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping owner account. |
address_hash -
HashAddress
|
Owner of token. |
quantity -
Decimal
|
The quantity of holder item. |
rank -
Int
|
The rank number of holder list. |
token_contract_address_hash -
HashAddress
|
Contract of token. |
Example
{
"account": Account,
"address_hash": HashAddress,
"quantity": Decimal,
"rank": 123,
"token_contract_address_hash": HashAddress
}
Erc721Erc1155InventoryInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress!
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
token_id -
Decimal
|
Example
{
"after": "abc123",
"before": "abc123",
"contract_address": HashAddress,
"limit": 123,
"token_id": Decimal
}
Erc721Erc1155TokenTransfersInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
age_range_end -
DateTime
|
|
age_range_start -
DateTime
|
|
before -
String
|
Fetch the records before this cursor. |
combine_from_to -
Boolean
|
if combine_from_to is true, then from_address and to_address are combined into query condition like |
end_block_number -
Int
|
argument: the end of block number(inclusive) for search query |
from_address -
HashAddress
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[TokenTransfersSorterInput]
|
|
start_block_number -
Int
|
argument: the start of block number(inclusive) for search query |
to_address -
HashAddress
|
|
token_contract_address_hash -
HashAddress
|
|
token_id -
Decimal
|
|
transaction_hash -
HashFull
|
Example
{
"after": "xyz789",
"age_range_end": "2007-12-03T10:15:30Z",
"age_range_start": "2007-12-03T10:15:30Z",
"before": "xyz789",
"combine_from_to": true,
"end_block_number": 987,
"from_address": HashAddress,
"limit": 987,
"sorter": [TokenTransfersSorterInput],
"start_block_number": 987,
"to_address": HashAddress,
"token_contract_address_hash": HashAddress,
"token_id": Decimal,
"transaction_hash": HashFull
}
Erc721HoldersInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress!
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
Example
{
"after": "abc123",
"before": "abc123",
"contract_address": HashAddress,
"limit": 123
}
Erc721Udt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of udt. |
contract_address_hash -
HashAddress
|
For type is native, it have contract address hash. |
description -
String
|
UDT's description. |
eth_type -
EthType
|
EVM token type. |
holders_count -
Int
|
Count holders of udt. |
icon -
String
|
UDT icon url. |
id -
Int
|
UDT ID is same with account id. |
minted_count -
Decimal
|
Count minted of erc721 udt. |
name -
String
|
UAN. |
official_site -
String
|
UDT's official site. |
rank -
Int
|
rank number of current returns |
symbol -
String
|
UAN. |
Example
{
"account": Account,
"contract_address_hash": HashAddress,
"description": "xyz789",
"eth_type": "ERC1155",
"holders_count": 987,
"icon": "xyz789",
"id": 987,
"minted_count": Decimal,
"name": "xyz789",
"official_site": "xyz789",
"rank": 987,
"symbol": "abc123"
}
Erc721UdtsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress
|
|
fuzzy_name -
String
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[Erc721UdtsSorterInput]
|
Example
{
"after": "abc123",
"before": "abc123",
"contract_address": HashAddress,
"fuzzy_name": "abc123",
"limit": 123,
"sorter": [Erc721UdtsSorterInput]
}
Erc721UdtsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Example
"EX_HOLDERS_COUNT"
Erc721UdtsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType!
|
|
sort_value -
Erc721UdtsSorter!
|
Example
{"sort_type": "ASC", "sort_value": "EX_HOLDERS_COUNT"}
Erc721UserToken
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping owner account. |
address_hash -
HashAddress
|
Owner of token. |
counts -
Decimal
|
Count value of token id |
token_contract_address_hash -
HashAddress
|
Contract of token. |
token_id -
Decimal
|
Token id of erc1155/erc721. |
token_instance -
TokenInstance
|
The token instance info of token id |
token_type -
EthType
|
Token type of erc1155/erc721. |
udt -
Erc7211155CommonUdt
|
|
value -
Decimal
|
Example
{
"account": Account,
"address_hash": HashAddress,
"counts": Decimal,
"token_contract_address_hash": HashAddress,
"token_id": Decimal,
"token_instance": TokenInstance,
"token_type": "ERC1155",
"udt": Erc7211155CommonUdt,
"value": Decimal
}
EthType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"ERC1155"
HashAddress
Description
The address (40 (hex) characters / 160 bits / 20 bytes) is derived from the public key (128 (hex) characters / 512 bits / 64 bytes) which is derived from the private key (64 (hex) characters / 256 bits / 32 bytes).
The address is actually the last 40 characters of the keccak-256 hash of the public key with 0x appended.
Example
HashAddress
HashFull
Description
A 32-byte KECCAK-256 hash.
Example
HashFull
HistoriesInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
end_block_number -
Int
|
argument: the end of block number(inclusive) for search query |
eth_address -
HashAddress
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[HistoriesSorterInput]
|
|
start_block_number -
Int
|
argument: the start of block number(inclusive) for search query |
udt_id -
Int
|
Example
{
"after": "xyz789",
"before": "xyz789",
"end_block_number": 987,
"eth_address": HashAddress,
"limit": 123,
"sorter": [HistoriesSorterInput],
"start_block_number": 987,
"udt_id": 987
}
HistoriesSorter
Values
| Enum Value | Description |
|---|---|
|
|
Example
"TIMESTAMP"
HistoriesSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType
|
|
sort_value -
HistoriesSorter
|
Example
{"sort_type": "ASC", "sort_value": "TIMESTAMP"}
Int
Description
The Int scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^53 - 1) and 2^53 - 1 since it is represented in JSON as double-precision floating point numbers specified by
IEEE 754.
Example
123
Json
Description
The Json scalar type represents arbitrary json string data, represented as UTF-8 character sequences. The Json type is most often used to represent a free-form human-readable json string.
Example
Json
Log
Fields
| Field Name | Description |
|---|---|
address_hash -
HashAddress
|
Contract address. |
block_hash -
HashFull
|
Layer2 block hash. |
block_number -
Int
|
Layer2 block number. |
data -
String
|
Log data. |
first_topic -
String
|
Log first topic. |
fourth_topic -
String
|
Log fourth topic. |
index -
Int
|
Log index. |
second_topic -
String
|
Log second topic. |
smart_contract -
SmartContract
|
|
third_topic -
String
|
Log third topic. |
transaction -
Transaction
|
|
transaction_hash -
HashFull
|
Layer2 transaction. |
udt -
Udt
|
Example
{
"address_hash": HashAddress,
"block_hash": HashFull,
"block_number": 123,
"data": "abc123",
"first_topic": "abc123",
"fourth_topic": "xyz789",
"index": 123,
"second_topic": "xyz789",
"smart_contract": SmartContract,
"third_topic": "xyz789",
"transaction": Transaction,
"transaction_hash": HashFull,
"udt": Udt
}
LogInput
Fields
| Input Field | Description |
|---|---|
address_hash -
HashAddress
|
|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
end_block_number -
Int
|
argument: the end of block number(inclusive) for search query |
first_topic -
String
|
|
fourth_topic -
String
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
second_topic -
String
|
|
sorter -
[LogsSorterInput]
|
|
start_block_number -
Int
|
argument: the start of block number(inclusive) for search query |
third_topic -
String
|
|
transaction_hash -
HashFull
|
Example
{
"address_hash": HashAddress,
"after": "xyz789",
"before": "abc123",
"end_block_number": 987,
"first_topic": "xyz789",
"fourth_topic": "abc123",
"limit": 987,
"second_topic": "xyz789",
"sorter": [LogsSorterInput],
"start_block_number": 123,
"third_topic": "xyz789",
"transaction_hash": HashFull
}
LogsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"BLOCK_NUMBER"
LogsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType
|
|
sort_value -
LogsSorter
|
Example
{"sort_type": "ASC", "sort_value": "BLOCK_NUMBER"}
PaginateAccountUdtHolders
Fields
| Field Name | Description |
|---|---|
entries -
[UdtHolderItem]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [UdtHolderItem],
"metadata": PaginateMetadata
}
PaginateDepositWithdrawalHistories
Fields
| Field Name | Description |
|---|---|
entries -
[DepositWithdrawalHistory]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [DepositWithdrawalHistory],
"metadata": PaginateMetadata
}
PaginateErc1155Inventory
Fields
| Field Name | Description |
|---|---|
entries -
[Erc1155Inventory]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc1155Inventory],
"metadata": PaginateMetadata
}
PaginateErc1155Udts
Fields
| Field Name | Description |
|---|---|
entries -
[Erc1155Udt]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc1155Udt],
"metadata": PaginateMetadata
}
PaginateErc1155UserInventory
Fields
| Field Name | Description |
|---|---|
entries -
[Erc1155UserToken]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc1155UserToken],
"metadata": PaginateMetadata
}
PaginateErc721Erc1155Holders
Fields
| Field Name | Description |
|---|---|
entries -
[Erc721Erc1155HolderItem]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc721Erc1155HolderItem],
"metadata": PaginateMetadata
}
PaginateErc721Inventory
Fields
| Field Name | Description |
|---|---|
entries -
[Erc721UserToken]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc721UserToken],
"metadata": PaginateMetadata
}
PaginateErc721Udts
Fields
| Field Name | Description |
|---|---|
entries -
[Erc721Udt]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc721Udt],
"metadata": PaginateMetadata
}
PaginateLogs
Fields
| Field Name | Description |
|---|---|
entries -
[Log]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Log],
"metadata": PaginateMetadata
}
PaginateMetadata
Fields
| Field Name | Description |
|---|---|
after -
String
|
An opaque cursor representing the last row of the current page. |
before -
String
|
An opaque cursor representing the first row of the current page. |
limit -
Int
|
The maximum number of entries that can be contained in this page. |
total_count -
Int
|
The total number of entries matching the query. |
total_count_cap_exceeded -
Boolean
|
A boolean indicating whether the :total_count_limit was exceeded. |
Example
{
"after": "xyz789",
"before": "xyz789",
"limit": 123,
"total_count": 123,
"total_count_cap_exceeded": false
}
PaginateSearchUdts
Fields
| Field Name | Description |
|---|---|
entries -
[SearchUdtResult]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [SearchUdtResult],
"metadata": PaginateMetadata
}
PaginateSmartContracts
Fields
| Field Name | Description |
|---|---|
entries -
[SmartContract]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [SmartContract],
"metadata": PaginateMetadata
}
PaginateTokenApprovals
Fields
| Field Name | Description |
|---|---|
entries -
[TokenApproval]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [TokenApproval],
"metadata": PaginateMetadata
}
PaginateTokenTransfers
Fields
| Field Name | Description |
|---|---|
entries -
[TokenTransfer]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [TokenTransfer],
"metadata": PaginateMetadata
}
PaginateTrasactions
Fields
| Field Name | Description |
|---|---|
entries -
[Transaction]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Transaction],
"metadata": PaginateMetadata
}
PaginateUdts
Fields
| Field Name | Description |
|---|---|
entries -
[Udt]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Udt],
"metadata": PaginateMetadata
}
PaginateUserErc1155Assets
Fields
| Field Name | Description |
|---|---|
entries -
[Erc1155UserToken]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc1155UserToken],
"metadata": PaginateMetadata
}
PaginateUserErc721Assets
Fields
| Field Name | Description |
|---|---|
entries -
[Erc721UserToken]
|
|
metadata -
PaginateMetadata
|
Example
{
"entries": [Erc721UserToken],
"metadata": PaginateMetadata
}
Polyjuice
Fields
| Field Name | Description |
|---|---|
call_contract -
HashAddress
|
Gas less tx struct |
call_data -
ChainData
|
Gas less tx struct |
call_gas_limit -
Bigint
|
Gas less tx struct |
created_contract_address_hash -
HashAddress
|
This transaction deployed contract address. |
eth_hash -
HashFull
|
The polyjuce eth transaction hash. |
gas_limit -
Bigint
|
Gas limited value. |
gas_price -
Bigint
|
How much the sender is willing to pay for gas. |
gas_used -
Bigint
|
The gas used for just transaction. nil when transaction is pending or has only been collated into one of the uncles in one of the forks. |
id -
Int
|
ID of polyjuice table. |
input -
ChainData
|
Data sent along with the transaction. |
input_size -
Int
|
Data size. |
is_create -
Boolean
|
This transaction deployed contract. |
max_fee_per_gas -
Bigint
|
Gas less tx struct |
max_priority_fee_per_gas -
Bigint
|
Gas less tx struct |
native_transfer_account -
Account
|
|
native_transfer_address_hash -
HashAddress
|
If this transaction is native transfer, to_address is a contract, this column is actual receiver. |
paymaster_and_data -
ChainData
|
Gas less tx struct |
status -
PolyjuiceStatus
|
Status of deployed. |
transaction -
Transaction
|
|
transaction_index -
Int
|
Index of this transaction in block. nil when transaction is pending or has only been collated into one of the uncles in one of the forks. |
tx_hash -
HashFull
|
The godwoken transaction hash. |
value -
Bigint
|
pCKB transferred from from_address to to_address. |
verification_gas_limit -
Bigint
|
Gas less tx struct |
Example
{
"call_contract": HashAddress,
"call_data": ChainData,
"call_gas_limit": Bigint,
"created_contract_address_hash": HashAddress,
"eth_hash": HashFull,
"gas_limit": Bigint,
"gas_price": Bigint,
"gas_used": Bigint,
"id": 123,
"input": ChainData,
"input_size": 987,
"is_create": false,
"max_fee_per_gas": Bigint,
"max_priority_fee_per_gas": Bigint,
"native_transfer_account": Account,
"native_transfer_address_hash": HashAddress,
"paymaster_and_data": ChainData,
"status": "FAILED",
"transaction": Transaction,
"transaction_index": 987,
"tx_hash": HashFull,
"value": Bigint,
"verification_gas_limit": Bigint
}
PolyjuiceCreator
Fields
| Field Name | Description |
|---|---|
code_hash -
String
|
Layer2 account code_hash. |
created_account -
Account
|
The mapping account which created. |
fee_amount -
Bigint
|
The tranasaction used fee. |
fee_udt_id -
Int
|
The transaction registry by which account. |
hash_type -
String
|
Layer2 account hash_type. |
id -
Int
|
ID of polyjuice_creator table. |
script_args -
String
|
Layer2 account script_args. |
tx_hash -
HashFull
|
The transaction foreign key. |
Example
{
"code_hash": "abc123",
"created_account": Account,
"fee_amount": Bigint,
"fee_udt_id": 123,
"hash_type": "xyz789",
"id": 123,
"script_args": "abc123",
"tx_hash": HashFull
}
PolyjuiceStatus
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"FAILED"
ReverseSearchBitAliasInput
Fields
| Input Field | Description |
|---|---|
address -
HashAddress!
|
Example
{"address": HashAddress}
SearchBitAliasInput
Fields
| Input Field | Description |
|---|---|
bit_alias -
String!
|
Example
{"bit_alias": "abc123"}
SearchKeywordInput
Fields
| Input Field | Description |
|---|---|
keyword -
String!
|
Example
{"keyword": "xyz789"}
SearchResult
Fields
| Field Name | Description |
|---|---|
id -
String
|
|
type -
SearchType
|
Example
{"id": "abc123", "type": "ACCOUNT"}
SearchType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Example
"ACCOUNT"
SearchUdtInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress
|
|
fuzzy_name -
String
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
Example
{
"after": "abc123",
"before": "abc123",
"contract_address": HashAddress,
"fuzzy_name": "xyz789",
"limit": 987
}
SearchUdtResult
Fields
| Field Name | Description |
|---|---|
contract_address_hash -
HashAddress
|
The udt contract address. |
eth_type -
EthType
|
EVM token type. |
icon -
String
|
UDT icon url. |
id -
Int
|
UDT primary key |
name -
String
|
For bridge token, read from UAN;For native token, read from contract. |
symbol -
String
|
For bridge token, read from UAN;For native token, read from contract. |
type -
UdtType
|
Bridge means from layer1;Native means layer2 contract. |
Example
{
"contract_address_hash": HashAddress,
"eth_type": "ERC1155",
"icon": "xyz789",
"id": 123,
"name": "xyz789",
"symbol": "abc123",
"type": "BRIDGE"
}
SmartContract
Fields
| Field Name | Description |
|---|---|
abi -
[Json]
|
Contract abi. |
account -
Account
|
The mapping account of smart contract. |
account_id -
Int
|
The account foreign key. |
address_hash -
HashAddress
|
The account's eth address |
ckb_balance -
Decimal
|
The ckb-balance of this contract. |
compiler_file_format -
String
|
Solidity or other. |
compiler_version -
String
|
Contract compiler version. |
constructor_arguments -
String
|
Contract constructor arguments. |
contract_source_code -
String
|
Contract code. |
deployment_tx_hash -
HashFull
|
Contract deployment at which transaction. |
id -
Int
|
ID of smart_contract table |
implementation_abi -
[Json]
|
The implementation contract's abi of proxy contract. |
implementation_address_hash -
HashAddress
|
address hash of the proxy's implementation if any |
implementation_fetched_at -
DateTime
|
timestamp of the last fetching contract's implementation info |
implementation_name -
String
|
name of the proxy implementation |
name -
String
|
Contract name. |
other_info -
String
|
Some info. |
sourcify_metadata -
Json
|
The sourcify metadata of this contract, if exists |
Example
{
"abi": [Json],
"account": Account,
"account_id": 987,
"address_hash": HashAddress,
"ckb_balance": Decimal,
"compiler_file_format": "xyz789",
"compiler_version": "xyz789",
"constructor_arguments": "abc123",
"contract_source_code": "xyz789",
"deployment_tx_hash": HashFull,
"id": 123,
"implementation_abi": [Json],
"implementation_address_hash": HashAddress,
"implementation_fetched_at": "2007-12-03T10:15:30Z",
"implementation_name": "abc123",
"name": "xyz789",
"other_info": "abc123",
"sourcify_metadata": Json
}
SmartContractInput
Fields
| Input Field | Description |
|---|---|
contract_address -
HashAddress
|
|
script_hash -
HashFull
|
Example
{
"contract_address": HashAddress,
"script_hash": HashFull
}
SmartContractsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_addresses -
[HashAddress]
|
smart contract mapping account eth address list |
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[SmartContractsSorterInput]
|
Example
{
"after": "xyz789",
"before": "abc123",
"contract_addresses": [HashAddress],
"limit": 123,
"sorter": [SmartContractsSorterInput]
}
SmartContractsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
Example
"CKB_BALANCE"
SmartContractsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType!
|
|
sort_value -
SmartContractsSorter!
|
Example
{"sort_type": "ASC", "sort_value": "CKB_BALANCE"}
SortType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"ASC"
SourcifyCheckByAddresses
Fields
| Field Name | Description |
|---|---|
address -
HashAddress
|
The contract address. |
chain_ids -
[String]
|
The contract chain ids of sourcify |
status -
String
|
The contract status of sourcify. |
Example
{
"address": HashAddress,
"chain_ids": ["abc123"],
"status": "abc123"
}
SourcifyCheckByAddressesInput
Fields
| Input Field | Description |
|---|---|
addresses -
[HashAddress]!
|
Example
{"addresses": [HashAddress]}
Status
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"ON_CHAINED"
String
Description
The String scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.
Example
"xyz789"
TokenApproval
Fields
| Field Name | Description |
|---|---|
approved -
Boolean
|
Approve operation or Cancel approval. |
block -
Block
|
The mapping block object of token_approval |
block_hash -
HashFull
|
Layer2 block. |
block_number -
Int
|
Layer2 block number |
data -
Decimal
|
ERC721 token id. |
spender_address_hash -
String
|
User approve token to which address. |
token_contract_address_hash -
HashAddress
|
Which token contract. |
token_owner_address_hash -
HashAddress
|
Token owner. |
transaction_hash -
HashFull
|
Layer2 transaction. |
type -
ApprovalType
|
Approve or approve_all. |
udt -
Udt
|
The mapping udt object of token_approval |
Example
{
"approved": false,
"block": Block,
"block_hash": HashFull,
"block_number": 123,
"data": Decimal,
"spender_address_hash": "abc123",
"token_contract_address_hash": HashAddress,
"token_owner_address_hash": HashAddress,
"transaction_hash": HashFull,
"type": "APPROVAL",
"udt": Udt
}
TokenApprovalInput
Fields
| Input Field | Description |
|---|---|
address -
HashAddress
|
|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[TokenApprovalsSorterInput]
|
|
token_type -
TokenType
|
Example
{
"address": HashAddress,
"after": "abc123",
"before": "xyz789",
"limit": 123,
"sorter": [TokenApprovalsSorterInput],
"token_type": "ERC1155"
}
TokenApprovalsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"BLOCK_NUMBER"
TokenApprovalsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType
|
|
sort_value -
TokenApprovalsSorter
|
Example
{"sort_type": "ASC", "sort_value": "BLOCK_NUMBER"}
TokenExchangeRate
Description
Trigger token exchange rate update by symbol name like ckb, btc or eth etc. And returning the previous exchange rate value. The first time trigger will return 0.
Example
{
"exchange_rate": Decimal,
"symbol": "abc123",
"timestamp": 123
}
TokenInstance
Fields
| Field Name | Description |
|---|---|
error -
String
|
Error of fetching token instance. |
metadata -
Json
|
Token instance metadata. |
token_contract_address_hash -
HashAddress
|
Address hash foreign key. |
token_id -
Decimal
|
ID of the token. |
Example
{
"error": "xyz789",
"metadata": Json,
"token_contract_address_hash": HashAddress,
"token_id": Decimal
}
TokenTransfer
Fields
| Field Name | Description |
|---|---|
amount -
Decimal
|
The erc721/erc1155's token amount. |
amounts -
[Decimal]
|
Token amounts of ERC1155. |
block -
Block
|
The mapping block info. |
block_hash -
HashFull
|
Layer2 block. |
block_number -
Int
|
Layer2 block number. |
from_account -
Account
|
The mapping sender's account info. |
from_address -
HashAddress
|
Transfer sender. |
log_index -
Int
|
Transaction's log index. |
polyjuice -
Polyjuice
|
The mapping polyjuice info. |
receiver_address -
Address
|
The mapping receiver's address info. |
to_account -
Account
|
The mapping receiver's account info. |
to_address -
HashAddress
|
Transfer receiver. |
token_contract_address_hash -
HashAddress
|
Which token contract. |
token_id -
Decimal
|
The erc721/erc1155's token id. |
token_ids -
[Decimal]
|
Token ids of ERC1155. |
transaction -
Transaction
|
The mapping transaction info. |
transaction_hash -
HashFull
|
Layer2 transaction. |
udt -
Udt
|
The mapping udt info. |
Example
{
"amount": Decimal,
"amounts": [Decimal],
"block": Block,
"block_hash": HashFull,
"block_number": 987,
"from_account": Account,
"from_address": HashAddress,
"log_index": 123,
"polyjuice": Polyjuice,
"receiver_address": Address,
"to_account": Account,
"to_address": HashAddress,
"token_contract_address_hash": HashAddress,
"token_id": Decimal,
"token_ids": [Decimal],
"transaction": Transaction,
"transaction_hash": HashFull,
"udt": Udt
}
TokenTransfersSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"BLOCK_NUMBER"
TokenTransfersSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType
|
|
sort_value -
TokenTransfersSorter
|
Example
{"sort_type": "ASC", "sort_value": "BLOCK_NUMBER"}
TokenType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"ERC1155"
Transaction
Fields
| Field Name | Description |
|---|---|
args -
ChainData
|
|
block -
Block
|
|
block_hash -
HashFull
|
The block hash which in. |
block_number -
Int
|
In Which block. |
eth_hash -
HashFull
|
Polyjuice transaction hash. |
from_account -
Account
|
|
from_account_id -
Int
|
The foreign key of account and which account invoke contract. |
hash -
HashFull
|
Godwoken transaction hash. |
index -
Int
|
Order of transaction in block. |
method_id -
ChainData
|
|
method_name -
String
|
|
nonce -
Int
|
From account's nonce. |
polyjuice -
Polyjuice
|
|
polyjuice_creator -
PolyjuiceCreator
|
|
to_account -
Account
|
|
to_account_id -
Int
|
Contract account. |
type -
TransactionType
|
Polyjuice means polyjuice tx;The other are godwoken tx. |
Example
{
"args": ChainData,
"block": Block,
"block_hash": HashFull,
"block_number": 123,
"eth_hash": HashFull,
"from_account": Account,
"from_account_id": 123,
"hash": HashFull,
"index": 987,
"method_id": ChainData,
"method_name": "abc123",
"nonce": 123,
"polyjuice": Polyjuice,
"polyjuice_creator": PolyjuiceCreator,
"to_account": Account,
"to_account_id": 987,
"type": "ETH_ADDRESS_REGISTRY"
}
TransactionInput
TransactionType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"ETH_ADDRESS_REGISTRY"
TransactionsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
age_range_end -
DateTime
|
|
age_range_start -
DateTime
|
|
before -
String
|
Fetch the records before this cursor. |
combine_from_to -
Boolean
|
if combine_from_to is true, then from_address and to_address are combined into query condition like |
end_block_number -
Int
|
argument: the end of block number(inclusive) for search query |
from_eth_address -
HashAddress
|
|
from_script_hash -
HashFull
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
method_id -
ChainData
|
|
method_name -
String
|
|
sorter -
[TransactionsSorterInput]
|
|
start_block_number -
Int
|
argument: the start of block number(inclusive) for search query |
status -
Status
|
|
to_eth_address -
HashAddress
|
|
to_script_hash -
HashFull
|
Example
{
"after": "abc123",
"age_range_end": "2007-12-03T10:15:30Z",
"age_range_start": "2007-12-03T10:15:30Z",
"before": "xyz789",
"combine_from_to": true,
"end_block_number": 123,
"from_eth_address": HashAddress,
"from_script_hash": HashFull,
"limit": 987,
"method_id": ChainData,
"method_name": "xyz789",
"sorter": [TransactionsSorterInput],
"start_block_number": 123,
"status": "ON_CHAINED",
"to_eth_address": HashAddress,
"to_script_hash": HashFull
}
TransactionsSorter
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"BLOCK_NUMBER"
TransactionsSorterInput
Fields
| Input Field | Description |
|---|---|
sort_type -
SortType
|
|
sort_value -
TransactionsSorter
|
Example
{"sort_type": "ASC", "sort_value": "BLOCK_NUMBER"}
Udt
Fields
| Field Name | Description |
|---|---|
account -
Account
|
The mapping account of udt. |
bridge_account_id -
Int
|
If udt type is bridge, it must have a native proxy account on layer2. |
contract_address_hash -
HashAddress
|
For type is native, it have contract address hash. |
decimal -
Int
|
Set in contract. |
description -
String
|
UDT's description. |
display_name -
String
|
UAN. |
eth_type -
EthType
|
EVM token type. |
holders_count -
Int
|
Count holders of udt. |
icon -
String
|
UDT icon url. |
id -
Int
|
UDT ID is same with account id. |
minted_count -
Decimal
|
Count minted of udt. |
name -
String
|
For bridge token, read from UAN;For native token, read from contract. |
official_site -
String
|
UDT's official site. |
price -
Decimal
|
UDT's market price. |
rank -
Int
|
rank number of current returns |
script_hash -
HashFull
|
Layer1 script hash. |
supply -
Decimal
|
Total supply. |
symbol -
String
|
For bridge token, read from UAN;For native token, read from contract. |
token_exchange_rate -
TokenExchangeRate
|
Token exchange rate of udt. |
type -
UdtType
|
Bridge means from layer1;Native means layer2 contract. |
type_script -
Json
|
Layer1 udt's type script. |
uan -
String
|
UAN. |
value -
Decimal
|
UDT's price * supply. |
Example
{
"account": Account,
"bridge_account_id": 987,
"contract_address_hash": HashAddress,
"decimal": 123,
"description": "abc123",
"display_name": "abc123",
"eth_type": "ERC1155",
"holders_count": 987,
"icon": "xyz789",
"id": 123,
"minted_count": Decimal,
"name": "xyz789",
"official_site": "abc123",
"price": Decimal,
"rank": 987,
"script_hash": HashFull,
"supply": Decimal,
"symbol": "xyz789",
"token_exchange_rate": TokenExchangeRate,
"type": "BRIDGE",
"type_script": Json,
"uan": "xyz789",
"value": Decimal
}
UdtHolderItem
Fields
| Field Name | Description |
|---|---|
balance -
Decimal
|
Holder's udt balance |
bit_alias -
String
|
The holder's alias name |
eth_address -
HashAddress
|
The holder's eth address |
tx_count -
Int
|
Holder's transaction count |
Example
{
"balance": Decimal,
"bit_alias": "abc123",
"eth_address": HashAddress,
"tx_count": 123
}
UdtInput
Fields
| Input Field | Description |
|---|---|
bridge_account_id -
Int
|
|
contract_address -
HashAddress
|
|
id -
Int
|
Example
{
"bridge_account_id": 987,
"contract_address": HashAddress,
"id": 123
}
UdtType
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
Example
"BRIDGE"
UdtsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
contract_address -
HashAddress
|
|
fuzzy_name -
String
|
|
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
sorter -
[Erc1155UdtsSorterInput]
|
|
type -
UdtType
|
Example
{
"after": "abc123",
"before": "xyz789",
"contract_address": HashAddress,
"fuzzy_name": "xyz789",
"limit": 123,
"sorter": [Erc1155UdtsSorterInput],
"type": "BRIDGE"
}
UserErc721Erc1155AssetsInput
Fields
| Input Field | Description |
|---|---|
after -
String
|
Fetch the records after this cursor. |
before -
String
|
Fetch the records before this cursor. |
limit -
Int
|
Limits the number of records returned per page. Note that this number will be capped by maximum_limit=100. Defaults to 20. |
user_address -
HashAddress!
|
Example
{
"after": "xyz789",
"before": "abc123",
"limit": 987,
"user_address": HashAddress
}
VerifyAndUpdateFromSourcifyInput
Fields
| Input Field | Description |
|---|---|
address -
HashAddress!
|
Example
{"address": HashAddress}
WithdrawalHistoryState
Values
| Enum Value | Description |
|---|---|
|
|
|
|
|
|
|
|
Example
"AVAILABLE"