For AI agents: an LLM-friendly Markdown version of every page is available by appending .md to its URL or by sending an Accept: text/markdown request header. The full documentation index is at https://www.ankr.com/docs/llms.txt
Skip to main content

TAC — Information, Transactions, ABCI, Cosmos REST methods

API reference for TAC. All methods ->

Information

blockchain

Retrieves block headers for minHeight <= height <= maxHeight.

At most 20 items will return for the minHeight or maxHeight parameters specified. If maxHeight does not yet exist, the blocks up to the current height will return. If minHeight does not exist (pruning), the earliest existing height will be used.

Parameters


  • minHeight (integer): the minimum block height to return.
  • maxHeight (integer): the maximum block height to return.

Returns

Block headers, in descending order (highest first).

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "blockchain",
"params": ["1", "2"],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"last_height": "2564978",
"block_metas": [
{
"block_id": {
"hash": "ED3BF22DDEAABE5B194ECE00FC97B73B31D6B6E381946054ADF248FADA65FD4F",
"parts": {
"total": 1,
"hash": "268422F8D294840DBC5B24FB031F976357E8478F72C16B66E7B7388C2429D18F"
}
},
"block_size": "830",
"header": {
"version": {
"block": "11"
},
"chain_id": "zgtendermint_16600-2",
"height": "2",
"time": "2024-06-24T07:25:41.380275895Z",
"last_block_id": {
"hash": "A3052C548269F770727A7E74EE90FCDAE6C4AEB5C0F0C614DA0621790D479B89",
"parts": {
"total": 1,
"hash": "E2CF5FEEBCCDA872FB23EA228B82937C4620A887071E9B68AE77CB62F431F2BA"
}
},
"last_commit_hash": "5148301A7ABA311392D676C3C967F299F85A1AD48D74E96AF083DA4787FF9C2D",
"data_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"next_validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"consensus_hash": "81BA6261D0077795E489737675DE120CC9170ADCCAAD805E12EF2708A2E21453",
"app_hash": "21181DF7C886CEE14012C07031E55BF04428BF77979015F2869ED1EACABAD22E",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "CDFF531A3AFA255BC193D52721027366935F9BF8"
},
"num_txs": "0"
},
{
"block_id": {
"hash": "A3052C548269F770727A7E74EE90FCDAE6C4AEB5C0F0C614DA0621790D479B89",
"parts": {
"total": 1,
"hash": "E2CF5FEEBCCDA872FB23EA228B82937C4620A887071E9B68AE77CB62F431F2BA"
}
},
"block_size": "353",
"header": {
"version": {
"block": "11"
},
"chain_id": "zgtendermint_16600-2",
"height": "1",
"time": "2024-06-24T07:24:31.526533772Z",
"last_block_id": {
"hash": "",
"parts": {
"total": 0,
"hash": ""
}
},
"last_commit_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"data_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"next_validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"consensus_hash": "81BA6261D0077795E489737675DE120CC9170ADCCAAD805E12EF2708A2E21453",
"app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "13E845BC0B362D63BC7D4817279EDE51BEB7F9AD"
},
"num_txs": "0"
}
]
}
}

block

Retrieves a block at a specified height.

Parameters


  • height (integer; default: 0): the height to return. If no height is provided, the latest block is to be fetched.

Returns

Block information.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "block",
"params": ["1"],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"block_id": {
"hash": "A3052C548269F770727A7E74EE90FCDAE6C4AEB5C0F0C614DA0621790D479B89",
"parts": {
"total": 1,
"hash": "E2CF5FEEBCCDA872FB23EA228B82937C4620A887071E9B68AE77CB62F431F2BA"
}
},
"block": {
"header": {
"version": {
"block": "11"
},
"chain_id": "zgtendermint_16600-2",
"height": "1",
"time": "2024-06-24T07:24:31.526533772Z",
"last_block_id": {
"hash": "",
"parts": {
"total": 0,
"hash": ""
}
},
"last_commit_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"data_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"next_validators_hash": "EC4FD9C58AB322D57FD67299FC64AE10459BDAA2652BFC1CC989C66F8B9B6EA1",
"consensus_hash": "81BA6261D0077795E489737675DE120CC9170ADCCAAD805E12EF2708A2E21453",
"app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "13E845BC0B362D63BC7D4817279EDE51BEB7F9AD"
},
"data": {
"txs": []
},
"evidence": {
"evidence": []
},
"last_commit": {
"height": "0",
"round": 0,
"block_id": {
"hash": "",
"parts": {
"total": 0,
"hash": ""
}
},
"signatures": []
}
}
}
}

