Chaingateway public API (2.0.0-beta)

Download OpenAPI specification:Download

Blockchain API to build the bridge between Blockchain and the real world

Introduction

This API allows you to interact with Ethereum, Binance smartchain and Tron blockchain. If you ever looked for a possibility to automate token or payments this is the right place. You still have no idea for real use cases? Let me give you some examples: Accept your own token as payment method for your shop, distribute airdrop tokens of your ICO, convert your site currency to a token that can be traded on exchanges and many more. There are a lot of use cases which are not only limited to sending tokens but also receiving them. You could even create a secure wallet for your token which only the wallet owner has access to.

Endpoints

At the moment we only have an production endpoint. Its reachable at

api.chaingateway.io

Postman

Postman is a great software to test APIs, it helped us a lot when developing this API. If you haven't installed it yet, you can download it here. We have created a Postman collection that allows to import all functions and their settings, including descriptions in Postman. This way you can test all functions with the click of a button (just change the parameters before). You can import the collection by clicking the button below:

Run in Postman

Authorization

You can get your personal API Key from your account dashboard. It is used by us to determine who is accessing the API and to count the requests by that account. Add it in the HTTP header

Authorization: q9PdaWuD4j6DK6vsUgehhL8pgarSrS9m

Please do not share your api key! If you did so by mistake, immediately delete it in your account panel and create a new one!

Ethereum

Ethereum > Info Requests

getLastBlockNumber

Get the latest block number

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Authorization
string
Example: {{api_key}}

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/blocks/number',
  headers: {Accept: 'SOME_STRING_VALUE', Authorization: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getERC20

Get information about an ERC20 token

Authorizations:
apikeyAuth
path Parameters
erc20_token
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

An ERC20 token address

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/erc20/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! ERC20 Token has been successfully parsed.",
  • "data": {
    }
}

getGasPrice

Get gas price

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Authorization
string
Example: APIKEY

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/gasprice',
  headers: {Accept: 'SOME_STRING_VALUE', Authorization: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getEthereumBalance

Get the balance of an address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

Ethereum address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/balances/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Ethereum address balance successfully parsed.",
  • "data": {
    }
}

getAllERC20Balance

Get the balance of an ERC20 address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce
erc20_token
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/balances/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce/erc20/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Token Balance has been successfully parsed.",
  • "data": {
    }
}

getBlock

Get information of a specific block

Authorizations:
apikeyAuth
path Parameters
block
required
string
Example: 0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5

Block number or hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/blocks/0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed the block.",
  • "data": [
    ]
}

getNFTUri

Get the URI of an NFT

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0x9db475371b5cc2913d3219f72e16a3f101339a05

NFT contract address

token_id
required
integer
Example: 374

Id of the NFT

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/nfts/0x9db475371b5cc2913d3219f72e16a3f101339a05/uri/374',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{}

getNFTOwner

Get the Owner of an NFT

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0x9db475371b5cc2913d3219f72e16a3f101339a05

NFT contract address

token_id
required
integer
Example: 374

Id of the NFT

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/nfts/0x9db475371b5cc2913d3219f72e16a3f101339a05/owner/374',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "NFT Owner has been successfully parsed.",
  • "data": {
    }
}

getTransaction

Get info about a transaction

You can choose if you want to get the Transaction encoded or decoded by add /decoded to your request. See examlpes for details

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/transactions/0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transactionReceipt",
  • "data": [
    ]
}

getTransactionReceipt

Get info about a transaction receipt

You can choose if you want to get the Transaction encoded or decoded by add /decoded to your request. See examlpes for details

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/transactions/0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037/receipt/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transactionReceipt",
  • "data": [
    ]
}

Ethereum > Address Requests

newAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Address was successfully created.",
  • "data": {
    }
}

listAddresses

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/addresses',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Addresses has been successfully parsed.",
  • "data": {
    }
}

deleteAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xfa343ee01667869cfb409b24ae33f7ce8b110eb0

Ethereum address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/ethereum/addresses/0xfa343ee01667869cfb409b24ae33f7ce8b110eb0',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Address has been successfully deleted.",
  • "data": {
    }
}

importAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "filename": "UTC--2020-09-19T10-42-26.196Z--71892889ed4d79d88ab6ea3783b571b8ece9bef4",
  • "content": {
    },
  • "password": "padN39QkRA2hJ"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum address has been successfully imported.",
  • "data": {
    }
}

exportAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xacc767f4042360c5f08c7b98bac8e66a5c679cef

0xe7114f0dbd5a5fa62ed2df905f7391c957ff9e36

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum address has been successfully exported.",
  • "data": {
    }
}

ListTransactionsByAddress

Our API provides an endpoint for retrieving all transactions associated with a particular blockchain address. To use this endpoint, you will need to provide the wallet address as a parameter in the request.

Each page of results returned by this endpoint contains up to 100 entries, and you can use a paginator to navigate through the pages of results.

To use the paginator, you can include parameter in your request: "page" . The "page" parameter specifies which page of results to retrieve,

For example, to retrieve the first 100 transactions associated with a particular blockchain address, you would make a request to the following URL:

/addresses//transactions/1

If there are more than 100 transactions associated with the blockchain address, you can retrieve additional pages of results by incrementing the "page" parameter in your request. For example, to retrieve the next 100 transactions, you would make a request to the following URL:

/addresses//transactions/2

By using the paginator, you can retrieve all transactions associated with a particular blockchain address, regardless of the total number of transactions in the blockchain.

each request tells you the max pages within the Request in the max_pages field

"max_pages": 515

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5

account address

page
required
integer
Example: 1

Current page, see description for more informatiosn how pagination works

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/addresses/0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5/transactions/1'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Addresses has been successfully parsed.",
  • "data": {
    }
}

Ethereum > Webhooks/IPN Requests

With webhooks, you can get notified about various events in the blockchain. E.g:

Receipt of payment to a specific address
Outgoing payment from a specific address
Exchange of sats between two specific addresses
Execution of a contract
Change of ownership of a token

For this you have to create a webhook with certain filter criteria. The following values are available as filter criteria:

from: Outgoing address
to: Incoming address
contract: Contract that should be monitored
tokenid: ID of a token that should be monitored.
type: Token type ([ETH', 'ERC20', 'ERC721', null)

Parameter "url" defines the url we are calling with a POST Request.. The request body will have your filter criterias and some additional informatiion about your transaction:

{
  "id": "63a1ae0887ca3625b82b4924",
  "webhook_id": "63a1ad0e87ca3625b82b4923",
  "from": "0x0000000000000000000000000000000000000000",
  "to": "0xa9d1e08c7793af67e9d92fe308d5697fb81d3e43",
  "blocknumber": "123",
  "datetime": "22-12-20 13:43:52",
  "tokenid": "0x0000000000000000000000000000000000000000",
  "type": null,
  "txid": "000000000000000000000000000000000000000000000000000",
  "amount": "000000000000000000000000000000000000000000000000000"
}

subscribeAddress

Creates a new subscription/IPN for the given address (and contractaddress). You will receive a notification to the given url every time a deposit is received. Unsubscribe the address before sending tokens/ETH from it or you won't get reliable notifications anymore.

You can choose one or more from following filter criterias

Parameter Description
from ethereum address
to ethereum address
contractaddress contract address
tokenid token id

You also need to dpecify the parameter "type". you can choose between ['ETH', 'ERC20', 'ERC721', null]

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully subscribed to IPN!.",
  • "data": {
    }
}

listSubscribedAddresses

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/webhooks',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPNs could be successfully parsed.",
  • "data": {
    }
}

unsubscribeAddress

Deletes an existing subscription/IPN for the given address (and contractaddress).

Authorizations:
apikeyAuth
path Parameters
webhook
required
string
Example: 626407c62e5e8235ca561dce

Webhook id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/ethereum/webhooks/626407c62e5e8235ca561dce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully unsubscribed to IPN!.",
  • "data": {
    }
}

listFailedIPNs

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
webhook
required
string
Example: 626407c62e5e8235ca561dce

webhook id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/webkhooks/626407c62e5e8235ca561dce/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "failed_ipns": [
    ]
}

listIPNsByWebhookId

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/ethereum/webkhooks/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "failed_ipns": [
    ]
}

resendFailedIPN

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
notification
required
string
Example: 62640817eb594da78c7bee00

Notification api

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPN successfully got resent.",
  • "data": {
    }
}

Ethereum > Transaction Requests

sendERC20

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "contractaddress": "0x55d398326f99059fF775485246999027B3197955",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": 0.1,
  • "password": "test123",
  • "gas": 0
}

sendERC721

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: */*
string

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/ethereum/transactions/erc721',
  headers: {'content-type': '*/*', Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

sendTransaction

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": "0.1",
  • "password": "test123",
  • "gas": 0
}

broadcastTransaction

Broadcast raw transactions

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "data": "0xf86b0685012a05f20082520894dfa04096652804362e4b7ae31835416974271e298609184e72a000808194a086277b0f2d7df91c9ce580171cd7f7be6e2c298727944a13fb40e5e9406ccb61a076105cefee8def061024dfb333a1bd47f629b52aae6621d2f2f39a0dccc3ac85"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Transaction has been successfully broadcasted.",
  • "data": {
    }
}

Ethereum > RPC API

getUncleByBlockNumberAndIndex

Returns information about a uncle of a block by number and uncle index position.

Parameters

QUANTITY|TAG - a block number, or the string "earliest", "latest" or "pending", as in the default block parameter.

QUANTITY - the uncle's index position.

params: [
   '0x29c', // 668
   '0x0' // 0
]

Returns

See eth_getBlockByHash

Note: An uncle doesn't contain individual transactions.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Request Body schema: */*
string

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/ethereum/rpc',
  headers: {'content-type': '*/*', 'Content-Type': 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "jsonrpc": "2.0",
  • "id": "1",
  • "result": {
    }
}

Polygon

Polygon > Info Requests

getLastBlockNumber

Get the latest block number

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/blocks/number',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getERC20

Get information about an ERC20 token

Authorizations:
apikeyAuth
path Parameters
erc20_token
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

ERC20 token address

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/erc20/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! ERC20 Token has been successfully parsed.",
  • "data": {
    }
}

getGasPrice

Get gas price

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/gasprice',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getPolygonBalance

Get the balance of an address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

Polygon address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/balances/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Ethereum address balance successfully parsed.",
  • "data": {
    }
}

getERC20Balance

Get the balance of an ERC20 address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

Polygon address

erc20_token
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/balances/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce/erc20/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Token Balance has been successfully parsed.",
  • "data": {
    }
}

getBlock

Get information of a specific block

Authorizations:
apikeyAuth
path Parameters
block
required
string
Example: 0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5

Polygon block number or hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/blocks/0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed the block.",
  • "data": [
    ]
}

getNFTUri

Get the URI of an NFT

Authorizations:
apikeyAuth
path Parameters
ft_contract
required
string
token_id
required
string
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/nfts/%7Bft_contract%7D/uri/%7Btoken_id%7D',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{}

getNFTOwner

Get the Owner of an NFT

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5

Polygon contract address

token_id
required
integer
Example: 374

Polygon token id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/nfts/0xd9186b67ae0d3ee0777a607eeb195c5a9fb0affcd78ddcd7481efae4b258c9f5/owner/374',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "NFT Owner has been successfully parsed.",
  • "data": {
    }
}

getTransaction

Get info about a transaction

You can choose if you want to get the Transaction encoded or decoded by add /decoded to your request. See examlpes for details

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/transactions/0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transactionReceipt",
  • "data": [
    ]
}

getTransactionReceipt

Get info about a transaction receipt

You can choose if you want to get the Transaction encoded or decoded by add /decoded to your request. See examlpes for details

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/transactions/0x0b361c13214a0d498b69d6ea86039fdf8e578f4b6e3b28db52a422f8ed3ea037/receipt/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transactionReceipt",
  • "data": [
    ]
}

Polygon > Address Requests

newAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Address was successfully created.",
  • "data": {
    }
}

listAddresses

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/addresses',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Addresses has been successfully parsed.",
  • "data": {
    }
}

deleteAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xfa343ee01667869cfb409b24ae33f7ce8b110eb0

Polygon address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/polygon/addresses/0xfa343ee01667869cfb409b24ae33f7ce8b110eb0',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Address has been successfully deleted.",
  • "data": {
    }
}

importAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "filename": "UTC--2020-09-19T10-42-26.196Z--71892889ed4d79d88ab6ea3783b571b8ece9bef4",
  • "content": {
    },
  • "password": "padN39QkRA2hJ"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum address has been successfully imported.",
  • "data": {
    }
}

exportAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xfa343ee01667869cfb409b24ae33f7ce8b110eb0

Polygon address

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum address has been successfully exported.",
  • "data": {
    }
}

ListTransactionsByAddress

Our API provides an endpoint for retrieving all transactions associated with a particular blockchain address. To use this endpoint, you will need to provide the wallet address as a parameter in the request.

Each page of results returned by this endpoint contains up to 100 entries, and you can use a paginator to navigate through the pages of results.

To use the paginator, you can include parameter in your request: "page" . The "page" parameter specifies which page of results to retrieve,

For example, to retrieve the first 100 transactions associated with a particular blockchain address, you would make a request to the following URL:

/addresses//transactions/1

If there are more than 100 transactions associated with the blockchain address, you can retrieve additional pages of results by incrementing the "page" parameter in your request. For example, to retrieve the next 100 transactions, you would make a request to the following URL:

/addresses//transactions/2

By using the paginator, you can retrieve all transactions associated with a particular blockchain address, regardless of the total number of transactions in the blockchain.

each request tells you the max pages within the Request in the max_pages field

"max_pages": 515

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5

account address

page
required
integer
Example: 1

Current page, see description for more informatiosn how pagination works

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/addresses/0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5/transactions/1'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Addresses has been successfully parsed.",
  • "data": {
    }
}

Polygon > Webhooks/IPN Requests

With webhooks, you can get notified about various events in the blockchain. E.g:

Receipt of payment to a specific address
Outgoing payment from a specific address
Exchange of sats between two specific addresses
Execution of a contract
Change of ownership of a token

For this you have to create a webhook with certain filter criteria. The following values are available as filter criteria:

from: Outgoing address
to: Incoming address
contract: Contract that should be monitored
tokenid: ID of a token that should be monitored.
type: Token type ([ETH', 'ERC20', 'ERC721', null)

Parameter "url" defines the url we are calling with a POST Request.. The request body will have your filter criterias and some additional informatiion about your transaction:

{
  "id": "63a1ae0887ca3625b82b4924",
  "webhook_id": "63a1ad0e87ca3625b82b4923",
  "from": "0x0000000000000000000000000000000000000000",
  "to": "0xa9d1e08c7793af67e9d92fe308d5697fb81d3e43",
  "blocknumber": "123",
  "datetime": "22-12-20 13:43:52",
  "tokenid": "0x0000000000000000000000000000000000000000",
  "type": null,
  "txid": "000000000000000000000000000000000000000000000000000",
  "amount": "000000000000000000000000000000000000000000000000000"
}

subscribeAddress

Creates a new subscription/IPN for the given address (and contractaddress). You will receive a notification to the given url every time a deposit is received. Unsubscribe the address before sending tokens/ETH from it or you won't get reliable notifications anymore.

You can choose one or more from following filter criterias

Parameter Description
from ethereum address
to ethereum address
contractaddress contract address
tokenid token id

You also need to dpecify the parameter "type". you can choose between ['ETH', 'ERC20', 'ERC721', null]

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully subscribed to IPN!.",
  • "data": {
    }
}

listSubscribedAddresses

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/webhooks',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPNs could be successfully parsed.",
  • "data": {
    }
}

unsubscribeAddress

Deletes an existing subscription/IPN for the given address (and contractaddress).

Authorizations:
apikeyAuth
path Parameters
webhook
required
string
Example: 626407c62e5e8235ca561dce

Webhook Id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/polygon/webhooks/626407c62e5e8235ca561dce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully unsubscribed to IPN!.",
  • "data": {
    }
}

listFailedIPNs

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
webhook
required
string
Example: 626407c62e5e8235ca561dce

Webhook Id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/webkhooks/626407c62e5e8235ca561dce/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "failed_ipns": [
    ]
}

listIPNsByWebhookId

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/polygon/webkhooks/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "failed_ipns": [
    ]
}

resendFailedIPN

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
notification_id
required
string
Example: 626407c62e5e8235ca561dce

Notification Id

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPN successfully got resent.",
  • "data": {
    }
}

Polygon > Transaction Requests

sendERC20

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "contractaddress": "0x55d398326f99059fF775485246999027B3197955",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": 0.1,
  • "password": "test123",
  • "gas": 0
}

sendERC721

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: */*
string

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/polygon/transactions/erc721',
  headers: {'content-type': '*/*', Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

sendTransaction

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": "0.1",
  • "password": "test123",
  • "gas": 0
}

broadcastTransaction

Broadcast raw transactions

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "data": "0xf86b0685012a05f20082520894dfa04096652804362e4b7ae31835416974271e298609184e72a000808194a086277b0f2d7df91c9ce580171cd7f7be6e2c298727944a13fb40e5e9406ccb61a076105cefee8def061024dfb333a1bd47f629b52aae6621d2f2f39a0dccc3ac85"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Transaction has been successfully broadcasted.",
  • "data": {
    }
}

Polygon > RPC API

getUncleByBlockNumberAndIndex

Returns information about a uncle of a block by number and uncle index position.

Parameters

QUANTITY|TAG - a block number, or the string "earliest", "latest" or "pending", as in the default block parameter.

QUANTITY - the uncle's index position.

params: [
   '0x29c', // 668
   '0x0' // 0
]

Returns

See eth_getBlockByHash

Note: An uncle doesn't contain individual transactions.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Request Body schema: */*
string

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/polygon/rpc',
  headers: {'content-type': '*/*', 'Content-Type': 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "jsonrpc": "2.0",
  • "id": "1",
  • "result": null
}

BinanceSmartChain

BinanceSmartChain > Info Requests

getLastBlocknumber

Get the latest block number

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/blocks/number',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getGasPrice

Get gas price

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/gasprice',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getBlock

Get information of a specific block

Authorizations:
apikeyAuth
path Parameters
block
required
integer
Example: 2000

Block number or hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/blocks/2000',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed the block.",
  • "data": [
    ]
}

getBinanceCoinBalance

Get the balance of an address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

BSC address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/balances/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Binancecoin address balance successfully parsed.",
  • "data": {
    }
}

getNFTUri

Get the URI of an NFT

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B

BSC contract address

token_id
required
integer
Example: 403706

Token Id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/nfts/0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B/uri/403706',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{}

getNFTOwner

Get the Owner of an NFT

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B

BSC contract address

token_id
required
integer
Example: 403706

Token id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/nfts/0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B/owner/403706',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "NFT Owner has been successfully parsed.",
  • "data": {
    }
}

getBEP20

Receive information of a BEP20 address

Authorizations:
apikeyAuth
path Parameters
contract
required
string
Example: 0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B

BSC contract address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/bep20/0xE6965B4F189DBDB2BD65e60aBAeb531B6fE9580B',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! BEP20 Token has been successfully parsed.",
  • "data": {
    }
}

getBEP20Balance

Get the balance of a BEP20 address

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xC3EBbE09c9cc4bF77A6F90687E5c292245Bc1090
contract
required
string
Example: 0x31471E0791fCdbE82fbF4C44943255e923F1b794
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/balances/0xC3EBbE09c9cc4bF77A6F90687E5c292245Bc1090/bep20/0x31471E0791fCdbE82fbF4C44943255e923F1b794',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Token Balance has been successfully parsed.",
  • "data": {
    }
}

getTransaction

Get info about a transaction

You can get your transaction decoded by add /decoded to your api call. If you want to get the transaction encoded, youst remove the /decoded part

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x59ca89ea05be9a9e83958404924a2ae450fe8e691b1aeedecf3a3645c6f64534

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/transactions/0x59ca89ea05be9a9e83958404924a2ae450fe8e691b1aeedecf3a3645c6f64534/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transaction.",
  • "data": [
    ]
}

getTransactionReceipt

Get info about a transaction receipt

You can get your transaction decoded by add /decoded to your api call. If you want to get the transaction encoded, youst remove the /decoded part

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: 0x59ca89ea05be9a9e83958404924a2ae450fe8e691b1aeedecf3a3645c6f64534

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/transactions/0x59ca89ea05be9a9e83958404924a2ae450fe8e691b1aeedecf3a3645c6f64534/receipt/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transactionReceipt",
  • "data": [
    ]
}

BinanceSmartChain > Address Requests

newAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! BSC Address was successfully created.",
  • "data": {
    }
}

listAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/addresses',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! BSC Addresses has been successfully parsed.",
  • "data": {
    }
}

deleteAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

BSC address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/bsc/addresses/0xa1f36016221d48ce7f15cde7b826a4fbe09bacce',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Address has been successfully deleted.",
  • "data": {
    }
}

importAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "filename": "UTC--2020-05-01T12-30-12.020Z--4fb45889cd2d3348348e39c613c41bf1dc43760a",
  • "content": {
    },
  • "password": "padN39QkRA2hJ"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! BSC address has been successfully imported.",
  • "data": {
    }
}

exportAddress

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xa1f36016221d48ce7f15cde7b826a4fbe09bacce

BSC address

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! BSC address has been successfully exported.",
  • "data": {
    }
}

ListTransactionsByAddress

Our API provides an endpoint for retrieving all transactions associated with a particular blockchain address. To use this endpoint, you will need to provide the wallet address as a parameter in the request.

Each page of results returned by this endpoint contains up to 100 entries, and you can use a paginator to navigate through the pages of results.

To use the paginator, you can include parameter in your request: "page" . The "page" parameter specifies which page of results to retrieve,

For example, to retrieve the first 100 transactions associated with a particular blockchain address, you would make a request to the following URL:

/addresses//transactions/1

If there are more than 100 transactions associated with the blockchain address, you can retrieve additional pages of results by incrementing the "page" parameter in your request. For example, to retrieve the next 100 transactions, you would make a request to the following URL:

/addresses//transactions/2

By using the paginator, you can retrieve all transactions associated with a particular blockchain address, regardless of the total number of transactions in the blockchain.

each request tells you the max pages within the Request in the max_pages field

"max_pages": 515

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: 0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5

account address

page
required
integer
Example: 1

Current page, see description for more informatiosn how pagination works

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/addresses/0xDAFEA492D9c6733ae3d56b7Ed1ADB60692c98Bc5/transactions/1'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Ethereum Addresses has been successfully parsed.",
  • "data": {
    }
}

BinanceSmartChain > Webhooks/IPN Requests

With webhooks, you can get notified about various events in the blockchain. E.g:

Receipt of payment to a specific address
Outgoing payment from a specific address
Exchange of sats between two specific addresses
Execution of a contract
Change of ownership of a token

For this you have to create a webhook with certain filter criteria. The following values are available as filter criteria:

from: Outgoing address
to: Incoming address
contract: Contract that should be monitored
tokenid: ID of a token that should be monitored.
type: Token type ([ETH', 'ERC20', 'ERC721', null)

Parameter "url" defines the url we are calling with a POST Request.. The request body will have your filter criterias and some additional informatiion about your transaction:

{
 "id": "63a1ae0887ca3625b82b4924",
  "webhook_id": "63a1ad0e87ca3625b82b4923",
  "from": "0x0000000000000000000000000000000000000000",
  "to": "0xa9d1e08c7793af67e9d92fe308d5697fb81d3e43",
  "blocknumber": "123",
  "datetime": "22-12-20 13:43:52",
  "tokenid": "0x0000000000000000000000000000000000000000",
  "type": null,
  "txid": "000000000000000000000000000000000000000000000000000",
  "amount": "000000000000000000000000000000000000000000000000000"
}

subscribeAddress

Creates a new subscription/IPN for the given address (and contractaddress). You will receive a notification to the given url every time a deposit is received. Unsubscribe the address before sending tokens/ETH from it or you won't get reliable notifications anymore.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully subscribed to IPN!.",
  • "data": {
    }
}

listSubscribedAddresses

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/webhooks',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPNs could be successfully parsed. But sadly you have no IPNs subscribed.",
  • "data": {
    }
}

unsubscribeAddress

Deletes an existing subscription/IPN for the given address (and contractaddress).

Authorizations:
apikeyAuth
path Parameters
webhook
required
string
Example: 624d7db34b026365cc22356b

Webhook id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/bsc/webhooks/624d7db34b026365cc22356b',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully unsubscribed to IPN!.",
  • "data": {
    }
}

listFailedIPNs

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bsc/webhooks/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPNs could be successfully parsed.",
  • "data": {
    }
}

resendFailedIPN

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
notification_id
required
string
Example: 62640817eb594da78c7bee00

Notification id

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "id": 17766
}

