Base

/getbalance

Get the balance or number of the given token in the requested public address.

GET https://api.expand.network/chain/getbalance

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
blockNumberString

Block number for which the balance needs to be retrieved.

By default, it will pick the latest block number when not specified.

address*StringThe public address to get the balance of.
tokenAddressStringThe address of token to get the balance of.
timestampStringThe timestamp of the block number.
Note- When both a timestamp and a block number are provided, the timestamp will take precedence.
https://api.expand.network/chain/getbalance?chainId=8453&blockNumber=15351657&address=0x20FE51A9229EEf2cF8Ad9E89d91CAb9312cF3b7A&tokenAddress=0x833589fcd6edb6e08f4c7c32d4f71b54bda02913

/getblock

Get details of a block.

GET https://historicallp.api.expand.network/chain/getblock

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
startBlockStringStarting block of the range. Note: Maximum supported range is 10, meaning the startBlock is determined by endBlock - 9.
endBlockString

Last block of the range.

Note: Maximum supported range is 10, meaning the endBlock is determined by startBlock + 9.

https://historicallp.api.expand.network/chain/getblock?chainId=8453

/getgasprice

Get the current gas price from the network.

GET https://api.expand.network/chain/getgasprice

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
https://api.expand.network/chain/getgasprice?chainId=8453

/getstorage

Get data stored in the given slot.

GET https://api.expand.network/chain/getstorage

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
address*StringContract address whose storage is needed.
indexStringSlot index on the smart contract. By default, it is taken as 0.
https://api.expand.network/chain/getstorage?chainId=8453&address=0xCA6f5B49967B492FEE81cA9C92a63a98903DD965

/gettransaction

Get details of a transaction.

GET https://api.expand.network/chain/gettransaction

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
transactionHash*StringThe transaction hash.
https://api.expand.network/chain/gettransaction?chainId=8453&transactionHash=0xcf15634c154cb70b8e02268eedd58d4949312414f796ca3296eebe07dc94ffb4

/portfolio

Get detailed information about the verified assets or tokens currently associated with a user's wallet address.

GET https://api.expand.network/chain/portfolio

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainIdStringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
address*StringPublic addess of the user.
tokensStringComma-separated value of ERC-20 tokens to get value of. Maximum 10 at a time.
pageTokenStringPresent at the end of a lengthy response to fetch the next page.
assetTypeStringfungible/nonFungible standard choice.
By default, all.
timestampStringThe Timestamp of the block number up to which the balances will be fetched.
Note-Only applicable for assetType fungible
blockNumberStringThe block number up to which the balances will be fetched.
Note-Only applicable for assetType fungible
include24hrChangeBooleanIf truereturn the token data with 24-hour changes.
By default, false
https://api.expand.network/chain/portfolio?chainId=8453&address=0xA5af143fd6f6093FDcF6D51d3641F08eaa07d53f&availableOnly=true

/getusertransactions

Get the historical transaction details for a specific user address.

GET https://historicallp.api.expand.network/chain/getusertransactions

Query Parameters

NameTypeDescription
rpcStringRemote procedural call URL.
chainIdStringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
address*StringThe public address of the user.
pageTokenStringThe page cursor present at the top to fetch the next page.
pageSizeStringThe page size.
By Default 30 and Max 100
sortOrderStringThe transaction sorting order.
asc or desc.
By default, desc.
startBlockStringThe starting block number from which to get the transactions.
By default, the Genesis block
endBlockStringThe ending block number from which to get the transactions
By default, the current block
fromTimestampStringThe start date from which to get the transactions ( format in seconds or date string )
Note-If 'fromTimestamp' and 'startBlock' are provided, 'startBlock' will be used.
By default, the Genesis block timestamp
toTimestampString

The end date from which to get the transactions ( format in seconds or date string )
Note- If 'toTimestamp' and 'endBlock' are provided, 'endBlock' will be used.

By default, the current block timestamp

https://historicallp.api.expand.network/chain/getusertransactions?pageSize=5&address=0xF977814e90dA44bFA03b6295A0616a897441aceC&chainId=8453

/sendtransaction

Send transaction on the chain.

POST https://api.expand.network/chain/sendtransaction

Request Body

NameTypeDescription
rpcStringRemote procedural call URL.
chainId*StringRefer to the Chain ID page for details.
chainSymbolStringRefer to the Chain ID page for details.
rawTransaction*StringThe encoded transaction, obtained from the signed transaction.
{
    "chainId": "8453",
    "rawTransaction": "0xf86a80830f4272830a3d8794a67e9b68c41b0f26184d64c26e0b2b81466e5994843b9aca00808302948ca0e073bcaa02ab49f019278be707e3e50433ac7ae6107649a8b1cbdbc368e9482ea05ba36d559c5b70ffa289f90a572adc0863c46fdd067c40c2f37b9ea666fcc8e7"
}