block_by_hash

Retrieves a block by hash.

Parameters


  • hash (string; required): the Base64-encoded block hash.

Returns

Block information.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "block_by_hash",
"params": {
"hash": "qKuv5HZ3tYbvJxK7TAW5frjLbg3ORxk49pkK11y9oAA="
},
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"block_id": {
"hash": "A8ABAFE47677B586EF2712BB4C05B97EB8CB6E0DCE471938F6990AD75CBDA000",
"parts": {
"total": 1,
"hash": "7017BF9E8E15A49C4C19A9293B47C2022CB76A1F857E93C535C237CC97C3AEA4"
}
},
"block": {
"header": {
"version": {
"block": "11"
},
"chain_id": "tacchain_2390-1",
"height": "2081453",
"time": "2025-01-29T11:23:05.876205111Z",
"last_block_id": {
"hash": "4CD5DEF666A98244E1AC52783D53ACC13A3DE39D6CFC6BE8540AB582F58E6294",
"parts": {
"total": 1,
"hash": "E9CDDE42389997FFEF4362B3D6866E01633C344A741B9AF099EC324222A716F3"
}
},
"last_commit_hash": "42BCA34B9D6E4ED49C267C34913C2DB9EA96EB91635877D0F78678355B34E9D5",
"data_hash": "56D3DB004B30913B1156E941CCDD28703EBEC112440CBB9EEA0BB89C15FD17AC",
"validators_hash": "B3ABC95E36789E4A61A817AEF2DC26DCF6D1922BF9391134221B378B13C0542D",
"next_validators_hash": "B3ABC95E36789E4A61A817AEF2DC26DCF6D1922BF9391134221B378B13C0542D",
"consensus_hash": "16DBFD0AAA36E214D4E55A6EAADF68E9802DD4845DBD49EB58DAA89F885D1FC0",
"app_hash": "F0FC1B6ACDAFEDDAA90116AAC6C9C668CB17F3FA3055C9334DAFF806291266B1",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "FAD767856DD735D350D1C2701E01E44E3CD8DCF0"
},
"data": {
"txs": [
"CpEDCt0CCh8vZXRoZXJtaW50LmV2bS52MS5Nc2dFdGhlcmV1bVR4ErkCCvIBCh4vZXRoZXJtaW50LmV2bS52MS5EeW5hbWljRmVlVHgSzwEKBDIzOTAQ5yUaATEiATEohaoEMioweGQzQThENDRiODg5ZEUwMjcwM0RGOEIzM2M1M0U5MzMxNWEzM2IwNmY6ATBCREDBDxkAAAAAAAAAA..."
]
},
"evidence": {
"evidence": []
},
"last_commit": {
"height": "2081452",
"round": 0,
"block_id": {
"hash": "4CD5DEF666A98244E1AC52783D53ACC13A3DE39D6CFC6BE8540AB582F58E6294",
"parts": {
"total": 1,
"hash": "E9CDDE42389997FFEF4362B3D6866E01633C344A741B9AF099EC324222A716F3"
}
},
"signatures": [
{
"block_id_flag": 2,
"validator_address": "A0E2E65C71DE9D8A59D182933122934A1FA23837",
"timestamp": "2025-01-29T11:23:05.876205111Z",
"signature": "KnjELWFDuPFrA6UH7IsqihmEM6bcgWkl6gG0WUnJrh+vc7HC9Y5Lk1ZalLS2YCJXgxqqO3j1xu4NRSmfnCEPAA=="
}
]
}
}
}
}

block_results

Retrieves block results at a specified height.

Parameters


  • height (integer; default: 0): the height to return. If no height is provided, the latest block info is to be fetched.

Returns

