Polkascan Development Update #3

Emiel Sebastiaan
Jul 11 · 9 min read

Milestone 3: key runtime data entities

1. Getting started

1.1. Polkascan PRE on Github

Image 1: Polkascan on Github: https://github.com/polkascan

1.2. What makes Polkascan PRE?

1.3. Requirements

1.4. Running Polkascan PRE

git clone https://github.com/polkascan/polkascan-pre.git
cd polkascan-pre
git tag
git checkout v0.3.x
git submodule update --init --recursive
docker-compose -p dev -f docker-compose.yml up -d mysql
docker-compose -p dev -f docker-compose.yml up --build
Image 2: A successful build of Polkascan PRE

1.5. Cleaning up

docker-compose -p dev -f docker-compose.yml down
docker system prune
[confirm] Y
docker system prune -a
[confirm] Y
docker volume prune
[confirm] Y

2. Exploring Polkascan PRE

2.1. Exploring the GUI

Blocks: http://127.0.0.1:8080/block
Extrinsics: http://127.0.0.1:8080/extrinsic
Events: http://127.0.0.1:8080/event
Logs: http://127.0.0.1:8080/log
Accounts: http://127.0.0.1:8080/account
Runtime specifications: http://127.0.0.1:8080/runtime
Account Indices: http://127.0.0.1:8080/indices/account
Transfers: http://127.0.0.1:8080/balances/transfer
Democracy Proposals: http://127.0.0.1:8080/democracy/proposal
Democracy Referenda: http://127.0.0.1:8080/democracy/referendum

2.2. Exploring the API

Image 3: Exploring the API
Block overview: http://127.0.0.1:8080/api/v1/block
Block detail: http://127.0.0.1:8080/api/v1/block/12345
Extrinsic overview: http://127.0.0.1:8080/api/v1/extrinsic
Extrinsic detail by id: http://127.0.0.1:8080/api/v1/extrinsic/12345-0
Extrinsic detail: http://127.0.0.1:8080/api/v1/extrinsic/0x123...def
Event overview: http://127.0.0.1:8080/api/v1/event
Event detail: http://127.0.0.1:8080/api/v1/event/12345-0
Log overview: http://127.0.0.1:8080/api/v1/log
Log detail: http://127.0.0.1:8080/api/v1/log/12345-0
Account overview: http://127.0.0.1:8080/api/v1/account
Account detail: http://127.0.0.1:8080/api/v1/account/5Cabdce..
Runtime specification overview: http://127.0.0.1:8080/api/v1/runtime
Runtime specification detail: http://127.0.0.1:8080/api/v1/runtime/112
Account Index overview: http://127.0.0.1:8080/api/v1/indices/account
Account Index detail: http://127.0.0.1:8080/api/v1/indices/account/Fc12
Transfer overview: http://127.0.0.1:8080/api/v1/balances/transfer
Transfer detail: http://127.0.0.1:8080/api/v1/balances/transfer/0x123..def
Democracy Proposal overview: http://127.0.0.1:8080/api/v1/democracy/proposal
Democracy Proposal detail: http://127.0.0.1:8080/api/v1/democracy/proposal/1
Democracy Referendum overview: http://127.0.0.1:8080/api/v1/democracy/referendum
Democracy Referendum detail: http://127.0.0.1:8080/api/v1/democracy/referendum/1

2.3. Exploring the DB

Host: 127.0.0.1
Port: 33061
Database: polkascan
Username: root
Password: root
Image 4: Exploring the DB
alembic_version: version data to enforce ddl by SQLAlchemy.
data_account: account data.
data_account_audit: account audit data.
data_account_index: indices account data.
data_account_index_audit: indices account audit data.
data_block: block data.
data_block_total: additional block data.
data_democracy_proposal: democracy proposal data.
data_democracy_proposal_audit: democracy proposal audit data.
data_democracy_referendum: democracy referendum data.
data_democracy_referendum_audit: democracy referendum audit data.
data_event: event data.
data_extrinsic: extrinsic (and transaction and inherent) data.
data_log: digest log data.
data_session: session data.
data_session_total: additional session data.
data_session_validator: session validator data.
runtime: runtime specification data.
runtime_call: runtime specification data of call functions.
runtime_call_param: runtime specification data of call function parameters.
runtime_storage: runtime specification data of storage functions.
runtime_event: runtime specification data of events.
runtime_event_attribute: runtime specification data of event attributes.
runtime_module: runtime specification data of modules.
runtime_type: runtime specification data of types.

3. Stateful data in state-machine

4. Polkascan and the ecosystem

Image 5: Integration between Polkadot-UI and Polkascan.io. (link)

5. Hacking Polkascan PRE

About Polkascan & WEB3SCAN

Image 6: Polkascan.io the multi-chain block explorer for the Polkadot ecosystem. (link)
Image 7: Polkascan’s Dave Hoogendoorn participating in the LongHash incubation program in Singapore. (tweet)

Polkascan project updates

WEB3SCAN | Service Provider

Polkadot Network

Medium account/ publication of the Polkadot Network

Emiel Sebastiaan

Written by

Philosophy of technology, computer science, economics, sociology, reading, writing, puzzles, music, scuba diving, flying & the nature of things.

Polkadot Network

Medium account/ publication of the Polkadot Network