This API provides an interface to delete address at customer account.
This API only accepts DELETE requests.
https://dev-api.aymakan.com.sa/v2/address/delete
https://api.aymakan.net/v2/address/delete
The following headers should be sent along with the request
Your account security code / Api TokenBelow is the list of parameters which should be sent to this API to delete a customer address.
{info} The request parameters should be sent in request body using JSON format.
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | integer | Yes | Address ID |
A sample DELETE request body is below:
{
"id":"2"
}
The following response will be returned upon success.
{
"success": true,
"message": "Record Delete Successfully"
}
In case the "id" of the address entered in the request of the body is not linked to this current account, the following error will be returned.
Also, an HTTP status of 422 Unprocessable Entity will be returned.
{
"error": true,
"message": "Validation Error.",
"errors": {
"id": [
"The selected id is invalid."
]
}
}