Block results.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "block_results",
"params": ["1"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"height": "1",
"txs_results": null,
"finalize_block_events": [
{
"type": "coin_spent",
"attributes": [
{
"key": "spender",
"value": "tac1tygms3xhhs3yv487phx3dw4a95jn7t7ly38lhf",
"index": false
},
{
"key": "amount",
"value": "40000000000000000000000utac",
"index": false
}
]
}
],
"validator_updates": null,
"consensus_param_updates": {
"block": {
"max_bytes": "22020096",
"max_gas": "20000000"
},
"evidence": {
"max_age_num_blocks": "100000",
"max_age_duration": "172800000000000",
"max_bytes": "1048576"
},
"validator": {
"pub_key_types": [
"ed25519"
]
},
"version": {},
"abci": {}
},
"app_hash": "gO0ylmiv3gyUf//1qmvmOEpx36TfluCm05LXVd/GHvk="
}
}

commit

Retrieves commit results at a specified height.

Parameters


  • height (integer; default: 0): the height to return. If no height is provided, the latest block commit info is to be fetched.

Returns

Commit results. Canonical switches from false to true for block H once block H+1 has been committed, until then it's subjective and only reflects what this node has seen so far.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "commit",
"params": ["1"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"signed_header": {
"header": {
"version": {
"block": "11"
},
"chain_id": "tacchain_2390-1",
"height": "1",
"time": "2024-11-08T12:01:27.393983011Z",
"last_block_id": {
"hash": "",
"parts": {
"total": 0,
"hash": ""
}
},
"last_commit_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"data_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"validators_hash": "307B2281CBDCC5D12F69345E9DA7B262C984BFFDD3EE85D7C732654EECB94B9D",
"next_validators_hash": "307B2281CBDCC5D12F69345E9DA7B262C984BFFDD3EE85D7C732654EECB94B9D",
"consensus_hash": "16DBFD0AAA36E214D4E55A6EAADF68E9802DD4845DBD49EB58DAA89F885D1FC0",
"app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "A0E2E65C71DE9D8A59D182933122934A1FA23837"
},
"commit": {
"height": "1",
"round": 1,
"block_id": {
"hash": "07726785B5E5EF0701CEAFA0B929BDF852ABE35840C885A2F740A9E7108A610A",
"parts": {
"total": 1,
"hash": "4289823D5E0104E13D4D5D72A84BF412914C900B2AE14FC6F285F80287B5F0C4"
}
},
"signatures": [
{
"block_id_flag": 2,
"validator_address": "0469070A1C182AF11A1939F098C5C2C666116561",
"timestamp": "2024-11-08T13:20:25.020397516Z",
"signature": "okpCLoE11eQ+b2NPvlIFeX8NXuS939cEa8+M0Yv5qT6L1UkpWZ1JLmDLQn9KO4QinpehezvuaKI3uwIeGQEJBg=="
}
]
}
},
"canonical": true
}
}

validators

Retrieves a validator set at a specified height.

Validators are sorted by voting power.

Parameters


  • height (integer; default: 0): the height to return. If no height is provided, the validator set corresponding to the latest block is to be fetched.
  • page (integer; default: 1): a page number (1-based).
  • per_page (integer; default: 30; max: 100): a number of entries per page.

Returns

Commit results.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "validators",
"params": ["1","1","30"],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"block_height": "1",
"validators": [
{
"address": "0469070A1C182AF11A1939F098C5C2C666116561",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "IXbZunQ86cctrrLCvi1IdSo4lUbQ9Yn8ZvJE8NJBUU0="
},
"voting_power": "10000000000000000",
"proposer_priority": "-30000000000000000"
},
{
"address": "A0E2E65C71DE9D8A59D182933122934A1FA23837",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "uY1lJrMtzM7YvevMIy7e8ncBw2H/rF80Hsy1Za76Gs8="
},
"voting_power": "10000000000000000",
"proposer_priority": "10000000000000000"
},
{
"address": "F811E7EEFD3C7869D015E94AA5E24E6C24D65438",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "taLMbOFCeclyC4PSsE4QfffRBd3bte2GDfUMEqQjVB4="
},
"voting_power": "10000000000000000",
"proposer_priority": "10000000000000000"
},
{
"address": "FAD767856DD735D350D1C2701E01E44E3CD8DCF0",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "MKl1KagA7T6KicN3fj7BHihg3KwDsbqHLSCUYXhdkbo="
},
"voting_power": "10000000000000000",
"proposer_priority": "10000000000000000"
}
],
"count": "4",
"total": "4"
}
}

