{"openapi":"3.1.0","info":{"title":"Crypto Security API","version":"1.0.0","description":"Static checks for caller-supplied EVM calldata and for Solidity storage layouts of upgradeable implementations. No network calls are made. Paid with x402 exact USDC on Base. No account is required.","contact":{"email":"support@brainiac.software"},"x-guidance":"BRAINIAC.software is a pay-per-call API for software agents. No account or API key is required.\nPayment uses the x402 protocol with exact USDC on Base (chain id 8453). Each POST operation has a fixed USD price.\nHow to call an operation:\n1. POST JSON matching the requestBody. Invalid input returns 400 with no payment challenge.\n2. A valid unpaid call returns 402 with the exact amount and payTo.\n3. Pay and retry with payment-signature. Payment settles only if the operation returns 2xx. A 4xx/5xx is not charged.\nInclude an Idempotency-Key header of 64 hex characters from 32 random bytes. Reuse that key only for retries of the same operation and request body.\nAll outputs are compliance prechecks, drafts, or data lookups for human review. They are not official determinations, legal advice, identity confirmation, or certified filings. Verify time-sensitive or official data with the cited source before acting."},"servers":[{"url":"https://www.brainiac.software"}],"paths":{"/api/v1/crypto-security/transaction-intent-verify":{"post":{"operationId":"verify_transaction_intent","summary":"Verify transaction intent","description":"Compare an EVM transaction's calldata and native value with the action declared in the request. Decoding uses the ABI in the request, or the standard ERC-20 transfer, transferFrom, approve, and increaseAllowance encodings when that selector matches. intent_match is true, false, or the string indeterminate when a declared field cannot be checked. risk_level is low, medium, high, or critical. This is static analysis: it does not read chain state, simulate the call, or decide that a contract is malicious or that the transaction will succeed.","tags":["crypto-security"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"chainId":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"contractAddress":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"calldata":{"type":"string","maxLength":131074,"pattern":"^0x(?:[0-9a-fA-F]{2})*$"},"value":{"type":"string"},"expectedAction":{"type":"string","enum":["transfer","token_approval","swap","contract_interaction"]},"expected":{"type":"object","properties":{"recipient":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"token":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"amount":{"type":"string"},"spender":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"contract":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"functionName":{"type":"string","pattern":"^[A-Za-z_][A-Za-z0-9_]{0,79}$"},"nativeValue":{"type":"string"}},"additionalProperties":false},"abi":{"maxItems":48,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["function","constructor","receive","fallback","event","error"]},"name":{"type":"string","maxLength":80},"stateMutability":{"type":"string","enum":["pure","view","nonpayable","payable"]},"inputs":{"maxItems":32,"type":"array","items":{"$ref":"#/$defs/__schema0"}},"outputs":{"maxItems":32,"type":"array","items":{"$ref":"#/$defs/__schema0"}},"anonymous":{"type":"boolean"}},"required":["type"],"additionalProperties":false}}},"required":["chainId","contractAddress","calldata","value","expectedAction"],"additionalProperties":false,"$defs":{"__schema0":{"type":"object","properties":{"name":{"type":"string","maxLength":80},"type":{"type":"string","minLength":1,"maxLength":200},"internalType":{"type":"string","maxLength":200},"indexed":{"type":"boolean"},"components":{"maxItems":32,"type":"array","items":{"$ref":"#/$defs/__schema0"}}},"required":["type"],"additionalProperties":false}}},"example":{"chainId":8453,"contractAddress":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","calldata":"0x095ea7b30000000000000000000000002222222222222222222222222222222222222222ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","value":"0","expectedAction":"token_approval","expected":{"spender":"0x2222222222222222222222222222222222222222","token":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"1000000","nativeValue":"0"}}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"intent_match":{"type":"boolean"},"risk_level":{"type":"string"},"mismatches":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string"},"expected":{"type":"string"},"actual":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"decoded_transaction":{"type":"object","properties":{"selector":{"type":"string"},"function_name":{"type":"string"},"parameters":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"type":{"type":"string"},"value":{"type":"string"}},"additionalProperties":true}}},"additionalProperties":true},"warnings":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"intent_match":false,"risk_level":"critical","mismatches":[{"field":"amount","expected":"1000000","actual":"115792089237316195423570985008687907853269984665640564039457584007913129639935","detail":"The approval amount exceeds the expected amount."}],"decoded_transaction":{"selector":"0x095ea7b3","function_name":"approve","parameters":[{"name":"spender","type":"address","value":"0x2222222222222222222222222222222222222222"},{"name":"amount","type":"uint256","value":"115792089237316195423570985008687907853269984665640564039457584007913129639935"}]},"warnings":[{"code":"approval_exceeds_expected","detail":"The approval amount is greater than the expected amount."},{"code":"unlimited_approval","detail":"The approval amount is the uint256 maximum. The calldata does not set an expiry."}],"limitations":["This is static calldata analysis. It does not read chain state, simulate execution, or decide whether the target contract is malicious or whether the transaction will succeed.","Chain ID is not checked against a network and does not change decoding.","The function was decoded with the standard ERC-20 ABI because the selector matched transfer, transferFrom, approve, or increaseAllowance. No caller ABI was supplied."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment required. The JSON body is the x402 PaymentRequired object: x402Version, resource with the operation description, accepts with the price and network, and extensions.bazaar with the input schema, input example, output schema, and output example."},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed before settlement, so no payment is taken. Reuse the same idempotency key to retrieve the stored error without paying again."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}],"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}},"/api/v1/crypto-security/intent-safety":{"post":{"operationId":"score_transaction_intent_safety","summary":"Score transaction intent safety","description":"Read a caller-supplied EVM transaction or an EIP-712 typed-data message and describe the transfer, approval, permit, or outer call it encodes. Known selectors are transfer, transferFrom, approve, increaseAllowance, setApprovalForAll, permit, multicall, aggregate, and execute. The score is a local penalty count. It does not simulate the call or read a chain.","tags":["crypto-security"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"transaction":{"type":"object","properties":{"to":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"value":{"type":"string","pattern":"^(0x[0-9a-fA-F]+|\\d+)$"},"data":{"type":"string","maxLength":100000,"pattern":"^(0x)?[0-9a-fA-F]*$"}},"required":["data"],"additionalProperties":false},"typed_data":{"type":"object","properties":{"primaryType":{"type":"string","minLength":1,"maxLength":80},"domain":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"types":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"maxItems":40,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":80},"type":{"type":"string","minLength":1,"maxLength":80}},"required":["name","type"],"additionalProperties":false}}},"message":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"required":["primaryType","message"],"additionalProperties":false}},"additionalProperties":false},"example":{"transaction":{"to":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","value":"0","data":"0x095ea7b30000000000000000000000002222222222222222222222222222222222222222ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"}}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"intent_safety_score":{"type":"number"},"unintended_transfers_risk":{"type":"number"},"human_readable_intent":{"type":"string"}},"additionalProperties":true},"example":{"intent_safety_score":55,"unintended_transfers_risk":55,"human_readable_intent":"Approve 0x2222222222222222222222222222222222222222 to spend the maximum uint256 of the token at 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913. The approval has no deadline in the calldata."}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment required. The JSON body is the x402 PaymentRequired object: x402Version, resource with the operation description, accepts with the price and network, and extensions.bazaar with the input schema, input example, output schema, and output example."},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed before settlement, so no payment is taken. Reuse the same idempotency key to retrieve the stored error without paying again."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}],"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}},"/api/v1/crypto-security/proxy-upgrade-storage-audit":{"post":{"operationId":"audit_proxy_upgrade_storage","summary":"Audit proxy upgrade storage","description":"Compare the Solidity storage layout of an upgradeable implementation with a proposed replacement. Variables are matched by slot and offset, not by name. The types map is used for structs, mappings, dynamic arrays, and byte sizes. compatibility_status is compatible, incompatible, warnings, or indeterminate. risk_level is low, medium, high, or critical. A compatible result is not a claim that the upgrade is safe. No chain is queried.","tags":["crypto-security"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"proxyPattern":{"type":"string","enum":["uups","transparent","beacon","custom"]},"current":{"type":"object","properties":{"storage":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"astId":{"type":"integer","minimum":0,"maximum":9007199254740991},"contract":{"type":"string","minLength":1,"maxLength":200},"label":{"type":"string","minLength":1,"maxLength":80},"offset":{"type":"integer","minimum":0,"maximum":31},"slot":{"type":"string","pattern":"^(0|[1-9][0-9]{0,77})$"},"type":{"type":"string","minLength":1,"maxLength":200}},"required":["label","offset","slot","type"],"additionalProperties":false}},"types":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":200},"additionalProperties":{"type":"object","properties":{"encoding":{"type":"string","enum":["inplace","mapping","dynamic_array","bytes"]},"label":{"type":"string","minLength":1,"maxLength":200},"numberOfBytes":{"type":"string","pattern":"^(0|[1-9][0-9]{0,8})$"},"base":{"type":"string","minLength":1,"maxLength":200},"key":{"type":"string","minLength":1,"maxLength":200},"value":{"type":"string","minLength":1,"maxLength":200},"members":{"maxItems":64,"type":"array","items":{"type":"object","properties":{"astId":{"type":"integer","minimum":0,"maximum":9007199254740991},"contract":{"type":"string","minLength":1,"maxLength":200},"label":{"type":"string","minLength":1,"maxLength":80},"offset":{"type":"integer","minimum":0,"maximum":31},"slot":{"type":"string","pattern":"^(0|[1-9][0-9]{0,77})$"},"type":{"type":"string","minLength":1,"maxLength":200}},"required":["label","offset","slot","type"],"additionalProperties":false}}},"required":["encoding","label"],"additionalProperties":false}}},"required":["storage"],"additionalProperties":false},"proposed":{"type":"object","properties":{"storage":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"astId":{"type":"integer","minimum":0,"maximum":9007199254740991},"contract":{"type":"string","minLength":1,"maxLength":200},"label":{"type":"string","minLength":1,"maxLength":80},"offset":{"type":"integer","minimum":0,"maximum":31},"slot":{"type":"string","pattern":"^(0|[1-9][0-9]{0,77})$"},"type":{"type":"string","minLength":1,"maxLength":200}},"required":["label","offset","slot","type"],"additionalProperties":false}},"types":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":200},"additionalProperties":{"type":"object","properties":{"encoding":{"type":"string","enum":["inplace","mapping","dynamic_array","bytes"]},"label":{"type":"string","minLength":1,"maxLength":200},"numberOfBytes":{"type":"string","pattern":"^(0|[1-9][0-9]{0,8})$"},"base":{"type":"string","minLength":1,"maxLength":200},"key":{"type":"string","minLength":1,"maxLength":200},"value":{"type":"string","minLength":1,"maxLength":200},"members":{"maxItems":64,"type":"array","items":{"type":"object","properties":{"astId":{"type":"integer","minimum":0,"maximum":9007199254740991},"contract":{"type":"string","minLength":1,"maxLength":200},"label":{"type":"string","minLength":1,"maxLength":80},"offset":{"type":"integer","minimum":0,"maximum":31},"slot":{"type":"string","pattern":"^(0|[1-9][0-9]{0,77})$"},"type":{"type":"string","minLength":1,"maxLength":200}},"required":["label","offset","slot","type"],"additionalProperties":false}}},"required":["encoding","label"],"additionalProperties":false}}},"required":["storage"],"additionalProperties":false},"currentMetadata":{"type":"object","properties":{"contractName":{"type":"string","minLength":1,"maxLength":120},"compilerVersion":{"type":"string","minLength":1,"maxLength":40},"sourceName":{"type":"string","minLength":1,"maxLength":200}},"additionalProperties":false},"proposedMetadata":{"type":"object","properties":{"contractName":{"type":"string","minLength":1,"maxLength":120},"compilerVersion":{"type":"string","minLength":1,"maxLength":40},"sourceName":{"type":"string","minLength":1,"maxLength":200}},"additionalProperties":false}},"required":["current","proposed"],"additionalProperties":false},"example":{"proxyPattern":"uups","currentMetadata":{"contractName":"Box","compilerVersion":"0.8.24+commit.e11b9ed9"},"proposedMetadata":{"contractName":"BoxV2","compilerVersion":"0.8.26+commit.8a97fa7a"},"current":{"storage":[{"label":"value","offset":0,"slot":"0","type":"t_uint256","contract":"Box.sol:Box"},{"label":"owner","offset":0,"slot":"1","type":"t_address","contract":"Box.sol:Box"},{"label":"__gap","offset":0,"slot":"2","type":"t_array(t_uint256)50_storage","contract":"Box.sol:Box"}],"types":{"t_uint256":{"encoding":"inplace","label":"uint256","numberOfBytes":"32"},"t_uint128":{"encoding":"inplace","label":"uint128","numberOfBytes":"16"},"t_address":{"encoding":"inplace","label":"address","numberOfBytes":"20"},"t_array(t_uint256)50_storage":{"encoding":"inplace","label":"uint256[50]","numberOfBytes":"1600","base":"t_uint256"},"t_array(t_uint256)49_storage":{"encoding":"inplace","label":"uint256[49]","numberOfBytes":"1568","base":"t_uint256"}}},"proposed":{"storage":[{"label":"value","offset":0,"slot":"0","type":"t_uint256","contract":"BoxV2.sol:BoxV2"},{"label":"owner","offset":0,"slot":"1","type":"t_uint256","contract":"BoxV2.sol:BoxV2"},{"label":"extra","offset":16,"slot":"1","type":"t_uint128","contract":"BoxV2.sol:BoxV2"},{"label":"__gap","offset":0,"slot":"2","type":"t_array(t_uint256)49_storage","contract":"BoxV2.sol:BoxV2"}],"types":{"t_uint256":{"encoding":"inplace","label":"uint256","numberOfBytes":"32"},"t_uint128":{"encoding":"inplace","label":"uint128","numberOfBytes":"16"},"t_address":{"encoding":"inplace","label":"address","numberOfBytes":"20"},"t_array(t_uint256)50_storage":{"encoding":"inplace","label":"uint256[50]","numberOfBytes":"1600","base":"t_uint256"},"t_array(t_uint256)49_storage":{"encoding":"inplace","label":"uint256[49]","numberOfBytes":"1568","base":"t_uint256"}}}}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"compatibility_status":{"type":"string"},"risk_level":{"type":"string"},"storage_differences":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"severity":{"type":"string"},"slot":{"type":"string"},"offset":{"type":"number"},"variable":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"affected_variables":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"slot":{"type":"string"},"offset":{"type":"number"},"change":{"type":"string"}},"additionalProperties":true}},"slot_collisions":{"type":"array","items":{"type":"object","properties":{"slot":{"type":"string"},"offset":{"type":"number"},"variables":{"type":"array","items":{"type":"string"}},"detail":{"type":"string"}},"additionalProperties":true}},"type_changes":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"slot":{"type":"string"},"offset":{"type":"number"},"previous_type":{"type":"string"},"proposed_type":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"recommendations":{"type":"array","items":{"type":"string"}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"compatibility_status":"incompatible","risk_level":"critical","storage_differences":[{"code":"slot_collision","severity":"critical","slot":"1","offset":0,"variable":"owner","detail":"The proposed layout overlaps owner and extra at slot 1."},{"code":"type_changed","severity":"critical","slot":"1","offset":0,"variable":"owner","detail":"Slot 1 offset 0 changed from owner (address) to owner (uint256)."},{"code":"inserted","severity":"high","slot":"1","offset":16,"variable":"extra","detail":"extra at slot 1 offset 16 is not in the current layout and is not an append after its last byte."},{"code":"gap_modified","severity":"critical","slot":"2","offset":0,"variable":"__gap","detail":"Gap __gap at slot 2 occupies 50 slots. The proposed layout does not fill that region with new variables followed by the remaining gap."},{"code":"compiler_version_differs","severity":"medium","detail":"The layouts name compiler 0.8.24 and 0.8.26. The comparison uses only the supplied layouts."},{"code":"inheritance_order_changed","severity":"medium","detail":"The declaring contracts in slot order changed from Box.sol:Box to BoxV2.sol:BoxV2."}],"affected_variables":[{"label":"owner","slot":"1","offset":0,"change":"slot_collision"},{"label":"owner","slot":"1","offset":0,"change":"type_changed"},{"label":"extra","slot":"1","offset":16,"change":"inserted"},{"label":"__gap","slot":"2","offset":0,"change":"gap_modified"}],"slot_collisions":[{"slot":"1","offset":0,"variables":["owner","extra"],"detail":"The proposed layout overlaps owner and extra at slot 1."}],"type_changes":[{"label":"owner","slot":"1","offset":0,"previous_type":"address","proposed_type":"uint256","detail":"Slot 1 offset 0 changed from owner (address) to owner (uint256)."}],"recommendations":["This comparison is structural. It does not execute the contracts or prove that an upgrade is safe.","Do not upgrade until every incompatible storage difference is resolved.","Keep the same type at each occupied slot and offset.","Change a storage gap only by placing new variables in its freed slots and leaving the remaining gap directly after them.","Remove overlapping variables so each byte of a slot belongs to one variable.","Recompile both implementations with the same compiler and compare those layouts."],"limitations":["Only the storage layouts in this request were compared. No bytecode, proxy address, or chain state was read.","Variables are matched by slot and offset. A matching name is not storage identity.","A compatible result means no structural difference was found in the supplied layouts. It does not prove that an upgrade is safe or that runtime behavior is unchanged.","Struct, mapping, and dynamic-array layouts are read only from the supplied types map. Missing type entries are not inferred.","Elementary widths are taken from compiler type ids such as t_uint256, or from numberOfBytes when the types map includes it.","A __gap length is read from numberOfBytes or from a uint256[N] compiler type id. Other array lengths are not inferred.","The contract field is compared as supplied. It is not resolved to a source file.","Compiler versions are labels from the request. Different versions are not given different packing rules.","The proxy pattern is uups. This compares implementation layouts only. ERC-1967 proxy slots were not added."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment required. The JSON body is the x402 PaymentRequired object: x402Version, resource with the operation description, accepts with the price and network, and extensions.bazaar with the input schema, input example, output schema, and output example."},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed before settlement, so no payment is taken. Reuse the same idempotency key to retrieve the stored error without paying again."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.05"},"protocols":[{"x402":{"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}],"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}},"/api/v1/crypto-security/storage-slot-grade":{"post":{"operationId":"grade_proxy_storage_slot_changes","summary":"Grade proxy storage slot changes","description":"Compare two caller-supplied storage layouts by slot, offset, and size. A name that moves is a shift. Different names that occupy the same bytes are a collision. The grade and the collision score come from those counts. A variable is one slice of a single slot. No chain is queried.","tags":["crypto-security"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"previous":{"minItems":1,"maxItems":400,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","pattern":"^[A-Za-z_][A-Za-z0-9_]{0,79}$"},"slot":{"type":"integer","minimum":0,"maximum":1000000},"offset":{"type":"integer","minimum":0,"maximum":31},"size":{"type":"integer","minimum":1,"maximum":32}},"required":["name","slot"],"additionalProperties":false}},"next":{"minItems":1,"maxItems":400,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","pattern":"^[A-Za-z_][A-Za-z0-9_]{0,79}$"},"slot":{"type":"integer","minimum":0,"maximum":1000000},"offset":{"type":"integer","minimum":0,"maximum":31},"size":{"type":"integer","minimum":1,"maximum":32}},"required":["name","slot"],"additionalProperties":false}}},"required":["previous","next"],"additionalProperties":false},"example":{"previous":[{"name":"value","slot":0,"offset":0,"size":32},{"name":"owner","slot":1,"offset":0,"size":20}],"next":[{"name":"value","slot":0,"offset":0,"size":32},{"name":"extra","slot":1,"offset":0,"size":32},{"name":"owner","slot":2,"offset":0,"size":20}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"upgrade_safety_grade":{"type":"string"},"collision_probability_score":{"type":"number"},"slot_shift_delta":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"from_slot":{"type":"number"},"to_slot":{"type":"number"},"from_offset":{"type":"number"},"to_offset":{"type":"number"}},"additionalProperties":true}}},"additionalProperties":true},"example":{"upgrade_safety_grade":"F","collision_probability_score":55,"slot_shift_delta":[{"name":"owner","from_slot":1,"to_slot":2,"from_offset":0,"to_offset":0}]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment required. The JSON body is the x402 PaymentRequired object: x402Version, resource with the operation description, accepts with the price and network, and extensions.bazaar with the input schema, input example, output schema, and output example."},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed before settlement, so no payment is taken. Reuse the same idempotency key to retrieve the stored error without paying again."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}],"facilitator":"https://api.cdp.coinbase.com/platform/v2/x402"}}}},"components":{"schemas":{"ApiError":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{}}}}}}}}