# Estimate request credits (QuantSet API)

> Calculate a request's maximum charge at the current published rate without executing the data query. Eligible sandbox reads and discovery operations can cost zero.

> ## For AI agents
> The QuantSet API is at https://api.quantset.dev. Send the key in the `X-API-Key` header. The sandbox key `mw_demo` needs no signup and reads the sample listings.
> No key yet? An agent can open an account on its own: https://api.quantset.dev/skill.md
> Connect an MCP client to https://api.quantset.dev/mcp. Client setup is at https://api.quantset.dev/agents.md.
> Start with https://api.quantset.dev/llms.txt or read the full reference at https://api.quantset.dev/llms-full.txt. The OpenAPI file is https://api.quantset.dev/openapi.json. Add `.md` to any docs URL to get that page as Markdown.

`POST https://api.quantset.dev/api/v1/billing/estimate` · `estimate_credit_cost`

Keyless operation.
Returns JSON.
Price: Free. It uses no credits.

## Workflow examples

### What is the maximum cost of a two-block price request?

```http
POST https://api.quantset.dev/api/v1/billing/estimate
Content-Type: application/json

{
  "method": "GET",
  "path": "/prices",
  "params": {
    "ticker": "NVDA",
    "limit": 251
  }
}
```

Inspect maximum_credits, exact and the returned tariff version before issuing the same data request. Pass X-Max-Credits on that read to enforce your budget.

## Reading the results

Estimates use the submitted selectors and page bounds at the published tariff. The actual receipt reports the settled charge, including any applicable free access.


## Coverage and limits

An estimate does not reserve credits or fetch observations. Missing data, eligible sample access and returned record counts can reduce the final charge.


## Related guides

- [Cap credits and read the receipt](https://quantset.dev/docs/guides/credit-metering)

## Parameters


## Response fields

- `operation` (string)
- `rate_card_version` (string)
- `maximum_credits` (integer)
- `exact` (boolean)
- `units` (object)

## Example

```
curl -X POST 'https://api.quantset.dev/api/v1/billing/estimate' -H 'Content-Type: application/json' --data '{"method":"GET","path":"/prices","params":{"ticker":"NVDA","limit":251}}'
```

## Responses

- 200 Successful Response
- 413 Reduce the size of the request body.
- 422 Correct the named parameter and retry.
- 429 Wait for Retry-After seconds.
- 500 The request could not be completed.
- 503 Retry safe reads after a short delay.

## Questions

**Can I try Estimate request credits without signing up?** Yes. This operation is keyless.

**Can an AI agent use this?** Yes. An agent calls it over HTTP like any client. Add .md to this page's address for a version written for agents.

**What does null mean in the response?** The value could not be confirmed. It is never a zero, so treat it as missing in your own calculations.

Group: Account and integration
Docs page: https://quantset.dev/docs/api/billing-estimate-post
Integrations & Ecosystem: https://quantset.dev/integrations (Claude/Cursor MCP, LangGraph, PydanticAI, CrewAI, Agno, Vercel AI SDK, Mastra, Sheets =QUANTSET(), Excel, Notion & x402)
Full API guide: https://api.quantset.dev/llms-full.txt