genesis_chunked

Retrieves Genesis in multiple chunks.

Gets genesis document in multiple chunks to make it easier to iterate through larger genesis structures. Each chunk is produced by converting the genesis document to JSON and then splitting the resulting payload into 16MB blocks, and then Base64-encoding each block.

Parameters


  • chunk (integer; default: 0): a sequence number of the chunk to download.

Returns

A Genesis chunk response.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "genesis_chunked",
"params": ["0"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": -1,
"result": {
"chunk": "0",
"total": "1",
"data": "eyJnZW5lc2lzX3RpbWUiOiIyMDI0LTA2LTI0VDA3OjI0OjMxLjUyNjUzMzc3MloiLCJjaGFpbl9pZCI6InpndGVuZGVybWludF8xNjYwMC0yIiwiaW5pdGlhbF9oZWlnaHQiOiIxIiwiY29uc2Vuc3VzX3BhcmFtcyI6eyJibG9jayI6eyJtYXhfYnl0ZXMiOiIyMjAyMD..."
}
}

dump_consensus_state

Retrieves consensus state.

Not safe to call from inside the ABCI application during a block execution.

Parameters


None.

Returns

A complete consensus state. See the Vote string description.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "dump_consensus_state",
"params": [],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"round_state": {
"height": "2130808",
"round": 0,
"step": 3,
"start_time": "2025-01-31T10:01:50.17850105Z",
"commit_time": "2025-01-31T10:01:47.17850105Z",
"validators": {
"validators": [
{
"address": "A0E2E65C71DE9D8A59D182933122934A1FA23837",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "uY1lJrMtzM7YvevMIy7e8ncBw2H/rF80Hsy1Za76Gs8="
},
"voting_power": "10060000000000400",
"proposer_priority": "11333000124971576"
}
],
"proposer": {
"address": "F811E7EEFD3C7869D015E94AA5E24E6C24D65438",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "taLMbOFCeclyC4PSsE4QfffRBd3bte2GDfUMEqQjVB4="
},
"voting_power": "10000000000000000",
"proposer_priority": "-20516000041617624"
}
},
"proposal": null,
"proposal_block": null,
"proposal_block_parts": null,
"locked_round": -1,
"locked_block": null,
"locked_block_parts": null,
"valid_round": -1,
"valid_block": null,
"valid_block_parts": null,
"votes": [
{
"round": 0,
"prevotes": [
"nil-Vote",
"nil-Vote",
"nil-Vote",
"nil-Vote"
],
"prevotes_bit_array": "BA{4:____} 0/40066000000000400 = 0.00",
"precommits": [
"nil-Vote",
"nil-Vote",
"nil-Vote",
"nil-Vote"
],
"precommits_bit_array": "BA{4:____} 0/40066000000000400 = 0.00"
}
],
"commit_round": -1,
"last_commit": {
"votes": [
"Vote{0:A0E2E65C71DE 2130807/00/SIGNED_MSG_TYPE_PRECOMMIT(Precommit) 5F824DEDE09C 0C7A9CCC11AA 000000000000 @ 2025-01-31T10:01:47.030466581Z}",
"Vote{1:FAD767856DD7 2130807/00/SIGNED_MSG_TYPE_PRECOMMIT(Precommit) 5F824DEDE09C B9034974713C 000000000000 @ 2025-01-31T10:01:47.046270001Z}",
"Vote{2:0469070A1C18 2130807/00/SIGNED_MSG_TYPE_PRECOMMIT(Precommit) 5F824DEDE09C A41F6EE27C20 000000000000 @ 2025-01-31T10:01:47.005732112Z}",
"Vote{3:F811E7EEFD3C 2130807/00/SIGNED_MSG_TYPE_PRECOMMIT(Precommit) 5F824DEDE09C 4658137BD5EA 000000000000 @ 2025-01-31T10:01:47.046268878Z}"
],
"votes_bit_array": "BA{4:xxxx} 40066000000000400/40066000000000400 = 1.00",
"peer_maj_23s": {}
},
"last_validators": {
"validators": [
{
"address": "A0E2E65C71DE9D8A59D182933122934A1FA23837",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "uY1lJrMtzM7YvevMIy7e8ncBw2H/rF80Hsy1Za76Gs8="
},
"voting_power": "10060000000000400",
"proposer_priority": "1273000124971176"
}
],
"proposer": {
"address": "FAD767856DD735D350D1C2701E01E44E3CD8DCF0",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "MKl1KagA7T6KicN3fj7BHihg3KwDsbqHLSCUYXhdkbo="
},
"voting_power": "10006000000000000",
"proposer_priority": "-20354000041636525"
}
},
"triggered_timeout_precommit": false
},
"peers": [
{
"node_address": "9b4995a048f930776ee5b799f201e9b00727ffcc@107.6.94.246:45120",
"peer_state": {
"round_state": {
"height": "2130808",
"round": 0,
"step": 1,
"start_time": "2025-01-31T10:01:49.230676037Z",
"proposal": false,
"proposal_block_part_set_header": {
"total": 0,
"hash": ""
},
"proposal_block_parts": null,
"proposal_pol_round": -1,
"proposal_pol": "____",
"prevotes": "____",
"precommits": "____",
"last_commit_round": 0,
"last_commit": "xxxx",
"catchup_commit_round": -1,
"catchup_commit": "____"
},
"stats": {
"votes": "350044",
"block_parts": "44573"
}
}
}
]
}
}

