Errors
Every error the API can answer, why it happens, and what to do.
Errors answer with an HTTP status and a JSON body with one field, error:
{ "error": "Device is not connected" }Decide what to do from the status. When two errors share a status, as with 402 and 429, read the error text too.
| Status | error | Why | What to do |
|---|---|---|---|
400 | invalid id | The Device id in the URL isn't a positive whole number. | Fix the URL. |
400 | label is required, to and type are required, text is required for type=text, media_url is required for media types, url and secret are required | A required field is missing. | Send the field. |
400 | Unsupported type: … | type isn't text, image, document or audio. | Use one of those. |
400 | Invalid media URL: …, Failed to download media: …, Refusing to fetch media from a private/reserved address … | We couldn't download the file from media_url. | Use a public http/https link that works. |
400 | Cap exceeds admin ceiling | A Send Cap is above the allowed maximum. | Use a lower cap. |
401 | Missing or invalid Authorization header | No Authorization: Bearer … header. | Send your API Key. See Authentication. |
401 | Invalid API key | The key is wrong or revoked. | Check the key, or create a new one. |
402 | No active Subscription | Your Tenant has no active Subscription. | Renew. See Subscription. |
402 | Device Quota reached | Your Plan allows no more Devices. | Upgrade your Plan, or delete a Device you don't use. |
404 | Device not found | No Device with this id in your Tenant. | Check the id with GET /v1/devices. |
404 | No QR available. Device may already be connected. | No QR code right now. | Check the Device's status. Ask again in a few seconds. |
409 | Device is not connected | The Device isn't connected. | Link it again. See Devices. |
413 | Media exceeds … byte limit for type … | The file is too big. | Images up to 5 MB. Documents and audio up to 16 MB. |
429 | Monthly Message Quota reached | Your Plan's monthly Message Quota is used up. | Wait for next month, or upgrade your Plan. |
429 | Rate limit exceeded (hourly cap: 60) or (daily cap: 500) | This Device reached a Send Cap. | Send later, or from another Device. |
500 | Internal Server Error | Something went wrong on our side. | Try again later. If it continues, contact us. |
Don't retry 400, 401, 402, 404 and 409 without changing something first. The same request fails again. Retry 429 later, and 500 after a short wait.