> ## Documentation Index
> Fetch the complete documentation index at: https://docs.etherscan.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Contract ABI

> Retrieve the ABI for a verified smart contract.

export const chain = '1';

<ResponseExample>
  ```json Response theme={null}
  {
    "status": "1",
    "message": "OK",
    "result": "[{\"constant\":false,\"inputs\":[{\"name\":\"_c\",\"type\":\"string\"}],\"name\":\"enterValue\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"test\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}]"
  }
  ```
</ResponseExample>


## OpenAPI

````yaml openapi/api-reference/endpoint/getabi.json GET /v2/api
openapi: 3.1.0
info:
  title: Get Contract ABI
  version: 2.0.0
  description: Retrieve the ABI for a verified smart contract.
  license:
    name: Etherscan API Terms
    url: https://etherscan.io/terms
servers:
  - url: https://api.etherscan.io
    description: Etherscan API.
security:
  - apiKey: []
paths:
  /v2/api:
    get:
      summary: Get Contract ABI
      description: Retrieve the ABI for a verified smart contract.
      operationId: getGetabi
      parameters:
        - name: chainid
          in: query
          required: true
          description: >-
            Chain ID to query, eg 1 for Ethereum, 8453 for Base from our
            supported chains.
          schema:
            type: string
          example: '1'
        - name: module
          in: query
          required: true
          description: Set to contract for this endpoint.
          schema:
            type: string
            default: contract
          example: contract
        - name: action
          in: query
          required: true
          description: Set to getabi for this endpoint.
          schema:
            type: string
            default: getabi
          example: getabi
        - name: address
          in: query
          required: true
          description: The contract address to query.
          schema:
            type: string
          example: '0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413'
      security:
        - apiKey: []
components:
  securitySchemes:
    apiKey:
      type: apiKey
      in: query
      name: apikey
      description: Your Etherscan API key.

````