Delete a Person
https://api-sandbox.letpay.io/token/person/PUBLIC_PERSON_ID
Deletes an existing person and its related credit cards.
Request Fields
None.
Response Fields
refresh_token
(string): Updated access token for next calls.
AUTHORIZATION | API Key |
---|---|
Key | X-Auth-Token |
Value | MY_ACCESS_TOKEN |
Example Request
- 200 - Success
- 401 - Unauthorized
- 404 - Not Found
Example Request
200 - Success
curl --location --request DELETE 'https://api-sandbox.letpay.io/token/person/PUBLIC_PERSON_ID' \
--header 'X-Auth-Token: MY_ACCESS_TOKEN'
Example Response
Header
Content-Type: application/json
Body
{
"refresh_token": "MY_ACCESS_TOKEN"
}
Example Request
401 - Unauthorized
curl --location --request DELETE 'https://api-sandbox.letpay.io/token/person/PUBLIC_PERSON_ID' \
--header 'X-Auth-Token: INVALID_ACCESS_TOKEN'
Example Response
Header
Content-Type: application/json
Body
{
"timestamp": "2024-01-16T19:52:18.186+0000",
"status": 401,
"error": "Unauthorized",
"message": "Access Denied",
"path": "/token/person/PUBLIC_PERSON_ID"
}
Example Request
404 - Not Found
curl --location --request DELETE 'https://api-sandbox.letpay.io/token/person/INVALID_PUBLIC_PERSON_ID' \
--header 'X-Auth-Token: MY_ACCESS_TOKEN'
Example Response
Header
Content-Type: application/json
Body
{
"timestamp": "2024-05-14T17:53:30.709+00:00",
"status": 404,
"error": "Not Found",
"message": "Public person id invalid or not found",
"path": "/token/person/INVALID_PUBLIC_PERSON_ID",
"errors": [
{
"code": "00.01.0017",
"description": "Public person id invalid or not found"
}
],
"refresh_token": "MY_ACCESS_TOKEN"
}