consensus_state

Retrieves consensus state.

Not safe to call from inside the ABCI application during a block execution.

Parameters


None.

Returns

Consensus state results.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "consensus_state",
"params": [],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"round_state": {
"height/round/step": "2130789/0/1",
"start_time": "2025-01-31T10:00:45.687676388Z",
"proposal_block_hash": "",
"locked_block_hash": "",
"valid_block_hash": "",
"height_vote_set": [
{
"round": 0,
"prevotes": [
"nil-Vote",
"nil-Vote",
"nil-Vote",
"nil-Vote"
],
"prevotes_bit_array": "BA{4:____} 0/40066000000000400 = 0.00",
"precommits": [
"nil-Vote",
"nil-Vote",
"nil-Vote",
"nil-Vote"
],
"precommits_bit_array": "BA{4:____} 0/40066000000000400 = 0.00"
}
],
"proposer": {
"address": "0469070A1C182AF11A1939F098C5C2C666116561",
"index": 2
}
}
}
}

consensus_params

Retrieves consensus parameters.

Parameters


  • height (integer; default: 0): the height to return. If no height is provided, the latest block commit info is to be returned.

Returns

Consensus parameters results.

Request parameters

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "consensus_params",
"params": ["1"],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"block_height": "1",
"consensus_params": {
"block": {
"max_bytes": "22020096",
"max_gas": "20000000"
},
"evidence": {
"max_age_num_blocks": "100000",
"max_age_duration": "172800000000000",
"max_bytes": "1048576"
},
"validator": {
"pub_key_types": [
"ed25519"
]
},
"version": {
"app": "0"
},
"abci": {
"vote_extensions_enable_height": "0"
}
}
}
}

unconfirmed_txs

Retrieves the list of unconfirmed transactions.

Parameters


  • limit (integer; default: 30; max: 100): the maximum number of unconfirmed transactions to return.

Returns

The list of unconfirmed transactions.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "unconfirmed_txs",
"params": ["1"],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"n_txs": "0",
"total": "0",
"total_bytes": "0",
"txs": []
}
}

num_unconfirmed_txs

Retrieves data on unconfirmed transactions.

Parameters


None.

Returns

The status of unconfirmed transactions.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "num_unconfirmed_txs",
"params": [],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"n_txs": "0",
"total": "0",
"total_bytes": "0",
"txs": null
}
}

Searches for transactions with their results.

