Launch & operate
Errors & retries
How beatra returns errors and what to do about each one.
Every error from beatra has the same shape and tells you whether it's safe to retry. Follow the one flag.
Error shape
The full list of code values lives in Error codes.
The one rule
- Retry only when
retryableistrue. - Use exponential backoff with jitter.
- Reuse the same
Idempotency-Keyon every retry of the same logical operation. - Stop after a reasonable number of attempts and show a stable message to your user.
What never to retry
Validation errors, authentication errors, and permission errors are deterministic. Retrying them gives the same answer and burns quota. Surface a clear message and let the user correct the input or contact support.
Logging
- Store the
request_idfrom every error alongside the user-facing job record. - Keep the response
X-Request-Idheader even when the call succeeds — it's the same id and the fastest way to find a request in support.
Customer-facing messages
Don't show raw code or message values to end users. Map a small set of intents (busy, invalid input, please retry, contact us) and translate the technical error into your own copy.