Skip to content
This repository has been archived by the owner on Apr 11, 2024. It is now read-only.

Substrate Raw+Decoded Stub Docs #457

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions docs/data-tables/decoded/substrate/balances.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Balances

## **{chain}.balances**

This table contains historical balances information:

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| ts | timestamp without timezone | Timestamp of balance |
| symbol | string | Token Symbol |
| address_ss58 | string | SS58 Address of Asset holder |
| address_pubkey | binary | Pubkey of holder |
| id | string | Chain ID (e.g. "polkadot") |
| chain_name | string | Chain Name (e.g. "KILT Spirit") |
| asset | string | |
| para_id | long | |
| free | double | |
| free_usd | double | |
| reserved | double | |
| reserved_usd | double | |
| misc_frozen | double | |
| misc_frozen_usd | double | |
| frozen | double | |
| frozen_usd | double | |
| price_usd | double | |
| nonce | long | |
| free_raw | string | |
| reserved_raw | string | |
| misc_frozen_raw | string | |
| frozen_raw | string | |
| flags_raw | string | |

Balances are taken at the end of each day.
23 changes: 23 additions & 0 deletions docs/data-tables/decoded/substrate/blocks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Blocks

## **{chain}.blocks**

This table contains historical blocks information:

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_time | timestamp | |
| number | long | |
| spec_version | long | |
| relay_block_number | long | |
| hash | binary | |
| parent_hash | binary | |
| state_root | binary | |
| extrinsics_root | binary | |
| author_ss58 | string | |
| author_pub_key | binary | |
| relay_state_root | binary | |
| extrinsic_count | long | |
| event_count | long | |
| transfer_count | long | |
| trace_count | long | |
36 changes: 36 additions & 0 deletions docs/data-tables/decoded/substrate/calls.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Calls

## **{chain}.calls**

This table contains historical calls information:



| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_number | bigint | |
| block_time | timestamp | |
| extrinsic_id | string | |
| relay_chain | string | |
| para_id | bigint | |
| id | string | |
| block_hash | binary | |
| extrinsic_hash | binary | |
| extrinsic_section | string | |
| extrinsic_method | string | |
| call_id | string | |
| call_index | binary | |
| call_args | string | |
| call_args_def | string | |
| root | boolean | |
| leaf | boolean | |
| fee | double | |
| fee_usd | double | |
| weight | bigint | |
| signed | boolean | |
| signer_ss58 | string | |
| signer_pub_key | binary | |
| lifetime | string | |


Calls are only included if the extrinsic is _successful_.
16 changes: 16 additions & 0 deletions docs/data-tables/decoded/substrate/events.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Events

## **{chain}.events**

This table contains historical events information:

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_time | timestamp |
| block_number | bigint |
| extrinsic_id | string |
| event_id | string |
| data | string |
| extrinsic_hash | binary |
| block_hash | binary |
| data_decoded | string |
24 changes: 24 additions & 0 deletions docs/data-tables/decoded/substrate/extrinsics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Extrinsics

## **{chain}.extrinsics**

This table contains historical extrinsics information:

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_time | timestamp | |
| block_number | long | |
| extrinsic_id | string | |
| hash | binary | |
| block_hash | binary | |
| lifetime | string | |
| params | string | |
| fee | double | |
| weight | long | |
| signed | boolean | |
| signer_ss58 | string | |
| signer_pub_key | binary | |
| fee_usd | double | |


Extrinsics are included if the extrinsic _successful_ or _failed_.
36 changes: 36 additions & 0 deletions docs/data-tables/decoded/substrate/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
title: Substrate Tables
description: Third-party Indexer Colorful Notion indexes Polkadot and Kusama ecosystem data into 6 core Substrate tables.
---

<div class="grid cards" markdown>

- #### Substrate tables

---

Across all Substrate chains (at present, Polkadot, Kusama, their system chains and parachains), the following tables are available:

[→ Blocks tables](blocks.md)

[→ Extrinsics tables](extrinsics.md)

[→ Calls tables](calls.md)

[→ Transfers tables](blocks.md)

[→ Blocks tables](blocks.md)

[→ Balances tables](balances.md)

- #### Special Tables

---

The following tables are only available for Polkadot and Kusama:

[→ Stakings](stakings.md)

[→ Traces tables](traces.md)

</div>
36 changes: 36 additions & 0 deletions docs/data-tables/decoded/substrate/stakings.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Stakings

## **{chain}.stakings**

This table contains historical staking information:


| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_number | long | |
| ts | timestamp | |
| era | long | |
| address_ss58 | string | |
| address_pubkey | binary | |
| block_hash | binary | |
| submitted_in | long | |
| suppressed | boolean | |
| validator_total | double | |
| validator_own | double | |
| validator_commission | double | |
| validator_reward_shares | double | |
| validator_reward_points | long | |
| validator_staking_rewards | double | |
| total_staked | double | |
| total_reward_points | long | |
| total_staking_rewards | double | |
| nominationpools_id | long | |
| nominationpools_total | double | |
| nominationpools_member_cnt | long | |
| nominationpools_commission | double | |
| nominationpools_rewardpools | string | |
| member_bonded | double | |
| member_unbonded | double | |
| member_share | double | |
| targets | array<string> | |
| pv | string | |
49 changes: 49 additions & 0 deletions docs/data-tables/decoded/substrate/traces.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Traces

## **{chain}.traces**

This table contains historical traces information:

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| ts | timestamp | |
| block_number | long | |
| trace_id | string | |
| extrinsic_id | string | |
| relay_chain | string | |
| para_id | string | |
| id | string | |
| chain_name | string | |
| block_hash | binary | |
| k | binary | |
| v | binary | |
| pk_extra | string | |
| pv | string | |
| symbol | string | |
| decimals | long | |
| asset | string | |
| asset_name | string | |
| asset_type | string | |
| xcm_interior_key | string | |
| address_ss58 | string | |
| address_pubkey | binary | |
| flags | string | |
| free | double | |
| free_usd | double | |
| free_raw | string | |
| reserved | double | |
| reserved_raw | string | |
| reserved_usd | double | |
| frozen | double | |
| frozen_raw | string | |
| frozen_usd | double | |
| misc_frozen | double | |
| misc_frozen_raw | string | |
| misc_frozen_usd | double | |
| fee_frozen | double | |
| fee_frozen_raw | string | |
| fee_frozen_usd | double | |
| total_issuance | double | |
| total_issuance_usd | double | |
| total_issuance_raw | string | |
| price_usd | double | |
27 changes: 27 additions & 0 deletions docs/data-tables/decoded/substrate/transfers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Transfers

## **{chain}.transfers**

This table contains historical transfers

| **Column name** | **Type** | **Description** |
| --------------------- | ------------------------------- | -------------------------------------------------------- |
| block_time | timestamp | |
| block_number | long | |
| event_id | string | |
| extrinsic_id | string | |
| section | string | |
| method | string | |
| extrinsic_hash | binary | |
| block_hash | binary | |
| from_ss58 | string | |
| from_pub_key | binary | |
| to_ss58 | string | |
| to_pub_key | binary | |
| asset | string | |
| price_usd | double | |
| amount_usd | double | |
| symbol | string | |
| decimals | long | |
| amount | double | |
| raw_amount | decimal(38,9) | |
6 changes: 6 additions & 0 deletions docs/data-tables/raw/substrate/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: Raw Tables (Substrate)
description: Instead of working with the raw Substrate tables, decoded data.
---

See [Decoded Substrate Tables](../../decoded/substrate/index.md)