Archive account
/accounts/archive
Target audience: Developers
Archive account¶
Introduction¶
This endpoint archives the given account immediately.
Danger
Archived accounts cannot be restored once archived. Use with caution
URI¶
Environment | URI |
---|---|
Stage | https://payway-api.stage.adeprimo.se/external/api/v1/accounts/archive |
Production | https://backend.worldoftulo.com/external/api/v1/accounts/archive |
Requirements¶
Identity | Scope |
---|---|
No | /external/account/archive/w |
Parameters¶
Field | Required | Type | Description |
---|---|---|---|
account_id | Required | String | The id of the account to archive. Size range ..24 Allowed values: "/^[a-f\d]{24}$/i" |
Curl Example¶
curl --request DELETE \
--url https://payway-api.stage.adeprimo.se/external/api/v1/accounts/archive?account_id=1234567890 \
--header 'accept: application/json' \
--header 'authorization: Bearer token'
Response¶
Example Response: Successfully archived account¶
HTTP 204 No Content
{}
Errors¶
Example error response¶
HTTP 409 Conflict
{
"code": "archive_account_with_active_products",
"message": "package_code,embedded_product_code"
}
HTTP 400 Bad Request¶
Name | Type | Description |
---|---|---|
invalid_parameter | Object | Account_id |
HTTP 404 Not Found¶
Name | Type | Description |
---|---|---|
not_found | Object | The account_id could not be found |
HTTP 409 Conflict¶
Name | Type | Description |
---|---|---|
archive_account_with_active_products | Object | An account with an active subscription cannot be archived. |
HTTP 500 Internal Server Error¶
Name | Type | Description |
---|---|---|
internal_server_error | Object | Something unexpected happened server side |