Parameters


  • query (string; required): query is a string, which has a form: "condition AND condition ..." (no OR at the moment). condition has a form: "key operation operand". key is a string with a restricted set of possible symbols ( \t\n\r()"'=>< are not allowed). operation can be =, <, <=, >, >=, CONTAINS. An operand can be a string (escaped with single quotes), number, date, or time.
  • prove (boolean; default: false): adds proofs of the transactions inclusion in the block.
  • page (integer; default: 1): a page number (1-based).
  • per_page (integer; default: 30, max: 100): a number of entries per page.
  • order_by (string; default: asc): the order in which transactions are sorted (asc or desc), by height & index. If empty, default sorting still applies.
  • match_events (boolean; default: false): match attributes in query within events, in addition to the height and txhash.

Returns

The list of unconfirmed transactions.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "tx_search",
"params": {
"query": "tx.height=13225811",
"prove": true,
"page": "1",
"per_page": "5",
"order_by": "desc"
},
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"txs": [],
"total_count": "0"
}
}

Searches for blocks by BeginBlock and EndBlock events.

Parameters


  • query (string; required): query is a string, which has a form: "condition AND condition ..." (no OR at the moment). condition has a form: "key operation operand". key is a string with a restricted set of possible symbols ( \t\n\r()"'=>< are not allowed). operation can be =, <, <=, >, >=, CONTAINS. An operand can be a string (escaped with single quotes), number, date, or time.
  • page (integer; default: 1): a page number (1-based).
  • per_page (integer; default: 30, max: 100): a number of entries per page.
  • order_by (string; default: asc): the order in which transactions are sorted (asc or desc), by height & index. If empty, default sorting still applies.
  • match_events (boolean; default: false): match attributes in query within events, in addition to the height.

Returns

The list of paginated blocks matching the search criteria.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "block_search",
"params": {
"query": "block.height=13225811",
"page": "1",
"per_page": "10",
"order_by": "desc"
},
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"blocks": [],
"total_count": "0"
}
}

tx

Retrieves a transaction by hash.

Parameters


  • hash (string; required): a hash of a transaction to retrieve.
  • prove (boolean; default: false): adds proofs of the transaction's inclusion in the block.

Returns

Transaction info.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "tx",
"params": ["ys4oH8G8i3TFkq51/8w/ntGD6YcJda1LVNEwh0cjxQ0=", true],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"hash": "4B6D8FEA3786BFC6152EAEA791C4DAF00C41E93DAD56A7230B565179CD29CAA1",
"height": "12345",
"index": 2,
"tx_result": {
"code": 0,
"log": "Success",
"events": [
{
"type": "transfer",
"attributes": [
{ "key": "sender", "value": "0g1xyz..." },
{ "key": "recipient", "value": "0g1abc..." },
{ "key": "amount", "value": "10000u0g" }
]
}
]
},
"tx": "BASE64_ENCODED_TX", // The transaction itself in Base64 format
"proof": {
"root_hash": "0xABC123...",
"data": "BASE64_ENCODED_PROOF",
"proof": { /* Detailed proof structure */ }
}
}
}

Transactions

broadcast_tx_sync

Returns with the response from CheckTx. Does not wait for DeliverTx result.

If you want to be sure that the transaction is included in a block, you can subscribe for the result using JSON-RPC via a websocket. See https://docs.cometbft.com/v0.34/core/subscription.html If you haven't received anything after a couple of blocks, resend it. If the same happens again, send it to some other node. A few reasons why it could happen:

  1. A malicious node drops or pretends it has committed your tx.
  2. A malicious proposer (not necessary the one you're communicating with) drops transactions, which might become valid in the future (https://github.com/tendermint/tendermint/issues/3322).

Please refer to Tendermint docs for formatting/encoding rules.

Parameters


  • tx (string; required): the signed transaction, encoded as Base64.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "broadcast_tx_sync",
"params": ["<BASE64_ENCODED_TRANSACTION>"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"code": 0,
"data": "",
"log": "transaction successfully broadcasted",
"hash": "0xABC123..." // The transaction hash
}
}

broadcast_tx_async

Returns right away, with no response. Does not wait for CheckTx nor DeliverTx results.

If you want to be sure that the transaction is included in a block, you can subscribe for the result using JSON-RPC via a websocket. See https://docs.cometbft.com/v0.34/core/subscription.html If you haven't received anything after a couple of blocks, resend it. If the same happens again, send it to some other node. A few reasons why it could happen:

  1. A malicious node drops or pretends it has committed your tx.
  2. A malicious proposer (not necessary the one you're communicating with) drops transactions, which might become valid in the future (https://github.com/tendermint/tendermint/issues/3322).
  3. A node is offline.

Please refer to CometBFT docs for formatting/encoding rules.

Parameters


  • tx (string; required): the Base64-encoded signed transaction.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "broadcast_tx_async",
"params": ["<BASE64_ENCODED_TRANSACTION>"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"code": 0,
"data": "",
"log": "",
"hash": "0xABC123..." // Transaction hash
}
}

broadcast_tx_commit

Returns with the responses from CheckTx and DeliverTx.

warning

Use only for testing and development. In production, use BroadcastTxSync or BroadcastTxAsync. You can subscribe for the transaction result using JSON-RPC via a websocket (see CometBFT docs).

tip

CONTRACT: only returns error if mempool.CheckTx() errs or if we timeout waiting for tx to commit. If CheckTx or DeliverTx fails, no error will be returned, but the result will contain a non-OK ABCI code. Please refer to CometBFT docs for formatting/encoding rules.

Parameters


  • tx (string; required): the Base64-encoded signed transaction.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "broadcast_tx_commit",
"params": ["<BASE64_ENCODED_TRANSACTION>"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"check_tx": {
"code": 0,
"data": "",
"log": "Transaction checked successfully"
},
"deliver_tx": {
"code": 0,
"data": "",
"log": "Transaction delivered successfully",
"events": [
{
"type": "transfer",
"attributes": [
{ "key": "sender", "value": "0g1xyz..." },
{ "key": "recipient", "value": "0g1abc..." },
{ "key": "amount", "value": "10000u0g" }
]
}
]
},
"hash": "0xABC123...",
"height": "12345"
}
}

check_tx

Checks the transaction without executing it.

The transaction won't be added to the mempool.

Please refer to CometBFT docs for formatting/encoding rules.

Parameters


  • tx (string; required): the Base64-encoded signed transaction.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "check_tx",
"params": ["<BASE64_ENCODED_TRANSACTION>"],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"code": 0,
"data": "",
"log": "Transaction is valid",
"events": [
{
"type": "transfer",
"attributes": [
{ "key": "sender", "value": "0g1xyz..." },
{ "key": "recipient", "value": "0g1abc..." },
{ "key": "amount", "value": "10000u0g" }
]
}
]
}
}

ABCI

abci_info

Retrieves application info.

Parameters


None.

Returns

Application info.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "abci_info",
"params": [],
"id": 1
}'

Response example

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"response": {
"data": "TacChainApp",
"version": "0.0.2",
"last_block_height": "2130968",
"last_block_app_hash": "X9pYsyApqs0iou6EgXqqfRrRbHRY9o3i7lbfUr/3DfI="
}
}
}

abci_query

Queries the application for particular information.

Parameters


  • path (string; required): a path to the data ("/a/b/c").
  • data (string; required): the hex-encoded data.
  • height (integer; default: 0): the height (0 means latest).
  • prove (boolean; default: false): adds proofs of the transactions inclusion in the block.

Returns

Particular info according to the query submitted.

Request example

curl -X POST https://rpc.ankr.com/tac_turin_tendermint/YOUR_ANKR_API_KEY \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "abci_query",
"params": ["a/b/c", "the_data", "1", true],
"id": 1
}'

Response example

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"response": {
"code": 0,
"log": "",
"info": "",
"index": -1,
"key": "0x6b61766131387879377a...",
"value": "0x123456789abcdef", // Hex-encoded value
"proofOps": null,
"height": "12345",
"codespace": ""
}
}
}

Cosmos REST methods

Query:

Service:

Auth methods

/cosmos/auth/v1beta1/accounts/{address}

Retrieves account details based on address.

Parameters

  • address (string; required): an address to query for account details.

Returns

Account details.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/auth/v1beta1/accounts/{address}

Response example

{
"account": {
"type_url": "string",
"value": "string"
}
}

/cosmos/auth/v1beta1/params

Retrieves all parameters.

Parameters

None.

Returns

