Get account information about a given asset. | Algorand Developer Portal
Get account information about a given asset.
HTTP Method
GET
Endpoint
/v2/accounts/{address}/assets/{asset-id}
Given a specific account public key and asset ID, this call returns the account’s asset holding and asset parameters (if either exist). Asset parameters will only be returned if the provided address is the asset’s creator.
Authorizations
- api_key
Parameters
Path Parameters
address
required
string/[A-Z0-9]{58}/
An account public key.
asset-id
required
integer
An asset identifier.
Query Parameters
format
string
Allowed values: json, msgpack
Configures whether the response object is JSON or MessagePack encoded. If not provided, defaults to JSON.
Responses
200
AccountAssetResponse describes the account’s asset holding and asset parameters (if either exist) for a specific asset ID. Asset parameters will only be returned if the provided address is the asset’s creator.
Select media type application/json, application/msgpack
object
asset-holding
Describes an asset held by an account.
Definition: data/basics/userBalance.go : AssetHolding
object
amount
required[a]number of units held.
integer format: uint64asset-id
required
Asset ID of the holding.
integeris-frozen
required[f]whether or not the holding is frozen.
booleancreated-asset
AssetParams specifies the parameters for an asset.[apar]when part of an AssetConfig transaction.
Definition: data/transactions/asset.go : AssetParams
objectclawback
[c]Address of account used to clawback holdings of this asset. If empty, clawback is not permitted.
string- creator
required
- creator
The address that created this asset. This is the address where the parameters for this asset can be found, and also the address where unwanted asset units can be sent in the worst case.
string
- **decimals**
*required*
[dc] The number of digits to use after the decimal point when displaying this asset. If 0, the asset is not divisible. If 1, the base unit of the asset is in tenths. If 2, the base unit of the asset is in hundredths, and so on. This value must be between 0 and 19 (inclusive).
integer format: uint64
<= 19
- **default-frozen**
`[df]` Whether holdings of this asset are frozen by default.
*boolean*
- **freeze**
`[f]` Address of account used to freeze holdings of this asset. If empty, freezing is not permitted.
*string*
- **manager**
`[m]` Address of account used to manage the keys of this asset and to destroy it.
*string*
- **metadata-hash**
`[am]` A commitment to some unspecified asset metadata. The format of this metadata is up to the application.
*string format: byte*
`/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/`
- **name**
`[an]` Name of this asset, as supplied by the creator. Included only when the asset name is composed of printable utf-8 characters.
*string*
- **name-b64**
Base64 encoded name of this asset, as supplied by the creator.
*string format: byte*
`/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/`
- **reserve**
`[r]` Address of account holding reserve (non-minted) units of this asset.
*string*
- **total**
*required*
[t] The total number of units of this asset.
integer format: uint64
- **unit-name**
`[un]` Name of a unit of this asset, as supplied by the creator. Included only when the name of a unit of this asset is composed of printable utf-8 characters.
*string*
- **unit-name-b64**
Base64 encoded name of a unit of this asset, as supplied by the creator.
*string format: byte*
`/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/`
- **url**
`[au]` URL where more information about the asset can be retrieved. Included only when the URL is composed of printable utf-8 characters.
*string*
- **url-b64**
Base64 encoded URL where more information about the asset can be retrieved.
*string format: byte*
`/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/`
- **round**
*required*
The round for which this information is relevant.
integer
400
Malformed address or asset ID
Select media type application/json, application/msgpack
An error response with optional data field.
object
data
object
- message
required
string
401
Invalid API Token
Select media type application/json, application/msgpack
An error response with optional data field.
object
data
object
- message
required
string
500
Internal Error
Select media type application/json, application/msgpack
An error response with optional data field.
object
data
object
- message
required
string
default
Unknown Error