Klantly Developers

Error codes

Every error is returned as application/problem+json with a fixed, English code. For each code you will find what went wrong and how to fix it.

The shape of an error

An error response always has type, title, status and code. For validation errors, errors contains the message per field. Every response has a request_id: mention it when you ask support for help.

application/problem+json
{
  "type": "https://developers.klantly.com/errors/validation_failed",
  "title": "The input is invalid.",
  "status": 422,
  "code": "validation_failed",
  "detail": "1 field is invalid.",
  "errors": {
    "email": [
      "The email field must be a valid email address."
    ]
  },
  "request_id": "req_01j7zq3k9x2m4n6p8r0t2v4w6y"
}

All error codes

HTTP status Code Meaning
400 bad_request Bad request.
401 api_key_expired This API key has expired.
401 api_key_revoked This API key has been revoked.
401 invalid_api_key Invalid API key.
401 unauthenticated Authentication required.
403 account_suspended This company's account has been blocked.
403 feature_not_available This feature is not available for this company.
403 forbidden Access denied.
403 insufficient_scope This API key has no access to this action.
403 ip_not_allowed This IP address may not use this API key.
403 limit_reached The subscription limit has been reached.
403 subscription_inactive This company has no active subscription.
404 not_found Not found.
405 method_not_allowed This method is not allowed here.
409 conflict This conflicts with the current state.
409 idempotency_in_progress A request with this Idempotency-Key is still in progress.
409 invalid_state_transition This action is not possible in the current status.
412 precondition_failed The record has been changed in the meantime.
413 payload_too_large The request body is too large.
415 unsupported_media_type This format is not supported.
422 idempotency_key_reused This Idempotency-Key was already used for a different request.
422 unknown_field The input contains an unknown field.
422 validation_failed The input is invalid.
429 rate_limited Too many requests.
500 server_error Something went wrong on our side.
503 api_disabled The API is temporarily unavailable.