BinanceSmartChain > Transaction Requests

sendBEP20

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "contractaddress": "0x55d398326f99059fF775485246999027B3197955",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": "0.1",
  • "password": "test123",
  • "gas": 0
}

sendBEP721

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "contractaddress": "0x55d398326f99059fF775485246999027B3197955",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "tokenId": 123,
  • "password": "test123"
}

sendTransaction

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "0xa1f36016221d48ce7f15cde7b826a4fbe09bacce",
  • "to": "0xef4943d727e34280a2efa0b3352dfd61f508ee48",
  • "amount": "0.1",
  • "password": "test123"
}

broadcastTransaction

Broadcast raw transactions

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "data": "0xf86b0685012a05f20082520894dfa04096652804362e4b7ae31835416974271e298609184e72a000808194a086277b0f2d7df91c9ce580171cd7f7be6e2c298727944a13fb40e5e9406ccb61a076105cefee8def061024dfb333a1bd47f629b52aae6621d2f2f39a0dccc3ac85"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Transaction has been successfully broadcasted.",
  • "data": {
    }
}

BinanceSmartChain > RPC API

getUncleByBlockNumberAndIndex

Returns information about a uncle of a block by number and uncle index position.

Parameters

QUANTITY|TAG - a block number, or the string "earliest", "latest" or "pending", as in the default block parameter.

QUANTITY - the uncle's index position.

params: [
   '0x29c', // 668
   '0x0' // 0
]

Returns

See eth_getBlockByHash

Note: An uncle doesn't contain individual transactions.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Request Body schema: */*
string

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/bsc/rpc',
  headers: {'content-type': '*/*', 'Content-Type': 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "jsonrpc": "2.0",
  • "id": "1",
  • "result": null
}

Tron

Tron > Info Requests

getLastBlockNumber

Get the latest block number

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/blocks/number',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getBlock

Authorizations:
apikeyAuth
path Parameters
block
required
integer
Example: 300

Block number

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/blocks/300',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed the block.",
  • "data": [
    ]
}

getTransaction

You can get your transaction decoded by add /decoded to your api call. If you want to get the transaction encoded, youst remove the /decoded part

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: dab6bb52e098232a2f115d56419124df1463ae60ac4f2effdb59984c550d8fa9

Transaction hash

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/transactions/dab6bb52e098232a2f115d56419124df1463ae60ac4f2effdb59984c550d8fa9/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transaction data.",
  • "data": {
    }
}

getTransactionReceipt

You can get your transaction decoded by add /decoded to your api call. If you want to get the transaction encoded, youst remove the /decoded part

Authorizations:
apikeyAuth
path Parameters
transaction
required
string
Example: dab6bb52e098232a2f115d56419124df1463ae60ac4f2effdb59984c550d8fa9

Transaction hash

header Parameters
Accept
string
Example: application/json
Authorization
string
Example: APIKEY

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/transactions/dab6bb52e098232a2f115d56419124df1463ae60ac4f2effdb59984c550d8fa9/receipt/decoded',
  headers: {Accept: 'SOME_STRING_VALUE', Authorization: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
Example
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transaction data.",
  • "data": {
    }
}

getAccountResources

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt

Account address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/account/TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt/resources',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed account informations.",
  • "data": [
    ]
}

getChainParameters

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/chainparameters',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed chain parameters.",
  • "data": [
    ]
}

getTronBalance

Authorizations:
apikeyAuth
path Parameters
address
required
string
Example: TSU2h3XdoW53hNkts2dQoXbJSNP1uL4r7A

Account address

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/balances/TSU2h3XdoW53hNkts2dQoXbJSNP1uL4r7A',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Tron balance successfully parsed.",
  • "data": {
    }
}

getTRC10Balance

Authorizations:
apikeyAuth
path Parameters
account
required
string
Example: TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt

Account address

tokenId
required
integer
Example: 10020000

Token Id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/balances/TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt/trc10/10020000',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! TRC10 balance successfully parsed.",
  • "data": {
    }
}

getTRC20Balance

Authorizations:
apikeyAuth
path Parameters
account
required
string
Example: TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt

Account address

token
required
string
Example: TGTE9Eo4hrkotStM1iGHSKA7gobxZxPuwQ

Tron TRC20 token

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/balances/TVqA9huwk2NBUxbanUNx4NVPKXjzWZqkJt/trc20/TGTE9Eo4hrkotStM1iGHSKA7gobxZxPuwQ',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! TRC20 balance successfully parsed.",
  • "data": {
    }
}

Tron > Address Requests

newAddress

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
""

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Tron Address was successfully created.",
  • "data": [
    ]
}

Tron > Webhooks/IPN Requests

With webhooks, you can get notified about various events in the blockchain. E.g:

Receipt of payment to a specific address
Outgoing payment from a specific address
Exchange of sats between two specific addresses
Execution of a contract
Change of ownership of a token

For this you have to create a webhook with certain filter criteria. The following values are available as filter criteria:

from: Outgoing address
to: Incoming address
contract: Contract that should be monitored
tokenid: ID of a token that should be monitored.
type: Token type ([ETH', 'ERC20', 'ERC721', null)

Parameter "url" defines the url we are calling with a POST Request.. The request body will have your filter criterias and some additional informatiion about your transaction:

{
  "id": "63a1ae0887ca3625b82b4924",
  "webhook_id": "63a1ad0e87ca3625b82b4923",
  "from": "0x0000000000000000000000000000000000000000",
  "to": "0xa9d1e08c7793af67e9d92fe308d5697fb81d3e43",
  "blocknumber": "123",
  "datetime": "22-12-20 13:43:52",
  "tokenid": "0x0000000000000000000000000000000000000000",
  "type": null,
  "txid": "000000000000000000000000000000000000000000000000000",
  "amount": "000000000000000000000000000000000000000000000000000"
}

subscribeAddress

Creates a new subscription/IPN for the given address (and contractaddress). You will receive a notification to the given url every time a deposit is received. Unsubscribe the address before sending tokens/ETH from it or you won't get reliable notifications anymore.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully subscribed to IPN!.",
  • "data": {
    }
}

listSubscribedAddresses

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/webhooks',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! IPNs could be successfully parsed.",
  • "data": {}
}

unsubscribeAddress

Deletes an existing subscription/IPN for the given address (and contractaddress).

Authorizations:
apikeyAuth
path Parameters
webhookid
required
string
Example: 624d7db34b026365cc22356b

Webhook id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/tron/webhooks/624d7db34b026365cc22356b',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully unsubscribed to IPN!.",
  • "data": {
    }
}

listFailedIPNs

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/webhooks/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "failed_ipns": [
    ]
}

resendFailedIPN

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "id": 17766
}

Tron > Transaction Requests

sendTransaction

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "to": "TEZU8f2twTLYJ8XPfLrRAXNCNqVt5xtV1M",
  • "amount": "1",
  • "privatekey": "92a5a62fdf7290244b564450f4ab10a5ea796f234aa6aded322c826ad40efb9c"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Successfully sent transaction.",
  • "data": [
    ]
}

sendTRC10

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "TCEz54GwDkTDHs5n5uYzbW3YSHTCbpeduY",
  • "to": "TEZU8f2twTLYJ8XPfLrRAXNCNqVt5xtV1M",
  • "privatekey": "2db07c55d9fd48a14f7f13c7a0363302c0cb812c4374f3a03aea91b857250146",
  • "tokenId": 1002000,
  • "amount": "0.0001"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Successfully sent transaction.",
  • "data": [
    ]
}

sendTRC20

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "from": "TWAJgk7DWpfrd58d9J781ns9YQFXz9Df1G",
  • "to": "TKchW737Ji3nSJQoP3rBnzTXxMXQ7AqXjs",
  • "privatekey": "2db07c55d9fd48a14f7f13c7a0363302c0cb812c4374f3a03aea91b857250146",
  • "contractaddress": "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t",
  • "amount": "1"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Successfully sent transaction.",
  • "data": [
    ]
}

sendTRC721

Authorizations:
apikeyAuth
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
""

freeze

Authorizations:
apikeyAuth
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "tronaddress": "TPbJ4q2wZP2UpsE7ME3bxewS5pKAdWZwCj",
  • "privatekey": "92a5a62fdf7290244b564450f4ab10a5ea796f234aa6aded322c826ad40efb9c",
  • "duration": 3,
  • "resource": "ENERGY",
  • "amount": "0.0001"
}

Response samples

Content type
application/json
{
  • "ok": false,
  • "status": 422,
  • "message": "Error! Something went wrong while freezing balance",
  • "data": {
    }
}

unfreeze

Authorizations:
apikeyAuth
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "tronaddress": "TPbJ4q2wZP2UpsE7ME3bxewS5pKAdWZwCj",
  • "privatekey": "92a5a62fdf7290244b564450f4ab10a5ea796f234aa6aded322c826ad40efb9c",
  • "duration": 3,
  • "resource": "ENERGY",
  • "amount": "0.0001"
}

Response samples

Content type
application/json
{
  • "ok": false,
  • "status": 422,
  • "message": "Error! Something went wrong while unfreezing balance",
  • "data": {
    }
}

Tron > Wallet API

UnfreezeBalanceV2

Unstake some TRX staked in Stake2.0, release the corresponding amount of bandwidth or energy, and voting rights (TP)

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "unfreeze_balance": 1000000,
  • "resource": "BANDWIDTH",
  • "permission_id": "<integer>",
  • "visible": true
}

GetBurnTRX

Query the amount of TRX burned due to on-chain transaction fees since No. 54 Committee Proposal took effect

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getburntrx',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "burnTrxAmount": 6945804255977440
}

GetBlockByLimitNext

Returns the list of Block Objects included in the 'Block Height' range specified.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "startNum": 1,
  • "endNum": 5
}

Response samples

Content type
application/json
{
  • "block": [
    ]
}

WithdrawExpireUnfreeze

Withdraw unfrozen balance in Stake2.0, the user can call this API to get back their funds after executing /wallet/unfreezebalancev2 transaction and waiting N days, N is a network parameter

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "visible": true,
  • "permission_id": "<integer>"
}

GetBlockById

Query block by ID(block hash).

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "00000000000f424013e51b18e0782a32fa079ddafdb2f4c343468cf8896dc887"
}

Response samples

Content type
application/json
{
  • "blockID": "00000000031fb42a6769634a12d3348980847a674f3c57bbf601d47c532cfb50",
  • "block_header": {
    },
  • "transactions": [
    ]
}

GetTransactionInfoById

Query the transaction fee, block height by transaction id

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "7c2d4206c03a883dd9066d620335dc1be272a8dc733cfa3f6d10308faa37facc"
}

Response samples

Content type
application/json
{
  • "id": "dd7d909085c103f60b046e65132293902cdf2bf77635feec8c784863f0033cd7",
  • "blockNumber": 52409386,
  • "blockTimeStamp": 1687849428000,
  • "contractResult": [
    ],
  • "receipt": {
    }
}

ClearAbi

To clear the ABI info of a smart contract.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TSNEe5Tf4rnc9zPMNXfaTF5fZfHDDH8oyW",
  • "contract_address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "8caadf9a915b5ad843e0314f21e30f0f6203997598508af3b8d4eac01af6c5ed",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b4362208437d9ce386714d4a40f0d6d3dd8f315a630830125f0a2d747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e436c656172414249436f6e7472616374122e0a1541517591d35d313bf6a5e33098284502b045e2bc08121541a614f803b6fd780986a42c78ec9c7f77e6ded13c708292afdd8f31"
}

CreateTransaction

Create a TRX transfer transaction. If to_address does not exist, then create the account on the blockchain.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "to_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "amount": 1000,
  • "permission_id": "<integer>",
  • "visible": true,
  • "extra_data": "<string>"
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "6c03d57deda3f0b94001e3dd86c274aeeb4006e5b25e6e06261f6f5d31cc5867",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b44122081e8187cba9e660c540d8d8d5dd8f3152083c737472696e673e5a66080112620a2d747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5472616e73666572436f6e747261637412310a1541c686c48436aec3a1dfce4ac5a4526c39366985ba12154198927ffb9f554dc4a453c64b2e553a02d6df514b18e807709194b1dd8f31"
}

UnfreezeAsset

Unstake a token that has passed the minimum freeze duration.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "Error": "class org.tron.core.exception.ContractValidateException : no frozen supply balance"
}

UnDelegateResource

Cancel the delegation of bandwidth or energy resources to other accounts in Stake2.0

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "receiver_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "balance": 1000000,
  • "resource": "BANDWIDTH",
  • "visible": true,
  • "permission_id": "<integer>"
}

