Integrate

Errors and status codes

What each status means, the body you get back, and how to surface it to the person filling the form.

StatusMeaningBody
200Stored and delivered{ "ok": true, "id": "…" }
200Caught by the honeypot{ "ok": true } with no id
400Body could not be parsed or is too large{ "statusMessage": "…" }
404Unknown form ID, or the form is a draft{ "statusMessage": "Form not found" }
410Form is closed or reached its response limit{ "statusMessage": "This form is closed" }
422A builder rule failed{ "statusMessage": "Email is required", "data": { "errors": [ … ] } }
429Rate limited{ "statusMessage": "Too many submissions…" }

Validation errors

A 422 lists every failing field so you can show all problems at once:

json
{
  "statusMessage": "Email is required",
  "data": {
    "errors": [
      { "field": "email", "message": "Email is required" },
      { "field": "message", "message": "Must be at least 20 characters" }
    ]
  }
}

Handling in the browser

js
const res = await fetch(endpoint, { method: 'POST', headers, body })
if (res.ok) return showThanks()
const err = await res.json().catch(() => ({}))
if (res.status === 422) showFieldErrors(err.data?.errors ?? [])
else if (res.status === 429) showMessage('Please wait a moment and try again.')
else showMessage(err.statusMessage || 'Something went wrong.')

Something missing or wrong? Email us and we will fix it.