Skip to main content
Praxa API failures are typed authority, validation, state, or availability signals. Read the HTTP status, code, retryable, and retry guidance together. Never turn every non-2xx response into the same automatic retry.

Understand the problem response

The response may omit optional fields. Record requestId, status, code, and a redacted operation label. Do not log bearer tokens, webhook secrets, task content, memory content, or arbitrary upstream bodies.

Decide what to do next

Distinguish failure from an unknown outcome

A client timeout, interrupted connection, or retryable 5xx does not prove that a mutation failed. For a keyed mutation:
  1. Keep the exact serialized input and original idempotency key.
  2. Read the returned resource when an identifier is known.
  3. Otherwise replay the exact request with the same key.
  4. Accept a matching replay as reconciliation.
  5. Treat a changed-body 409 as evidence that the stored input and retry no longer match.
For an unkeyed read, use bounded exponential backoff with jitter only when the problem says it is retryable.

Inspect headers and body with cURL

Use temporary files containing synthetic data and remove them after the test.

Test failure behavior before production

  • missing, malformed, under-scoped, and revoked credentials;
  • invalid body and over-limit input;
  • foreign run, endpoint, delivery, candidate, tenant, and subject identifiers;
  • exact mutation replay and changed-body conflict;
  • 429 with a bounded retry budget;
  • client timeout after admission;
  • SSE disconnect before terminal state;
  • webhook duplicate, invalid signature, and expired timestamp;
  • memory provider outage and candidate deletion.
The end-to-end testing tutorial turns these cases into a reusable release gate.
Last modified on August 14, 2026