Delete Warehouse
Permanently deletes a warehouse and its stock levels. This action cannot be undone.
HTTP Request
- URL:
/wareHouse/{id} - Method:
DELETE - Headers:
accessToken: Required. Your API access token.
- Required scope:
READ_WRITE_WAREHOUSE
Path Parameters
| Parameter | Type | Description |
|---|---|---|
id | String | Required. The ID of the warehouse to delete. |
cURL Example
curl --location --request DELETE '<BASE_URL>/wareHouse/6650c4b2e8a1f93d7c2b5e40' \
--header 'accessToken: <ACCESS_TOKEN>'
Response
- 200 OK: The warehouse was deleted successfully.
- 400 Bad Request: The access token is missing or invalid, does not have the required scope, the warehouse ID is not valid, or the warehouse is the default warehouse.
Sample JSON Response
{
"success": true,
"message": "WareHouse deleted Successfully"
}
Response Details
| Field | Type | Description |
|---|---|---|
success | Boolean | Whether the request was successful. |
message | String | Result message. |
Notes
- The default warehouse cannot be deleted. Make another warehouse the default first using Update Warehouse.