Get contracts by trait

Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens.

GET

/extended/v1/contract/by_trait

Retrieves a list of contracts based on the following traits listed in JSON format - functions, variables, maps, fungible tokens and non-fungible tokens.

Query parameters

trait_abi
Required
string

JSON abi of the trait.

limitinteger

Max number of contracts fetch

offsetinteger

Index of first contract event to fetch

Status codeDescription
200List of contracts implement given trait
Terminal
curl -X GET "https://api.mainnet.hiro.so/extended/v1/contract/by_trait"

GET list of contracts

Example response
{
  "limit": 0,
  "offset": 0,
  "results": [
    {
      "tx_id": "string",
      "canonical": true,
      "contract_id": "string",
      "block_height": 0,
      "source_code": "string",
      "abi": "string"
    }
  ]
}