Asentum

Reference

JSON-RPC Reference

Canonical method list · Estimated read time: 10 minutes

Updated 2026-09-18: public RPC host in examples is explorer.asentum.com.

TL;DR

Asentum exposes a JSON-RPC 2.0 interface deliberately shaped like Ethereum's. Most eth_* read methods work unmodified with ethers.js, viem, web3.js, and MetaMask. Asentum-specific functionality, such as read-only contract calls, lives on plain HTTP endpoints like POST /view. For signing, you need a Dilithium3-aware client - see Ethereum Compatibility.

Endpoint

  • HTTP - https://explorer.asentum.com (POST JSON-RPC 2.0 bodies)
  • Chain ID - 1423 (testnet default - fetch live via eth_chainId)

CORS is open on the testnet for all origins. Rate limits are applied per IP on the hosted RPC; self-hosted nodes don't enforce them.

eth_* methods

The following Ethereum-compatible methods are supported:

MethodPurpose
eth_chainIdReturns the chain id.
eth_blockNumberLatest block height.
eth_getBalanceBalance of an address at a given block.
eth_getTransactionCountNonce of an address.
eth_getCodeDeployed contract source at an address.
eth_getStorageAtReads a storage slot on a contract.
eth_getBlockByNumberBlock + transactions by height.
eth_getBlockByHashBlock + transactions by hash.
eth_getTransactionByHashTransaction body by hash.
eth_getTransactionReceiptReceipt (status, gas used, events).
eth_getLogsEvent log filter - indexed topics + block range.
eth_callRead-only contract call (no tx, no gas).
eth_estimateGasEstimate gas for a transaction.
eth_gasPriceCurrent legacy gas price (equal to base fee).
eth_feeHistoryBase-fee + priority-fee history for EIP-1559.
eth_sendRawTransactionSubmit a signed transaction.
net_versionChain id as a decimal string.
web3_clientVersionNode software + version string.

eth_getCode returns the contract source, not bytecode - contracts on Asentum are plain JavaScript. See Smart Contracts for the why.

Address parameters take an ase1 address. Some response fields (the to of a transaction or receipt, and a receipt's contractAddress) are still returned in the node's internal encoding. Convert them to ase1 (bech32 of the same 20 bytes, prefix ase) before you show them to anyone.

Asentum HTTP endpoints

There are no asentum_* JSON-RPC methods; in particular asentum_viewCall does not exist. Asentum-specific reads are plain HTTP endpoints on the same host:

EndpointPurpose
POST /viewRead-only contract call (no gas, no tx). JSON body: {contract, method, args}. Returns {ok, returnValue, events, gasUsed} or {ok: false, reason}.
GET /validatorsCurrent validator set with stake and status.

There are no governance JSON-RPC methods. Governance data is served as plain GET endpoints on the same host:/governance/proposals,/governance/proposal/<id>,/governance/locked/<address> and/governance/withdrawable/<address>. SeeProtocol Governance.

WebSocket subscriptions

Over WebSocket, eth_subscribe supports the standard topics:

  • newHeads - new block headers
  • logs - event logs matching a filter
  • newPendingTransactions - mempool entries

GRANDPA provides deterministic finality: once a block is finalized it never reorgs. Finality trails the head by a few blocks, so a freshly emitted newHeads block is confirmed once GRANDPA finalizes it.

Error codes

Asentum follows JSON-RPC 2.0 standard error codes plus a few protocol-specific ones:

  • -32700 Parse error
  • -32600 Invalid request
  • -32601 Method not found
  • -32602 Invalid params
  • -32000 Generic server error (insufficient balance, nonce mismatch, etc.)
  • -32010 Contract execution reverted (message contains the reason)

Examples

Get the latest block height:

curl -X POST https://explorer.asentum.com \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"eth_blockNumber","params":[]}'

Read a contract (view call) with POST /view. This is a plain HTTP request, not JSON-RPC:

curl -X POST https://explorer.asentum.com/view \
  -H 'Content-Type: application/json' \
  -d '{"contract":"ase1…contract","method":"totalSupply","args":[]}'

When an argument is an address, the SDK's viewCall(contract, method, args) converts ase1 addresses into the form the contract stores, so prefer it for calls like balanceOf.

For a typed, higher-level interface see the SDK API Reference.

Read next