Skip to main content

Whautomate REST API Error Messages

A request that fails returns an HTTP error status and a JSON body, usually {"error": "..."}. Some errors add a code you can check in your program. Errors from the key check and the API gateway use {"message": "..."} instead. Successful requests return 200.

The status code is the real outcome of the request, so check it before reading the body.

Status codes​

StatusExample bodyWhat it means and how to fix it
400 Bad Request{"message": "Invalid request body"}The JSON is malformed, or a field has the wrong type. Check commas, brackets and quotes, and the field types on the endpoint page.
400 Bad Request{"error": "Invalid parameters"}A required field is missing or has an invalid value. Many endpoints say exactly what is wrong, for example Invalid time format. Please provide the time in the format 'hh:mm AM/PM'.
400 Bad Request{"error": "...", "code": "CHANNEL_NOT_CONNECTED"}The channel you are sending on (WhatsApp, Telegram, SMS, Instagram, Messenger, TikTok, live chat) is not connected in that location. Connect it in Integrations.
401 Unauthorized{"message": "Unauthorized"}The x-api-key header is missing, or the key is wrong or was deleted. Copy the key again from Settings > Integrations > REST API.
403 Forbidden{"error": "This feature is not included in your plan.", "code": "MODULE_NOT_ENABLED", "module": "bookings", "modules": ["bookings"]}Your plan does not include the add-on this action needs (crm, bookings or sales). Reading data and handling existing bookings still work. See Plan add-ons.
403 Forbidden{"error": "Your subscription is not active. Renew it to send messages.", "code": "SUBSCRIPTION_INACTIVE"}Sending messages and broadcasts needs an active subscription. Renew your plan in the app.
403 Forbidden{"error": "WhatsApp account is restricted by Meta. ...", "code": "ACCOUNT_RESTRICTED"}Meta has restricted (ACCOUNT_RESTRICTED) or disabled (ACCOUNT_DISABLED) the WhatsApp account, or it is disconnected (ACCOUNT_DISCONNECTED). The message says until when; reconnect or review the account in Integrations > WhatsApp.
404 Not Found{"error": "Location not found in the account."}The location id is wrong, from another account, or the location is deactivated. Records of a deactivated location answer the same. Get ids from GET /v1/locations.
404 Not Found{"error": "Client not found in the account."}The record id (client, contact, class, credit and so on) does not exist in your account. Use the id the API returned, not the client number shown in the app.
405 Method Not Allowed{"error": "There are no slots available at the selected time"}The action is not possible right now: the time is taken, no team member is free, the booking is past its reschedule or cancellation cut-off, or the record cannot be changed (for example a category still in use). Method not supported means the endpoint is read only (locations and staff).
409 Conflict{"error": "...", "code": "PRICE_CONFIRMATION_REQUIRED", "priceChange": {...}}Reschedule with repricing: the new time costs more. Show priceChange to the client and send the request again with the difference accepted.
409 Conflict{"error": "No slots available ..."}Booking with payment: the time is no longer free. Get fresh times from available slots.
429 Too Many Requests{"message": "Too Many Requests"}You went over your rate limit. Slow down and retry after a short wait.
500 Internal Server Error{"error": "Something went wrong."}Something went wrong on our side. Retry later; if it keeps happening, contact support with the request and the time it was sent.
503 Service Unavailable{"error": "This time is being booked right now. Please try again in a moment."}Someone else is booking the same time at this moment, or the service is briefly unavailable. Retry after a few seconds.

Bulk endpoints answer 200 even when some items fail: each item in results has its own status and error.

Tips​

  • Log the status code and body of failed requests; the message usually says what to fix.
  • Retry 429, 500 and 503 responses with a growing delay. Do not retry 400, 401, 403, 404 or 405 without changing the request.