← Documentation home
POST
/hyax-api/v1/people/confirm-subscriptionConfirm subscription (double opt-in)
HMAC-SHA256 token signs the string `confirm:${email}:${teamId}` using `UNSUBSCRIBE_HMAC_SECRET` or `BETTER_AUTH_SECRET`.
Base URL: https://platform.hyax.com · Replace YOUR_API_KEY with your team API key.
Request body
| Field | Required | Description |
|---|---|---|
| Yes | ||
| teamId | Yes | |
| token | Yes | Hex HMAC-SHA256 of `confirm:email:teamId` |
Request examples
Same request in cURL, Node.js (fetch), and PHP (ext-curl).
curl -X POST 'https://platform.hyax.com/hyax-api/v1/people/confirm-subscription' \
-H 'Content-Type: application/json' \
-d '{
"email": "[email protected]",
"teamId": "clx_team_id",
"token": "<hex_hmac>"
}'Example response
Shape varies by data; values are illustrative.
{
"success": true,
"message": "Your subscription has been confirmed."
}