GetBlock

Query block header information or entire block information according to block height or block hash

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "id_or_num": "1000000",
  • "detail": false
}

Response samples

Content type
application/json
{
  • "blockID": "00000000000f424043f26367f461f6947fb4b8818df0aa6d6030e26a9d9add13",
  • "block_header": {
    }
}

DelegateResource

Delegate bandwidth or energy resources to other accounts in Stake2.0.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "receiver_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "balance": 1000000,
  • "resource": "BANDWIDTH",
  • "lock": false,
  • "visible": true,
  • "permission_id": "<integer>"
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "8248192993861a257dacd3f00d892d3f025ca123bfcef9b8b1d73fb925f7387c",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b4df220840c6d8c123b1a16940e8cff2dd8f315a6f0839126b0a35747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e44656c65676174655265736f75726365436f6e747261637412320a15418632237fd33f62c549ee044dd3da779aba947dcc18e0c65b221541d92c5b25db595b170b4f1a5081068b91684fa37870918ecedd8f31"
}

BroadcastTransaction

Broadcast the signed transaction

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "RAW_BODY": {
    }
}

GetNodeInfo

Query Node Information. Returns information about current state of node.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getnodeinfo',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "activeConnectCount": 8,
  • "beginSyncNum": 52409502,
  • "block": "Num:52409521,ID:00000000031fb4b10685b0546af3b7cfa1bd8c60dd4598bc247506ca9c90f1a2",
  • "cheatWitnessInfoMap": [ ],
  • "configNodeInfo": {
    },
  • "currentConnectCount": 8,
  • "machineInfo": {
    },
  • "passiveConnectCount": 0,
  • "peerList": [
    ],
  • "solidityBlock": "Num:52409503,ID:00000000031fb49f709f9768c313c767785dfc99e3ad19895f5b97900ae3da27",
  • "totalFlow": 0
}

GetContract

Queries a contract's information from the blockchain, including the bytecode of the contract, ABI, configuration parameters, etc.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "bytecode": "60806040526000600260146101000a81548160ff021916908315150217905550600060035560006004553480156200003657600080fd5b50d380156200004457600080fd5b50d280156200005257600080fd5b5060405162003bd738038062003bd78339810180604052810190808051906020019092919080518201929190602001805182019291906020018051906020019092919050505033600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550836008819055508260059080519060200190620000f8929190620001b7565b50816006908051906020019062000111929190620001b7565b5080600760006101000a81548160ff021916908360ff16021790555083600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000600a60146101000a81548160ff0219169083151502179055505050505062000266565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620001fa57805160ff19168380011785556200022b565b828001600101855582156200022b579182015b828111156200022a5782518255916020019190600101906200020d565b5b5090506200023a91906200023e565b5090565b6200026391905b808211156200025f57600081600090555060010162000245565b5090565b90565b61396180620002766000396000f3006080604052600436106101a1576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde03146101a65780630753c30c14610250578063095ea7b3146102ad5780630e136b191461032c5780630ecb93c01461037557806318160ddd146103d257806323b872dd1461041757806326976e3f146104b6578063313ce5671461052757806335390714146105725780633eaaf86b146105b75780633f4ba83a146105fc57806359bf1abe1461062d5780635c975abb146106a257806366188463146106eb57806370a082311461076a57806375dc7d8c146107db5780638456cb59146108365780638da5cb5b1461086757806395d89b41146108d8578063a9059cbb14610982578063b7a3446c14610a01578063c0324c7714610a72578063cc872b6614610ac3578063d73dd62314610b0a578063db006a7514610b89578063dd62ed3e14610bd0578063dd644f7214610c61578063e47d606014610ca6578063e4997dc514610d1b578063e5b5019a14610d78578063f2fde38b14610dbd578063f3bdc22814610e1a575b600080fd5b3480156101b257600080fd5b50d380156101bf57600080fd5b50d280156101cc57600080fd5b506101d5610e77565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156102155780820151818401526020810190506101fa565b50505050905090810190601f1680156102425780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561025c57600080fd5b50d3801561026957600080fd5b50d2801561027657600080fd5b506102ab600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f15565b005b3480156102b957600080fd5b50d380156102c657600080fd5b50d280156102d357600080fd5b50610312600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061106f565b604051808215151515815260200191505060405180910390f35b34801561033857600080fd5b50d3801561034557600080fd5b50d2801561035257600080fd5b5061035b6111f0565b604051808215151515815260200191505060405180910390f35b34801561038157600080fd5b50d3801561038e57600080fd5b50d2801561039b57600080fd5b506103d0600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611203565b005b3480156103de57600080fd5b50d380156103eb57600080fd5b50d280156103f857600080fd5b506104016112fd565b6040518082815260200191505060405180910390f35b34801561042357600080fd5b50d3801561043057600080fd5b50d2801561043d57600080fd5b5061049c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506113e5565b604051808215151515815260200191505060405180910390f35b3480156104c257600080fd5b50d380156104cf57600080fd5b50d280156104dc57600080fd5b506104e56115f5565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561053357600080fd5b50d3801561054057600080fd5b50d2801561054d57600080fd5b5061055661161b565b604051808260ff1660ff16815260200191505060405180910390f35b34801561057e57600080fd5b50d3801561058b57600080fd5b50d2801561059857600080fd5b506105a161162e565b6040518082815260200191505060405180910390f35b3480156105c357600080fd5b50d380156105d057600080fd5b50d280156105dd57600080fd5b506105e6611634565b6040518082815260200191505060405180910390f35b34801561060857600080fd5b50d3801561061557600080fd5b50d2801561062257600080fd5b5061062b61163a565b005b34801561063957600080fd5b50d3801561064657600080fd5b50d2801561065357600080fd5b50610688600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506116fa565b604051808215151515815260200191505060405180910390f35b3480156106ae57600080fd5b50d380156106bb57600080fd5b50d280156106c857600080fd5b506106d1611750565b604051808215151515815260200191505060405180910390f35b3480156106f757600080fd5b50d3801561070457600080fd5b50d2801561071157600080fd5b50610750600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611763565b604051808215151515815260200191505060405180910390f35b34801561077657600080fd5b50d3801561078357600080fd5b50d2801561079057600080fd5b506107c5600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506118e4565b6040518082815260200191505060405180910390f35b3480156107e757600080fd5b50d380156107f457600080fd5b50d2801561080157600080fd5b5061082060048036038101908080359060200190929190505050611a0b565b6040518082815260200191505060405180910390f35b34801561084257600080fd5b50d3801561084f57600080fd5b50d2801561085c57600080fd5b50610865611a52565b005b34801561087357600080fd5b50d3801561088057600080fd5b50d2801561088d57600080fd5b50610896611b13565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156108e457600080fd5b50d380156108f157600080fd5b50d280156108fe57600080fd5b50610907611b39565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561094757808201518184015260208101905061092c565b50505050905090810190601f1680156109745780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561098e57600080fd5b50d3801561099b57600080fd5b50d280156109a857600080fd5b506109e7600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611bd7565b604051808215151515815260200191505060405180910390f35b348015610a0d57600080fd5b50d38015610a1a57600080fd5b50d28015610a2757600080fd5b50610a5c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611db1565b6040518082815260200191505060405180910390f35b348015610a7e57600080fd5b50d38015610a8b57600080fd5b50d28015610a9857600080fd5b50610ac16004803603810190808035906020019092919080359060200190929190505050611dde565b005b348015610acf57600080fd5b50d38015610adc57600080fd5b50d28015610ae957600080fd5b50610b0860048036038101908080359060200190929190505050611ed4565b005b348015610b1657600080fd5b50d38015610b2357600080fd5b50d28015610b3057600080fd5b50610b6f600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506120e4565b604051808215151515815260200191505060405180910390f35b348015610b9557600080fd5b50d38015610ba257600080fd5b50d28015610baf57600080fd5b50610bce60048036038101908080359060200190929190505050612265565b005b348015610bdc57600080fd5b50d38015610be957600080fd5b50d28015610bf657600080fd5b50610c4b600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612475565b6040518082815260200191505060405180910390f35b348015610c6d57600080fd5b50d38015610c7a57600080fd5b50d28015610c8757600080fd5b50610c906125d2565b6040518082815260200191505060405180910390f35b348015610cb257600080fd5b50d38015610cbf57600080fd5b50d28015610ccc57600080fd5b50610d01600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125d8565b604051808215151515815260200191505060405180910390f35b348015610d2757600080fd5b50d38015610d3457600080fd5b50d28015610d4157600080fd5b50610d76600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125f8565b005b348015610d8457600080fd5b50d38015610d9157600080fd5b50d28015610d9e57600080fd5b50610da76126f2565b6040518082815260200191505060405180910390f35b348015610dc957600080fd5b50d38015610dd657600080fd5b50d28015610de357600080fd5b50610e18600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612716565b005b348015610e2657600080fd5b50d38015610e3357600080fd5b50d28015610e4057600080fd5b50610e75600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061286e565b005b60058054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610f0d5780601f10610ee257610100808354040283529160200191610f0d565b820191906000526020600020905b815481529060010190602001808311610ef057829003601f168201915b505050505081565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610f7157600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614151515610fad57600080fd5b6001600a60146101000a81548160ff02191690831515021790555080600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055507fcc358699805e9a8b7f77b522628c7cb9abd07d9efb86b6fb616af1609036a99e81604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a150565b6000600260149054906101000a900460ff1615151561108d57600080fd5b600a60149054906101000a900460ff16156111dd57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663aee92d333385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561119b57600080fd5b505af11580156111af573d6000803e3d6000fd5b505050506040513d60208110156111c557600080fd5b810190808051906020019092919050505090506111ea565b6111e783836129e0565b90505b92915050565b600a60149054906101000a900460ff1681565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561125f57600080fd5b6001600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508073ffffffffffffffffffffffffffffffffffffffff167f42e160154868087d6bfdc0ca23d96a1c1cfa32f1b72ba9ba27b69b98a0d819dc60405160405180910390a250565b6000600a60149054906101000a900460ff16156113dc57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15801561139a57600080fd5b505af11580156113ae573d6000803e3d6000fd5b505050506040513d60208110156113c457600080fd5b810190808051906020019092919050505090506113e2565b60085490505b90565b6000600260149054906101000a900460ff1615151561140357600080fd5b600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615151561145c57600080fd5b600a60149054906101000a900460ff16156115e057600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638b477adb338686866040518563ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001945050505050602060405180830381600087803b15801561159e57600080fd5b505af11580156115b2573d6000803e3d6000fd5b505050506040513d60208110156115c857600080fd5b810190808051906020019092919050505090506115ee565b6115eb848484612ad2565b90505b9392505050565b600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600760009054906101000a900460ff1681565b60045481565b60085481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561169657600080fd5b600260149054906101000a900460ff1615156116b157600080fd5b6000600260146101000a81548160ff0219169083151502179055507f7805862f689e2f13df9f062ff482ad3ad112aca9e0847911ed832e158c525b3360405160405180910390a1565b6000600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b600260149054906101000a900460ff1681565b6000600260149054906101000a900460ff1615151561178157600080fd5b600a60149054906101000a900460ff16156118d157600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636001279f3385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561188f57600080fd5b505af11580156118a3573d6000803e3d6000fd5b505050506040513d60208110156118b957600080fd5b810190808051906020019092919050505090506118de565b6118db83836130be565b90505b92915050565b6000600a60149054906101000a900460ff16156119fa57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231836040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b1580156119b857600080fd5b505af11580156119cc573d6000803e3d6000fd5b505050506040513d60208110156119e257600080fd5b81019080805190602001909291905050509050611a06565b611a038261334f565b90505b919050565b600080611a37612710611a296003548661339790919063ffffffff16565b6133d290919063ffffffff16565b9050600454811115611a495760045490505b80915050919050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611aae57600080fd5b600260149054906101000a900460ff16151515611aca57600080fd5b6001600260146101000a81548160ff0219169083151502179055507f6985a02210a168e66602d3235cb6db0e70f92b3ba4d376a33c0f3d9434bff62560405160405180910390a1565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60068054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611bcf5780601f10611ba457610100808354040283529160200191611bcf565b820191906000526020600020905b815481529060010190602001808311611bb257829003601f168201915b505050505081565b6000600260149054906101000a900460ff16151515611bf557600080fd5b600960003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151515611c4e57600080fd5b600a60149054906101000a900460ff1615611d9e57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e18980a3385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b158015611d5c57600080fd5b505af1158015611d70573d6000803e3d6000fd5b505050506040513d6020811015611d8657600080fd5b81019080805190602001909291905050509050611dab565b611da883836133ed565b90505b92915050565b6000600a60149054906101000a900460ff1615611dd857611dd18261334f565b9050611dd9565b5b919050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611e3a57600080fd5b601482101515611e4957600080fd5b603281101515611e5857600080fd5b81600381905550611e87600760009054906101000a900460ff1660ff16600a0a8261339790919063ffffffff16565b6004819055507fb044a1e409eac5c48e5af22d4af52670dd1a99059537a78b31b48c6500a6354e600354600454604051808381526020018281526020019250505060405180910390a15050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611f3057600080fd5b611fa381600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061201c8160085461345c90919063ffffffff16565b6008819055507fcb8241adb0c3fdb35b70c24ce35c5eb0c17af7431c99f827d44a445ca624176a816040518082815260200191505060405180910390a1600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a350565b6000600260149054906101000a900460ff1615151561210257600080fd5b600a60149054906101000a900460ff161561225257600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a95381573385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561221057600080fd5b505af1158015612224573d6000803e3d6000fd5b505050506040513d602081101561223a57600080fd5b8101908080519060200190929190505050905061225f565b61225c838361347a565b90505b92915050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156122c157600080fd5b6122d68160085461367690919063ffffffff16565b60088190555061234f81600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f702d5967f45f6513a38ffc42d6ba9bf230bd40e8f53b16363c7eb4fd2deb9a44816040518082815260200191505060405180910390a1600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a350565b6000600a60149054906101000a900460ff16156125bf57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050602060405180830381600087803b15801561257d57600080fd5b505af1158015612591573d6000803e3d6000fd5b505050506040513d60208110156125a757600080fd5b810190808051906020019092919050505090506125cc565b6125c9838361368f565b90505b92915050565b60035481565b60096020528060005260406000206000915054906101000a900460ff1681565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561265457600080fd5b6000600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508073ffffffffffffffffffffffffffffffffffffffff167fd7e9ec6e6ecd65492dce6bf513cd6867560d49544421d0783ddf06e76c24470c60405160405180910390a250565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561277257600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156127ae57600080fd5b8073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156128cc57600080fd5b600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151561292457600080fd5b61292d826118e4565b905060008060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506129888160085461367690919063ffffffff16565b6008819055508173ffffffffffffffffffffffffffffffffffffffff167f61e6e66b0d6339b2980aecc6ccc0039736791f0ccde9ed512e789a7fbdd698c6826040518082815260200191505060405180910390a25050565b600081600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60008060008073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614151515612b1257600080fd5b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548411151515612b5f57600080fd5b600160008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548411151515612bea57600080fd5b612bf384611a0b565b9150612c08828561367690919063ffffffff16565b9050612c5b846000808973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b6000808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612cee816000808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015612ee457612e6384600160008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a360008211156130b157612fc582600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a35b6001925050509392505050565b600080600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050808311156131cf576000600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550613263565b6131e2838261367690919063ffffffff16565b600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546040518082815260200191505060405180910390a3600191505092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60008060008414156133ac57600091506133cb565b82840290508284828115156133bd57fe5b041415156133c757fe5b8091505b5092915050565b60008082848115156133e057fe5b0490508091505092915050565b60008060006133fb84611a0b565b9150613410828561367690919063ffffffff16565b905061341c8582613716565b50600082111561345457613452600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1683613716565b505b505092915050565b600080828401905083811015151561347057fe5b8091505092915050565b600061350b82600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546040518082815260200191505060405180910390a36001905092915050565b600082821115151561368457fe5b818303905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b60008073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415151561375357600080fd5b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205482111515156137a057600080fd5b6137f1826000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550613884826000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a360019050929150505600a165627a7a72305820ebc7abb2eb78f3b47e72fe9da09012eb7735aa2af8f739851b7e93bb4f8f813400290000000000000000000000000000000000000000000000000000000000989680000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a546574686572205553440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045553445400000000000000000000000000000000000000000000000000000000",
  • "consume_user_resource_percent": 30,
  • "name": "TetherToken",
  • "origin_address": "THPvaUhoh2Qn2y9THCZML3H815hhFhn5YC",
  • "abi": {
    },
  • "origin_energy_limit": 10000000,
  • "contract_address": "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t",
  • "code_hash": "99bb60e56b4cd2642c6847e372b18b6e0f9514229e3086d3a042d60a4c7b78a9"
}

