REST API
Resolve .algo names and perform name operations on ANS .algo names.
Resolve .algo name
Resolve .algo name to get the address of the owner. Use query params listed below to get further information including linked socials and other metadata.
Method: GET
Query Params:
Param Name | Data Type | Required/ Optional | Description |
---|---|---|---|
socials | boolean | optional | if true, returns socials along with name information |
metadata | boolean | optional | if true, returns metadata along with name information |
Names owned by address
This GET method gets all the names owned by an Algorand address in reverse chronological order of registration. Use query parameters listed below to get more details about the name including linked socials and other metadata including avatar and transfer information.
Method: GET
Query Params:
Param Name | Date Type | Required/ Optional | Description |
---|---|---|---|
socials | boolean | optional | if true, returns the socials of each name along with name information |
metadata | boolean | optional | if true, returns metadata along with name information |
limit | number | optional | set the limit on number of names to be returned. |
Multiple account reverse lookup
This GET method gets the most recently registered domain name by each of the Algorand address provided through accounts[] query parameter.
Register a new name
This POST method returns the transactions to be signed to register a .algo name.
Method: POST
Query Params:
Param Name | Data Type | Required/optional | Description |
---|---|---|---|
name | string | required | .algo name to register |
address | string (Algorand address format) | required | account address of the sender |
period | number | required | number of years to register the name |
Renew name
Retrieve transactions to renew a name. The ANS registry currently supports renewal only by the owner hence the transactions will fail if the input address is not the current owner of the name.
Method: POST
Query Params:
Param Name | Data Type | Required/ optional | Description |
---|---|---|---|
name | string (<name>.algo) | required | input .algo name to be renewed |
address | string (Algorand Account address) | required | account address of name owner |
period | number | required | number of years to extend the name |
Update Name (Set name properties)
Retrieve transactions to set the social media handles of a domain name
Method: POST
Param Name | Data Type | Required/ optional | Description |
---|---|---|---|
name | string (<name>.algo) | required | the .algo name to be updated |
address | string (Algorand Account Address) | required | algorand account address, must match the current owner |
updatedHandle | JSON string | required | list of social-media handle names and corresponding new values to update |
Initiate transfer
Retrieve the transactions to initiate name transfer. The owner is required to set the price for transfer and the recipient's algorand account address.
Method: POST
Param Name | Data Type | Required/ optional | Description |
---|---|---|---|
name | string (<name>.algo) | required | the .algo name to be transferred |
owner | string (Algorand account address) | required | algorand account address, must match the current name owner's address |
transfer_to | string (Algorand account address) | required | the recipient's algorand account address |
price | number (of ALGOs) | required | the price at which the owner transfers the name |
Accept transfer
Retrieve the transactions to complete the transfer by providing the current owner's address, the transfer recipient's address, and the price set by the owner
Method: POST
Param Name | Data Type | Required/ optional | Description |
---|---|---|---|
name | string (<name>.algo) | required | the .algo name to be tranferred |
current_owner | string (Algorand account address) | required | algorand account address, must match the current owner |
new_owner | string (Algorand account address) | required | algorand account address, must match the value of "transfer_to" address of the name |
price | number (of ALGOs) | required | payment amount for transfer, must match the value of "transfer_price" set by the name owner |
Last updated