Skip to main content
When something goes wrong with a Scalysis API call, the response will almost always include a descriptive error message to point you in the right direction. This page walks you through every common error, explains why it happens, and shows you exactly what to change so you can get back to making calls as quickly as possible.

Common Errors

What it means: The server could not verify your identity. Your API key is either missing from the request, misspelled, or formatted incorrectly.How to fix it:Make sure every request includes one of the two accepted auth headers. Choose whichever style your HTTP client makes easiest:
Do not include both headers in the same request — use one or the other. Also confirm you are copying the full key from the Scalysis dashboard with no leading or trailing spaces.
For POST requests, you also need the content-type header alongside your auth header:
What it means: You sent a trigger or campaign-creation request without a scriptId, or the value you provided is not a valid number.How to fix it:Include scriptId in your request body and make sure its value is the integer shown in the Scalysis UI for the AI agent script you want to use — not a string.
You can find your script IDs by logging into the Scalysis dashboard and navigating to the Scripts section. Each script card displays its ID.
What it means: The phone number to dial is missing. This can happen either because you omitted customerPhone from the trigger body, or because a contact in your campaign’s contacts[] array is missing a phone field.How to fix it:For a single-call trigger, add customerPhone directly to the request body:
For a campaign using contacts[], make sure every contact object includes a phone number:
If you are using csvText instead, verify the column specified by phoneColumn (default: "phone_number") is present and populated in every row.
What it means: The script you selected contains a brand_name placeholder, but you did not supply a value for it in the request body. The AI agent cannot speak the brand name during the call without it.How to fix it:Add brand_name as a top-level field in your request body:
If your script uses other custom variables beyond brand_name, the error message will list all of the missing ones at once (e.g., Missing required script variables: brand_name, agent_name). Add each missing variable as its own key in the request body.
What it means: You sent a GET request for a call outcome, but the call has not finished yet. Scalysis returns a 404 here to signal that a finalized result does not exist yet — not that the order_id is wrong.How to fix it:Wait 10–30 seconds after triggering a call before polling for the outcome, then retry your GET request:
Build a short retry loop into your integration rather than firing the outcome request immediately after the trigger response. A simple approach is to wait 15 seconds, then poll every 5 seconds until you receive a successful response.
What it means: The order_id or campaign_id you referenced does not exist under the API key you are using. This usually means one of the following:
  • You used an ID from a different store or a different API key.
  • You mistyped or truncated the numeric ID.
  • The resource was deleted from the Scalysis dashboard.
How to fix it:Double-check that the order_id or campaign_id value matches exactly what was returned in the original trigger or create response:
IDs are scoped to your API key. An order_id created with one key is not accessible using a different key, even within the same Scalysis account.
What it means: Your account’s calling channel pool is fully occupied by active campaigns. Scalysis cannot start new concurrent calls until capacity is freed up.How to fix it:You have two options:
  1. Pause or stop a running campaign to release channels, then start the new one.
  2. Lower maxConcurrency on your active campaigns so they each consume fewer channels, leaving room for the new one.
The server may also enforce a hard cap on maxConcurrency regardless of what you request. If you need a higher concurrency limit, contact Scalysis support to discuss your plan limits.

Auth Header Reference

Every request to the Scalysis API must be authenticated. You can use either of the two header formats below — pick one and use it consistently across all your requests. Option A — Bearer token:
Option B — X-API-Key:
For any POST request (triggering a call, creating a campaign, controlling a campaign), include the content-type header as well:
Here is a complete POST example using curl:
And a GET example for fetching a call outcome:
Every successful Scalysis response includes "success": true at the top level. Make this the first field you check in your integration logic — if it is absent or false, read the accompanying message field for a plain-English description of what went wrong.