SubVT Backend

January 29, 2026 ยท View on GitHub

SubVT Backend

SubVT (Substrate Validator Toolkit) backend system implementation.

SubVT is proudly supported by the Kusama Treasury. Please refer to the top-level project repository for more information.

Architecture

Complete details can be found in the system architecture document.


Crates

NameInfo
subvt-app-serviceApplication REST service with such endpoints as user registration, notification rule definitions, etc. OpenAPI YAML specification document here, viewable here.
subvt-block-processorBlock processor and indexer. Stores in the PostgreSQL database the events and extrinsics of interest, era validator and staker inoformation and more.
subvt-configConfiguration component that is used by all SubVT executables for runtime configuration.
subvt-governanceContains the functions to fetch open referenda list and referendum details from the Polkassembly public API.
subvt-loggingLog configurator that is used by all crates.
subvt-metricsCommon crate that contains Prometheus helper functions. Used by all other crates that export Prometheus metrics data.
subvt-network-status-serverPublishes the network status data prepared by the network status updater through WS RPC.
subvt-network-status-updaterFetches the network status data from the Substrate node after each finalized block and stores it in the Redis instance.
subvt-nofification-generatorProcesses the indexed block (PostgreSQL), validator list (Redis) and Telemetry time-series (TimescaleDB) data for possible notifications, and persists notifications according to the previously-defined notification rules.
subvt-notification-processorProcesses and sends the notifications persisted by the notification generator.
subvt-persistenceComplete persistence logic for PostgreSQL and Redis (TBD). Contains the full migrations for the network and application PostgreSQL databases.
subvt-plotterUsed for server-side generation of report charts. Currently used by the Telegram bot to deliver rewards and payouts reports.
subvt-proc-macroProcedural macros.
subvt-report-serviceEra and validator report REST service. OpenAPI YAML specification document here, viewable here.
subvt-service-commonContains the service trait implemented by all SubVT services.
subvt-substrate-clientFacilitates all of the communication between SubVT and Substrate node RPC interfaces.
subvt-telegram-botSubVT Telegram bot, currently live for Kusama and Polkadot. View its readme for details.
subvt-typesComplete SubVT types.
subvt-utilityBasic utility functions. Not used a lot at the moment, but more a place for later work.
subvt-validator-details-serverPublishes a validator's details through a WS RPC channel. Subscriber send the account id of the validator at the initial connection, receives the full validator data as the first response, then only the changes with the new finalized blocks.
subvt-validator-list-serverPublishes through its WS RPC interface the validator list data, which is prepared by the validator list updater.
subvt-validator-list-updaterEvery few blocks, fetches the complete inactive and active validator data from the Substrate node and the PostgreSQL network instance stores it in the Redis instance and notifies the subscriber services.