GetDelegatedResourceAccountIndexV2

In Stake2.0, query the resource delegation index by an account. Two lists will return, one is the list of addresses the account has delegated its resources(toAddress), and the other is the list of addresses that have delegated resources to the account(fromAddress).

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "account": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1"
}

ValidateAddress

Validates address, returns either true or false.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "result": true,
  • "message": "Base58check format"
}

GetBlockByLatestNum

Returns a list of block objects.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "num": 5
}

Response samples

Content type
application/json
{
  • "block": [
    ]
}

GetAssetIssueByName

Query a token by name, returns token info.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "62747474657374"
}

GetAccountBalance

Get the account balance in a specific block.(Note: At present, the interface data can only be queried through the following official nodes 13.228.119.63 & 18.139.193.235 & 18.141.79.38 & 18.139.248.26)

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "account_identifier": "{ \"address\": \"TLLM21wteSPs4hKjbxgmH1L6poyMjeTbHm\" }",
  • "block_identifier": "{ \"hash\": \"0000000000010c4a732d1e215e87466271e425c86945783c3d3f122bfa5affd9\", \"number\": 68682 }",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "balance": 0,
  • "block_identifier": {
    }
}

TriggerSmartContract

Returns TransactionExtention, which contains the unsigned Transaction

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "contract_address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "function_selector": "transfer(address,uint256)",
  • "parameter": "00000000000000000000004115208EF33A926919ED270E2FA61367B2DA3753DA0000000000000000000000000000000000000000000000000000000000000032",
  • "fee_limit": 1000000000,
  • "call_value": 0,
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "result": {
    },
  • "transaction": {
    }
}

GetBlockBalance

Get all balance change operations in a block.(Note: At present, the interface data can only be queried through the following official nodes 13.228.119.63 & 18.139.193.235&18.141.79.38 &18.139.248.26)

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "hash": "0000000001f5b9ca67c722d9263879696c92e8e383d4f0b31c15a91b8a249029",
  • "number": 32881098,
  • "visible": true
}

Response samples

Content type
application/json
{
  • "Error": "class org.tron.core.exception.ItemNotFoundException : This block does not exist"
}

FreezeBalanceV2

In Stake2.0, stake an amount of TRX to obtain bandwidth or energy, and obtain equivalent TRON Power(TP) according to the staked amount

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "frozen_balance": 10000000,
  • "resource": "ENERGY",
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "2ee88bd87da28458389dde60476ac44e335ca3852131cce731fa80d1c0f1b85d",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b5942208c04f564559f3e67f4080e293de8f315a5a083612560a34747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e467265657a6542616c616e63655632436f6e7472616374121e0a154148f49cd5523d2807b45ccb7342cbadd8f8b623351080ade20418017093a0efdd8f31"
}

GetAccountResource

Query the resource information of an account(bandwidth,energy,etc)

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "freeNetLimit": 1500,
  • "TotalNetLimit": 43200000000,
  • "TotalNetWeight": 35951243026,
  • "TotalEnergyLimit": 90000000000,
  • "TotalEnergyWeight": 5289765243
}

ListNodes

Query the list of nodes connected to the API node

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/listnodes',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "nodes": [
    ]
}

GetNowBlock

Query the latest block information

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'POST',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getnowblock',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "blockID": "00000000031fb5b309e5bb30ac5b260453e8886827c0f2858adf754c83f354f3",
  • "block_header": {
    },
  • "transactions": [
    ]
}

GetAssetIssueById

Query a token by token id. Returns the token object, which contains the token name.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": 1000001
}

Response samples

Content type
application/json
{
  • "owner_address": "414d1ef8673f916debb7e2515a8f3ecaf2611034aa",
  • "name": "53454544",
  • "abbr": "53454544",
  • "total_supply": 100000000000,
  • "trx_num": 1000000,
  • "num": 1,
  • "start_time": 1529987043000,
  • "end_time": 1530342060000,
  • "description": "536573616d657365656420746f6b656e7320666f7220636f6d6d756e697479207265776172647320616e6420534545446765726d696e61746f7220696e766573746d656e74206f6620636f6d6d756e6974792d766f7465642070726f6a656374732e",
  • "url": "687474703a2f2f7777772e736573616d65736565642e6f7267",
  • "id": "1000001"
}

GetChainParameters

All parameters that the blockchain committee can set

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getchainparameters',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "chainParameter": [
    ]
}

GetAccountNet

Query bandwidth information.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "freeNetLimit": 1500,
  • "TotalNetLimit": 43200000000,
  • "TotalNetWeight": 35951243020
}

GetTransactionById

Query transaction information by transaction id.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "7c2d4206c03a883dd9066d620335dc1be272a8dc733cfa3f6d10308faa37facc",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "ret": [
    ],
  • "signature": [
    ],
  • "txID": "62372e30584baebdd943faf4bb80826edac7df90a75d38bd39bf63969f9da873",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02af48220884d5c2d12b669dcf4080d2cbdb8f315a65080112610a2d747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5472616e73666572436f6e747261637412300a1541233a7af3bb346b41109929521688fe46360d839212154148f49cd5523d2807b45ccb7342cbadd8f8b62335180170ae95c8db8f31"
}

GetDelegatedResourceAccountIndex

Query the resource delegation by an account during stake1.0 phase. i.e. list all addresses that have delegated resources to an account.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "account": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g"
}

GetEnergyPrices

Query historical energy unit price

Authorizations:
apikeyAuth

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getenergyprices'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "prices": "0:100,1542607200000:20,1544724000000:10,1606240800000:40,1613044800000:140,1635422400000:280,1670133600000:420"
}

UpdateSetting

Update the consume_user_resource_percent parameter of a smart contract

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TSNEe5Tf4rnc9zPMNXfaTF5fZfHDDH8oyW",
  • "contract_address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "consume_user_resource_percent": 10,
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "66a00a03666093825ac3e3bdc2cd9a7bd144bd0e3ac2f2ce8c085b1a6a5429bb",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b5c22208696e68cf1d1460de4090989cde8f315a6a082112660a32747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e55706461746553657474696e67436f6e747261637412300a1541517591d35d313bf6a5e33098284502b045e2bc08121541a614f803b6fd780986a42c78ec9c7f77e6ded13c180a70a9e0f7dd8f31"
}

UpdateEnergyLimit

Update the origin_energy_limit parameter of a smart contract

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TSNEe5Tf4rnc9zPMNXfaTF5fZfHDDH8oyW",
  • "contract_address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "origin_energy_limit": 100000000,
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "d361c0e522bb21ce2dba77b2303e4d8a4dda451f222c475755343ec6a2308971",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b5c8220855c554af6e41cb7c40e0a49dde8f315a71082d126d0a36747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e557064617465456e657267794c696d6974436f6e747261637412330a1541517591d35d313bf6a5e33098284502b045e2bc08121541a614f803b6fd780986a42c78ec9c7f77e6ded13c1880c2d72f708edef8dd8f31"
}

GetBlockByNum

Returns the Block Object corresponding to the 'Block Height' specified (number of blocks preceding it).

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "num": 200
}

Response samples

Content type
application/json
{
  • "blockID": "00000000000000c82a54a3bbdc956e1ddebc903f29b8daf28505b56f55a3f87d",
  • "block_header": {
    }
}

GetBandwidthPrices

Query historical bandwidth unit price

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/tron/wallet/getbandwidthprices',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "prices": "0:10,1606240800000:40,1613044800000:140,1627279200000:1000"
}

GetCanWithdrawUnfreezeAmount

Query the withdrawable balance at the specified timestamp In Stake2.0

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "timestamp": 1667977444000,
  • "visible": true
}

Response samples

Content type
application/json
[ ]

GetAvailableUnfreezeCount

Remaining times of executing unstake operation in Stake2.0

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "visible": true
}

GetCanDelegatedMaxSize

In Stake2.0, query the amount of delegatable resources share of the specified resource type for an address, unit is sun.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "type": 0,
  • "visible": true
}

GetDelegatedResource

Returns all resources delegations during stake1.0 phase from an account to another account. The fromAddress can be retrieved from the GetDelegatedResourceAccountIndex API.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "fromAddress": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "toAddress": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "visible": true
}

