toolzerhub API Docs

Responses & Errors

The success and error response envelopes, stable codes, and retry behavior.

Success responses

Every successful response is wrapped in a data field:

{
  "data": {
    "...": "endpoint-specific payload"
  }
}

The schema only guarantees data.products[].product_id for product-shaped endpoints; everything else is source-specific. See each operation in the API reference for its exact response shape.

Error responses

Every error response is wrapped the same way, regardless of endpoint:

{
  "error": {
    "code": "NOT_FOUND",
    "status": 404,
    "message": "User not found.",
    "retryable": false,
    "details": {}
  }
}
FieldTypeMeaning
codestringStable machine-readable code for the failure
statusnumberThe matching HTTP status code
messagestringHuman-readable description of what went wrong
retryablebooleanWhether retrying the same request could succeed
detailsobjectOptional extra context, shape varies by error

Error codes

CodeTypical meaning
INVALID_REQUESTThe request was malformed — a missing or invalid parameter
UNAUTHORIZEDThe x-api-key header was missing or invalid
FORBIDDENThe key is valid but not allowed to access this resource
PAYMENT_REQUIREDOut of credits — see Credits
NOT_FOUNDThe requested resource doesn't exist
RATE_LIMITEDToo many requests — see Rate limits
SOURCE_UNAVAILABLEThe upstream public source is temporarily unreachable
SOURCE_ERRORThe upstream public source returned an unexpected error
INTERNAL_ERRORSomething went wrong on Toolzer Hub's side

Check retryable before you retry

SOURCE_UNAVAILABLE and some INTERNAL_ERROR responses are typically retryable: true — a short backoff-and-retry is reasonable. Treat INVALID_REQUEST, UNAUTHORIZED, FORBIDDEN, and NOT_FOUND as not worth retrying without changing the request first.

On this page