Deletes the specified supplier.
Only suppliers that were created with the REST API can be deleted with this request.
Path
/api/%API_VERSION%/suppliers
/{supplier
}
Method
DELETE
Request headers
This request has the following headers.
Request headers
Name |
Value |
Description |
---|---|---|
|
|
|
|
|
Response content type. |
Request parameters
This request has the following parameters:
Request parameters
Name |
Parameter type |
Description |
---|---|---|
|
Path |
Name of the supplier. |
Request body
This request has an empty body.
Request example
The following is an example of a DELETE suppliers/{supplier} request.
DELETE https://192.0.2.57/api/1.1/
Accept: application/json Authorization: Basic |
Response headers
The response has the following headers.
Response headers
Name |
Value |
Description |
---|---|---|
Content-Type |
|
Response content type. |
Content-Length |
|
Response body size, in bytes. |
Response body
The response body contains a JSON object with a status of the operation.
[
{
"status": "Supplier successfully removed"
}
]
Status object properties are described in the following table.
Status object properties
Property |
Value |
Description |
---|---|---|
|
|
Status of the operation. |
Response example
The following is an example of a DELETE suppliers/{supplier} request response.
НТТР/1.1 201 ОК Date:Mon, 23 Dec 2019 09:56:10 UTC Content-Type: application/json Content-Length: 46
[{"status": "Supplier successfully removed"}] |
Error responses
For more information about possible response statuses, see section "Response statuses".
An error response contains a JSON object with the error description.
[
{
"status": "An error occurred while removing the supplier",
"reason": "%REASON%"
}
]
Error object properties are described in the following table.
Error object properties
Property |
Value |
Description |
---|---|---|
|
|
Error description. |
|
|
Cause of the error. This property may not be present in the response. |
Error response example
The following is an example of a DELETE suppliers/{supplier} error response.
ННТТР/1.1 404 Supplier doesn't exist Date:Mon, 23 Dec 2019 09:56:10 UTC Content-Type: application/json Content-Length: 86
[{"status": "An error occurred while removing the supplier", "reason": "Supplier doesn't exist"}] |