GREMDocs

Errors

Last updated: 2026-07-212 min read

Errors use the RFC 7807 application/problem+json format, so they are consistent and machine-readable:

HTTP/1.1 400 Bad Request
Content-Type: application/problem+json

{
  "type": "https://docs.grem.capital/api/errors/validation",
  "title": "validation",
  "status": 400,
  "detail": "totalArea (m2) is required",
  "requestId": "req_…"
}

Always log the requestId — quote it in support requests to trace a call.

Status codes

StatusMeaningWhat to do
400Validation errorFix the request body/params per detail.
401Invalid or missing keyCheck the Authorization header.
402Insufficient funds or quotaTop up or upgrade the plan.
403Missing scopeThe key isn't scoped for this tool.
404Not foundWrong path, or the resource doesn't exist.
409Idempotency conflictA request with this Idempotency-Key is still in flight.
422Business ruleThe request is valid but can't be processed as-is.
429Rate limitedBack off and retry — see Rate limits.
5xxService errorTransient; retry with backoff.

A rejected request (4xx) is not billed — the per-call charge is only captured on success.

Handling errors

  • Branch on the numeric HTTP status, not on the human-readable detail text.
  • Retry 429 and 5xx with exponential backoff; do not retry 4xx (except 409, after the in-flight request finishes).
  • Provider details are never leaked in errors — a failure surfaces as a generic provider_error.

Was this article helpful?