Gateway

Get Contract Metadata

Retrieves detailed metadata for a specific smart contract from the thirdweb contract metadata service. This includes compilation information, ABI, documentation, and other contract-related metadata. Note: Source code is excluded from the response to keep it lightweight and suitable for programmatic access.

Authentication: This endpoint requires backend authentication using the x-secret-key header. The secret key should never be exposed publicly.

Metadata Source: The metadata is fetched from the thirdweb contract metadata service and includes detailed Solidity compilation information, contract ABI, and developer documentation.

get/v1/contracts/{chainId}/{address}/metadata

Request

  • Base URL
    https://api.thirdweb.com
  • Auth
    API key in header x-secret-key

Path parameters

chainIdinteger required

The blockchain network identifier where the contract is deployed.

Example:1
addressstring required

The smart contract address or ENS name.

Response

Successfully retrieved contract metadata

Changes

No recorded changes to this operation across all 5 revisions of this API.