## Prices API

*a table rebuilt about every 75 s*

The router's price table in one call: each token's price and depth, or only the mints you name.

```
# Prices  the whole table, or the mints you name.
curl https://services.carbium.sh -H 'content-type: application/json' -H 'x-api-key: <YOUR_KEY>' \
  -d '{"jsonrpc":"2.0","id":1,"method":"prices","params":[{
        "mints":["So11111111111111111111111111111111111111112",
                 "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"]}]}'
# -> HTTP 200, x-request-id 9f88dd7e228b4ce9e04556b87d471abf
# {"jsonrpc":"2.0","id":1,"result":{"solUsd":118.927290,"builtUnix":1790033392,
#   "priced":4202,"stale":0,"noroute":0,"total":4202,"rows":[
#   ["EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",1.000000,46980639,"So11111111111111111111111111111111111111112"],
#   ["So11111111111111111111111111111111111111112",118.960000,601543324,"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"]]}}
#
# Omit params for the whole table, one large body. Ask for it on a timer, not on every request.
```

### request and result

| field | type | meaning |
|---|---|---|
| **params · optional; send none, {}, or the subset** |  |  |
| mints[] | array of base58 pubkeys | up to 64: only those rows; omit for the whole table. A mint not in the table is absent, no error |
| **result** |  |  |
| solUsd | number | SOL price this table build used |
| builtUnix | number | unix seconds the build finished |
| priced | number | rows with a price |
| stale | number | rows marked stale |
| noroute | number | rows with no route to price |
| total | number | rows in the table |
| rows[] | array | [mint, priceUsd or null, tvlUsd, quoteMint] per token, in the router's order |

> One call, any size, costs `60` cells of the quote plan, like one `quote` or `swap`, and shares their lane permit: up to 10 tables a second on FREE. Cached `30 s`, so polling faster gets nothing new; check `builtUnix` before trusting a price.

> The whole table is about half a megabyte (`475,883` bytes over `4,202` rows on 2026-09-22) and grows with `total`.

### refusals

| http | code | message | what to do |
|---|---|---|---|
| 400 | -32602 | params accepts only mints, or no params at all | send no params, {} or {"mints":[...]} |
| 400 | -32602 | mints must be an array of at most 64 base58 32-byte pubkeys | past 64 mints, take the whole table |
| 400 | -32600 | quote is not batchable | one call per request; a batch holding any quote plan call but health is refused before it runs |
| 503 | -32011 | prices upstream unreachable / timed out / read failed / response too large | router did not answer, or answered over 4 MiB |
| 503 | -32011 | prices upstream response shape / prices upstream row shape | the table's columns changed |

> Header fields always describe the whole table. Key, scope, module and rate limit are checked first.

### methods

#### prices

0 credits

| param | type |   |   |
|---|---|---|---|
| mints | pubkey[] | opt | at most 64; omit for the whole table |

```
{"jsonrpc":"2.0","id":1,"method":"prices","params":[{"mints":["So11111111111111111111111111111111111111112","EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"]}]}
```

**answer**: {solUsd, builtUnix, priced, stale, noroute, total, rows: [[mint, price, tvl, quote_mint]]}

**refuses**: 403 -32050 the account lacks the quote module; 401 -32001 the key lacks the quote scope; 400 -32602 a key other than mints; 400 -32602 mints empty, over 64 or not pubkeys; 400 -32600 sent in a batch
