Docs
Open dashboard

Add opt-out

POST/sms/opt-outs

Adds a number to the unsubscribe list. The number is stored as digits only. Adding a number already on the list is not an error: it returns 200 with the existing entry and already: true. Works without credits.

Requires Authorization: Bearer <api_key>. Create a key in the Inspra dashboard under Workspace Settings → API Keys.

Body application/json

  • phone_numberstringrequired

Response 200 OK

Number was already on the list.

  • idstringuuidoptional
  • phone_numberstringoptional
    Stored as digits only.
  • sourcestringoptional
    How the number got here. stop_keyword (the contact texted STOP), manual (added in the app) or api.
  • campaign_idstringnullableuuidoptional
  • created_atstringdate-timeoptional
  • alreadybooleanoptional

Errors

  • 400Bad Request
    Validation failed / malformed request.
  • 401Unauthorized
    Missing, malformed, or invalid API key.
  • 403Forbidden
    Workspace unavailable, suspended, or paywalled.
  • 429Too Many Requests
    Workspace request limit exceeded; shared across all its API keys.