Retokenize Token
Retries the tokenization of a token whose previous attempt failed. Only a token in status 3 (Error) qualifies, and its setup must still have all its contracts deployed. Use this instead of creating the token again: a second Create Token would make a second record for the same asset.
The call is asynchronous: the token moves back to status 2 (InProgress) at once, a new CreateTokenization transaction (type 1) is queued, and both ids are returned. Poll Get Token Transaction By ID: when it reaches 3 (Done) the token is in status 4 (NotListed); when it reaches 4 (Error) the token is back in status 3 (Error). Of two retries sent at the same time, only one starts; the other is refused with 10029.
Required permission: token:create
Request
POST /v2/admin/tokens/{token_id}/retokenize
Parameters
| Name | Type | In | Description |
|---|---|---|---|
token_id | string | path | Required. Token id. |
Headers
| Name | Description |
|---|---|
Authorization | Required. Bearer <access_token> |
Example
curl --request POST \
--url '{{baseUrl}}/v2/admin/tokens/67d8774e903bfcbe7eb5d93e/retokenize' \
--header 'Authorization: Bearer <access_token>'
Response
{
"token_id": "67d8774e903bfcbe7eb5d93e",
"transaction_id": "6a8b5e13f9129816a6cc7a12"
}
Response Fields
| Field | Type | Description |
|---|---|---|
token_id | string | The token being tokenized again. |
transaction_id | string | The new CreateTokenization transaction. Poll it with Get Token Transaction By ID. |
Errors
| Status | Code | Description |
|---|---|---|
| 400 | 10016 | token_id is not a valid id |
| 400 | 10001 | Token not found (token domain 5) |
| 403 | 10005 | The caller's node does not cover the token's node (node domain 2) |
| 400 | 10026 | The token is not in status 3 (Error) (token domain 5) |
| 400 | 10011 | The token's setup does not have all its contracts deployed (node domain 2) |
| 409 | 10029 | The token's status changed since it was read, for example by a concurrent retry (token domain 5) |
See Errors for the error format and common codes.