Idempotency

Safe retries on write routes: send an Idempotency-Key header (any unique string, up to 256 characters). Edison stores the response for 24 hours per key.

Replay

Repeat the same key with the same body → original response with Idempotent-Replayed: true. Same key with a different body → 422 and code: "idempotency_mismatch".

Which routes

Shop PATCH, job approve/decline, webhook create/update, and other mutating routes honor idempotency when the header is present. Omit the header if you do not need deduplication.

BASH
curl -X PATCH https://app.tryedison.com/api/v1/shop \
  -H "Authorization: Bearer ed_test_…" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: setup-greeting-v1" \
  -d '{"greeting":"Thanks for calling."}'