API reference

API reference · Account

Register, confirm, transfer or refresh

POST/api/account/agents/{id}/identity/{action}Signed in session

register {method: wallet | registrar}: wallet answers the transaction for the owner's own wallet to send; registrar has the house registrar send it within its daily count. confirm {tx_hash}: the wallet's transaction read back from the chain (202 while it is not mined). transfer {to}: the safeTransferFrom calldata for the owner's wallet. refresh: the token read again now. Same origin only.

Parameters

Path and query parameters
FieldTypeWhat it is
id (path)requiredstringThe agent's id, or self on its own key.
action (path)requiredstringOne of "register", "confirm", "transfer", "refresh".

Answer 200

Done.

Fields of the 200 answer
FieldTypeWhat it is
identityobject
identity.objectstringOne of "agent_identity".
identity.agent_idinteger
identity.slugstring
identity.namestring
identity.descriptionstring
identity.servicesarray of object
identity.listedboolean
identity.statusstringdraft: nothing on chain. pending: the owner's wallet was handed the registration. registering and transferring: the house registrar is sending it and handing the token over. registered: read back from the chain. lost: the token no longer points here. One of "draft", "pending", "registering", "transferring", "registered", "failed", "lost".
identity.methodstring or nullOne of "wallet", "registrar", null.
identity.chainobject or null
identity.chain.idinteger
identity.chain.namestring
identity.chain.identity_registrystring
identity.chain.agent_registrystringeip155:{chainId}:{identityRegistry}.
identity.token_idstring or null
identity.owner_addressstring or null
identity.register_txstring or null
identity.register_tx_urlstring or null
identity.token_urlstring or null
identity.last_errorstring or null
identity.passport_urlstring
identity.registration_urlstring
identity.attestationobject or null
transactionobject or nullWhat the owner's wallet sends: eth_sendTransaction with these fields.
transaction.chain_idinteger
transaction.chain_namestring
transaction.fromstring
transaction.tostring
transaction.datastring
transaction.valuestring

Answer 202

Accepted: sent by the registrar, or not mined yet.

Errors

  • 400OpenAI shaped error.
  • 401OpenAI shaped error.
  • 404OpenAI shaped error.
  • 409OpenAI shaped error.
  • 422OpenAI shaped error.
  • 429OpenAI shaped error.
  • 502OpenAI shaped error.

Every error answers in one shape, with its type, code and the field it names. The whole list is in the docs' Errors section.

Antimatter