Delete Token
Deletes a token that never reached the market: only a token in status 1 (Draft), 3 (Error) or 4 (NotListed) can be deleted. The deletion is immediate and off-chain; the token is soft-deleted (it keeps its record with deleted_at set, and List Tokens still returns it unless is_not_deleted=true). A token that is listed between the check and the write is refused rather than deleted.
Required permission: token:delete
Request
DELETE /v2/admin/tokens/{token_id}
Parameters
| Name | Type | In | Description |
|---|---|---|---|
token_id | string | path | Required. Token id. |
Headers
| Name | Description |
|---|---|
Authorization | Required. Bearer <access_token> |
Example
curl --request DELETE \
--url '{{baseUrl}}/v2/admin/tokens/67d8774e903bfcbe7eb5d93e' \
--header 'Authorization: Bearer <access_token>'
Response
200 OK with an empty body.
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 | 10005 | The token's status does not allow deletion (token domain 5, message token cannot be deleted) |
See Errors for the error format and common codes.