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

Stellar — Assets, Claimable balances, Effects, Ledgers (1/3)

API reference for Stellar. All methods ->

Part 1 of 3: 1 · 2 · 3

Assets

Assets are representations of value issued on the Stellar network. An asset consists of a type, code, and issuer.

GET /assets

Lists all assets.

This endpoint lists all assets.

Parameters

  • asset_code (any; query): the code of the asset you would like to filter by.
  • asset_issuer (any; query): the Stellar address of the issuer for the asset you would like to filter by.
  • cursor (integer; query): a number that points to a specific location in a collection of responses and is pulled from the paging_token value of a record.
  • order (string; query): a designation of the order in which records should appear. Options include asc (ascending) or desc (descending). If this argument isn’t set, it defaults to asc.
  • limit (integer; query): the maximum number of records returned. The limit can range from 1 to 200 - an upper limit that is hardcoded in Horizon for performance reasons. If this argument isn’t designated, it defaults to 10.

Returns

{
"_links": {
"self": {
"href": "string",
"templated": true
},
"next": {
"href": "string",
"templated": true
},
"prev": {
"href": "string",
"templated": true
}
},
"_embedded": {
"records": [
{
"_links": {
"toml": {
"href": "string",
"templated": true
}
},
"asset_type": "string",
"asset_issuer": "string",
"paging_token": "string",
"accounts": {
"authorized": 0,
"authorized_to_maintain_liabilities": 0,
"unauthorized": 0
},
"num_claimable_balances": 0,
"num_contracts": 0,
"num_liquidity_pools": 0,
"balances": {
"authorized": "string",
"authorized_to_maintain_liabilities": "string",
"unauthorized": "string"
},
"claimable_balances_amount": "string",
"contracts_amount": "string",
"liquidity_pools_amount": "string",
"amount": "string",
"num_accounts": 0,
"flags": {
"auth_required": true,
"auth_revocable": true,
"auth_immutable": true
}
}
]
}
}

Request example

curl https://rpc.ankr.com/http/stellar_horizon/assets{?asset_code,asset_issuer,cursor,limit,order}

Response example

{
"_links": {
"self": {
"href": "https://rpc.ankr.com/assets?cursor=\u0026limit=1\u0026order=asc"
},
"next": {
"href": "https://rpc.ankr.com/assets?cursor=0_GBBJZOYEGLOCW32Q4ZGWRWQ7UKIGMMIQXIRBBBOVJVFJTZW7CR2VQKAT_credit_alphanum4\u0026limit=1\u0026order=asc"
},
"prev": {
"href": "https://rpc.ankr.com/assets?cursor=0_GBBJZOYEGLOCW32Q4ZGWRWQ7UKIGMMIQXIRBBBOVJVFJTZW7CR2VQKAT_credit_alphanum4\u0026limit=1\u0026order=desc"
}
},
"_embedded": {
"records": [
{
"_links": {
"toml": {
"href": "https://emily.stellarskull.io/.well-known/stellar.toml"
}
},
"asset_type": "credit_alphanum4",
"asset_code": "0",
"asset_issuer": "GBBJZOYEGLOCW32Q4ZGWRWQ7UKIGMMIQXIRBBBOVJVFJTZW7CR2VQKAT",
"paging_token": "0_GBBJZOYEGLOCW32Q4ZGWRWQ7UKIGMMIQXIRBBBOVJVFJTZW7CR2VQKAT_credit_alphanum4",
"num_accounts": 24,
"num_claimable_balances": 0,
"num_liquidity_pools": 0,
"amount": "998.9481303",
"accounts": {
"authorized": 24,
"authorized_to_maintain_liabilities": 0,
"unauthorized": 0
},
"claimable_balances_amount": "0.0000000",
"liquidity_pools_amount": "0.0000000",
"balances": {
"authorized": "998.9481303",
"authorized_to_maintain_liabilities": "0.0000000",
"unauthorized": "0.0000000"
},
"flags": {
"auth_required": false,
"auth_revocable": false,
"auth_immutable": false,
"auth_clawback_enabled": false
}
}
]
}
}