Errors / insufficient_credit

Insufficient credit

HTTP 402invalid_requestinsufficient_credit

The campaign, or the first month of a rented number, would cost more than the balance on the account.

What to do

Top up, then send. The check happens before the campaign starts rather than partway through, because a send that stops mid-list has messaged some of your customers and not others, which is worse than not sending at all. The message names both the estimate and the balance. Renting a number takes its first month from the balance before anything is bought, and nothing is bought if the balance cannot cover it.

What it looks like

{
  "error": {
    "type": "invalid_request",
    "code": "insufficient_credit",
    "message": "…",
    "doc_url": "https://docs.textmast.com/errors/insufficient_credit",
    "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.