SendPulse error_code 999 "Badly formed incoming data" fix
SendPulse's error_code 999 "Badly formed incoming data" means the server could not parse what it received. In the flow builder, hard refresh (Ctrl/Cmd+Shift+R) and retry; SendPulse staff say that save error is logged on their side. In the API, isolate your request step by step.
Sohail Hussain8 min readShort answer
- If you see the error while saving a flow in the flow builder, do a hard refresh (Ctrl+Shift+R on Windows and Linux, Cmd+Shift+R on Mac), redo your last change and save again. SendPulse staff have said this error is on their side and is logged automatically.
- If you get it from an API call, the cause is most likely in the request body or how your code or SDK serializes it. Capture the raw request, replay it with curl, then shrink the payload until it works.
- If neither helps, send SendPulse support the endpoint, the sanitized body, the full response and a UTC timestamp.
You call the SendPulse REST API from Node, or click save in the flow builder, and get this back:
{ error_code: 999, message: 'Badly formed incoming data' }
Or the flow builder simply refuses to save and shows the same error. The text suggests SendPulse's server could not parse what it received, but it does not say which field or action was the problem.
One limit up front: SendPulse does not publish a list of what triggers 999, and the public reports I found contain no confirmed root cause for the API version. A report in the issue tracker of SendPulse's Node REST library has been open since 2021 with only a few comments. What follows is a way to isolate the problem, not a guaranteed fix.
Why it happens
The code 999 is a SendPulse application error, not an HTTP or SMTP status code, so it does not map to a standard meaning. Two different situations produce the same text.
| Where you see it | Likely side | Symptom | First move |
|---|---|---|---|
| REST API call (Node or any other client) | Probably your request | Call fails with error_code: 999 | Capture the raw request, replay it with curl |
| "Can't save flow" in the flow builder | SendPulse, per their staff | Save button fails, error shown | Hard refresh, retry, then contact support |
For the flow builder, a user on SendPulse's subreddit reported being unable to save a flow, and a SendPulse representative replied that the error was on their end and logged automatically, advising a refresh and retry. That is one staff answer, not a published root cause.
For the API, the causes below are plausible rather than confirmed. They are the usual reasons a server says "badly formed data":
- The body is not valid JSON after serialization (an
undefinedturned into the text "undefined", a nested object flattened, an array sent as a string). - A content type mismatch: JSON sent with a form content type, or the reverse.
- Wrong value types: a number where a string is expected, an empty string where a list is expected, or
nullin a required field. - Invalid characters: smart quotes, control characters or broken UTF-8 in names or HTML bodies.
- An SDK bug in how it builds the request. This is the one the library's open issue hints at, but it is not confirmed.
Fix it in the flow builder
- Press Ctrl+Shift+R (Windows, Linux) or Cmd+Shift+R (Mac) to reload the page without the cache.
- Reopen the flow and redo your last change before saving. An old session may be holding stale state.
- If it still fails, try a private window with browser extensions off. This is my suggestion, not SendPulse's, but it rules out a blocker interfering with the save request.
- Contact SendPulse support with the flow name, the time of the failed save (with your timezone) and a screenshot of the error. A timestamp helps them find the logged entry.
Save a copy first
If the flow is large, note down or screenshot your recent changes before refreshing. A hard refresh can discard unsaved edits.
Fix it in the API
Do not wait for the library to change; isolate your own request.
1. Capture exactly what you send
Log the final HTTP request: method, URL, headers and the raw body after serialization. The object you built in code is not what the server sees. Look for values that serialized differently than you expected.
2. Replay it outside your code
Get an access token, then send the same body with curl or a REST client. SendPulse uses OAuth client credentials:
curl -X POST https://api.sendpulse.com/oauth/access_token \
-H "Content-Type: application/json" \
-d '{"grant_type":"client_credentials","client_id":"{your-id}","client_secret":"{your-secret}"}'
Then call the failing endpoint with an Authorization: Bearer {token} header and the same body. If curl succeeds, the bug is in how your Node code or the SDK builds the request. If curl fails with the same 999, the payload itself is the problem.
3. Shrink the payload until it works
Cut the body down to the smallest request the endpoint documents and confirm it succeeds. Then add fields back one at a time. The field whose return brings back 999 is your culprit. It is slow but reliable when the message tells you nothing.
4. Check the usual suspects
- Content type matches what the endpoint's documentation specifies.
- Each field has the structure the API reference describes; do not assume.
- Names and HTML bodies contain no control characters or broken UTF-8.
- No
null, empty string or wrong type in a required field. - Try a fresh access token. A stale token is less likely to produce this exact message, but a new one is cheap.
5. Bypass the SDK
If curl works and your SDK call fails, send the request with fetch or axios directly. If that works, you have found an SDK serialization problem. Add it to the library's GitHub issue with a redacted minimal example.
Keep secrets out of logs
When you log raw requests, strip the client secret, access tokens and recipient data before sharing them in an issue or a support ticket.
Checklist before you contact support
- The failing call reproduces with curl using the same body.
- The body is the smallest one that still fails.
- You tested with a fresh token.
- For the flow builder: hard refresh done, private window tried.
- You wrote down the UTC time of one failing attempt.
If nothing works
Contact SendPulse support through your account's help channel. Support can see logs you cannot, and staff have said flow-builder failures are logged automatically, so an exact timestamp is the most useful detail. Include:
- The endpoint and HTTP method
- The request body with secrets and personal data removed
- The full response, including
error_codeand message - The UTC timestamp of a failing call
- Whether curl reproduces it, and whether a fresh token changes anything
- For flows: the flow name and a screenshot
Subject: error_code 999 "Badly formed incoming data" on {endpoint}
Hello,
Since {date}, {method} {endpoint} returns:
{ error_code: 999, message: 'Badly formed incoming data' }
Failing call at {UTC timestamp}. The sanitized request body is below.
It also fails with curl using a fresh access token (or: it works with curl
but fails through the Node SDK).
Minimal body that fails:
{paste body with secrets removed}
I have already tried: shrinking the payload, replaying with curl,
checking content type and encoding.
Could you check the logs for this timestamp and tell me which field
is rejected?
Thank you
Common questions
Is error 999 an HTTP status code?
No. It is a SendPulse application error code returned in the response body. Check the actual HTTP status separately; it may help you tell auth problems from payload problems.
Will updating the Node library fix it?
I could not confirm that. The related issue in the library's repository has been open since 2021 without a documented fix, so test with a direct fetch or axios call to see whether the SDK is involved.
Can I retry automatically?
For the flow builder, a retry after a hard refresh is what staff suggested. For API calls, blind retries rarely help if the payload is malformed, so fix the request first and retry only after a successful curl replay.
How do I stop it recurring?
Validate payloads against a schema before sending, log the serialized body on any non-2xx response, and keep one known-good curl command per endpoint you use. For general patterns around retries and payload checks, see our API and webhooks guide.
Explore: Email Automation
Related Articles
Drip Zapier error: "Could not locate the bindings file"
This Zapier error points to a problem inside the Drip app's code, where a compiled native module (the deasync bindings file) could not be found. Your Zap settings are not the likely cause. Replay the run, check Zapier's status page, and send the run details to Zapier support if it repeats.
Lemlist Trigger: 404 - {} in n8n: fix and Make errors
"Lemlist Trigger: 404 - {}" in n8n usually means the trigger could not register its webhook with lemlist. On self-hosted n8n, set WEBHOOK_URL to a public HTTPS address, restart, and re-activate the workflow. If that fails, re-check the API key and the campaign you selected.
Mailchimp Omnivore account suspended: triggers and review fix
Omnivore is Mailchimp's automated abuse-prevention system. It suspends accounts when it flags a list or content, often at send time. You can't switch it off. Reply to the suspension notice with proof of how each contact opted in, keep everything in one ticket, and follow up through support chat.
Marketing Cloud "General System Error" in Automation Studio SQL
In Salesforce Marketing Cloud, "General System Error" on an Automation Studio SQL activity is a catch-all message that often hides an ordinary syntax or schema mistake. Validate the query, check field types and lengths, run it in pieces, then try another browser or a cleared cache. If it persists, contact Salesforce support.
Ready to supercharge your email marketing?
Start sending smarter emails with AI-powered campaigns. No credit card required.
Get Started Free