POA
English
English
  • Welcome to POA
  • Features
    • Known Validators
    • POADAO Consensus
    • Bridged Native Token
    • On-Chain Randomness
  • Use Cases
    • Scalability for BlockChain Games
    • Community-Based Currencies
    • Subsidized Transactions
    • Decentralized Finance (DeFi)
  • DApp Spotlights
    • Ethernal.World
  • Roadmap
  • For users
    • POA Tokens
      • POA Merger & STAKE Swap
      • POA - STAKE FAQs
      • POA Token Supply
      • POA & POA20 Exchanges
      • POA & POA20 on Binance
      • FAQ: POA20 General Questions
    • POA Token Use Cases
      • Utility Token
      • Currency Token
      • Collateral Token
      • Bridged Token
      • Staking Token
      • Stable Token
    • POA to POA20 Bridge
    • Accept POA20 Payments
      • Account Registration & Login (Merchant Setup)
      • Setup Merchant Account
      • Merchant Payment Method Setup
      • Making a Payment with POA20 (Customer Perspective)
    • Tutorials
      • Trading POA20 on DEX.AG
      • POA20 Token Swaps on 1inch.exchange
      • Getting Airdrops via Discord
    • Governance
      • Article: A Successful Year of On-Chain Governance
      • Governance Reports
        • April 2020 Report
        • December 2019 Report
      • Ballot Type, Lifecycle & Limits
    • ❌Nifty Wallet (Discontinued)
      • Getting Started
      • Import and Interact with Smart Contracts
      • Connect to a Hardware Wallet (Ledger & Trezor)
      • Connect to D'CENT Biometric Wallet
      • Connect to Pocket Decentralized Network
    • 3rd Party Wallets
      • Trust Wallet
      • MetaMask
    • POA Mania
      • News - Updates
      • Rules
      • POA Mania FAQs
      • Deposit & Withdraw
      • Winner Selection
      • Round Details
      • POA Mania vs PoolTogether
      • POA Mania on Trust Wallet
      • POA Mania Security Audit
      • POA Mania on MetaMask Mobile
    • Whitepaper
      • POADAO v1
        • Introduction
        • Proof of Authority
        • POA Network Functionality
        • Decentralized apps (DApps)
          • Initial ceremony DApp
          • Proof of Physical Address (PoPA) DApp
          • Proof of Bank Account DApp
          • Proof of Social Network DApp
          • Proof of Phone Number DApp
          • Governance DApp
        • Summary & Acknowledgements
        • References
        • Appendix A: Code Samples
          • Ballots manager
          • Validators manager
          • Deployment scripts for the mining node
  • For developers
    • Developer Resources
    • Getting Tokens For Tests
      • ERC20 Test Token Faucet
      • Sokol Testnet Faucet
    • Full Node Setup
      • Install OpenEthereum Client
      • Install Nethermind Client
    • DApp Deployment
    • TheGraph Data Indexing
    • On-Chain Random Numbers
      • RNG explainer (AuRa + RandomAura Contract)
      • Accessing a Random Seed with a Smart Contract
      • Randomness FAQs
    • API & SQL Access
    • Smart Contract Dashboard
    • Grants for Building on POA
  • For validators
    • Getting Started
      • Validator Resources
      • Becoming a Validator
    • Bootnode Setup
      • AWS Bootnode Setup
        • Prerequisites
        • Configure AWS
        • Download and Configure Playbook
        • Deploy
      • Non-AWS Bootnode Setup & Deployment
        • Local/Remote Machine System Requirements
        • Node Preparation
        • Configure node with Deployment Playbook
    • Validator Node Setup
      • Nethermind Upgrade
      • AWS VM for Validator Node Deployment
        • MoC: Master of Ceremony Key Exchange & Generation
        • Current Validators Vote in New Validators
        • Validator Node Setup Prerequisites
        • Configuring AWS
        • Download and Configure Playbook
        • Deployment
        • Upgrade Instance to a Larger Instance Type
      • Non-AWS Validator Node Setup
        • Local & Remote Machine System Requirements
        • Remote Machine Setup
        • Configure Node using Deployment Playbook
      • NetStats Dashboard
    • Hard Forks
      • Parity Upgrade Guide
      • POA Core
        • 2021-11-02 | #24090200
        • 2021-05-24 | #21364900
        • 2020-03-31 | #14350721
        • 2019-12-19 | #12598600
        • 2019-04-29 | #8582254
        • 2018-01-29 | # 772000
        • 2018-10-22 | #5329160
        • POA Core spec.json hard-fork update
      • Sokol
        • 2021-05-24 | #21050600
        • 2020-02-20 | #13391641
        • 2019-12-05 | #12095200
        • 2019-02-06 | #7026400
        • 2019-01-04 | #6464300
        • 2018-09-19 | #4622420
        • 2018-01-18 | #509355
        • 2018-01-08 | #362296
        • Sokol spec.json hard-fork update
    • Validator DApps
      • Validators MetaData DApp
      • Adding or Removing a Validator
  • Media
    • Social Media
    • Media Kit
    • Contact Us
Powered by GitBook
On this page
  • ElasticSearch
  • SQL Access

Was this helpful?

  1. For developers

API & SQL Access

AnyBlock Analytics (eth.events) offers access to POA core and Sokol testnet through ElasticSearch and the ability to query a SQL Database.

PreviousRandomness FAQsNextSmart Contract Dashboard

Last updated 5 years ago

Was this helpful?

1) Go to and sign up for a free account.

2) You will receive an API key and SQL username/password.

ElasticSearch

  • Your API key is used to replace $mytoken in standard queries.

  • Queries use the poa eth.events endpoint:

For example, this curl query will show us data about the last 2 blocks.

curl -X POST \
https://api.eth.events/ethereum/poa/core/es/block/search/ \
-H 'Authorization: Bearer $mytoken' \
-H 'Content-Type: application/json' \
-d '{
  "sort": {
    "number.num": "desc"
  },
  "size": 2
}'

SQL Access

2) Click on Server -> Create -> Server

3) In the General Tab, choose a Name for your server instance

4) Go to the Connection Tab, and fill in the information from your AnyBlock Analytics Account and click Save:

Host name.address

sql.anyblock.tools

Port

45432

Maintenance database

ethereum_ethereum_mainnet (or another db from the list)

Username

<your_username>

Password

<your_password>

5) You will see a list of all databases.

  1. Click on ethereum_poa_core or ethereum_poa_sokol to interact with POA data.

  2. To Query the DB, go to Tools -> Query Tool

6) Try a Query!

  1. Check you are in the correct POA database.

  2. Enter your Query (this query shows info about the most recent block).

  3. Click the lighting icon to execute.

  4. Output from query.

Example query to get transactions to the AMB contract on POA Mainnet

SELECT * FROM tx
WHERE tx.to = '0xD9a3039cfC70aF84AC9E566A2526fD3b683B995B'
LIMIT 50

Core:

Sokol Testnet:

Example Queries are located here:

Documentation regarding ElasticSearch API calls is available here:

1) Download a SQL client Anyblock Analytics suggests

7) Explore different queries and information in the SQL documentation and tutorials available here:

https://api.eth.events/ethereum/poa/core/es/
https://api.eth.events/ethereum/poa/sokol/es/
https://docs.anyblockanalytics.com/en/latest/elastic/example-queries/index.html
https://docs.anyblockanalytics.com/en/latest/elastic/index.html
PGAdmin4
https://docs.anyblockanalytics.com/en/latest/sql/tutorials/sql.html
https://account.anyblock.tools/auth/login/