Tools
This is a reference catalogue. Tools cannot be configured or run from this page.
Base native balances
BITQUERY_MCP_BASE_NATIVE_BALANCESNATIVE COIN BALANCE of up to 50 Base (base, L2, Coinbase L2) addresses you ALREADY HAVE: each address's current ETH balance (the coin that pays gas) - for filtering a known set of wallets down to the funded ones, e.g. an airdrop cohort. To discover holders you do not have yet, use base_token_holders. NOT one address's transfer history → use base_address_flow_summary. Pass the addresses separated by "|" (0x..) - up to 50; addresses after the 50th distinct one are ignored (compare Addresses_Requested with Addresses_Used), so split a longer list into several calls. WINDOW: only balances UPDATED within the last `since_days` days (default 7) are read, so an address that has not moved its native coin in that window returns NO row. Use the same window you searched for activity - e.g. the window of base_token_senders - because an active wallet's balance is always fresh there; a wider window costs more for no gain on active wallets. Native_Balance is in ETH (18 decimals); Native_Balance_Raw is the exact integer amount (wei); Balance_As_Of is when that balance was last updated. To identify the addresses, pass them to labels_for_addresses. Each row: Address, Native_Balance, Native_Balance_Raw, Balance_As_Of, Addresses_Requested, Addresses_Used.
Base token holders
BITQUERY_MCP_BASE_TOKEN_HOLDERSTOP HOLDERS of a Base (base, L2, Coinbase L2) token by CURRENT on-chain balance — holder address + balance, largest first. Use for token analysis: whales, holder concentration, distribution. Pass the token CONTRACT address (not a wallet). Label the returned holders with labels_for_addresses to spot CEX / team / LP / bridge wallets. This is real on-chain balance, NOT DEX-trade PnL — for trader profitability use profitable_traders_by_token / trader_positions. Balances exclude NFTs (fungible only). SCOPE. days=0 (default) ranks EVERY holder over the token's whole history, and Holders_In_Window is then the token's holder count (positive balances). A very widely held token - a major stablecoin, for example - has too much history for that: the call answers at once with one Status=TOO_LARGE row instead of timing out. Then call with days=30 (days=7 if that is still TOO_LARGE): it ranks the holders whose balance CHANGED in that window, and their balances are still exact current balances. A holder that did not move the token in the window is absent, so on such a token the page is the top of the ACTIVE holders, not a guaranteed global top. To reach quieter holders pass Next_Cursor as cursor: each page covers the next older window of `days` and lists only holders whose LAST balance change falls inside it, so no holder appears on two pages and the top N of all pages merged is the global top N. Each page also checks all later activity up to today, so paging far back on a very busy token ends in TOO_LARGE - stop there and say the list covers only the windows read. Next_Cursor is empty when the token has nothing older. Window_From / Window_To are the dates a page covers (Window_From empty = whole history). A row with an empty Holder is a status row: read Status (TOO_LARGE / NO_HOLDERS / BAD_CURSOR). Balance is in the token's OWN units, never USD - no USD value is available in this data, so there is no usd filter and balances of different tokens are not comparable. `Decimals` gives the scale. Holders whose recorded balance is NEGATIVE are dropped and counted in Negative_Balances_Excluded: the transfer history behind them is inconsistent (typically a transfer recorded twice or missing), so that balance cannot be trusted - and the same kind of error can inflate a positive balance of that token. A balance far above the token's total supply is such an artifact, not a whale: check it with token_supply or the holder's transfers before reporting it. `Symbol_NonAscii` = 1 flags a symbol that is not plain ASCII: normal for CJK / emoji names, but also how a scam token impersonates a major one with Cyrillic or Greek look-alike letters - never treat such a token as the asset it resembles.
Base token senders
BITQUERY_MCP_BASE_TOKEN_SENDERSTOKEN SENDERS COHORT on Base (base, L2, Coinbase L2): the addresses that SENT a given token at least `min_transfers` times inside a time window, most recently active first - "wallets that actively use this token", "build a cohort or airdrop list of recent senders of this token". NOT one wallet's own outgoing transfers → use base_transfers_out. This counts SENDERS of the token, one row per sender; it does not value or label them - pass the returned addresses to labels_for_addresses, and to base_native_balances to keep only funded wallets. By default only normal user wallets (EOAs) that sent the token in their OWN transaction count (eoa_only=1); set eoa_only=0 to include contract senders. Pass the token's CONTRACT address in token (0x-hex (case-insensitive)); a symbol also matches clone tokens, so pin the exact contract. WINDOW: the last `days` days (default 1, at most 30) ending at before_time or now; after_time sets the start instead. A sender must reach `min_transfers` sends WITHIN this window, so a short recent window keeps only clearly-active wallets - the recency the cohort wants. There is no full-history mode: to go further back, page with before_time. PAGING: newest-active first, at most `limit` rows. If the result has `limit` rows there may be more - set before_time to the oldest Last_Transfer_Time returned and call again, then combine and de-duplicate the pages. COST grows with the token's volume times the window: widen `days` step by step. A row-limit error ("Limit for rows ... exceeded") means the token is too busy for that window - shorten days. Each row: Address, Transfers, First_Transfer_Time, Last_Transfer_Time.
Base trace dominant path
BITQUERY_MCP_BASE_TRACE_DOMINANT_PATHAUTO-WALK the dominant (largest-total-amount) OUTGOING edge of ONE token from a Base (base, L2, Coinbase L2) address, hop by hop, up to 5 hops — collapses ~5 manual base_trace_next_hop calls into one. Every hop returns Hop*_To (the address that received), Hop*_Token (the contract of the token that moved) and Hop*_Edge_Total, plus Hops_Found (how many hops resolved) and Path_Status for the walk itself. Hop*_Edge_Total is NOT the amount that travelled along the path: it is the ALL-TIME total of EVERY transfer of that token between that hop's sender and receiver, so it can be orders of magnitude larger than the sum you are tracing and the hop totals are not comparable with each other. To break one edge down — its transfer count (Transfers), first/last seen, and the full ranking of that address's edges — call base_trace_next_hop on the hop's sender. The walk NEVER goes back to an address it has already visited (the seed included), so it cannot bounce back and forth between the same two wallets — each hop is the largest edge to a NEW address. READ Path_Status FIRST — NO_MATCH means the token filter matched nothing (wrong symbol, or that symbol belongs to a different token — pass `contract`), PATH_END means the trail really ran out, DEPTH_LIMIT means it may continue past hop 5. All-NULL hops with NO_MATCH are a filter problem, not a dead end. Pass the hop addresses to labels_for_addresses and read down to the FIRST labeled address (CEX / mixer / bridge) — that's the destination. Pin the token with `contract` whenever you know it — a SYMBOL is not unique, clone tokens reuse popular symbols, and with a symbol alone the hops can drift between look-alike tokens; compare the per-hop token contract to spot that. LIMITS: follows only the single biggest edge per hop (misses splits / fan-outs), fixed depth 5, and transfers to the burn address are not followed. For branching / adaptive tracing call base_trace_next_hop hop by hop, identify each hop with labels_for_addresses and choose the next address yourself (prompt_playbook with playbook=money_flow returns the full step-by-step procedure); for one hop's full ranking use base_trace_next_hop. Heavy multi-hop walk — can time out on a very busy address; retry, or narrow it with `contract` / a less-busy token. A transaction's own transfer is TOP-LEVEL, not internal, and is always counted. ETH moved by contract code deeper inside a transaction (an internal transfer) is left out unless you pass include_internal=1.
Base trace next hop
BITQUERY_MCP_BASE_TRACE_NEXT_HOPCONVERGENCE primitive for Base (base, L2, Coinbase L2) tracing: aggregate an address's OUTGOING flow by counterparty (Σ amount, count, first/last seen), largest first. NOT edges for a diagram → use base_flow_edges. NOT an automatic walk along the largest edge → use base_trace_dominant_path. Answers "where did the bulk of the funds go" in one shot. Narrow with currency (recommended), after_time (= when funds reached this hop), min_amount. Pass the top counterparties to labels_for_addresses to spot a CEX / mixer / bridge (= the destination, stop there). One row per (counterparty, TOKEN); identify a token by Contract, not Currency. On a very high-traffic address (an exchange or bridge hub) this aggregates a lot of history and can take tens of seconds — narrow it with contract or currency to one token, and with after_time to one period, which is far faster than one wide call. Amounts here are TOKEN UNITS, never USD - no USD value is available in this data, so there is no usd filter and totals for different tokens must not be compared or added together. For a ranking you can reason about, pin ONE token with contract, or bound the range with min_amount / max_amount. A transaction's own transfer is TOP-LEVEL, not internal, and is always counted. ETH moved by contract code deeper inside a transaction (an internal transfer) is left out unless you pass include_internal=1. Returns up to top_n rows (default 10, at most 10000), largest Total_Amount first; no rows = nothing matched. `Symbol_NonAscii` = 1 flags a symbol that is not plain ASCII: normal for CJK / emoji names, also how a look-alike imitates a major token. For the full labelled list in USD, totals by label type, or a set of addresses → counterparties. Each row: Counterparty, Currency, Symbol_NonAscii, Contract, Total_Amount, Transfers, First_Seen, Last_Seen.
Base transactions
BITQUERY_MCP_BASE_TRANSACTIONSPaginated TRANSACTION HISTORY of a Base (base, L2, Coinbase L2) address — every transaction it sent or received directly (its own From or To; a token it received inside someone else's transaction is in base_transfers_in), newest first. Page back: pass the last Tx of the previous page as `before` to get strictly older transactions (an unknown hash returns an empty page); `until` returns only transactions strictly newer than that hash. NOT a token-transfer list — for token/native transfer flows use base_transfers_in / base_transfers_out; to inspect one transaction's transfers use base_tx_transfers. Value and Fee are in ETH. Each row also carries the exact fee: Fee_Wei is the fee in the smallest unit as a decimal string (Fee is the same amount in ETH, rounded to 8 decimals); Fee_Usd is its value at the ETH price at the time of the transaction. Fee_Price_Status says how far to trust that price: ok; no_price (Fee_Usd is empty - never read it as zero); suspect (the price is more than twice, or less than half, the price a day earlier AND a day later - a likely data glitch, so Fee_Usd is left empty). A failed transaction (Success = 0) still paid its fee: treat it as a fee-only row. The fee was paid by the sender (From): count it for this address only on rows where From is the address. Fee_Status tells whether the fee itself can be used: ok; may_omit_l1 = the recorded amount is the execution fee alone, the L1 data fee is missing from it, so the true fee is higher (a lower bound); unreliable = the recorded fee is known to be wrong and is NOT usable - Fee_Wei and Fee_Usd are empty there, the Fee of such a row must be ignored, and the real fee has to come from the transaction's receipt. Three cases are unreliable: every transaction before 2024-03-14; every transaction from 2026-05-30 19:29 to 2026-07-01 17:30 UTC (recorded too high, up to more than a thousand times); and a transaction recorded with a lower gas price than it was sent with (recorded far too low). Returns up to limit transactions per page (default 25, at most 10000), newest first, failed transactions (Success = 0) included unless only_successful=1; a page shorter than limit is the last one. An unknown `until` hash is not applied (no lower bound); `before` and `until` together bound one range. With after_time / before_time only that period is read, so the cost follows the period, not the address's whole history; pass the same pair with every page. Each row: Tx, Time, Block, TxIndex, From, To, Value, Success, Fee, Fee_Status, Fee_Wei, Fee_Usd, Fee_Price_Status.
Base transfers in
BITQUERY_MCP_BASE_TRANSFERS_ININCOMING Base (base, L2, Coinbase L2) transfers to an address — where this wallet received funds from. NOT the opposite direction → use base_transfers_out. NOT totals per sender → use base_address_flow_summary. Returns up to limit transfers (default 20, at most 10000), newest first by default; page back with the last row's Cursor. Use to trace the source of funds backwards. For an address with many transfers set min_amount or sort='amount', else large sources hide behind recent dust. Query WITHOUT a currency filter to see where the bulk of funds originated. To identify counterparties, pass the returned addresses to labels_for_addresses. Each row carries the token Contract — a symbol alone can match look-alike clones, so pin the real token with the contract param. Amount is in TOKEN UNITS; amounts of different tokens must never be added together. Each row also carries Price_Usd - the token's USD price at the time of the transfer - and Value_Usd = Amount x Price_Usd, with Price_Status: "ok"; "no_price" = no price is known for this token at that time, so Price_Usd and Value_Usd are empty (never read that as zero); "suspect" = the stored price is more than twice the price one day earlier AND one day later, or less than half of both - a likely data glitch - so Value_Usd is left empty - check the price with price_at. ETH and the major tokens are priced to 5 minutes, every other token has ONE price per day, so the value of a small token is approximate. There is no usd filter: min_amount / max_amount are in token units. For a ranking you can reason about, pin ONE token with contract, or bound the range with min_amount / max_amount. Amount_Raw is the exact amount as an integer in the token's smallest unit and Decimals its scale (Amount = Amount_Raw / 10^Decimals); Block and Tx_Index place the row in the chain. A transaction's own transfer is TOP-LEVEL, not internal, and is always included. Internal = 1 marks a transfer moved by contract code deeper inside a transaction; those are left out unless you pass include_internal=1. `Symbol_NonAscii` = 1 flags a symbol that is not plain ASCII: normal for CJK / emoji names, also how a look-alike imitates a major token. Each row: Time, Sender, Currency, Symbol_NonAscii, Contract, Amount, Internal, Tx, Cursor, Amount_Raw, Decimals, Block, Tx_Index, Price_Status, Price_Usd, Value_Usd.
Base transfers out
BITQUERY_MCP_BASE_TRANSFERS_OUTOUTGOING Base (base, L2, Coinbase L2) transfers from an address — where this wallet sent funds. Narrow with after_time (flows after funds arrived), currency (follow one asset), min_amount (drop dust). For an aggregated "where did the bulk go" view use base_trace_next_hop; for incoming use base_transfers_in. For an address with many transfers set min_amount or sort='amount', else large counterparties hide behind recent dust. Query WITHOUT a currency filter to surface the token → USDT off-ramp. Page back through history with cursor: pass the Cursor value of the LAST row of a page to get the next one — unlike before_time it never skips rows that share a timestamp. To identify counterparties, pass the returned addresses to labels_for_addresses. Each row carries the token Contract — a symbol alone can match look-alike clones, so pin the real token with the contract param. Amount is in TOKEN UNITS; amounts of different tokens must never be added together. Each row also carries Price_Usd - the token's USD price at the time of the transfer - and Value_Usd = Amount x Price_Usd, with Price_Status: "ok"; "no_price" = no price is known for this token at that time, so Price_Usd and Value_Usd are empty (never read that as zero); "suspect" = the stored price is more than twice the price one day earlier AND one day later, or less than half of both - a likely data glitch - so Value_Usd is left empty - check the price with price_at. ETH and the major tokens are priced to 5 minutes, every other token has ONE price per day, so the value of a small token is approximate. There is no usd filter: min_amount / max_amount are in token units. For a ranking you can reason about, pin ONE token with contract, or bound the range with min_amount / max_amount. Amount_Raw is the exact amount as an integer in the token's smallest unit and Decimals its scale (Amount = Amount_Raw / 10^Decimals); Block and Tx_Index place the row in the chain. A transaction's own transfer is TOP-LEVEL, not internal, and is always included. Internal = 1 marks a transfer moved by contract code deeper inside a transaction; those are left out unless you pass include_internal=1.
Base transfers raw sql
BITQUERY_MCP_BASE_TRANSFERS_RAW_SQLLAST RESORT — arbitrary READ-ONLY SQL against the Base transfers database. The Bitquery MCP specialized base_* tools are the PRIORITY; use this ONLY when none of them can answer (e.g. an uncovered table). No query optimizer here — naive SQL full-scans huge tables and JOINs time out. Runs read-only ClickHouse SQL. SQL reference: https://clickhouse.com/docs/reference/home FAST-QUERY RULES: filter on the indexed key tables — `base_api.transfers_sender` (by sender / outgoing), `base_api.transfers_receiver` (by receiver / incoming), `base_api.transfers_tx` (by tx hash); NEVER JOIN big tables — use `WHERE col IN (SELECT …)` (use `GLOBAL IN` when the subquery is referenced inside another subquery, otherwise its result is not available where it is used). A subquery that itself reads a transfers table (`IN (SELECT Transfer_Sender FROM …transfers_… WHERE …)`) is re-run for every shard and rescans that table — run it as its OWN query first, then pass the result back as a literal list (`IN (unhex('a'), unhex('b'))`). To filter transfers by a specific token, read `transfers_currency` (keyed by the token contract + `Block_Time`); `transfers_sender` / `transfers_receiver` are keyed by address, so filtering those by a token contract scans the table. Addresses are RAW BYTES `FixedString(20)` in `Transfer_Sender` / `Transfer_Receiver` (there are NO plain string address columns) → `Transfer_Sender = unhex(substring(lower('0x…'),3))`, output `concat('0x',lower(hex(col)))`. Tx hash is `Transaction_Hash` `FixedString(32)` (same unhex/hex pattern). A SET of hashes or addresses must have the column's exact type: `Transaction_Hash IN (SELECT toFixedString(unhex(h), 32) FROM …)`, `toFixedString(…, 20)` for an address. A plain `unhex(…)` set, or a JOIN on a String key, silently misses every value ending in `00`; `=` and a literal list `IN (unhex('a'), unhex('b'))` are safe. Currency symbol + decimals are INLINE columns (no dictionaries): amount = `toFloat64(Transfer_Amount) / pow(10, Transfer_Currency_Decimals)`; symbol = `Transfer_Currency_Symbol`; token contract = `Transfer_Currency_SmartContract` — itself RAW BYTES in a `String` column (not text), so filter it `= unhex('<40 hex, no 0x>')` and read it back `concat('0x',lower(hex(…)))`; a `'0x…'` text literal matches nothing. Always add `AND Transfer_Success = 1`. `Transfer_Type`: 'token' = a token transfer, 'transaction' = a plain native-coin send, 'call' = native coin moved by a call. A transaction's OWN value transfer is stored either as 'transaction' or as a 'call' with `Call_Index = 0`; only a 'call' with `Call_Index != 0` is an INTERNAL transfer (made by contract code deeper inside the transaction). For top-level transfers filter `(Transfer_Type IN ('token','transaction') OR (Transfer_Type = 'call' AND Call_Index = 0))` - `Transfer_Type IN ('token','transaction')` alone drops a large share of ordinary sends. Time = `Block_Time`. Date-time values come back as ISO-8601 UTC, e.g. 2026-09-21T15:04:18Z (toString() of a date-time gives 2026-09-21 15:04:18). Other `base_api.*` tables (calls, transactions, balances) are reachable with an explicit db prefix. Counterparty labels are NOT in this database — use labels_for_addresses. Read-only; always add a LIMIT of at most 10,000 — a larger answer fails with an error, so aggregate (GROUP BY, count) instead. 64-bit integers come back as JSON numbers, exact only up to 2^53: return a hash such as cityHash64(...) or any other 64-bit id as toString(x). Exact table and column names first: chain_list_tables, chain_describe_table and chain_search_columns with database=base_api.
Base tx events
BITQUERY_MCP_BASE_TX_EVENTSALL EVENT LOGS in one or more Base (base, L2, Coinbase L2) transactions, including decoded arguments plus raw topics and data. Use after base_find_events identifies a transaction, or whenever a tx receipt's complete event payload is needed. Accepts up to 50 transaction hashes separated by "|". `Parsed=0` means no ABI matched: Event, Signature and Arguments can then be empty, but Topic0, Topics and Data remain usable. NOT the value moved in a transaction → use base_tx_transfers. Arguments are named objects with Name, Type, string Value and Indexed; integer values are decimal strings to avoid JSON-number precision loss; use raw Topics/Data for values wider than the decoded numeric fields. Argument names come from one known ABI for the Signature and can be another contract's wording - Topics and Data are the log's own. By default, reverted call-frame logs, removed logs and failed transactions are excluded; set only_successful=0 to inspect them with the returned status fields.
Base tx transfers
BITQUERY_MCP_BASE_TX_TRANSFERSAll token & native transfers inside ONE Base (base, L2, Coinbase L2) transaction — or a BATCH of transactions (pass several hashes separated by "|") — sender → receiver, currency, amount, plus the method that produced each transfer. Rows are grouped per tx (Tx column). Entry point for tracing when you have tx hashes. NOT the event logs of a transaction → use base_tx_events. For an address's flow over time use base_transfers_out / base_transfers_in. To identify the addresses, pass them to labels_for_addresses. FRESHNESS: transfers reach this data some minutes after the trade tools see a swap, so a hash that trader_trades or tx_trades already shows can return NO rows here yet - that is lag, not a missing transaction: retry in a few minutes. A transaction's own transfer is TOP-LEVEL, not internal, and is always included. Internal = 1 marks a transfer moved by contract code deeper inside a transaction; those are left out unless you pass include_internal=1.
Bch address flow summary
BITQUERY_MCP_BCH_ADDRESS_FLOW_SUMMARYADDRESS FLOW SUMMARY / top counterparties of a Bitcoin Cash (bch, BCH, mainnet) address in one call: who it pays and who pays it, plus its lifetime profile and a computed Role. Call this FIRST when triaging a hop; for raw rows use bch_sent_from_address / bch_address_received, for one transaction bch_tx_flow. NOT only the lifetime totals, without counterparties → use bch_address_profile. PROFILE columns (Lifetime_*, First_Received, Last_Received, Last_Sent) cover the address's WHOLE history. Lifetime_Received_BCH / Lifetime_Sent_BCH are cumulative TURNOVER, not holdings: every output ever paid to the address (including the change it pays back to itself inside its own spending transactions) and every input it ever spent. The same coins are counted each time they pass through, so a busy exchange wallet's totals can exceed the coin's total supply many times over; Lifetime_Received minus Lifetime_Sent is the balance at this address. Bitcoin Cash totals come from a pre-aggregated table that holds a few duplicated and a few missing records. They match the transactions exactly on an ordinary address; on a busy one they can be off in either direction by up to a fraction of a percent (a Litecoin exchange address: 10 receiving outputs and 78 LTC too many, 0.14 %), so a negative balance, or a remainder on an emptied address, can be that artifact rather than real funds. For an exact figure on a single transaction use bch_tx_flow. Role covers the WHOLE history too, not the `days` window, and follows from the lifetime counts: no_transfers (nothing received and nothing spent) / receive_only (it never spent anything — cold storage or an unused deposit address) / send_only (spends with no recorded receipt) / hub (more than 1,000 distinct senders AND more than 1,000 distinct receivers — an exchange or service, don't trace deeper) / consolidator (distinct senders more than 3 times distinct receivers) / distributor (distinct receivers more than 3 times distinct senders) / relay (none of these). The TOP ARRAYS cover only the last `days` (default 90) and, inside that window, at most the 1,000 most recent transactions on each side. Spend_Txs_Scanned / Receipt_Txs_Scanned say how many were read; Spend_Txs_Truncated / Receipt_Txs_Truncated = 1 means older transactions in the window were left out. So the arrays do NOT add up to the Lifetime_* totals. Window_Days / Window_From state the period covered: empty arrays for an address whose Last_Sent is long ago mean nothing moved in the window, not that it never moved — raise days. Top_Receivers = the non-change recipients of the transactions this address spent in; Amount = BCH paid to that recipient. Top_Senders = the input addresses of the transactions that paid this address (change excluded); Amount = BCH this address received in those transactions. A transaction with several input addresses credits each of them in full (they are usually one owner — see bch_related_addresses), so Amount can be far more than what moved between the two addresses. pro_rata_amount is Amount scaled by the input share: how much of those transactions this address paid (Top_Receivers) or that sender paid (Top_Senders). Both arrays are RANKED by pro_rata_amount, largest first, and min_amount / max_amount filter on it — dust and address-poisoning payments hidden inside a large co-signed transaction have a tiny share. Window_Own_Input_BCH is what this address itself put into the spending transactions read, the ceiling the Top_Receivers pro-rata amounts add up to. The arrays are built from a copy of the transaction data that misses a few whole blocks (a handful a month), so a counterparty can be absent. READING THE TOP ARRAYS: positional 4-tuples [counterparty, amount, txs, pro_rata_amount]; the Top_Fields column lists those names in the same order. No address labels are returned here: identify the address and its counterparties with labels_for_addresses(chain='bitcoin-cash'), which knows only a handful of Bitcoin Cash addresses (a few exchange reserve wallets, sanctioned entities) — pass Address and the Top_Receivers / Top_Senders counterparties in ONE call; an empty answer there is a coverage gap, not a clean address. A counterparty shown as m-… or d-… is a script placeholder, not an address: it cannot be traced further. Amounts are in BCH; for a USD value use currency_price with currency_id "bch". A first call on an address can take a minute or more while its transactions are fetched; repeated calls answer in seconds. For the full labelled list in USD, totals by label type, or a set of addresses → counterparties.
Bch address profile
BITQUERY_MCP_BCH_ADDRESS_PROFILEBitcoin Cash (bch, BCH, mainnet) address PROFILE (lifetime summary): total received & sent (BCH), number of distinct senders/receivers, receiving/spending counts, first/last activity. Use to triage a BCH address during tracing — how much flowed and how connected. NOTE: an aggregate profile, not hop-by-hop edges — bch_address_flow_summary returns the top counterparties, bch_flow_edges and bch_tx_flow the edges. Role from the ratio: Distinct_Senders ≫ Distinct_Receivers = consolidator; the reverse = distributor; thousands of both = mega-hub (exchange — don't trace deeper). Received_BCH / Sent_BCH are cumulative TURNOVER, not holdings: every output ever paid to the address (including the change it pays back to itself inside its own spending transactions) and every input it ever spent. The same coins are counted each time they pass through, so a busy exchange wallet's totals can exceed the coin's total supply many times over; Received_BCH minus Sent_BCH is the balance at this address. Bitcoin Cash totals come from a pre-aggregated table that holds a few duplicated and a few missing records. They match the transactions exactly on an ordinary address; on a busy one they can be off in either direction by up to a fraction of a percent (a Litecoin exchange address: 10 receiving outputs and 78 LTC too many, 0.14 %), so a negative balance, or a remainder on an emptied address, can be that artifact rather than real funds. For an exact figure on a single transaction use bch_tx_flow. No address labels are returned here: identify addresses with labels_for_addresses(chain='bitcoin-cash'), which knows only a handful of Bitcoin Cash addresses (a few exchange reserve wallets, sanctioned entities) — pass many addresses in ONE call; an empty answer there is a coverage gap, not a clean address. Amounts are in BCH; for a USD value use currency_price with currency_id "bch".
Bch address received
BITQUERY_MCP_BCH_ADDRESS_RECEIVEDINCOMING Bitcoin Cash (bch, BCH, mainnet) outputs for an address — every coin received (tx, amount, output type: payment/change, time), most recent first. Indexed by address (fast). Use to see what a BCH address received and in which transactions. NOT what this address spent → use bch_sent_from_address. NOT sums over its whole history → use bch_address_flow_summary or bch_address_profile. An address can receive several coins (outputs) in one transaction, each its own row. Returns up to limit rows (default 20, at most 1000), newest first; page back with the last row's Cursor - a page shorter than limit is the last one. Set sort='amount' for the largest receipts instead: a top-N page with no Cursor. NOTE: shows receiving events, not the sender addresses (a UTXO output has no single sender) — pass a Tx to bch_tx_flow to see the addresses that funded it, or call bch_address_flow_summary for the top senders. A small share of outputs is missing from this list (a few whole blocks a month, under 0.1 % on busy addresses, a few % in some months of 2023), so it can hold a few rows fewer than bch_address_profile counts; bch_tx_flow on the transaction is complete. Each row: Time, Tx, Type, Amount_BCH, Cursor.
Bch flow edges
BITQUERY_MCP_BCH_FLOW_EDGESMONEYFLOW GRAPH EDGES out of a Bitcoin Cash (bch, BCH, mainnet) address: Source → Target (real recipients of the address's spends, excluding change), total Amount (BCH). Building block for a MoneyFlow DIAGRAM — call per address/hop, collect edges, render Mermaid `graph LR`. Merge same-owner Targets via bch_related_addresses. NOT one transaction's outputs → use bch_tx_flow. NOT its spending transactions one by one → use bch_sent_from_address. Returns up to limit rows (default 20, at most 1000), one per recipient of its spends. The edges carry no labels: identify the Targets with labels_for_addresses(chain='bitcoin-cash') (many addresses in one call) and stop at exchange / mixer nodes. A counterparty shown as m-… or d-… is a script placeholder, not an address: it cannot be traced further. Amount is the FULL value of those outputs; Pro_Rata_Amount is the part of it this address paid for - its own input value divided by the total input value of the same transaction. When the address signs a transaction together with other addresses, every output of it is credited to each of them in full, so Amount can be many times the money this address ever moved (over a hundred times on an address that keeps co-signing with a large wallet). The rows are therefore RANKED by Pro_Rata_Amount, and that is the figure to add up or to compare between Targets. Own_Input_BCH on every row is what the address itself put into the transactions read: the Pro_Rata_Amount of all its edges adds up to at most that, the rest being fees and change it paid back to itself. SCOPE: reads the address's most recent max_txs spending transactions (default 1000, at most 2000); Amount, Pro_Rata_Amount and Txs cover those transactions only. Two scope columns on every row state what was covered: how many of those transactions were read and the time of the oldest one. Next_Cursor is set whenever the batch was full, so older transactions may exist - pass it as cursor (same address and max_txs) to continue with the next older batch; an empty Next_Cursor means the history ends here. The outputs of those transactions come from a copy of the transaction data that misses a few whole blocks (a handful a month), so an edge can be absent; bch_tx_flow and bch_sent_from_address read the complete data. When nothing matched in the transactions read, ONE row comes back with an empty Target that carries only these scope columns - that means no edge in this batch, not in the whole history. Each row: Source, Target, Currency, Amount, Pro_Rata_Amount, Txs, Own_Input_BCH, Spend_Txs_Scanned, Oldest_Spend_Time, Next_Cursor.
Bch related addresses
BITQUERY_MCP_BCH_RELATED_ADDRESSESLIKELY SAME-OWNER Bitcoin Cash (bch, BCH, mainnet) addresses (common-input-ownership heuristic): addresses that co-signed inputs together with this address in the same transactions — a strong signal they belong to the same wallet/entity. NOT the addresses it paid → use bch_flow_edges. Shared_Txs is how many txs they co-spent in, Co_Input_BCH the co-input volume. Returns up to limit rows (default 20, at most 1000), most Shared_Txs first. Use to expand an address into its cluster during tracing. CAVEAT: CoinJoin/mixer txs break the heuristic (false positives) — treat high-fan-in shared txs with caution. A shared input is evidence of one owner, not proof. SCOPE: reads the address's most recent max_txs spending transactions (default 1000, at most 2000). Two scope columns on every row state what was covered: how many of those transactions were read and the time of the oldest one. Next_Cursor is set whenever the batch was full, so older transactions may exist - pass it as cursor (same address and max_txs) to continue with the next older batch; an empty Next_Cursor means the history ends here. The inputs of those transactions come from a copy of the transaction data that misses a few whole blocks (a handful a month), so a transaction counted in Spend_Txs_Scanned can contribute no related address; bch_tx_flow and bch_sent_from_address read the complete data. When nothing matched in the transactions read, ONE row comes back with an empty Related_Address that carries only these scope columns - that means nothing in this batch, not in the whole history. No address labels are returned here: identify addresses with labels_for_addresses(chain='bitcoin-cash'), which knows only a handful of Bitcoin Cash addresses (a few exchange reserve wallets, sanctioned entities) — pass many addresses in ONE call; an empty answer there is a coverage gap, not a clean address. Each row: Related_Address, Shared_Txs, Co_Input_BCH, Spend_Txs_Scanned, Oldest_Spend_Time, Next_Cursor.
Bch sent from address
BITQUERY_MCP_BCH_SENT_FROM_ADDRESSOUTGOING Bitcoin Cash (bch, BCH, mainnet) — transactions where this address SPENT coins (its inputs): tx, amount, time, and the prior tx that funded each input. Indexed by address (fast). NOT what this address received → use bch_address_received. Page back through history with cursor: pass the Cursor value of the LAST row of a page to get the next one — unlike before_time it never skips rows that share a timestamp (a busy address can spend hundreds of inputs in the same second). Set sort='amount' to surface the largest spends instead of the newest. To see WHERE the funds went, take a Spend_Tx and call bch_tx_flow — its non-change outputs are the recipients.
Bch transfers raw sql
BITQUERY_MCP_BCH_TRANSFERS_RAW_SQLLAST RESORT — arbitrary READ-ONLY SQL against the Bitcoin Cash transfers data. The bch_* tools are the PRIORITY; use this ONLY when none of them can answer. No query optimizer here: filter on the per-key tables and NEVER JOIN big tables (use `IN (SELECT …)`, the only way to "follow" across txs). Runs read-only ClickHouse SQL. SQL reference: https://clickhouse.com/docs/reference/home This data runs on an older release of the engine: some functions and syntax in that reference (map() and toJSONString() among them) do not exist here — when a statement is refused for an unknown function or setting, use the forms shown in this description. Tables (db `bitcash`): `bitcash.inputs_by_address` / `outputs_by_address` (by address), `bitcash.inputs_by_tx` (by tx; cols address, tx_id_bin, value, output_tx_id_bin, output_index) and `bitcash.outputs_by_tx` (by tx; cols address, tx_id_bin, output_index, value and direction, an Enum unknown/not_change/change/likely_not_change/likely_change/mining/fee), `bitcash.transactions` (one row per tx: tx_date, input_value, output_value, fee_value, is_coinbase; look a hash's tx_date up here first). Every `bitcash` table is partitioned by month on `tx_date` — add a `tx_date` bound whenever you can: a read by address or tx alone probes every month since the chain began. Db `bitcash_flow`: address_transfers (keyed by address; AggregateFunction → -Merge; its count / sum totals hold a few duplicated and missing records — take exact totals from the `bitcash` tables), outputs_to_address (by address), tx_inputs / tx_outputs (by block, tx_index; a few whole blocks are missing). Addresses & tx ids: `address` is a plain string (CashAddr q… / p… lowercase WITHOUT the bitcoincash: prefix; m-… / d-… placeholders for bare multisig / non-standard scripts; empty for coinbase inputs and fee rows); `tx_id_bin = unhex('<64hex>')`, output `hex(tx_id_bin)`; `value` is Decimal(18,8), already in BCH (a JSON number: above about 1e8 it loses its last decimals - return toString(value) when every decimal matters). Date-times come back as 'YYYY-MM-DD hh:mm:ss' UTC; select formatDateTime(tx_time, '%FT%TZ') for ISO-8601 (2026-09-21T15:04:18Z), the shape the other tools return. Address labels: none in this data — use labels_for_addresses(chain='bitcoin-cash'). Read-only; JSONEachRow. A result of more than 25,000 rows is not cut off - the whole query fails with an error - so aggregate (GROUP BY, count) or add a LIMIT of at most 25,000. 64-bit integers come back as JSON numbers, exact only up to 2^53: return a hash such as cityHash64(...) or any other 64-bit id as toString(x).
Bch tx flow
BITQUERY_MCP_BCH_TX_FLOWFull flow of one or several Bitcoin Cash (bch, BCH, mainnet) transactions: all INPUT addresses (senders) and OUTPUT addresses (receivers) with amounts, each annotated. Note shows change/not_change on outputs — the real payment is the non-change output(s). THE hop primitive for BCH tracing: follow a non-change recipient to its own spends (bch_sent_from_address) and repeat. tx_hash is the 64-hex id as returned by the other bch tools; pass several ids separated by "|" (up to 20; ids past the 20th are ignored) to expand a batch in one call — the Tx column attributes each row. Side is input, output, fee (the miner fee of the transaction — one row per transaction, 0 on a block reward) or not_found (a requested id that does not exist here — check the id and the chain). Index is the position of the input or output inside the transaction, and Funded_By_Tx on an input row is the transaction that created the coins being spent — pass it back to this tool to trace one hop backwards. An output whose address is also one of the transaction's OWN input addresses is marked change_to_input_address: the wallet paid itself, so it is not a payment to someone else. Outputs whose script has no standard address carry a placeholder instead of an address: m-… (a bare multisig script) or d-… (a data or other non-standard script; one d-… value can stand for many unrelated outputs). A placeholder cannot be looked up with the address tools — the visible trail ends there. No address labels are returned here: identify addresses with labels_for_addresses(chain='bitcoin-cash'), which knows only a handful of Bitcoin Cash addresses (a few exchange reserve wallets, sanctioned entities) — pass many addresses in ONE call; an empty answer there is a coverage gap, not a clean address.
Bch wallet ledger
BITQUERY_MCP_BCH_WALLET_LEDGERWALLET LEDGER of a set of Bitcoin Cash (bch, BCH, mainnet) addresses — one row per transaction that touches the client's addresses, NETTED over the whole set: what the set received, what it spent and the difference, so change paid back to one of the client's own addresses is neither income nor a payment. Built for accounting and tax ledgers, wallet statements and reconciliation. NOT one address's raw outputs or inputs — use bch_address_received / bch_sent_from_address; NOT the addresses inside one transaction — use bch_tx_flow. Pass EVERY address of the wallet in `addresses` (up to 50 per call). Netting covers only the addresses passed: an address of the same wallet that is left out looks like an outside party — its change shows as a payment out and its inputs as someone else's (Fee_Shared = 1 is the usual sign). bch_related_addresses suggests addresses that sign together with a known one. Direction: in (the set funded no input — a receipt), out (the set funded inputs and at least one output went elsewhere), self (the set funded inputs and every output came back to it — a consolidation or an internal move, only the fee left). Net_BCH = Received_BCH − Spent_BCH, negative on a payment; on an outgoing payment the amount that went to others is −Net − Fee_Paid. On a transaction funded together with other addresses (Fee_Shared = 1) Net can be positive although Direction is out or self — read the sign of Net. Received_Raw / Spent_Raw / Net_Raw / Fee_Raw / Fee_Paid_Raw are the same amounts as exact integer strings in the smallest unit (1 BCH = 100,000,000 units) — use them when every digit matters; the decimal columns are JSON numbers. Fee_BCH is the miner fee of the whole transaction. Fee_Paid_BCH is the set's part of it: all of it when the set funded every input, nothing when it funded none (a receipt costs the receiver no fee), and — when other addresses funded inputs too (Fee_Shared = 1) — the fee split by input value (fee × spent ÷ all inputs, rounded half up to the smallest unit), Input_Share being the set's share of the transaction's inputs; what the other parties paid is Fee − Fee_Paid. A shared fee is an estimate: either addresses of the wallet are missing from `addresses`, or several parties built the transaction together. Is_Coinbase = 1 marks a block reward (newly mined coins). Fee_Status is exact, or unknown when the transaction's totals are not available — the fee columns are then null and a spend's Direction reads unknown. Price_Usd is the USD price of BCH at the start of the transaction's hour (hourly market data). Value_Usd = Net × Price_Usd, signed like Net, and Fee_Usd = Fee_Paid × Price_Usd. Price_Status: ok; no_price (no market price for that hour — the newest hour or two have none yet — Price_Usd and the USD columns are null, never a guess and never today's price); suspect (the price is more than twice, or less than half, the price one day earlier AND one day later — a likely data glitch, so Value_Usd and Fee_Usd are left empty). Rows come newest first in block order (Block, then Tx_Index). The window is the last `days` (default 365), or after_time … before_time for a fixed period such as a tax year. Page with cursor: pass the Cursor of the LAST row, with every other argument unchanged, to get the next older page. after_time and before_time bound every page, so no page leaves the period. With after_time set, a page shorter than `limit` is the end of the period; without it each page looks `days` back from its cursor, so a walk continues into older history until a page comes back short. Addresses_Requested / Addresses_Used on every row say how many distinct addresses were passed and how many were read. No rows = no transaction of these addresses in the window. Counterparties are not listed: pass a Tx to bch_tx_flow. SCAN COST grows with the window and with the number of addresses, not with limit: prefer a fixed period to a very large `days`. A window in which the addresses have more than 200,000 inputs or outputs (an exchange-size address) is refused — narrow it.