cancel
Showing results for 
Search instead for 
Did you mean: 

Rest API - allow customer to fetch and delete their addresses.

0 Kudos

Rest API - allow customer to fetch and delete their addresses.

I  know there are endpoints for both fetching an address by id and deleting one by id.

Listed below: (customerAddressRepositoryV1) as listed here http://devdocs.magento.com/swagger/index_20.html#/

1) To get a address 
Endpoint: /V1/customers/addresses/{addressId}
Method: GET

2) To delete a address
Endpoint: 
/V1/addresses/{addressId}

Method: DELETE

The issue with either of them is that they are not accessible by customer token. They seem to only work with Admin Token Authentication.

If a customer adds multiple addresses and selects a specific one to fetch entire details or delete it, it should be allowed from his customer access.

Please suggest.