Browse API Reference

Errors and status codes

Read GymAssets status codes and stable error identifiers, then handle refusals without parsing human-readable messages.

A JSON refusal includes an error identifier. Additional fields such as detail, accepted, or expected explain how to correct the request.

{
  "error": "unknown_value",
  "parameter": "category",
  "value": "machines",
  "accepted": ["machine", "free-weight"]
}
StatusMeaningWhat to do
400The path, parameter, value, cursor, or requested format is invalidRead accepted, expected, or supported
401A key is missing, invalid, revoked, or the wrong typeCheck the credential and where it was sent
402The product allowance is exhaustedHandle the refusal and review account usage
403The image request’s origin is not allowedUpdate the key’s origins or use the intended key
404The version, resource, member, figure, side, or asset does not existCorrect the id or discover it from the API
405The HTTP method is unsupportedUse GET or HEAD
429A short burst limit refused the requestRetry after retry-after

Error handling

Use error as the stable identifier for programmatic error handling. detail is a human-readable description and may change over time.

errorStatusWhat happenedWhat to do
bad_request400The path is not one this API servesexpected lists every path that is
unknown_parameter400A query parameter this resource does not takeaccepted lists the ones it does
unknown_value400A filter value outside its vocabularyRead accepted, or fetch the vocabulary
page_size_not_negotiable400A page-size parameter was sentRemove it and follow the cursor
bad_cursor400A cursor that did not come from a next fieldStart the walk again
too_many_terms400q carried more words than search acceptsSearch with fewer words
unsupported_format400An image extension the route does not servesupported lists the ones it does
unauthenticated401No Authorization header, or nothing that parses as a keySend the secret half as a bearer token
wrong_credential401A publishable key reached the data APISend the secret half instead
quota_exceeded402The product allowance for the period is spentHandle the refusal; product names which one
origin_not_allowed403An image request presented an origin the key does not listAdd the origin to the key, or use the intended key
not_found404No record in this collection has that idCorrect the id or discover it from the collection
unknown_equipment404No equipment has that idids names the endpoint that lists them
unknown_resource404No such collection or vocabularyRead expected on a bad_request for the current paths
unknown_version404A version prefix other than /v1 on the data APIUse /v1. The image host answers not_found
method_not_allowed405A method other than GET, HEAD, or OPTIONSRead the allow header
rate_limited429Too many requests in a short windowRetry after retry-after

New identifiers are added over time. Handle an unrecognised error by its status code rather than assuming this list is complete.

A retired equipment id returns a plain not_found. There is no alias fallback to an id that replaced it.

Authentication errors

unauthenticated means a usable credential was not presented. wrong_credential means a publishable key reached the data API, which requires the secret half.

Unknown filter values

A collection filter outside its published vocabulary returns 400 unknown_value rather than an empty result. A misspelled filter and a valid filter with no matching records are answered differently.

Image diagnostics

A Musclegram image can return 200 while reporting a partial result: