Skip to main content

Parameters

chainId
string
default:"sui"
required
Unique identifier for a blockchain network.
id
number
default:1
required
Request identifier used to match responses.
jsonrpc
string
default:"2.0"
required
JSON-RPC version.
method
string
default:"suix_getBalance"
required
JSON-RPC method name.
params
object
required
Parameters for suix_getBalance [ownerAddress, coin_type]Positional parameters for suix_getBalance:
  • params[0]: The owner’s Sui address
  • params[1]: Optional coin type. Defaults to 0x2::sui::SUI if not provided.

Returns

result
object
Response for suix_getBalance
curl --request POST \
  --url https://api.uniblock.dev/uni/v1/json-rpc?chainId=sui \
  --header 'content-type: application/json' \
  --data '{
    "id": 1,
    "jsonrpc": "2.0",
    "method": "suix_getBalance",
    "params": [
      "0xa6f5a7953a75dc632e696cabe60560522a017bf2fb0bd930d1ec22c06f1ee4e4",
      "0x168da5bf1f48dafc111b0a488fa454aca95e0b5e::usdc::USDC"
    ]
  }'
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "jsonrpc": "2.0",
    "result": {
      "coinType": "0x168da5bf1f48dafc111b0a488fa454aca95e0b5e::usdc::USDC",
      "coinObjectCount": 15,
      "totalBalance": "15",
      "lockedBalance": {}
    },
    "id": 1
  }
}