> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bloklake.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Troubleshooting and FAQ

> Common surprises, what causes them, and what to do.

## Queries

> [accordion] I got fewer rows than I expected
>
> 1. Check `to_block` in the response: near the head, or for ranges over 50,000 blocks, the
>    response covers less than you asked for. Continue from `next_block`.
> 2. Check your topic filters: an address in a topic must be padded to 32 bytes.
> 3. Check `address`: events are emitted by the contract that runs the code. For a proxy, that's
>    the proxy's address.
> 4. ERC-20 `Transfer` and ERC-721 `Transfer` share a `topic0`; check which you want.

> [accordion] I asked for maxObjects: 1000 and got 3,000 rows
>
> A response never splits a block. It stops at the end of the block where the count reached
> `maxObjects`, so a busy block can push it well past.

> [accordion] The response is empty, but I know there's data
>
> * Is `fromBlock` past the head? Then `to_block` is lower than `from_block`, and `next_block`
>   equals your `fromBlock`. Wait for the chain to get there.
> * Is it the right chain? `https://api.bloklake.com/v1/chains/eth/…` vs `…/rh/…`.
> * Hex values are case-insensitive, so case isn't the problem.

> [accordion] A column is all null
>
> Check `unavailable_fields`: the chain might not have that field (for example `withdrawals` on
> Robinhood Chain). Otherwise the field doesn't apply to those rows (`baseFeePerGas` before
> London, `to` on contract creations).

> [accordion] 404 on api.bloklake.com/query
>
> Add the chain: `https://api.bloklake.com/v1/chains/eth/query`, or use
> `https://eth.api.bloklake.com/query`.

> [accordion] 400 invalid\_query: no fields selected for logs
>
> You filtered logs but selected no `fields.log`. Select at least one log field.

> [accordion] 400 unknown\_query\_id
>
> Prepared queries expire 30 minutes after their last use, and live on one chain. Send the full
> filter again; it re-registers under the same id.

> [accordion] Data I read near the head changed
>
> A reorg replaced those blocks. Only rows at or below `finalized_block` are final. See
> [Finality and reorgs](https://docs.bloklake.com/querying/finality-and-reorgs.md).

> [accordion] Can I filter by value, gas, or a function argument?
>
> Not on the server. Only `address`/`topic0`–`topic3` (logs) and `from`/`to`/`sighash`/`status`
> (transactions) are indexed. Filter as narrowly as those allow, then filter the rest in your
> code.

> [accordion] Can I get internal transactions, traces, balances or contract state?
>
> No. Bloklake serves blocks, transactions (with receipts) and logs.

## Reading responses

> [accordion] My Arrow reader only sees the first row type
>
> A response with several row types is several Arrow streams back to back. Open a new stream
> reader on the same body after the first one ends. See [Reading Arrow](https://docs.bloklake.com/responses/reading-arrow.md),
> or use a [client library](https://docs.bloklake.com/clients.md), which handles it.

> [accordion] Block numbers are bigint in JavaScript
>
> apache-arrow returns `UInt64` as `bigint`. Use `Number(x)` for block numbers and timestamps.

> [accordion] How do I turn a 16-byte value into a number?
>
> It's a big-endian unsigned integer: `int.from_bytes(b, "big")` in Python,
> `BigInt("0x" + hex)` in JavaScript. See [Data types](https://docs.bloklake.com/responses/data-types.md).

> [accordion] My client sometimes gets cut off
>
> The server closes responses that aren't read for 60 seconds, or are read slower than 50 KB/s.
> Read the response fully before processing it, or use smaller pages.

## Keys and billing

> [accordion] 401 missing\_api\_key
>
> Send `Authorization: Bearer <key>`. Keys in the URL aren't accepted.

> [accordion] I lost my key
>
> Keys are shown once. Rotate it on **API keys** to get a new one.

> [accordion] 402 balance\_exhausted
>
> Your pay-as-you-go balance is used up. Top up on **Billing**; requests work again as soon as
> the payment settles.

> [accordion] 402 overage\_limit\_reached
>
> Your subscription used its included data plus its overage limit this period. An admin can raise
> the limit on **Billing**, effective immediately.

> [accordion] 429 rate\_limited, though I send one request at a time
>
> Every chain counts toward the same requests-per-second limit, and so does every process using
> the key. On pay-as-you-go the limit is 1 per second.

> [accordion] Why was I billed for an error?
>
> Requests rejected by validation (`400`, `404 unknown_set`) are billed the 10 KB minimum, like any
> other processed request. Server errors, rate-limited and refused requests are free. See
> [How billing works](https://docs.bloklake.com/billing/how-billing-works.md#whats-free).

> [accordion] Can I call the API from a web page?
>
> No: the API doesn't send CORS headers, and a key in a browser would be public. Call it from your
> backend.

## Still stuck?

Email [support@bloklake.com](mailto:support@bloklake.com) with the request body, the response
status and body, and the `X-Request-Id`.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.