Skip to content

Document the per-1,000-request price denomination - #13

Merged
kev1n merged 2 commits into
mainfrom
docs-price-per-1k-requests
Aug 15, 2026
Merged

Document the per-1,000-request price denomination#13
kev1n merged 2 commits into
mainfrom
docs-price-per-1k-requests

Conversation

@kev1n

@kev1n kev1n commented Aug 15, 2026

Copy link
Copy Markdown
Member

What changed

The gateway publishes every static discovery maximum in two denominations. The docs enumerated only the per-request half, so a reader building against discovery could not find the field AnyAPI actually quotes customers in.

Field Meaning
pricing.from.maxUsd The most one request can be billed
pricing.from.maxPer1kUsd That same maximum per 1,000 requests
pricing.failoverMaxUsd The greatest fallback ceiling for one request
pricing.failoverMaxPer1kUsd That same fallback ceiling per 1,000 requests

Lane-level pricing objects carry maxPer1kUsd too.

Pages

  • index.mdx - new ### Every static price in two denominations subsection under Pricing: the field table above, per 1,000 requests as the quoting denomination and why, read the published field rather than multiplying, baseUsd/perUnitUsd have no per-1k twin, and per-call amounts (maxCostUsd/minCostUsd, costUsd, wallet balance) stay per request.
  • quickstart.mdx - the "Find an API" discovery-fields paragraph now names both denominations and the same five rules in short form.
  • mcp-server.mdx - the search_apis and get_api worked-example JSON now carry maxPer1kUsd and failoverMaxPer1kUsd (including on the lane object). The paragraph after them explains both denominations, the quoting standard, the float-drift warning, and that costUsd from run_api and balanceUsd from get_balance stay per request.
  • cli.mdx - the static-discovery-pricing paragraph lists maxPer1kUsd in both the flat and linear field sets and names pricing.failoverMaxPer1kUsd; a following paragraph carries the quoting rule and the anyapi balance per-request boundary.
  • sdks.mdx - the gateway-published-facts section gains the two denominations, the quoting standard, and the no-per-1k-twin boundary.
  • n8n.mdx - the gateway/node responsibilities section gains the same field pair and the read-do-not-scale rule.
  • agent-skills.mdx - "check the per-request USD price" is now "check its published USD price", the only line implying per-request was the customer-facing quoting convention.

Not changed

  • openapi.json and the generated API Reference. That snapshot is dispatched on gateway deploy and is never hand-edited. Its per-SKU descriptions already quote per 1,000 requests.
  • pagination.mdx (references pricing and costUsd without enumerating fields; both statements remain correct), agent-payments.mdx and api-keys.mdx (per-request actuals, which stay per request by contract), and sell/* (operator list price is already stated per 1,000 requests).

Gate

$ bash scripts/check-docs-nav.sh && mint validate --telemetry false < /dev/null && mint broken-links --telemetry false < /dev/null
docs.json nav guard: ok (every openapi group carries a pages key)
success build validation passed
success no broken links found

bash scripts/check-agent-contract.sh also passes: agent contract guard: ok (docs root is schema-first; universal field claims absent).

🤖 Generated with Claude Code

kev1n and others added 2 commits August 14, 2026 18:26
Every static discovery offer now publishes its maximum twice: `maxUsd` for one
request and `maxPer1kUsd` for 1,000 of them, with `failoverMaxPer1kUsd` as the
twin of `failoverMaxUsd`. Lane-level `pricing` objects carry `maxPer1kUsd` too.
The docs enumerated only the per-request half, so a reader building against
discovery could not find the field AnyAPI quotes customers in.

Per 1,000 requests is the customer-facing standard because most of the catalog
costs a fraction of a cent per call. Each page that lists the discovery pricing
fields now also states that adapters read the published per-1k figure rather
than multiplying `maxUsd`, which drifts in floating point, that `baseUsd` and
`perUnitUsd` have no per-1k twin, and that amounts naming what a specific call
costs stay per request.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The worked examples showed maxUsd 0.003 where production publishes
0.0009, and a failover ceiling of 0.003 where production publishes
0.0036. The per-1k figures added alongside were internally consistent
with the stale number, so the page taught the right rule with the wrong
price.

Verified against GET /catalog today: reddit.search is $0.0009 per
request, $0.90/1k req, failover ceiling $0.0036 and $3.60/1k req. The
run_api costUsd example follows the same price.
@kev1n
kev1n merged commit 2ae891f into main Aug 15, 2026
2 checks passed
@kev1n
kev1n deleted the docs-price-per-1k-requests branch August 15, 2026 01:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant