Easymailing
Store customers

Delete a store customer

DELETE /stores/{storeResourceId}/customers/{resourceId}

DELETE/stores/{storeResourceId}/customers/{resourceId}

Removes the customer record from the store. The audience member is kept, and is unsubscribed only if you ask for it with unsubscribe. Their orders stay in the store without a customer.

When to use: When the buyer is deleted in the shop. Use unsubscribe=true if they must also stop receiving emails.

When not to use: To unsubscribe a member without deleting the customer use member_unsubscribe.

Side effects: With unsubscribe=true, a member whose email is confirmed is unsubscribed: the confirmed email and SMS channels become suscriber.status.unsuscribed.admin, the unsubscription is recorded in the activity, the member's automations are cancelled and the unsubscription webhooks fire. A member whose email is not confirmed is not touched (an SMS-only member stays subscribed). The orders of the customer are kept but are no longer linked to anyone.

Permissions: Requires the manager role or higher, or the marketing.audiences.delete capability.

Authorization

X-Auth-Token<token>

Value for the X-Auth-Token header parameter.

In: header

Path Parameters

storeResourceId*string

Identifier (resource_id) of the store the customer belongs to.

resourceId*string

Identifier (resource_id) of the customer: the one you chose when you created it with create_store_customer.

Query Parameters

unsubscribe?boolean

If true, the audience member is also unsubscribed (only if it is currently subscribed).

Response Body

application/problem+json

application/problem+json

application/problem+json

curl -X DELETE "https://api.easymailing.com/stores/acme-shop/customers/customer-1042?unsubscribe=false" \  -H "X-Auth-Token: YOUR_API_KEY"
Empty