TriggerConstantContract

Invoke the readonly function (modified by the view or pure modifier) of a contract for contract data query; or Invoke the non-readonly function of a contract for predicting whether the transaction can be successfully executed or estimating the energy consumption

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TZ4UXDV5ZhNW7fb2AMSbgfAEZ7hWsnYS2g",
  • "contract_address": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "function_selector": "balanceOf(address)",
  • "parameter": "000000000000000000000000a614f803b6fd780986a42c78ec9c7f77e6ded13c",
  • "call_value": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "result": {
    },
  • "energy_used": 919,
  • "constant_result": [
    ],
  • "energy_penalty": 479,
  • "transaction": {
    }
}

GetContractInfo

Queries a contract's information from the blockchain. The difference from the wallet/getcontract interface is that this interface returns not only the bytecode but also the runtime bytecode of the contract. Compared with bytecode, runtime bytecode does not contain constructor and constructor parameter information.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "value": "TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "runtimecode": "6080604052600436106101a1576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde03146101a65780630753c30c14610250578063095ea7b3146102ad5780630e136b191461032c5780630ecb93c01461037557806318160ddd146103d257806323b872dd1461041757806326976e3f146104b6578063313ce5671461052757806335390714146105725780633eaaf86b146105b75780633f4ba83a146105fc57806359bf1abe1461062d5780635c975abb146106a257806366188463146106eb57806370a082311461076a57806375dc7d8c146107db5780638456cb59146108365780638da5cb5b1461086757806395d89b41146108d8578063a9059cbb14610982578063b7a3446c14610a01578063c0324c7714610a72578063cc872b6614610ac3578063d73dd62314610b0a578063db006a7514610b89578063dd62ed3e14610bd0578063dd644f7214610c61578063e47d606014610ca6578063e4997dc514610d1b578063e5b5019a14610d78578063f2fde38b14610dbd578063f3bdc22814610e1a575b600080fd5b3480156101b257600080fd5b50d380156101bf57600080fd5b50d280156101cc57600080fd5b506101d5610e77565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156102155780820151818401526020810190506101fa565b50505050905090810190601f1680156102425780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561025c57600080fd5b50d3801561026957600080fd5b50d2801561027657600080fd5b506102ab600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f15565b005b3480156102b957600080fd5b50d380156102c657600080fd5b50d280156102d357600080fd5b50610312600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061106f565b604051808215151515815260200191505060405180910390f35b34801561033857600080fd5b50d3801561034557600080fd5b50d2801561035257600080fd5b5061035b6111f0565b604051808215151515815260200191505060405180910390f35b34801561038157600080fd5b50d3801561038e57600080fd5b50d2801561039b57600080fd5b506103d0600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611203565b005b3480156103de57600080fd5b50d380156103eb57600080fd5b50d280156103f857600080fd5b506104016112fd565b6040518082815260200191505060405180910390f35b34801561042357600080fd5b50d3801561043057600080fd5b50d2801561043d57600080fd5b5061049c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506113e5565b604051808215151515815260200191505060405180910390f35b3480156104c257600080fd5b50d380156104cf57600080fd5b50d280156104dc57600080fd5b506104e56115f5565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561053357600080fd5b50d3801561054057600080fd5b50d2801561054d57600080fd5b5061055661161b565b604051808260ff1660ff16815260200191505060405180910390f35b34801561057e57600080fd5b50d3801561058b57600080fd5b50d2801561059857600080fd5b506105a161162e565b6040518082815260200191505060405180910390f35b3480156105c357600080fd5b50d380156105d057600080fd5b50d280156105dd57600080fd5b506105e6611634565b6040518082815260200191505060405180910390f35b34801561060857600080fd5b50d3801561061557600080fd5b50d2801561062257600080fd5b5061062b61163a565b005b34801561063957600080fd5b50d3801561064657600080fd5b50d2801561065357600080fd5b50610688600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506116fa565b604051808215151515815260200191505060405180910390f35b3480156106ae57600080fd5b50d380156106bb57600080fd5b50d280156106c857600080fd5b506106d1611750565b604051808215151515815260200191505060405180910390f35b3480156106f757600080fd5b50d3801561070457600080fd5b50d2801561071157600080fd5b50610750600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611763565b604051808215151515815260200191505060405180910390f35b34801561077657600080fd5b50d3801561078357600080fd5b50d2801561079057600080fd5b506107c5600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506118e4565b6040518082815260200191505060405180910390f35b3480156107e757600080fd5b50d380156107f457600080fd5b50d2801561080157600080fd5b5061082060048036038101908080359060200190929190505050611a0b565b6040518082815260200191505060405180910390f35b34801561084257600080fd5b50d3801561084f57600080fd5b50d2801561085c57600080fd5b50610865611a52565b005b34801561087357600080fd5b50d3801561088057600080fd5b50d2801561088d57600080fd5b50610896611b13565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156108e457600080fd5b50d380156108f157600080fd5b50d280156108fe57600080fd5b50610907611b39565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561094757808201518184015260208101905061092c565b50505050905090810190601f1680156109745780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561098e57600080fd5b50d3801561099b57600080fd5b50d280156109a857600080fd5b506109e7600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611bd7565b604051808215151515815260200191505060405180910390f35b348015610a0d57600080fd5b50d38015610a1a57600080fd5b50d28015610a2757600080fd5b50610a5c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611db1565b6040518082815260200191505060405180910390f35b348015610a7e57600080fd5b50d38015610a8b57600080fd5b50d28015610a9857600080fd5b50610ac16004803603810190808035906020019092919080359060200190929190505050611dde565b005b348015610acf57600080fd5b50d38015610adc57600080fd5b50d28015610ae957600080fd5b50610b0860048036038101908080359060200190929190505050611ed4565b005b348015610b1657600080fd5b50d38015610b2357600080fd5b50d28015610b3057600080fd5b50610b6f600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506120e4565b604051808215151515815260200191505060405180910390f35b348015610b9557600080fd5b50d38015610ba257600080fd5b50d28015610baf57600080fd5b50610bce60048036038101908080359060200190929190505050612265565b005b348015610bdc57600080fd5b50d38015610be957600080fd5b50d28015610bf657600080fd5b50610c4b600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612475565b6040518082815260200191505060405180910390f35b348015610c6d57600080fd5b50d38015610c7a57600080fd5b50d28015610c8757600080fd5b50610c906125d2565b6040518082815260200191505060405180910390f35b348015610cb257600080fd5b50d38015610cbf57600080fd5b50d28015610ccc57600080fd5b50610d01600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125d8565b604051808215151515815260200191505060405180910390f35b348015610d2757600080fd5b50d38015610d3457600080fd5b50d28015610d4157600080fd5b50610d76600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125f8565b005b348015610d8457600080fd5b50d38015610d9157600080fd5b50d28015610d9e57600080fd5b50610da76126f2565b6040518082815260200191505060405180910390f35b348015610dc957600080fd5b50d38015610dd657600080fd5b50d28015610de357600080fd5b50610e18600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612716565b005b348015610e2657600080fd5b50d38015610e3357600080fd5b50d28015610e4057600080fd5b50610e75600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061286e565b005b60058054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610f0d5780601f10610ee257610100808354040283529160200191610f0d565b820191906000526020600020905b815481529060010190602001808311610ef057829003601f168201915b505050505081565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610f7157600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614151515610fad57600080fd5b6001600a60146101000a81548160ff02191690831515021790555080600a60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055507fcc358699805e9a8b7f77b522628c7cb9abd07d9efb86b6fb616af1609036a99e81604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a150565b6000600260149054906101000a900460ff1615151561108d57600080fd5b600a60149054906101000a900460ff16156111dd57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663aee92d333385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561119b57600080fd5b505af11580156111af573d6000803e3d6000fd5b505050506040513d60208110156111c557600080fd5b810190808051906020019092919050505090506111ea565b6111e783836129e0565b90505b92915050565b600a60149054906101000a900460ff1681565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561125f57600080fd5b6001600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508073ffffffffffffffffffffffffffffffffffffffff167f42e160154868087d6bfdc0ca23d96a1c1cfa32f1b72ba9ba27b69b98a0d819dc60405160405180910390a250565b6000600a60149054906101000a900460ff16156113dc57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15801561139a57600080fd5b505af11580156113ae573d6000803e3d6000fd5b505050506040513d60208110156113c457600080fd5b810190808051906020019092919050505090506113e2565b60085490505b90565b6000600260149054906101000a900460ff1615151561140357600080fd5b600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615151561145c57600080fd5b600a60149054906101000a900460ff16156115e057600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638b477adb338686866040518563ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001945050505050602060405180830381600087803b15801561159e57600080fd5b505af11580156115b2573d6000803e3d6000fd5b505050506040513d60208110156115c857600080fd5b810190808051906020019092919050505090506115ee565b6115eb848484612ad2565b90505b9392505050565b600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600760009054906101000a900460ff1681565b60045481565b60085481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561169657600080fd5b600260149054906101000a900460ff1615156116b157600080fd5b6000600260146101000a81548160ff0219169083151502179055507f7805862f689e2f13df9f062ff482ad3ad112aca9e0847911ed832e158c525b3360405160405180910390a1565b6000600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b600260149054906101000a900460ff1681565b6000600260149054906101000a900460ff1615151561178157600080fd5b600a60149054906101000a900460ff16156118d157600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636001279f3385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561188f57600080fd5b505af11580156118a3573d6000803e3d6000fd5b505050506040513d60208110156118b957600080fd5b810190808051906020019092919050505090506118de565b6118db83836130be565b90505b92915050565b6000600a60149054906101000a900460ff16156119fa57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231836040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b1580156119b857600080fd5b505af11580156119cc573d6000803e3d6000fd5b505050506040513d60208110156119e257600080fd5b81019080805190602001909291905050509050611a06565b611a038261334f565b90505b919050565b600080611a37612710611a296003548661339790919063ffffffff16565b6133d290919063ffffffff16565b9050600454811115611a495760045490505b80915050919050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611aae57600080fd5b600260149054906101000a900460ff16151515611aca57600080fd5b6001600260146101000a81548160ff0219169083151502179055507f6985a02210a168e66602d3235cb6db0e70f92b3ba4d376a33c0f3d9434bff62560405160405180910390a1565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60068054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611bcf5780601f10611ba457610100808354040283529160200191611bcf565b820191906000526020600020905b815481529060010190602001808311611bb257829003601f168201915b505050505081565b6000600260149054906101000a900460ff16151515611bf557600080fd5b600960003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151515611c4e57600080fd5b600a60149054906101000a900460ff1615611d9e57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e18980a3385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b158015611d5c57600080fd5b505af1158015611d70573d6000803e3d6000fd5b505050506040513d6020811015611d8657600080fd5b81019080805190602001909291905050509050611dab565b611da883836133ed565b90505b92915050565b6000600a60149054906101000a900460ff1615611dd857611dd18261334f565b9050611dd9565b5b919050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611e3a57600080fd5b601482101515611e4957600080fd5b603281101515611e5857600080fd5b81600381905550611e87600760009054906101000a900460ff1660ff16600a0a8261339790919063ffffffff16565b6004819055507fb044a1e409eac5c48e5af22d4af52670dd1a99059537a78b31b48c6500a6354e600354600454604051808381526020018281526020019250505060405180910390a15050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611f3057600080fd5b611fa381600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061201c8160085461345c90919063ffffffff16565b6008819055507fcb8241adb0c3fdb35b70c24ce35c5eb0c17af7431c99f827d44a445ca624176a816040518082815260200191505060405180910390a1600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a350565b6000600260149054906101000a900460ff1615151561210257600080fd5b600a60149054906101000a900460ff161561225257600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a95381573385856040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b15801561221057600080fd5b505af1158015612224573d6000803e3d6000fd5b505050506040513d602081101561223a57600080fd5b8101908080519060200190929190505050905061225f565b61225c838361347a565b90505b92915050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156122c157600080fd5b6122d68160085461367690919063ffffffff16565b60088190555061234f81600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f702d5967f45f6513a38ffc42d6ba9bf230bd40e8f53b16363c7eb4fd2deb9a44816040518082815260200191505060405180910390a1600073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a350565b6000600a60149054906101000a900460ff16156125bf57600a60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050602060405180830381600087803b15801561257d57600080fd5b505af1158015612591573d6000803e3d6000fd5b505050506040513d60208110156125a757600080fd5b810190808051906020019092919050505090506125cc565b6125c9838361368f565b90505b92915050565b60035481565b60096020528060005260406000206000915054906101000a900460ff1681565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561265457600080fd5b6000600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508073ffffffffffffffffffffffffffffffffffffffff167fd7e9ec6e6ecd65492dce6bf513cd6867560d49544421d0783ddf06e76c24470c60405160405180910390a250565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561277257600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156127ae57600080fd5b8073ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156128cc57600080fd5b600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151561292457600080fd5b61292d826118e4565b905060008060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506129888160085461367690919063ffffffff16565b6008819055508173ffffffffffffffffffffffffffffffffffffffff167f61e6e66b0d6339b2980aecc6ccc0039736791f0ccde9ed512e789a7fbdd698c6826040518082815260200191505060405180910390a25050565b600081600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60008060008073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614151515612b1257600080fd5b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548411151515612b5f57600080fd5b600160008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548411151515612bea57600080fd5b612bf384611a0b565b9150612c08828561367690919063ffffffff16565b9050612c5b846000808973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b6000808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612cee816000808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015612ee457612e6384600160008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a360008211156130b157612fc582600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a35b6001925050509392505050565b600080600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050808311156131cf576000600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550613263565b6131e2838261367690919063ffffffff16565b600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546040518082815260200191505060405180910390a3600191505092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60008060008414156133ac57600091506133cb565b82840290508284828115156133bd57fe5b041415156133c757fe5b8091505b5092915050565b60008082848115156133e057fe5b0490508091505092915050565b60008060006133fb84611a0b565b9150613410828561367690919063ffffffff16565b905061341c8582613716565b50600082111561345457613452600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1683613716565b505b505092915050565b600080828401905083811015151561347057fe5b8091505092915050565b600061350b82600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546040518082815260200191505060405180910390a36001905092915050565b600082821115151561368457fe5b818303905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b60008073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415151561375357600080fd5b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205482111515156137a057600080fd5b6137f1826000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461367690919063ffffffff16565b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550613884826000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461345c90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a360019050929150505600a165627a7a72305820ebc7abb2eb78f3b47e72fe9da09012eb7735aa2af8f739851b7e93bb4f8f813400290000000000000000000000000000000000000000000000000000000000989680000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a546574686572205553440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045553445400000000000000000000000000000000000000000000000000000000",
  • "smart_contract": {
    },
  • "contract_state": {
    }
}

