Delete Customer Account
This endpoint is used to permanently delete a customer account from the system. To perform this action, a valid deletion reason must be provided.

When to use:
When a customer requests account removal or when the account must be deactivated for business, compliance, or security reasons.

Important notes:
  • This action is irreversible — all associated data will be removed.
  • A reason for deletion is required for auditing and record-keeping purposes.

This endpoint helps enforce data control and compliance with user account management policies.

Authorization: Bearer YOUR_TOKEN


Expected Behavior:


  • On success, the system will delete the customer record and return a confirmation message.
  • If the request is unauthorized or invalid, the system will respond with an error message.

Need to view or update customer details instead? Visit Get Customer or Update Customer.
Request Body Parameters
  • reason string
    The reason for deleting the customer. Example: 'poor-features'
JavaScript
Response codes
const axios = require('axios');

const url = "https://customer-cmd.api.pinghome.io/v1/customer";
const data = {
    "reason": "poor-features"
};

axios.delete(url, {
  headers: {
    'Authorization': 'Bearer YOUR_TOKEN',
    'Content-Type': 'application/json'
  },
  data
})
.then(response => {
  console.log(response.data);
})
.catch(error => {
  console.error(error);
});
ResponseThis section is used to view the possible HTTP response codes returned by the API. These codes indicate the status of a request, such as 201 (Created), 401 (Unauthorized), 409 (Conflict), or 422 (Unprocessable Entity).