ConceptsError responses

Error responses

The API uses standard HTTP status codes. Error bodies follow RFC 7807 (Problem Details for HTTP APIs):

{
  "type": "https://tools.ietf.org/html/rfc9110#section-15.5.5",
  "title": "Not Found",
  "status": 404,
  "detail": "Listing 99999999 not found in your feed scope.",
  "traceId": "00-f9c2…-c84e…-01"
}

Status codes you’ll see

StatusWhen
200 OKSuccess.
400 Bad RequestInvalid query param (e.g. radius without lat/long, malformed WKT polygon, resultsPerPage out of 1–100).
401 UnauthorizedMissing, malformed, revoked, or wrong X-API-KEY.
402 Payment RequiredTenant has no active subscription or trial — returned only from /portal/* (the portal API) when trying to connect a feed without billing set up.
404 Not FoundListing doesn’t exist OR it exists in CREA but isn’t in your tenant’s feed scope. Same status code for both — we don’t leak which case it is.
429 Too Many RequestsYou exceeded the per-tenant rate limit. See rate limits.
500 Internal Server ErrorGenuine server-side failure. traceId is the thing to send if you email support.

traceId

Every error carries a traceId — that’s the X-Ray correlation ID for the request across our Lambda + RDS Proxy + Postgres stack. If you reach out about a specific failure, include it; we can pull the full trace in seconds.

Don’t retry on 4xx

400 / 401 / 404 / 429 retries waste your rate-limit budget and our infrastructure. Only retry 5xx and network-level errors (DNS, TCP, TLS). A simple backoff:

async function withRetry<T>(fn: () => Promise<T>, max = 3): Promise<T> {
  for (let i = 0; i < max; i++) {
    try {
      return await fn();
    } catch (err) {
      if (err.status && err.status < 500) throw err;       // don't retry 4xx
      if (i === max - 1) throw err;
      await new Promise((r) => setTimeout(r, 2 ** i * 500)); // 500 / 1000 / 2000 ms
    }
  }
  throw new Error('unreachable');
}