GetTransactionInfoByBlockNum

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "num": 1000000
}

Response samples

Content type
application/json
[
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]

UpdateAsset

Update basic TRC10 token information.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "owner_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  • "description": "<string>",
  • "url": "<string>",
  • "new_limit": "<integer>",
  • "new_public_limit": "<integer>",
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": true,
  • "txID": "217caafb78f0d86dffe664c57a7cadbb353a1c9aa727cc1aff23b63ad2c0bb9e",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b6622208d14ebcb55e1585ae4090beb9de8f315a67080f12630a30747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5570646174654173736574436f6e7472616374122f0a15414a193c92cd631c1911b99ca964da8fd342f4cddd12083c737472696e673e1a083c737472696e673e200128017087f694de8f31"
}

BroadcastHex

Broadcast the protobuf encoded transaction hex string after sign

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "transaction": "0A8A010A0202DB2208C89D4811359A28004098A4E0A6B52D5A730802126F0A32747970652E676F6F676C65617069732E636F6D2F70726F746F636F6C2E5472616E736665724173736574436F6E747261637412390A07313030303030311215415A523B449890854C8FC460AB602DF9F31FE4293F1A15416B0580DA195542DDABE288FEC436C7D5AF769D24206412418BF3F2E492ED443607910EA9EF0A7EF79728DAAAAC0EE2BA6CB87DA38366DF9AC4ADE54B2912C1DEB0EE6666B86A07A6C7DF68F1F9DA171EEE6A370B3CA9CBBB00"
}

Response samples

Content type
application/json
{
  • "result": false,
  • "code": "SIGERROR",
  • "txid": "38a0482d6d5a7d1439a50b848d68cafa7d904db48b82344f28765067a5773e1d",
  • "message": "Validate signature error: 8bf3f2e492ed443607910ea9ef0a7ef79728daaaac0ee2ba6cb87da38366df9ac4ade54b2912c1deb0ee6666b86a07a6c7df68f1f9da171eee6a370b3ca9cbbb00 is signed by TJCnKsPa7y5okkXvQAidZBzqx3QyQ6sxMW but it is not contained of permission.",
  • "transaction": "{\"raw_data\": {\"ref_block_bytes\": \"02db\",\"ref_block_hash\": \"c89d4811359a2800\",\"expiration\": 1560496575000,\"contract\": [{\"type\": \"TransferAssetContract\",\"parameter\": {\"type_url\": \"type.googleapis.com/protocol.TransferAssetContract\",\"value\": \"0a07313030303030311215415a523b449890854c8fc460ab602df9f31fe4293f1a15416b0580da195542ddabe288fec436c7d5af769d242064\"}}]},\"signature\": [\"8bf3f2e492ed443607910ea9ef0a7ef79728daaaac0ee2ba6cb87da38366df9ac4ade54b2912c1deb0ee6666b86a07a6c7df68f1f9da171eee6a370b3ca9cbbb00\"]}"
}

DeployContract

Deploys a contract. Returns TransactionExtention, which contains an unsigned transaction.

Authorizations:
apikeyAuth
header Parameters
Content-Type
string
Example: application/json
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "abi": "\"[{\\\"constant\\\":false,\\\"inputs\\\":[{\\\"name\\\":\\\"key\\\",\\\"type\\\":\\\"uint256\\\"},{\\\"name\\\":\\\"value\\\",\\\"type\\\":\\\"uint256\\\"}],\\\"name\\\":\\\"set\\\",\\\"outputs\\\":[],\\\"payable\\\":false,\\\"stateMutability\\\":\\\"nonpayable\\\",\\\"type\\\":\\\"function\\\"},{\\\"constant\\\":true,\\\"inputs\\\":[{\\\"name\\\":\\\"key\\\",\\\"type\\\":\\\"uint256\\\"}],\\\"name\\\":\\\"get\\\",\\\"outputs\\\":[{\\\"name\\\":\\\"value\\\",\\\"type\\\":\\\"uint256\\\"}],\\\"payable\\\":false,\\\"stateMutability\\\":\\\"view\\\",\\\"type\\\":\\\"function\\\"}]\"",
  • "bytecode": "608060405234801561001057600080fd5b5060de8061001f6000396000f30060806040526004361060485763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416631ab06ee58114604d5780639507d39a146067575b600080fd5b348015605857600080fd5b506065600435602435608e565b005b348015607257600080fd5b50607c60043560a0565b60408051918252519081900360200190f35b60009182526020829052604090912055565b600090815260208190526040902054905600a165627a7a72305820fdfe832221d60dd582b4526afa20518b98c2e1cb0054653053a844cf265b25040029",
  • "fee_limit": "<integer>",
  • "parameter": "<string>",
  • "origin_energy_limit": "<integer>",
  • "owner_address": "TJmmqjb1DK9TTZbQXzRQ2AuA94z4gKAPFh",
  • "name": "SomeContract",
  • "call_value": "<integer>",
  • "consume_user_resource_percent": "<integer>",
  • "permission_id": "<integer>",
  • "visible": true
}

Response samples

Content type
application/json
{
  • "visible": false,
  • "txID": "cf84c1d9afdefc896e5340e9f3482261600813716067e17575bbcc35d62c5744",
  • "contract_address": "41403a54967eb594b1cc8f1d859dbab5a4c034fa95",
  • "raw_data": {
    },
  • "raw_data_hex": "0a02b6b5220824301b14216bf1b040b8d7c8de8f315add03081e12d8030a30747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e437265617465536d617274436f6e747261637412a3030a1541d1e7a6bc354106cb410e65ff8b181c600ff142921289030a1541d1e7a6bc354106cb410e65ff8b181c600ff142921a5c0a2b1a03736574220e12036b65791a0775696e743235362210120576616c75651a0775696e74323536300240030a2d10011a03676574220e12036b65791a0775696e743235362a10120576616c75651a0775696e743235363002400222fd01608060405234801561001057600080fd5b5060de8061001f6000396000f30060806040526004361060485763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416631ab06ee58114604d5780639507d39a146067575b600080fd5b348015605857600080fd5b506065600435602435608e565b005b348015607257600080fd5b50607c60043560a0565b60408051918252519081900360200190f35b60009182526020829052604090912055565b600090815260208190526040902054905600a165627a7a72305820fdfe832221d60dd582b4526afa20518b98c2e1cb0054653053a844cf265b2504002930643a0c536f6d65436f6e747261637440a08d06709d99a4de8f319001c0843d"
}

Bitcoin

Bitcoin > Info Requests

getLastBlockNumber

Get the latest block number

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/blocks/number',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed",
  • "data": {
    }
}

getBlock

Authorizations:
apikeyAuth
path Parameters
block
required
integer
Example: 737832

Block Number

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/blocks/737832',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed the block.",
  • "data": [
    ]
}

getTransaction

You can get your transaction decoded by add /decoded to your api call. If you want to get the transaction encoded, youst remove the /decoded part

Authorizations:
apikeyAuth
path Parameters
id
required
string
Example: 66a645494483bd8243762361a34b02826f7e62d0ced3888234f975b185aecbb4

Transaction Id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/transactions/66a645494483bd8243762361a34b02826f7e62d0ced3888234f975b185aecbb4/decoded',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed transaction data.",
  • "data": {
    }
}

getBlockchaIninfo

Authorizations:
apikeyAuth

Responses

Request samples

const request = require('request');

const options = {method: 'GET', url: 'https://api.chaingateway.io/v2/bitcoin/info'};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully parsed chain parameters.",
  • "data": {
    }
}

getFees

The fees are parted into three categroies

fast (10min / 1 block)
medium (30 min / 3 blocks)
slow (60 min / 6 blocks)

this tells you in wich block distance your transaction get confirmed. A block is around ~10 minutes.

Please note that fees are dynamic by transaction size. This is only an estimation!

Authorizations:
apikeyAuth

Responses

Request samples

const request = require('request');

const options = {method: 'GET', url: 'https://api.chaingateway.io/v2/bitcoin/fees'};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Successfully get fees.",
  • "data": {
    }
}

Bitcoin > Wallet Requests

createWallet

Authorizations:
apikeyAuth
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet was successfully created.",
  • "data": {
    }
}

getWallets

Authorizations:
apikeyAuth

Responses

Request samples

const request = require('request');

const options = {method: 'GET', url: 'https://api.chaingateway.io/v2/bitcoin/wallets'};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! bitcoinWallets has been successfully parsed.",
  • "data": {
    }
}

getWallet

Authorizations:
apikeyAuth
path Parameters
walletname
required
string
Example: Evolo_4949974

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/wallets/Evolo_4949974'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet has been successfully loaded.",
  • "data": {
    }
}

deleteWallet

Authorizations:
apikeyAuth
path Parameters
walletname
required
string
Example: Evolo_4215179

Name of your wallet

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/bitcoin/wallets/Evolo_4215179'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet has been successfully deleted.",
  • "data": {
    }
}

createWalletAddress

Authorizations:
apikeyAuth
path Parameters
wallet_name
required
string
Example: Evolo_2163532

Wallet name

Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet Address successfully created",
  • "data": {
    }
}

getWalletAddresses

Authorizations:
apikeyAuth
path Parameters
wallet_name
required
string
Example: Evolo_6674942

Wallet name

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/wallets/Evolo_6674942/addresses'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet Address successfully loaded",
  • "data": [
    ]
}

exportAddressPrivateKey

Authorizations:
apikeyAuth
path Parameters
name
required
string
Example: Evolo_4215179
address
required
string
Example: bc1qz3hdws5lt5ug7qwfv4m4ttanaq67ts77ekv95x
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "password": "test123"
}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Bitcoin Wallet Address private key successfully loaded",
  • "data": {
    }
}

Bitcoin > Transaction Requests

sendTransaction

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "to": "bc1qzq8m9ukvvgvj7kmlejnfr2q4ndmk2e4ndtr9rn",
  • "amount": "1",
  • "walletname": "Evolo_6928232",
  • "password": "Test123",
  • "subtractfee": false,
  • "speed": "fast"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

Bitcoin > Webhooks/IPN Requests

With webhooks, you can get notified about various events in the blockchain. E.g:

Receipt of payment to a specific address
Outgoing payment from a specific address
Exchange of sats between two specific addresses

