---
title: "Record CASL consent for a phone number or email address"
method: POST
path: "/v1/compliance/consents"
tags: ["Compliance / CASL"]
---

# Record CASL consent for a phone number or email address

`POST /v1/compliance/consents`

## Request

- Base URL: `https://api.honkio.ca`
- URL: `https://api.honkio.ca/v1/compliance/consents`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Records express or implied consent per CASL §6-10. Every SMS needs consent on file for its recipient, transactional or commercial (a verification code through the Verify API needs none); email needs it only for commercial sends. Refused with 409 CONSENT_REVOKED_BY_REVIEW when HonkIO revoked this recipient's consent on review of a bulk upload: such consent cannot be recorded again unless HonkIO lifts the block.

Requires `compliance:w`.

## Request body

- object
  - `phone_number` string: E.164 phone number of subscriber
  - `email_address` string: Email address of the subscriber (email channel). Email consent is available when the email product launches.
  - `consent_type` 'express' | 'implied', required
  - `source_description` string: How/where consent was obtained (required for express)
  - `source_ip` string: IP address of subscriber at time of consent
  - `source_url` string: URL where consent was obtained
  - `relationship_type` string: Business relationship type (required for implied; e.g. "purchase")
  - `last_transaction_date` string, date: Date of last transaction (implied consent: expiry calculated from this)
  - `expires_at` string: Explicit expiry (ISO 8601 date or date-time) for implied consent. Overrides the expiry derived from last_transaction_date. Not accepted for express consent, which never expires (CASL §10).

## Response `201`

Default Response

- object
  - `status` string
  - `phone_number` string
  - `email_address` string
  - `expires_at` string, nullable: When this consent lapses (implied only); null for express consent.

## Other responses

- `401`: Missing, invalid, revoked or expired API key.
- `402`: The account has no balance, or a LIVE key was used before the first top-up.
- `403`: The API key lacks the permission this operation requires, or the account is suspended or closed.
- `409`: CONSENT_REVOKED_BY_REVIEW: HonkIO revoked this recipient's consent on review of a bulk upload, so it cannot be recorded again unless HonkIO lifts the block.
- `422`: INVALID_PHONE_NUMBER, EMAIL_INVALID_ADDRESS, or VALIDATION_ERROR (provide exactly one of phone_number or email_address; express consent needs source_description and takes no expires_at; implied consent needs relationship_type).
- `429`: Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).
- `500`: Unexpected server error.
- `501`: EMAIL_COMING_SOON: email consent is available when the email product launches (sent only for an email_address request).

---

[API](https://skmtc.dev/honkio/apis/honkio-api.md) · [All operations](https://skmtc.dev/honkio/apis/honkio-api/llms.txt) · [OpenAPI document](https://skmtc.dev/honkio/apis/honkio-api/revisions/ce4ed3fe9691?raw)
