Get contract events

Retrieves a list of events that have been triggered by a given smart contract.

GET

/extended/v1/contract/{contract_id}/events

Retrieves a list of events that have been triggered by a given contract_id.

Path parameters

contract_id
Required
string

Contract identifier formatted as \<contract_address\>.<contract_name>

Example: "SP6P4EJF0VG8V0RB3TQQKJBHDQKEF6NVRD1KZE3C.satoshibles"

Query parameters

limitinteger

Max number of contract events to fetch

offsetinteger

Index of first contract event to fetch

Example: 42000

unanchoredboolean

Include transaction data from unanchored (i.e. unconfirmed) microblocks

Example: trueDefault: false
Status codeDescription
200List of events
Terminal
curl -X GET "https://api.mainnet.hiro.so/extended/v1/contract/SP6P4EJF0VG8V0RB3TQQKJBHDQKEF6NVRD1KZE3C.satoshibles/events"
Example response
{
  "event_index": 0,
  "event_type": "smart_contract_log",
  "tx_id": "string",
  "contract_log": {
    "contract_id": "string",
    "topic": "string",
    "value": {
      "hex": "string",
      "repr": "string"
    }
  }
}