Skip to main content

Error envelope

SendyKit error responses use this shape:
{
  "error": "subscriber not found",
  "code": "not_found"
}

Common error codes

CodeMeaning
unauthorizedMissing or invalid auth
forbiddenAuthenticated, but not allowed
not_foundResource does not exist
invalid_requestMissing or invalid input
internal_errorUnexpected server-side failure

Common statuses

StatusTypical cause
400Invalid request body, query, or params
401Missing or invalid API key / token
402Machine payment required for premium action
403Auth ok, permission denied
404Resource not found
409Idempotency or state conflict
500Internal server error

Source of truth

Defined in:
  • internal/respond/respond.go
  • docs/AUTH-BILLING-MATRIX.md