Skip to main content

Errors

The Partner API uses standard HTTP status codes with JSON bodies. FastAPI-style validation errors return 422 Unprocessable Entity.

Common statuses​

CodeMeaningAction
401Missing/invalid X-API-Key or X-Client-IDRotate credentials with Lynq ops
403IP not on partner allowlistUpdate allowlist or fix egress IP
404Order or webhook not foundCheck ULID and environment
409Conflict (e.g. cancel not allowed)Inspect current order status
422Schema validation failedFix request payload
429Quote rate limit exceededHonour Retry-After; see Rate limits
503Quote routing/pricing unavailable (distance_unavailable) or OSRM ETA unavailable (eta_unavailable)Retry with exponential backoff

Response shapes​

Simple error:

{"detail": "Invalid API key"}

Structured detail (example):

{"detail": {"error": "distance_unavailable"}}

Validation (422):

{
"detail": [
{"loc": ["body", "dropoff", "contact_phone"], "msg": "field required", "type": "missing"}
]
}

Webhook endpoint errors​

Your listener should:

  • Return 2xx quickly after enqueueing work (avoid long DB transactions in the HTTP thread)
  • Return 4xx only for permanent misconfiguration Lynq should not retry (rare — consult Lynq if unsure)
  • Log X-Lynq-Signature, X-Lynq-Event, and envelope id for support tickets