reservation_create_failed

Creating the reservation failed for a reason that is not about the request. Retry with the same `Idempotency-Key`.

HTTP 502An upstream channel failed to complete the request. Safe to retry with backoff.

When it fires

Creating the reservation failed for a reason that is not about your request and is not covered by a more specific code. The status mirrors the failure — 502 when it is unknown. message carries what is known.

Response shape

Every Repull error follows the same envelope. The code is stable and safe to switch on.

{
  "error": {
    "code": "reservation_create_failed",
    "message": "Reservation creation failed",
    "fix": "See https://repull.dev/docs/errors for recovery steps.",
    "docs_url": "https://repull.dev/docs/errors/reservation_create_failed",
    "request_id": "req_01J5X7Y8Z9ABCDEF12345678"
  }
}

How to fix

  1. Check `GET /v1/reservations` for the listing and dates first: this failure is not stored against your `Idempotency-Key`, so a retry runs the create again.
  2. If nothing was created, retry with backoff.
  3. If it keeps failing, email hello@repull.dev with the `request_id`.

Examples

curl

curl -X POST https://api.repull.dev/v1/reservations \
  -H "Authorization: Bearer sk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: 9f1c2f7e-4a3b-4f2e-9c8d-1b6a0e5d7c31" \
  -d @booking.json

TypeScript

const { error } = await res.json()
if (error?.code === 'reservation_create_failed') {
  // Not stored against the key: check GET /v1/reservations before retrying
  console.error('create failed', error.request_id)
}

If you're an AI agent

Creating the reservation failed for an unknown reason. First check GET /v1/reservations for the listing and dates, since a retry runs the create again; retry with backoff only if nothing was created. Report the request_id if it persists.

Hit an error that isn't covered? Email hello@repull.dev with the request id from the response headers.

AI