Decode an EVM smart contract.
Decode an EVM smart contract. Pass chain (ethereum, base, polygon, arbitrum, optimism, bsc, avalanche) + address; returns whether the contract is source-verified (Sourcify), its name/compiler/language, whether it is a proxy and its implementation address, and human-readable function and event signatures from the ABI. Optionally pass selector (a 0x 4-byte function selector) to decode what it calls — resolved from the contract's own ABI when verified, otherwise from the public 4byte directory. Pairs with crypto.tx (which gives a to address + calldata): turn an opaque contract + selector into "what is this and what does it do." Free, keyless.
Request
- Base URL: https://2s.io
- URL: https://2s.io/api/crypto/contract
- Auth: API key in header PAYMENT-SIGNATURE
Query parameters
EVM chain: ethereum, base, polygon, arbitrum, optimism, bsc, or avalanche.
0x-prefixed 40-hex contract address.
Optional 0x 4-byte function selector to decode (e.g. 0xa9059cbb).
Try before you buy. Set to 1 for one free real call per endpoint per hour — no wallet or payment needed — to verify the endpoint before paying. Equivalent to sending the "X-2s-Trial: 1" request header. Listed only on operations that offer a trial; the others always answer 402.
Response
Changes
No recorded changes to this operation across all 1 revision of this API.