For this you have to create a webhook with certain filter criteria. The following values are available as filter criteria:

from: Outgoing address
to: Incoming address

Parameter "url" defines the url we are calling with a POST Request.. The request body will have your filter criterias and some additional informatiion about your transaction:

{
  "id": "63a1ae0887ca3625b82b4924",
  "webhook_id": "63a1ad0e87ca3625b82b4923",
  "from": "0x0000000000000000000000000000000000000000",
  "to": "0xa9d1e08c7793af67e9d92fe308d5697fb81d3e43",
  "blocknumber": "123",
  "datetime": "22-12-20 13:43:52",
  "txid": "000000000000000000000000000000000000000000000000000",
  "amount": "0.01"
}

subscribeAddress

Creates a new subscription/IPN for the given address You will receive a notification to the given url every time a deposit is received. Unsubscribe the address before sending sats from it or you won't get reliable notifications anymore.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully subscribed to IPN!.",
  • "data": {
    }
}

listSubscribedAddresses

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/webhooks',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{}

unsubscribeAddress

Deletes an existing subscription/IPN for the given address (and contractaddress).

Authorizations:
apikeyAuth
path Parameters
id
required
string
Example: 63ef470294d74b0f290b4b64

Webhook id

header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'DELETE',
  url: 'https://api.chaingateway.io/v2/bitcoin/webhooks/63ef470294d74b0f290b4b64',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Successfully unsubscribed to IPN!.",
  • "data": {
    }
}

listFailedIPNs

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/bitcoin/webhooks/notifications/failed',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

resendFailedIPN

Returns all subscriptions/IPNs created with an account.

Authorizations:
apikeyAuth
path Parameters
notification_id
required
string
Example: 62640817eb594da78c7bee00

Notification id

header Parameters
Accept
string
Example: application/json
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "ok": true,
  • "id": 17766
}

Bitcoin > RPC API

help

help

help ( "command" )

List all commands, or get help for a specified command.

Argument #1 - command

Type: string, optional, default=all commands

The command to get help on

Authorizations:
apikeyAuth
Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "jsonrpc": "1.0",
  • "id": "curltest",
  • "method": "help",
  • "params": [ ]
}

Response samples

Content type
application/json
{
  • "result": "== Blockchain ==\ngetbestblockhash\ngetblock \"blockhash\" ( verbosity )\ngetblockchaininfo\ngetblockcount\ngetblockfilter \"blockhash\" ( \"filtertype\" )\ngetblockfrompeer \"blockhash\" peer_id\ngetblockhash height\ngetblockheader \"blockhash\" ( verbose )\ngetblockstats hash_or_height ( stats )\ngetchaintips\ngetchaintxstats ( nblocks \"blockhash\" )\ngetdeploymentinfo ( \"blockhash\" )\ngetdifficulty\ngetmempoolancestors \"txid\" ( verbose )\ngetmempooldescendants \"txid\" ( verbose )\ngetmempoolentry \"txid\"\ngetmempoolinfo\ngetrawmempool ( verbose mempool_sequence )\ngettxout \"txid\" n ( include_mempool )\ngettxoutproof [\"txid\",...] ( \"blockhash\" )\ngettxoutsetinfo ( \"hash_type\" hash_or_height use_index )\ngettxspendingprevout [{\"txid\":\"hex\",\"vout\":n},...]\npreciousblock \"blockhash\"\npruneblockchain height\nsavemempool\nscantxoutset \"action\" ( [scanobjects,...] )\nverifychain ( checklevel nblocks )\nverifytxoutproof \"proof\"\n\n== Control ==\ngetmemoryinfo ( \"mode\" )\ngetrpcinfo\nhelp ( \"command\" )\nlogging ( [\"include_category\",...] [\"exclude_category\",...] )\nstop\nuptime\n\n== Mining ==\ngetblocktemplate ( \"template_request\" )\ngetmininginfo\ngetnetworkhashps ( nblocks height )\nprioritisetransaction \"txid\" ( dummy ) fee_delta\nsubmitblock \"hexdata\" ( \"dummy\" )\nsubmitheader \"hexdata\"\n\n== Network ==\naddnode \"node\" \"command\"\nclearbanned\ndisconnectnode ( \"address\" nodeid )\ngetaddednodeinfo ( \"node\" )\ngetconnectioncount\ngetnettotals\ngetnetworkinfo\ngetnodeaddresses ( count \"network\" )\ngetpeerinfo\nlistbanned\nping\nsetban \"subnet\" \"command\" ( bantime absolute )\nsetnetworkactive state\n\n== Rawtransactions ==\nanalyzepsbt \"psbt\"\ncombinepsbt [\"psbt\",...]\ncombinerawtransaction [\"hexstring\",...]\nconverttopsbt \"hexstring\" ( permitsigdata iswitness )\ncreatepsbt [{\"txid\":\"hex\",\"vout\":n,\"sequence\":n},...] [{\"address\":amount,...},{\"data\":\"hex\"},...] ( locktime replaceable )\ncreaterawtransaction [{\"txid\":\"hex\",\"vout\":n,\"sequence\":n},...] [{\"address\":amount,...},{\"data\":\"hex\"},...] ( locktime replaceable )\ndecodepsbt \"psbt\"\ndecoderawtransaction \"hexstring\" ( iswitness )\ndecodescript \"hexstring\"\nfinalizepsbt \"psbt\" ( extract )\nfundrawtransaction \"hexstring\" ( options iswitness )\ngetrawtransaction \"txid\" ( verbose \"blockhash\" )\njoinpsbts [\"psbt\",...]\nsendrawtransaction \"hexstring\" ( maxfeerate )\nsignrawtransactionwithkey \"hexstring\" [\"privatekey\",...] ( [{\"txid\":\"hex\",\"vout\":n,\"scriptPubKey\":\"hex\",\"redeemScript\":\"hex\",\"witnessScript\":\"hex\",\"amount\":amount},...] \"sighashtype\" )\ntestmempoolaccept [\"rawtx\",...] ( maxfeerate )\nutxoupdatepsbt \"psbt\" ( [\"\",{\"desc\":\"str\",\"range\":n or [n,n]},...] )\n\n== Signer ==\nenumeratesigners\n\n== Util ==\ncreatemultisig nrequired [\"key\",...] ( \"address_type\" )\nderiveaddresses \"descriptor\" ( range )\nestimatesmartfee conf_target ( \"estimate_mode\" )\ngetdescriptorinfo \"descriptor\"\ngetindexinfo ( \"index_name\" )\nsignmessagewithprivkey \"privkey\" \"message\"\nvalidateaddress \"address\"\nverifymessage \"address\" \"signature\" \"message\"\n\n== Wallet ==\nabandontransaction \"txid\"\nabortrescan\naddmultisigaddress nrequired [\"key\",...] ( \"label\" \"address_type\" )\nbackupwallet \"destination\"\nbumpfee \"txid\" ( options )\ncreatewallet \"wallet_name\" ( disable_private_keys blank \"passphrase\" avoid_reuse descriptors load_on_startup external_signer )\ndumpprivkey \"address\"\ndumpwallet \"filename\"\nencryptwallet \"passphrase\"\ngetaddressesbylabel \"label\"\ngetaddressinfo \"address\"\ngetbalance ( \"dummy\" minconf include_watchonly avoid_reuse )\ngetbalances\ngetnewaddress ( \"label\" \"address_type\" )\ngetrawchangeaddress ( \"address_type\" )\ngetreceivedbyaddress \"address\" ( minconf include_immature_coinbase )\ngetreceivedbylabel \"label\" ( minconf include_immature_coinbase )\ngettransaction \"txid\" ( include_watchonly verbose )\ngetunconfirmedbalance\ngetwalletinfo\nimportaddress \"address\" ( \"label\" rescan p2sh )\nimportdescriptors \"requests\"\nimportmulti \"requests\" ( \"options\" )\nimportprivkey \"privkey\" ( \"label\" rescan )\nimportprunedfunds \"rawtransaction\" \"txoutproof\"\nimportpubkey \"pubkey\" ( \"label\" rescan )\nimportwallet \"filename\"\nkeypoolrefill ( newsize )\nlistaddressgroupings\nlistdescriptors ( private )\nlistlabels ( \"purpose\" )\nlistlockunspent\nlistreceivedbyaddress ( minconf include_empty include_watchonly \"address_filter\" include_immature_coinbase )\nlistreceivedbylabel ( minconf include_empty include_watchonly include_immature_coinbase )\nlistsinceblock ( \"blockhash\" target_confirmations include_watchonly include_removed include_change )\nlisttransactions ( \"label\" count skip include_watchonly )\nlistunspent ( minconf maxconf [\"address\",...] include_unsafe query_options )\nlistwalletdir\nlistwallets\nloadwallet \"filename\" ( load_on_startup )\nlockunspent unlock ( [{\"txid\":\"hex\",\"vout\":n},...] persistent )\nmigratewallet\nnewkeypool\npsbtbumpfee \"txid\" ( options )\nremoveprunedfunds \"txid\"\nrescanblockchain ( start_height stop_height )\nrestorewallet \"wallet_name\" \"backup_file\" ( load_on_startup )\nsend [{\"address\":amount,...},{\"data\":\"hex\"},...] ( conf_target \"estimate_mode\" fee_rate options )\nsendall [\"address\",{\"address\":amount,...},...] ( conf_target \"estimate_mode\" fee_rate options )\nsendmany \"\" {\"address\":amount,...} ( minconf \"comment\" [\"address\",...] replaceable conf_target \"estimate_mode\" fee_rate verbose )\nsendtoaddress \"address\" amount ( \"comment\" \"comment_to\" subtractfeefromamount replaceable conf_target \"estimate_mode\" avoid_reuse fee_rate verbose )\nsethdseed ( newkeypool \"seed\" )\nsetlabel \"address\" \"label\"\nsettxfee amount\nsetwalletflag \"flag\" ( value )\nsignmessage \"address\" \"message\"\nsignrawtransactionwithwallet \"hexstring\" ( [{\"txid\":\"hex\",\"vout\":n,\"scriptPubKey\":\"hex\",\"redeemScript\":\"hex\",\"witnessScript\":\"hex\",\"amount\":amount},...] \"sighashtype\" )\nsimulaterawtransaction ( [\"rawtx\",...] {\"include_watchonly\":bool,...} )\nunloadwallet ( \"wallet_name\" load_on_startup )\nupgradewallet ( version )\nwalletcreatefundedpsbt ( [{\"txid\":\"hex\",\"vout\":n,\"sequence\":n,\"weight\":n},...] ) [{\"address\":amount,...},{\"data\":\"hex\"},...] ( locktime options bip32derivs )\nwalletdisplayaddress \"address\"\nwalletlock\nwalletpassphrase \"passphrase\" timeout\nwalletpassphrasechange \"oldpassphrase\" \"newpassphrase\"\nwalletprocesspsbt \"psbt\" ( sign \"sighashtype\" bip32derivs finalize )\n\n== Zmq ==\ngetzmqnotifications",
  • "error": null,
  • "id": "curltest"
}

Market

getRateByCurrency

Authorizations:
apikeyAuth
path Parameters
currency1
required
string
Example: btc
currency2
required
string
Example: eur
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/markets/prices/btc/eur',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Bitcoinprice has been successfully parsed.",
  • "data": {
    }
}

getCurrencies

Authorizations:
apikeyAuth
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/markets/currencies',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Currency list has been successfully parsed.",
  • "data": {
    }
}

getPriceDataByCurrency

Authorizations:
apikeyAuth
path Parameters
currency1
required
string
Example: btc
currency2
required
string
Example: usd
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/markets/data/btc/usd',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Currency data has been successfully parsed.",
  • "data": {
    }
}

getAllTimeHigh

Authorizations:
apikeyAuth
path Parameters
currency1
required
string
Example: btc
currenty2
required
string
Example: eur
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/markets/prices/btc/eur/ath',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Success! Currency data has been successfully parsed.",
  • "data": {
    }
}

getAllTimeLow

Authorizations:
apikeyAuth
path Parameters
currency1
required
string
Example: btc
currency2
required
string
Example: eur
header Parameters
Accept
string
Example: application/json

Responses

Request samples

const request = require('request');

const options = {
  method: 'GET',
  url: 'https://api.chaingateway.io/v2/markets/prices/btc/eur/atl',
  headers: {Accept: 'SOME_STRING_VALUE'}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});

Response samples

Content type
application/json
{
  • "ok": true,
  • "status": 200,
  • "message": "Currency data has been successfully parsed.",
  • "data": {
    }
}