curl --request GET \
--url https://sourcify.dev/server/v2/contract/{chainId}/{address}Get verified contract
By default returns minimal information about the contract: match, creation_match, runtime_match, chainId, address, and verifiedAt
To get other details one can either list the fields requested in the fields query param or ask all fields but omit several with omit. To get everything just pass fields=all.
curl --request GET \
--url https://sourcify.dev/server/v2/contract/{chainId}/{address}Path Parameters
The chainId number of the EVM chain
1 - 20^\d+$"11155111"
Contract's 20 byte address in hex string with the 0x prefix. Case insensitive.
42(\b0x[a-fA-F0-9]{40}\b)"0x2738d13E81e30bC615766A0410e7cF199FD59A83"
Query Parameters
Comma seperated fields to include in the response. Can also take all
"abi,metadata,creationBytecode.onchainBytecode,deployment.blockNumber,compilation"
Comma seperated fields to NOT include in the response. All fields except matching ones will be returned. Can't be used simultanously with fields.
"userdoc,devdoc,storageLayout,transientStorageLayout,compilation.sources"
Response
Example response
match, exact_match, null match, exact_match, null match, exact_match, null 1 - 20^\d+$"11155111"
Contract Address in hex string. Can be checksummed or not (i.e. can contain capital letters)
(\b0x[a-fA-F0-9]{40}\b)"0xDFEBAd708F803af22e81044aD228Ff77C83C935c"
"2024-07-24T12:00:00Z"
"3266227"
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Storage layout of the contract. Format differs by language: Solidity uses {storage: [...], types: {...}}, Vyper uses {variableName: {type, slot, n_slots}}.
Same as stdJsonOutput.sources
Show child attributes
Show child attributes
Additional compiler input fields from the top level of the standard JSON input that are not part of settings. Currently contains Vyper's storage_layout_overrides when used.
Show child attributes
Show child attributes
The input fields conforming the compiler standard-JSON format.
Show child attributes
Show child attributes
The outputs conforming the compiler standard JSON format
Show child attributes
Show child attributes
The signatures of the contract grouped by type (function, event, error).
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?