Errors / insufficient_scope

Insufficient scope

HTTP 403invalid_requestinsufficient_scope

The key is valid but does not carry the scope this endpoint needs. The message names it.

What to do

Scopes are fixed when a key is created, so add a key with the scope you need rather than editing this one. Resist the temptation to reach for a key with everything: a booking system that sends confirmations has no reason to be able to read your contact list, and the day a key leaks is the day you find out whether you agreed with that.

What it looks like

{
  "error": {
    "type": "invalid_request",
    "code": "insufficient_scope",
    "message": "…",
    "doc_url": "https://docs.textmast.com/errors/insufficient_scope",
    "request_id": "req_01j8xk2p7n4qc3m9v0wz5bt6ay"
  }
}

Quote the request_id if you get in touch. It is on every response, including this one, and it turns a support email into a single log query rather than an archaeology exercise.