Saltar al contenido principal
Beta sin calibrar
StrikeStrike

Errors

HTTP status codes, JSON error bodies, and Python exceptions in strikeflow.

JSON error shape (HTTP API)

Non-2xx responses use a nested error object:

JSON
{
  "error": {
    "type": "api_error",
    "code": "authentication_error",
    "message": "Invalid API key",
    "param": null,
    "request_id": ""
  }
}

type is invalid_request for HTTP 422 validation failures, otherwise usually api_error.

Responses include x-request-id (and x-strike-api-version) headers.

HTTP status codes

Statuscode (typical)Meaning
401authentication_errorMissing or invalid Bearer token
404(varies)Resource not found
413payload_too_largeBody over limit on the public proxy (see Rate limits)
422validation_errorRequest failed schema or engine validation
429too_many_requests or quota_exceededRate limit or monthly beta quota
503model_warmingstrike-1 is starting up. Retry after the Retry-After header when present.
529engine_unavailable, inference_overloadedEngine not ready or upstream failure
530engine_unavailablestrike-1 is temporarily unreachable. The SDK retries it.

Proxy-only 429 body example:

JSON
{
  "error": {
    "type": "rate_limit",
    "code": "too_many_requests",
    "message": "Too many requests. Try again shortly."
  }
}

Monthly cap (platform keys): HTTP 429 with code quota_exceeded and a message referencing the beta cap.

Python exceptions (strikeflow)

Catch strike.StrikeError for all SDK failures.

ExceptionWhen
APIConnectionErrorDNS, TLS, connection reset
APITimeoutErrorRequest timed out
AuthenticationErrorHTTP 401 or 403
RateLimitErrorHTTP 429
NotFoundErrorHTTP 404
InternalServerErrorHTTP 5xx including 530
APIStatusErrorOther non-2xx

APIStatusError exposes status_code, body, and request_id.

Retries

StrikeModel retries 408, 409, 429, 5xx, 530 and connection/timeouts up to max_retries (default 2) with jittered backoff, honouring Retry-After when present.

Python
import strikeflow as strike

strike.configure(max_retries=3, timeout=45.0)

Decision tool errors

strike_decision_tool().handle(...) does not raise for decision failures. It returns {"error": "..."} so the host LLM loop can continue.

User-facing copy

The console maps common statuses to short titles in its error catalogue (401, 404, 413, 422, 429, 529, 503 model warming, network). Use those messages in UI; in backend code prefer checking status_code and error.code.

Errors: Strike docs