Skip to content

Chain events, newest first

GET
/events/

Chain events, newest block first and in emission order within a block, filtered by block, block range, pallet (section) or event name (method). data holds the event’s arguments as a JSON string, with integers above 2^53 as strings. Page-number pagination without totals: follow has_next.

Rate limit: 300 requests per minute per IP (scope explore).

  • None
block
integer

Only this block. An unparseable value is ignored, never a 400.

from_block
integer

Lower bound on the block number. An unparseable value is ignored, never a 400.

method
string

Exact event name.

page
integer

1-based page number. Defaults to 1; an unparseable value falls back to it.

page_size
integer

Rows per page. Default 25, clamped to [1, 100].

section
string

Exact pallet name.

to_block
integer

Upper bound on the block number. An unparseable value is ignored.

One page of events, without totals.

Media typeapplication/json
object
results
required

This page’s rows, in the order the operation states.

Array<object>

One event. Same shape from /events/ and /blocks/{block}/events/; /events/{event_id}/ adds tao_price_usd.

object
block
required
integer
idx
required

Index of the event in its block, so {block}-{idx} names it on /events/{event_id}/.

integer
extrinsic_idx
required

Index of the extrinsic that emitted it, so {block}-{extrinsic_idx} names it on /extrinsics/{extrinsic_id}/; null outside an extrinsic.

integer
nullable
section
required

Pallet, e.g. SubtensorModule.

string
method
required

Event name, e.g. StakeAdded.

string
phase
required

ApplyExtrinsic({idx}), or null outside an extrinsic.

string
nullable
data
required

The event attributes as a JSON-ENCODED STRING, not an object. Parse it client-side.

string
nullable
pagination
required

Where this page sits in the list, and whether another follows.

object
page
required

The page served, counting from 1.

integer
page_size
required

Rows per page, the requested size within the route’s bounds.

integer
has_next
required

Whether another page follows.

boolean
has_previous
required

True past page 1.

boolean

Examples

ExampleEvents

Two stake additions

{
"results": [
{
"block": 9346501,
"idx": 192,
"extrinsic_idx": 22,
"section": "SubtensorModule",
"method": "StakeAdded",
"phase": "ApplyExtrinsic(22)",
"data": "{\"values\": [\"5HgtEjWZ9mwgqrwbqqiDZhUxAijfuJJU4GLCML2qJ33qA2KV\", \"5GKH9FPPnWSUoeeTJp19wVtd84XqFW4pyK2ijV2GsFbhTrP1\", 12686321540, 1796189056863, 23, 0]}"
},
{
"block": 9346501,
"idx": 222,
"extrinsic_idx": 28,
"section": "SubtensorModule",
"method": "StakeAdded",
"phase": "ApplyExtrinsic(28)",
"data": "{\"values\": [\"5GjD6wt4GNRmRYbxa7Svtq86EUQmbwURfokpsFDNetKWmSAf\", \"5GKH9FPPnWSUoeeTJp19wVtd84XqFW4pyK2ijV2GsFbhTrP1\", 1408134904, 84183066482, 68, 0]}"
}
],
"pagination": {
"page": 1,
"page_size": 2,
"has_next": true,
"has_previous": false
}
}

A parameter failed its check, which message names. code is usually VALIDATION_ERROR.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleVALIDATIONERROR

VALIDATION_ERROR

{
"error": true,
"code": "VALIDATION_ERROR",
"message": "page too deep: max page is 401 for page_size=25",
"detail": null
}

Rate limit exceeded (300/minute, per IP). Retry-After carries the seconds to wait.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleRATELIMITED

RATE_LIMITED

{
"error": true,
"code": "RATE_LIMITED",
"message": "Request was throttled",
"detail": {
"retry_after": 12
}
}
Retry-After
integer

Seconds before the next request is accepted.

QUERY_TIMEOUT: the query exceeded its budget. detail carries budget_ms, elapsed_ms, path and query.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleQUERYTIMEOUT

QUERY_TIMEOUT

{
"error": true,
"code": "QUERY_TIMEOUT",
"message": "query exceeded the 12000 ms budget; retry, or narrow the requested range",
"detail": {
"budget_ms": 12000,
"elapsed_ms": 12004,
"path": "/trades/summary/",
"query": "coldkey=5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY&resolution=day"
}
}