Returns stats to be displayed on the main page of indexer.
curl --request GET \
--url https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"average_block_time": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"daily_new_operational_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"daily_new_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"op_stack_daily_new_operational_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"op_stack_total_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"op_stack_yesterday_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_addresses": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_blocks": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"yesterday_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"yesterday_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
}
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}StatsService
Returns stats to be displayed on the main page of indexer.
GET
/
{chain_id}
/
stats-service
/
api
/
v1
/
pages
/
main
Returns stats to be displayed on the main page of indexer.
curl --request GET \
--url https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockscout.com/{chain_id}/stats-service/api/v1/pages/main")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"average_block_time": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"daily_new_operational_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"daily_new_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"op_stack_daily_new_operational_transactions": {
"chart": [
{
"date": "<string>",
"date_to": "<string>",
"is_approximate": true,
"value": "<string>"
}
],
"info": {
"description": "<string>",
"id": "<string>",
"resolutions": [
"<string>"
],
"title": "<string>",
"units": "<string>"
}
},
"op_stack_total_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"op_stack_yesterday_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_addresses": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_blocks": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"total_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"yesterday_operational_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
},
"yesterday_transactions": {
"description": "<string>",
"id": "<string>",
"title": "<string>",
"units": "<string>",
"value": "<string>"
}
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}Authorizations
bearerAuthapiKeyAuth
API key passed as a Bearer token in the Authorization header.
Path Parameters
The ID of the blockchain
Response
A successful response.
Pre-assembled set of statistics for the main indexer page. Fields are optional because individual charts may be disabled.
Show child attributes
Show child attributes
A line chart: its metadata and the series of data points.
Show child attributes
Show child attributes
A line chart: its metadata and the series of data points.
Show child attributes
Show child attributes
A line chart: its metadata and the series of data points.
Show child attributes
Show child attributes
OP-Stack-specific variants of operational transaction counters.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?
Returns interchain messaging stats to be displayed on the main page of interchain indexer.
Previous
Returns multichain-aggregated stats to be displayed on the main page of multichain indexer.
Next
⌘I