Parameters.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/auth/v1beta1/params

Response example

{
"params": {
"max_memo_characters": "string",
"tx_sig_limit": "string",
"tx_size_cost_per_byte": "string",
"sig_verify_cost_ed25519": "string",
"sig_verify_cost_secp256k1": "string"
}
}

Bank methods

/cosmos/bank/v1beta1/balances/{address}

Retrieves the balance of all coins for a single account.

Parameters

  • address(string; required): an address to query balances for.
  • pagination.key (string, byte): value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set.
  • pagination.offset (string, uint64): numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set.
  • pagination.limit (string, uint64): total number of results to be returned in the result page. If left empty it will default to a value to be set by each app.
  • pagination.count_total (boolean): set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used, it is ignored when key is set.

Returns

Balance of all coins for a single account.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/bank/v1beta1/balances/{address}

Response example

{
"balances": [
{
"denom": "string",
"amount": "string"
}
],
"pagination": {
"next_key": "string",
"total": "string"
}
}

/cosmos/bank/v1beta1/balances/{address}/{denom}

Retrieves balance of a single coin for a single account.

Parameters

  • address (string; required): an address to query balances for.
  • denom (string; required): a coin denom to query balances for.

Returns

Balance of the specific coin for a single account.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/bank/v1beta1/balances/{address}/{denom}

Response example

{
"balance": {
"denom": "string",
"amount": "string"
}
}

/cosmos/bank/v1beta1/params

Retrieves the parameters of x/bank module.

Parameters

None.

Returns

Parameters of x/bank module.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/bank/v1beta1/params

Response example

{
"params": {
"send_enabled": [
{
"denom": "string",
"enabled": true
}
],
"default_send_enabled": true
}
}

/cosmos/bank/v1beta1/supply

Retrieves the total supply of all coins.

Parameters

None.

Returns

Supply of all coins.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/bank/v1beta1/supply

Response example

{
"supply": [
{
"denom": "string",
"amount": "string"
}
]
}

Distribution methods

/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards

Retrieves the total rewards accrued by each validator.

Parameters

  • delegator_address (string; required): a delegator address to query for.

Returns

Rewards from each validator.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards

Response example

{
"rewards": [
{
"validator_address": "string",
"reward": [
{
"denom": "string",
"amount": "string"
}
]
}
],
"total": [
{
"denom": "string",
"amount": "string"
}
]
}

/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/{validator_address}

Retrieves the total rewards accrued by a delegation.

Parameters

  • delegator_address (string; required): a delegator address to query for.
  • validator_address (string; required): a validator address to query for.

Returns

Total rewards accrued by a delegation for a specific validator.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/{validator_address}

Response example

{
"rewards": [
{
"denom": "string",
"amount": "string"
}
]
}

/cosmos/distribution/v1beta1/delegators/{delegator_address}/validators

Retrieves the validators of a delegator.

Parameters

  • delegator_address (string; required): a delegator address to query for.

Returns

Validators for a given delegator.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/delegators/{delegator_address}/validators

Response example

{
"validators": [
"string"
]
}

/cosmos/distribution/v1beta1/delegators/{delegator_address}/withdraw_address

Retrieves withdraw address of a delegator.

Parameters

  • delegator_address (string, required): a delegator address to query for.

Returns

Withdraw address of delegator.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/delegators/{delegator_address}/withdraw_address

Response example

{
"withdraw_address": "string"
}

/cosmos/distribution/v1beta1/params

Retrieves params of the distribution module.

Parameters

None.

Returns

Params of the distribution module.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/params

Response example

{
"params": {
"community_tax": "string",
"base_proposer_reward": "string",
"bonus_proposer_reward": "string",
"withdraw_addr_enabled": true
}
}

/cosmos/distribution/v1beta1/validators/{validator_address}/commission

Retrieves accumulated commission for a validator.

Parameters

  • validator_address (string; required): a validator address to query for.

Returns

Total commission for a validator.

Request example

curl https://rpc.ankr.com/http/tac_turin_cosmos/cosmos/distribution/v1beta1/validators/{validator_address}/commission

Response example

{
"commission": {
"commission": [
{
"denom": "string",
"amount": "string"
}
]
}
}