Skip to content

Can I use GET /usage as a complete history of all my generation jobs?

No. GET /usage provides the shared balance, this key's UTC-month allowance and a recent account-job view filtered by allowed model scope. It is not a paginated complete export or a guaranteed key-only ledger. Keep your own durable task records and use returned job IDs for reconciliation instead of relying on the recent list as the sole history.

RECOVER AND DELIVER API JOBSAISwapLab team · Editorial methodPublished 2 min read
Open API documentationExplore 67 Image SkillsPrivate keys · Explicit credit approval
Article workflow: Record jobs when accepted; Use usage for current gates; Reconcile known IDs directly.
Workflow diagram: Record jobs when accepted → Use usage for current gates → Reconcile known IDs directly. Read the article for evidence and limits.

Recent visibility is not full accounting

The current implementation returns up to twenty recent account jobs before applying the key's model visibility. That means an older relevant job can be absent even though it still exists. Changing scopes or rotating keys can change what appears without deleting the underlying resources or changing their actual generation status.

What to do next

  1. 01

    Record jobs when accepted

    Persist each returned ID, originating application task, model and approved cost. Retain the creation response even if the job later falls outside the recent view.

  2. 02

    Use usage for current gates

    Read balance, month, monthly_limit and monthly_used to inform preflight decisions. Treat the recent jobs as a helpful operational view rather than an exhaustive financial statement.

  3. 03

    Reconcile known IDs directly

    Poll or download an existing owned job by its recorded route. If a task cannot be located, investigate the saved identifier and account before assuming its absence from usage means it was never accepted.

A concrete example

Illustrative mismatch: an application created thirty image jobs over time. Only a recent subset appears in usage, but its own ledger still links each user request to the corresponding durable job ID and charge information.

Before you call it ready

  • The recent list is not advertised as a full export.
  • Known task identifiers are stored independently.
  • Per-key allowance is separate from account job visibility.

When to stop or choose another method

If you need an audit-grade history, build and maintain your application ledger from accepted responses and confirmed settlements. Do not infer missing jobs were free or canceled.

Sources

One task. A recoverable workflow.

Check the contract, approve the quote and retain the job.

Open API documentation