The v2 API shipped create-time usage quotas (epic silvxlabs/FastFuels-API-v2#340). The SDK should expose the read surface and handle the new error path. Additive — not a breaking change — but the 429 is a new error every create can now raise, so SDK users need a typed way to handle it.
New features
client.me() → GET /users/me — returns {id, kind, tier, quotas}.
client.usage() → GET /users/me/usage — per-resource-type usage vs limits (active / total / storage), plus domains / api_keys and a lifecycle block.
- Typed
QuotaExceededError for 429 with detail.reason == "QUOTA_EXCEEDED" — surface the structured detail (quota, current, limit, message) and the Retry-After header (present on active-job limits), instead of a generic HTTP error. Every resource-create method can raise it.
Notes
- Source of truth: the OpenAPI schemas (
/users/me, /users/me/usage, QuotaExceededDetail).
- Document the new error path in the SDK's usage/errors docs.
- Ships as a minor version (new feature, backward compatible).
The v2 API shipped create-time usage quotas (epic silvxlabs/FastFuels-API-v2#340). The SDK should expose the read surface and handle the new error path. Additive — not a breaking change — but the 429 is a new error every create can now raise, so SDK users need a typed way to handle it.
New features
client.me()→GET /users/me— returns{id, kind, tier, quotas}.client.usage()→GET /users/me/usage— per-resource-type usage vs limits (active/total/storage), plusdomains/api_keysand alifecycleblock.QuotaExceededErrorfor429withdetail.reason == "QUOTA_EXCEEDED"— surface the structured detail (quota,current,limit,message) and theRetry-Afterheader (present on active-job limits), instead of a generic HTTP error. Every resource-create method can raise it.Notes
/users/me,/users/me/usage,QuotaExceededDetail).