Apply Discount Voucher

This API endpoint allows applying a voucher code for a customer. The request body must contain the voucher code.

Authorization: Bearer YOUR_TOKEN


Expected Behavior:


  • On success, the system will apply the voucher and return a confirmation message.
  • If the request is unauthorized or invalid, the system will respond with an error message.
Request Body Parameters
  • code string
    The voucher code to be applied. Example: 'AAACCCBBDD-CSSSS1'
curl -X POST "https://api.pinghome.io/customer-cmd/v1/customer/applied-voucher" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
--data '{
  "code": "AAACCCBBDD-CSSSS1"
}'
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).