Subscribe
Signs someone up to the newsletter. The subscriber is a customer, matched by email or created with just an email, who has opted in to marketing email.
POST
https://api.duma-business.com/v1/store/newsletternewsletter:writeSecret key only
Signing up again after unsubscribing opts the address back in. alreadySubscribed is true when they were already opted in.
Request example
Example request
curl -X POST "https://api.duma-business.com/v1/store/newsletter" \
-H "Authorization: Bearer dk_sec_…" \
-H "Content-Type: application/json" \
-d '{
"email": "[email protected]",
"firstName": "Amelia",
"lastName": "Hart"
}'Request body
JSON, sent with Content-Type: application/json.
emailstringRequired- Lower-cased for you. Up to 255 characters.
Optional
firstNamestring- Up to 100 characters.
lastNamestring- Up to 100 characters.
Response
Response · 200
{
"data": {
"status": "subscribed",
"alreadySubscribed": false
}
}