Skip to main content
POST
/
v1
/
customers
/
{customerId}
/
permanent-deletion
Delete Customer Permanently
curl --request POST \
  --url https://{cluster}.voucherify.io/v1/customers/{customerId}/permanent-deletion \
  --header 'Authorization: Bearer <token>' \
  --header 'X-App-Id: <api-key>' \
  --header 'X-App-Token: <api-key>'
{
  "id": "del_7k3buMvBsJuXiLRmdh1WZvZs",
  "created_at": "2022-09-02T17:50:29.302Z",
  "related_object_id": "cust_XI8sPLvznzVpNI1BMIWGcUJa",
  "related_object": "customer",
  "status": "DONE",
  "data_json": {
    "events": 16,
    "customer_events": 28,
    "daily_events": 0,
    "segments": 0,
    "orders": 9,
    "order_events": 5,
    "customer": 1
  },
  "object": "pernament_deletion"
}

Authorizations

X-App-Id
string
header
required
X-App-Token
string
header
required
Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

customerId
string
required

A Voucherify customer's id or source_id.

Example:

"cust_nk0N1uNQ1YnupAoJGOgvsODC"

Response

Returns a permanent deletion object and status of the deletion.

Response body schema for POST v1/customers/{customerId}/permanent-deletion.

id
string
required

Unique permanent deletion object ID.

Example:

"del_mgzqZNwUnwnt1Ddw6phEG90Q"

created_at
string<date-time>
required

Timestamp representing the date and time when the customer was requested to be deleted in ISO 8601 format.

Example:

"2022-09-02T17:55:47.865Z"

Unique customer ID that is being deleted.

Example:

"cust_m557pDDl4IGXexkU6KOQ2Dwi"

Object being deleted.

status
string
default:DONE
required

Deletion status.

data_json
object
required

Statistics summarizing the number of related information that was deleted.

object
string
default:pernament_deletion
required

The type of the object represented by JSON.

I