Delete An Address
Delete an existing profile address
HTTP Request
Delete Address:
DELETE/api/shop/customers/me/addresses/:id
Authorization
Authorization
- Required: Yes
- Permission: Authenticated Customer
- Authentication: Token-based (`Authorization: Token <your_api_key>`)
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | Integer | Yes | Unique ID of the address |
Example Requests
- 🐍 Python
- 🌐 Curl
1import requests
2
3# Delete address
4response = requests.delete('http://www.example.com/api/shop/customers/me/addresses/123',
5 headers={'Authorization': 'Token <your_api_key>'}
6)
7print(response.status_code) # Should be 2041# Delete address
2curl -X DELETE "http://www.example.com/api/shop/customers/me/addresses/123" -H "Authorization: Token <your_api_key>"Response Fields
| Field | Type | Description |
|---|---|---|
| None | None | No response body returned |
Notes
- Geographic Validation: State must belong to the specified country, and city must belong to the specified state
- Access Control: Customers can only access their own addresses
- Default Address: Only one address can be set as default per customer