CryptoTaxEdge classification API
app.cryptotaxedge.com/v1/classify-batch
Up to 100 transactions per call. Returns one result per tx; your tx_id is echoed back as id.
app.cryptotaxedge.com/v1/classify
Single transaction by hash. Same result shape, one record.
app.cryptotaxedge.com/quota-status
Read-only usage readout for your key's pool; never consumes quota. Optional ?hash= reports whether re-running that hash is free.
app.cryptotaxedge.com/v1/verify
Verify one label you already hold. Send the transaction and your label; the answer is agree, disagree with evidence and a dispute, or unverifiable with a reason. No model call unless you pass fill: true. Keyed callers only.
app.cryptotaxedge.com/v1/verify-batch
Up to 100 labels per call, { "rows": [...], "fill": <optional default> }. One result per row in input order; per-row problems never fail the batch.
mcp.cryptotaxedge.com · classify_batch and verify_batch
Optional: the same tools over JSON-RPC for agent-native stacks, same fields, same result bodies. Most integrations use the REST endpoints above.
The full machine-readable contract is published as an OpenAPI 3.1 spec: request and response schemas, the closed treatment enum, and every error code, ready for codegen and validation.
Each request carries a bearer token. Create your own API key in Settings → API keys: sign in (free, no credit card), click “Create API key”, and copy the token. Developer keys include 250 billable classifications a month on the free tier (25,000 on Pro); the same key works on both the REST API and the MCP server. For partner integrations with volume pricing, contact us.
Authorization: Bearer YOUR_API_KEY
A valid key is required on every request; there is no anonymous access to the public API. Rate limits depend on the key class: Developer keys (free tier) 60 requests per minute per key, where the working ceiling is the 250-transaction monthly pool rather than the rate; partner-tier keys 300 per key; Firm plan keys on MCP 600 per key. A single batch request carries up to 100 transactions. Transactions the engine has already classified come back in that one call: measured on 2026-11-11, a batch of 62 known Ethereum transactions took about 20 seconds, because each row re-reads its receipt so a batch row carries the same legs and fee as a single call; a transaction it has never seen can need a deep analysis that takes most of a minute, so plan first-time volume around the unfinished-item flow described below rather than around the rate limit. Over the limit you get 429 rate_limited; back off and retry. tx_id is yours: we echo it back as id on each batch result so you can correlate to your records. chain is optional and auto-detected when omitted. We never return source or vendor internals. Quota counts distinct billable tax classifications only: re-running a hash you already classified is always free, and failed rows, unsupported rows, and free identification rows (plain transfers, approvals, spam) never consume quota. Review-flagged rows do count: the delivered triage - candidate treatment, confidence, evidence, and reason - is billable work. Check your pool anytime with GET /quota-status (free, never consumes quota). Self-serve plans cover your own product and workflows, including free products and internal betas; charging end users for CryptoTaxEdge-powered output requires a partner agreement.
Two known-good Ethereum mainnet hashes you can drop straight into a request. Re-runs are free, so testing costs you nothing:
0x280710a5673a8ff1af7f623ddb5148417ac36539228d0eec8edb8a57b19383c2
0x9b5693fc24d2e31c59317f53f7ca77b3d570ad86999bd22a4fc53a7d06a48da6
curl -X POST https://app.cryptotaxedge.com/v1/classify-batch \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"hashes": [
{ "tx_id": "row_1", "hash": "0x280710a5673a8ff1af7f623ddb5148417ac36539228d0eec8edb8a57b19383c2", "chain": "ethereum" },
{ "tx_id": "row_2", "hash": "0x9b5693fc24d2e31c59317f53f7ca77b3d570ad86999bd22a4fc53a7d06a48da6", "chain": "ethereum" }
]
}'
Agent-native stacks can call the same classify_batch and verify_batch tools over MCP (JSON-RPC 2.0) at mcp.cryptotaxedge.com, same parameters, same key. MCP setup →
policy parameterA handful of treatments are genuinely two-sided: the same on-chain event has two defensible tax positions, and which one a firm posts is a house call, not a fact the chain settles. Send an optional policy object and the returned classification reflects your firm's chosen position for those treatments, applied on the wire so every downstream system reads one answer. Four dimensions are governed today:
lpLP entry and exit. disposal or non_taxable.wrapWrap and unwrap of the same underlying. non_taxable or disposal.lstLiquid-staking token mint. disposal or non_taxable.stakingRebase-reward timing only: income (the default; Rev. Rul. 2023-14) or defer. Plain staking rewards always ship as income at receipt - this key never changes them.{
"hashes": [
{ "tx_id": "row_1", "hash": "0x280710a5673a8ff1af7f623ddb5148417ac36539228d0eec8edb8a57b19383c2", "chain": "ethereum" }
],
"policy": {
"lp": "non_taxable",
"wrap": "non_taxable",
"lst": "disposal",
"staking": "income"
}
}
Strictly additive. Omit policy (or any single key) and that treatment falls back to the platform default, byte-identical to a policy-free call. Unknown keys and invalid values are ignored, never an error. Policy never overrides a transaction we flagged for review: it resolves a grey treatment, never papers over a classification we are not sure of. The grey_area block still names the position not taken.
block_time and the optional prices parameterEvery classified transaction carries block_time (UTC) and block_number, so a row can be dated without a second lookup.
Send "prices": true on /v1/classify or /v1/classify-batch and each asset leg that can be priced carries usd_price and usd_value: the market price near the block time, and the amount times that price. The response also carries a valuation object that counts priced and unpriced legs and gives a reason for each unpriced one.
These are indicative market prices for sizing and review. They are not a cost basis and not a fair market value determination; your tax software or your own records remain the source for those. A quote is used only when it sits within six hours of the block and the source is confident in it. An NFT, a token on a row we classify as spam, and a token with no reliable quote are left without a value. Nothing is estimated.
legsA leveraged loop, a collateral swap or a repay-and-withdraw is one transaction with several bookable events. The wallet's own token movements show only what entered and left the wallet, so we also read the lending market's events from the receipt (Morpho Blue and Aave V3) and return one leg per event: flash_loan, supply_collateral, withdraw_collateral, borrow, repay. Each leg names its asset and exact amount and carries a proposed treatment.
When the amounts imply that assets were exchanged, a swap leg is added with "basis": "derived". It is worked out from the amounts in and out across the transaction, not decoded pool by pool, and it is stated only when market prices at the block confirm that what was given up and what was received are worth the same. When that cannot be confirmed, no swap leg is returned and memo says so.
The legs are a proposal for a reviewer. They never change the transaction's own treatment or needs_review: a transaction in review stays in review. A repay does not separate interest from principal.
queue_unfinished parameterA batch call has a fixed amount of work it can do, and a transaction we have never seen can need a deep analysis that takes most of a minute. So a batch of never-seen transactions comes back with some items finished and the rest marked budget_exhausted: not classified, never guessed. Resubmitting those items finishes a few more each time. For a whole month of activity that is slow.
Send "queue_unfinished": true on /v1/classify-batch and the items that call could not finish are handed to a background queue. We classify them over the following minutes and store the answers. The response carries queued, the number accepted. Resubmit the same hashes later and the finished ones come back at once.
To see what is still waiting, POST /v1/queue-status with { "hashes": [...] } (up to 100). Each hash comes back queued (with its position, how long it has waited and an estimate of runs to go), not_queued (finished, or never queued: send it to /v1/classify-batch again to read its answer) or invalid_hash. The queue runs every five minutes.
Nothing changes about what you receive in the first response: unfinished items are still returned as unfinished. Transactions we have already classified are always served immediately and never enter the queue. The queue works through a limited number of items a day, so a very large first submission can take hours; what is finished is available as soon as it is finished.
wallets parameterA plain transfer is the one event the chain cannot settle for us: we can see an asset move, but not who owns the other side. A send to your own cold wallet is a non-event; the same send to a vendor is a disposition. So without ownership evidence every transfer comes back needs_review with the question stated. Send the list of wallets the books belong to and a transfer between two of them is returned as what it is: transfer, non_taxable, not flagged.
{
"hashes": [
{ "tx_id": "row_1", "hash": "0x<transaction hash>", "chain": "ethereum" }
],
"wallets": [
"0x<the wallet that sent it>",
"0x<the wallet that received it>"
]
}
walletsUp to 50 addresses, EVM or Solana, on /v1/classify and /v1/classify-batch (one list for the whole batch). Include the sending wallet.exchange_accountsUp to 50 addresses, EVM or Solana, that are the client's own account at an exchange: a deposit address, or the exchange wallet their withdrawals arrive from. A transfer between a listed wallet and one of these is returned as a movement within the client's own holdings. An exchange address is shared with other customers, so it only ever counts as the other side of a transfer.walletThe wallet a transaction is read from. On Solana this matters whenever someone else paid for the transaction: without it the row is reported from the paying wallet's side. With the client's wallet named, sent and received are the client's, the network fee appears only if the client paid it, and a wallet that is not in the transaction is told so. A Solana wallet on an EVM hash, or the reverse, is a 400 on a single call; in a batch a wallet applies to the rows of its own kind.pairing_basisOn /v1/classify-batch, when the request names the wallet: a deposit into a contract that issues no receipt token is held on its own, because it cannot be told from a payment. When the same contract later returns exactly the same amount of the same asset in another transaction in the same call, both rows are returned as a deposit and its return, non_taxable, with pairing_basis: round_trip_in_request and paired_with naming the other hash. Send a wallet's history together to get the benefit; the same hash sent alone stays held.counterparties_to_confirmReturned by /v1/classify-batch: the addresses on the other side of the transfers held for review in that call, most transfers first, with a count each. Ask the client which are theirs, add them to wallets or exchange_accounts, and send the call again. On a real wallet a handful of addresses usually account for most held transfers.It fails closed. A transfer is treated as your own movement only when the wallet the transaction is read from is on the list and every asset leg's counterparty is on the list too. One outside address, or a leg we cannot attribute, and the row is returned exactly as it would be without the list. Categories other than transfer are never changed by it. The list is applied to your response only: nothing we store about the transaction depends on it. A malformed list (not an array, more than 50 entries, or an entry that is not a 0x address) is a 400 invalid_request, not ignored, because a silently dropped wallet would change the answer.
{
"api_version": "v1",
"hash": "0x280710a5673a8ff1af7f623ddb5148417ac36539228d0eec8edb8a57b19383c2",
"chain": "ethereum",
"category": "swap",
"treatment": "disposal",
"taxable": true,
"confidence": 77,
"needs_review": false,
"ledger_action": "Trade",
"protocol": null,
"description": "Token swap; a taxable disposition under IRC 1001.",
"review_note": null,
"grey_area": null,
"assets": {
"sent": [ { "symbol": "stETH", "amount": "0.002297", "decimals": 18, "action": "transferred",
"token_address": "0xae7a...fe84", "to": "0x89c6...f818" } ],
"received": [ { "symbol": "USDC", "amount": "3.723749", "decimals": 6, "action": "received",
"token_address": "0xa0b8...eb48", "from": "0x1231...4eae" } ],
"gas": null
}
}
Complex transactions additionally return a per-leg breakdown plus a memo, so you can post the correct number of taxable events for a single on-chain transaction.
{
"category": "needs_review",
"treatment": "needs_review",
"needs_review": true,
"legs": [
{ "leg_index": 1, "role": "flash_loan", "category": "flash_loan", "treatment": "non_taxable", "taxable": false, "basis": "event", "asset": { "symbol": "USDC", "amount_exact": "19110.222973" } },
{ "leg_index": 2, "role": "supply_collateral", "category": "collateral_supply", "treatment": "non_taxable", "taxable": false, "basis": "event", "asset": { "symbol": "fxSAVE", "amount_exact": "19564.927030782543977205" } },
{ "leg_index": 3, "role": "borrow", "category": "borrow", "treatment": "non_taxable", "taxable": false, "basis": "event", "asset": { "symbol": "USDC", "amount_exact": "19110.222973" } },
{ "leg_index": 4, "role": "swap", "category": "swap", "treatment": "disposal", "taxable": true, "basis": "derived", "sold": [ { "symbol": "USDC", "amount_exact": "22110.874948" } ], "bought": [ { "symbol": "fxSAVE", "amount_exact": "19564.927030782543977205" } ] }
],
"memo": "One transaction, 4 legs: a flash loan, a swap, collateral posted, debt drawn. ..."
}
Verify checks the label you already hold against the verified cache, the rule registry and the answer guards, with no model call, and answers agree, disagree, or unverifiable. Fill runs the classification engine on a row only when nothing deterministic exists and you ask for it with fill: true, then verifies the result in the same call. Prove means every verdict carries the evidence it rests on and every disagree carries a dispute_id you can contest.
Verify needs a partner, developer or internal key; session and guest callers get 401. Units drawn by a verified row are reported in metered.units; see the price book for the unit rate.
treatment is a closed set of five values you can switch on exhaustively: disposal, income, non_taxable, expense, needs_review. Anything the engine cannot map to one of those five is clamped to needs_review, so a partner switch statement never sees an out-of-contract value. confidence is an integer from 0 to 100.
An uncertain transaction is never a silent wrong non-taxable. When the engine cannot reach a confident classification it returns needs_review: true with taxable: null and a review_note explaining why: a deliberate deferral for a human to resolve, never a forced answer, never a guess dressed as certainty. The flagged row bills as delivered triage: you still receive the candidate treatment, confidence, evidence, and reason. A taxable of false means a positive non-taxable finding; a taxable of null always travels with needs_review: true and means undetermined. Treat the two as distinct in your ledger.
This is the differentiator: the engine flags what it is unsure of rather than committing a wrong number to the books.
confidence is a routing signal, not an accuracy percentage. It reflects how strongly independent evidence agreed on the classification, and its job is to decide what gets served, what gets hedged, and what gets flagged. Do not read 77 as "77% likely correct".
The score lands in bands that track corroboration:
95+Full agreement: every consulted source (or a verified rule with on-chain evidence) reached the same classification.80 to 94Majority agreement, or a rule adjudicated with supporting evidence.70 to 79Single-source: one source or a deterministic rule decoded the transaction and nothing contradicted it.<70Under the serving floor. A model answer here ships as needs_review: true with the candidate treatment and the model's view in review_note, never as an authoritative result. A deterministic rule can still serve between 60 and 69 (a plain transfer identified from the receipt, for example).Because the bands track corroboration rather than complexity, a trivially simple transfer can sit at 60: only one source decoded it, so it is single-source even though the shape is obvious. A more complex swap that three sources agree on scores 95. Both numbers are honest; neither is a quality grade on the transaction itself.
You do not need to invent your own cutoff: anything the engine is not prepared to stand behind already ships needs_review: true. A classification with needs_review: false is one the engine serves as authoritative, at any confidence. If your workflow wants a stricter posture on top of that, sampling single-source results (the 60 to 79 band) is the sensible dial; the MCP surface applies an additional review floor at 70 for hosts that want it prebuilt. When needs_review is true, taxable is always null; treatment may still name the engine's leaning, and it is a pointer for the reviewer, not an answer to post.
When a transaction has more than one defensible treatment, the response adds a grey_area block: note is the basis for the split, and alternate carries the position not taken so your accountant can see and switch it. When a policy is supplied, the top-level classification reflects the firm's chosen position and alternate shows the road not taken. grey_area is null on transactions with a single settled treatment.
{
"category": "liquidity_add",
"treatment": "disposal",
"taxable": true,
"needs_review": false,
"grey_area": {
"note": "LP contribution/withdrawal: no LP-specific IRS guidance; general property/realization principle governs.",
"alternate": {
"treatment": "non_taxable",
"taxable": false,
"label": "Pool-position continuity view (non-taxable LP entry/exit)"
}
}
}
The example shows the house default for an LP entry (disposal). Supplying a continuity policy flips the top-level treatment to non_taxable and moves the disposition view into alternate: same evidence, the firm's documented position on top.
Every error uses one envelope, { "error": { "code", "message" } }, with standard HTTP semantics. Codes are stable; messages are human-readable and can change.
| Code | HTTP | Meaning | What to do |
|---|---|---|---|
invalid_request |
400 | Body is not a JSON object, hashes is missing or empty, chain is not a supported chain slug (the list is at GET /chains), or wallet is not an EVM address. The message for a bad chain or wallet reads invalid_input. | Fix the request. Do not retry unchanged. |
payload_too_large |
413 | A batch carries more than 100 transactions, or the body is over the byte limit. | Split the batch into calls of 100 or fewer. |
invalid_hash |
400 | A hash is not a 0x-prefixed 64-hex EVM hash or a base58 Solana signature. On /v1/classify this is the HTTP 400. On /v1/classify-batch the call still returns 200 and the one bad item carries error invalid_hash, so one typo does not fail the other 99. | Fix the hash. Do not retry unchanged. |
unauthorized |
401 | Missing, malformed, or revoked API key. | Check the Authorization header and the key in Settings. Do not retry unchanged. |
quota_exceeded |
402 | The classification pool for your key (monthly) is exhausted. Re-running an already-classified hash never hits this: repeats are always free. | Check GET /quota-status, wait for the reset, or upgrade. Key on the HTTP 402 status. |
tx_not_found |
404 | The hash is well-formed but was not found on the searched chain. In a batch the same condition is reported on the item as error tx_not_retrievable, inside the 200. If you pinned a chain, the engine already probed other supported chains before answering (see chain_corrected). | Verify the hash; or omit chain to auto-detect. |
chain_not_detected |
404 | The hash matched no supported chain. It may be mistyped or from an unsupported network. | Verify the hash and network; supported chains are listed at GET /chains. |
tx_not_yet_mined |
404 | The transaction is in the mempool but not yet mined, so no classification exists yet. | Retry after the transaction is included in a block. |
rate_limited |
429 | Over the per-minute limit for this key class (60 for Developer keys, 300 for partner-tier keys, 600 for Firm plan keys on MCP). | Back off with jitter and retry. Prefer batching (100 per call) over request fan-out. |
internal_error |
500 | An engine fault, logged on our side. | Retry shortly; contact us if it persists. |
(upstream reason) |
502 | An upstream data source failed before a classification was reached; the code carries the failure reason. Never shipped as a 200 result. | Retry shortly. Treat as transient. |
Batch semantics: /v1/classify-batch returns HTTP 200 with one result per input, same order, same count. An item the engine did not finish is not a classification: status is budget_exhausted, infra_unavailable, or error, with a machine-readable reason, the hash you sent, and your tx_id echoed as id. Those rows have no treatment and no classification confidence, and needs_review is false. A real needs_review verdict is unchanged. client_label is not supported yet. The single endpoint maps the same failures to the HTTP statuses above. Treat any item with error set as not classified, and never as a result to book.
Every field the /v1 wire carries, verified against live responses. Fields marked "only" are conditional; everything else is always present. Unknown future fields are additive: ignore what you do not use.
| Field | Type | Description | Example |
|---|---|---|---|
api_version |
string | Contract version echo. Always "v1" on this surface. | "v1" |
id |
string | Batch results only: your tx_id echoed back so you can correlate results to your records. A single classify response omits it. | "row_1" |
hash |
string | The transaction hash that was classified. | "0x2807...83c2" |
chain |
string | Chain slug the classification was served from. Can differ from your request when chain_corrected is present. | "ethereum" |
category |
string | Canonical transaction type. Open, additively growing vocabulary; branch exhaustive logic on treatment instead. Reads needs_review when the engine routed the row to a human and does not assert a type. | "swap" |
treatment |
enum | Closed five-value tax treatment: disposal, income, non_taxable, expense, needs_review. Safe to switch on exhaustively. | "disposal" |
taxable |
bool | null | Tri-state on a classification. true = taxable event; false = a positive non-taxable finding; null = undetermined, paired with needs_review: true. An unfinished batch item is the exception: taxable null with needs_review false and no treatment. Never coerce null to false. | true |
confidence |
integer | 0 to 100. Corroboration and routing signal, not an accuracy percentage; see the confidence section above. | 77 |
needs_review |
boolean | True when the engine defers to a human instead of guessing. Route to a review queue, never to the books. | false |
ledger_action |
string | null | Suggested ledger label for posting. | "Trade" |
protocol |
string | null | Protocol display name when identified. | "Aave V3" |
description |
string | null | Plain-English reasoning behind the classification. | "Token swap; a taxable disposition..." |
review_note |
string | null | Set only when needs_review is true: why the transaction was flagged and what a reviewer should check. | null |
review_candidate |
object | Review rows only, and only when the engine reached an answer at confidence 50 to 69, just under its serving floor: { label, confidence }, what it leans toward. A weaker leaning (under 50) is stated in review_note only. A starting point for the reviewer, never a treatment. Absent when there is no leaning. | { "label": "Trade", "confidence": 62 } |
grey_area |
object | null | Non-null only when more than one treatment is defensible: { note, alternate: { treatment, taxable, label } }. See the grey-area section. | null |
assets |
object | Net asset movements: { sent: [legs], received: [legs], gas: leg | null }. Leg fields below. gas is the network fee the sender paid, in the native coin, at full precision. It is set whenever the engine read the receipt for this response: on /v1/classify whenever the receipt could be read, and on batch rows that needed a receipt read. On Arbitrum and the OP-stack chains the fee comes only from the receipt of the chain, so an older transaction whose receipt no public node serves carries null. A batch row served from stored data can still carry null; a null fee means not reported, never zero. | { "sent": [...], ... } |
chain_corrected |
object | Present only when you pinned a chain, the tx was not there, and the engine found and classified it on another chain: { requested, detected }. | { "requested": "polygon", "detected": "ethereum" } |
block_time |
string | When the transaction was mined, UTC. Absent when it could not be read. | "2026-11-10T22:12:47Z" |
block_number |
integer | The block (on Solana, the slot) the transaction was mined in. | 26387422 |
valuation |
object | Only when the request set prices: true. Says what the usd_value figures on the legs are: { currency, as_of, priced_legs, unpriced_legs, unpriced: [{ symbol, reason }], basis }. Indicative market prices near the block time, not a cost basis. | { "currency": "USD", "priced_legs": 2, ... } |
legs |
array | Only when the receipt shows this wallet changing a lending position (Morpho Blue, Aave V3) in two or more steps. One leg per market event (flash_loan, supply_collateral, withdraw_collateral, borrow, repay), each with role, category, treatment, taxable, protocol, asset and basis. A swap leg is added only when market prices at the block confirm its two sides are worth the same; it is marked basis: derived. A proposal for the reviewer: the legs never change the transaction verdict. | [ { "leg_index": 1, "role": "flash_loan", ... } ] |
memo |
string | Present with legs: a plain-English summary of them. | "One transaction, 4 legs: a flash loan, a swap, ..." |
error |
string | Batch results only: the failure reason for this one item (a batch call returns HTTP 200 with per-item errors). Treat any item with error set as not classified. | "tx_not_retrievable" |
assets.sent[], assets.received[], assets.gas)| Field | Type | Description | Example |
|---|---|---|---|
symbol |
string | On-chain token symbol exactly as the contract reports it. Never rewritten, so your matching logic can key on it. | "USDC" |
amount |
string | Decimal amount rounded for display (six decimals, nine for dust), as a string. Use amount_exact for a ledger. | "0.000018" |
amount_exact |
string | The same amount with every digit the chain recorded. Present on every leg whose amount is a number. Do not parse as a float. | "0.000018702420884568" |
decimals |
integer | null | Token decimals used to render the amount. | 6 |
usd_price / usd_value |
number | Only when the request set prices: true and a usable quote exists: the indicative USD price of one unit near the block time, and amount_exact times that price, to cents. A leg with no usable quote carries neither; nothing is estimated. | 0.9989 / 52.68 |
position_marker |
string | debt on a lending market debt token (for example variableDebtEthUSDT). It records what the wallet owes; it is not an asset received and is never valued. | "debt" |
mint |
string | Solana legs: the token mint address, or "native" for SOL. Solana assets are priced by mint, never by symbol. | "EPjF...Dt1v" |
action |
string | transferred: left the wallet read. received: arrived in it. paidGas: the network fee (gas leg only). on-behalf-of: moved between other addresses in this transaction; not this wallet's asset, shown so the movement is visible, never booked. | "transferred", "received", "on-behalf-of" |
native |
boolean | True on a leg of the chain's own coin (ETH and so on), which has no token_address. | true |
token_address |
string | Contract address of the token, lowercase hex. Present on legs decoded from event logs. | "0xa0b8...eb48" |
token_name |
string | Token display name when metadata resolved one. | "Aave Ethereum USDC" |
to / from |
string | Counterparty address: to on sent legs, from on received legs. | "0x89c6...f818" |
token_type |
string | Present on NFT legs. When set, amount is a token count, not a fungible balance. | (NFT legs only) |
symbol_collision |
boolean | True when this symbol matches a canonical token on the same chain at a DIFFERENT contract (e.g. a vault share reusing a major stablecoin symbol). symbol itself is never altered. | true |
display_symbol |
string | Display-only disambiguated symbol, present only when symbol_collision is true. Render this; keep matching on symbol. | "USDC (Varlamore USDC Growth)" |
inferred |
boolean | True when the amount was inferred rather than read from an event log (native-coin proceeds emit no log). The review_note names the method. | true |
inferred_basis |
string | Inference method when inferred is true. | "balance_delta" |
Deprecated aliases (MCP surface only): the MCP tools historically used the field names tx_type, tax_category, reasoning, source, and authoritative. These are now deprecated aliases of category, treatment, description, and the needs_review flag (authoritative is exactly needs_review: false, never an independent stamp). They are kept for one release for back-compat and will be removed in the next minor version; migrate to the canonical names. None of these aliases ever appear on REST /v1.
category is the canonical transaction type. Its core is the stable set below; the vocabulary grows as new on-chain patterns are named (for example wrap, reward, liquid_staking_mint), always additively, so treat an unfamiliar category gracefully rather than as an error. For an exhaustive switch, branch on treatment (the closed five-value set), not category. ledger_action carries the suggested ledger label.
swap transfer income_receipt fee_payment borrow repay collateral_supply collateral_withdraw liquidity_add liquidity_remove unclassifiedThe full taxonomy, with each category's default treatment, the house position on grey-area categories, and the named alternatives, is published at cryptotaxedge.com/taxonomy.
The contract is versioned in the path (/v1/) and echoed in every response as api_version. Within v1 we only make additive changes: new optional fields may appear, but existing fields are never renamed or removed and the treatment enum never gains a value without a version bump. A breaking change ships as /v2 with v1 kept live through a published deprecation window. Build against the fields you use and ignore unknown ones, and the contract will not break under you.
- Create an API key in Settings, API keys and send it as
Authorization: Beareron every call. - Batch your transactions (up to 100 per call) to
POST /v1/classify-batch, each with your owntx_id; usePOST /v1/classifyfor one-offs. - Optionally send a
policyobject to apply your firm's house positions on the wire. - Correlate each result to your record by the echoed
id, then post fromtreatment,taxable, andledger_action. Multi-step transactions carry a per-leg breakdown so you post the right number of events. - Route any result with
needs_review: trueto a human queue rather than to the books; surfacegrey_areawhere present. - Handle errors from the
{ error: { code, message } }envelope (full table above). Retrytx_not_yet_minedafter the transaction mines and back off onrate_limited. - Generate a typed client from the OpenAPI 3.1 spec if your stack supports it, and poll
GET /quota-statusto surface remaining quota in your own UI.