Skip to content

Events of one block

GET
/blocks/{block}/events/

The events of one block in emission order, optionally only those of one extrinsic, one pallet (section) or one event name (method). Page-number pagination with exact totals.

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

  • None
block
required
integer

Block number.

extrinsic_idx
integer

Only the events emitted by this extrinsic. 400 when not an integer.

method
string

Exact event name, e.g. StakeAdded.

page
integer

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

page_size
integer

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

section
string

Exact pallet name, e.g. SubtensorModule.

One page of the block’s events, in emission order.

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
total_count
required

Exact number of matching rows, whether or not the pages can reach them all.

integer
reachable_count
required

Rows the pages can reach: total_pages times page_size, capped at total_count. Below total_count only when the set runs deeper than the offset cap; read the rest through the cursor where the route offers one.

integer
total_pages
required

Clamped to the deepest page the API will serve (offset <= 10000).

integer
has_next
required

Whether a next page exists within the deepest page served.

boolean
has_previous
required

True past page 1.

boolean
next_cursor

Where the list offers a cursor form (/v2/subnets/{netuid}/?delegators=true, /v2/validators/{hotkey}/): the after= that reads the page after this one, null on the last page, and valid only under the sort, direction and grouping that issued it (a 400 otherwise). Absent on lists with no cursor form.

string
nullable

Examples

ExampleBlockEvents

The two stake additions of one block

{
"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,
"total_count": 2,
"reachable_count": 2,
"total_pages": 1,
"has_next": false,
"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": "extrinsic_idx must be an integer",
"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.