Peaq

Peaq is a Substrate/Polkadot Layer-1 SDK for DePIN (Decentralized Physical Infrastructure Networks) and the machine economy. Its node exposes a rich JSON-RPC surface over a single endpoint: the classic Substrate method families (system_, chain_, state_, childstate_, author_, payment_, offchain_, rpc_methods), the newer JSON-RPC-spec families (chainHead_v1_, chainSpec_v1_, transaction_v1_, transactionWatch_v1_), a full Ethereum-compatible EVM layer via Frontier (eth_, net_, web3_), peaq's own machine-economy pallets (peaqdid_, peaqrbac_, peaqstorage_), and the Zenlink DEX (zenlinkProtocol_). The native token is PEAQ (18 decimals; SS58 prefix 42).

Interfaces

InterfaceTransportUse it for
JSON-RPC (HTTP)JSON-RPC 2.0 over HTTP POSTAll request/response methods — Substrate, EVM, peaq pallets, and Zenlink
WebSocket (WSS)JSON-RPC 2.0 over WebSocketThe same methods, plus pub-sub subscriptions (new heads, storage, extrinsic/transaction status, eth_subscribe)

Both interfaces carry the same method set; subscription methods (marked below) require WebSocket. Every call is a POST with a method and a params array to the single endpoint.

Interface Endpoints

bashhttps://shared.us-east-1.getblock.io/<ACCESS-TOKEN>/
bashwss://shared.us-east-1.getblock.io/<ACCESS-TOKEN>/

Replace <ACCESS-TOKEN> with the token from the GetBlock dashboard. The peaq node serves the Substrate and EVM method families on the same endpoint; subscription methods require the WebSocket interface.

Network Information

PropertyValue
Network Namepeaq
Native CurrencyPEAQ (18 decimals)
SS58 Format42
EVM Chain ID3338
FrameworkSubstrate / Polkadot SDK (Layer-1) with Frontier EVM
ConsensusProof-of-Stake (Aura block production + GRANDPA finality)
FinalityDeterministic (GRANDPA)

Supported Networks

NetworkJSON-RPC (HTTP)WebSocket (WSS)Frankfurt, GermanyNew York, USASingapore, Singapore
Mainnet✅✅❌✅❌

Quickstart

  1. Setup project

    bashmkdir peaq-api-quickstart && cd peaq-api-quickstart  && npm init --yes
  2. Install dependency

    bashnpm install axios
  3. Add code

    index.js

    javascriptconst axios = require('axios');
    
    const url = 'https://shared.us-east-1.getblock.io/<ACCESS-TOKEN>/';
    
    const payload = {
      jsonrpc: '2.0',
      method: 'eth_blockNumber',
      params: [],
      id: 'getblock.io'
    };
    
    axios.post(url, payload, {
      headers: { 'Content-Type': 'application/json' }
    })
    .then(response => {
      console.log('Latest block:', parseInt(response.data.result, 16));
    })
    .catch(error => console.error(error));
  4. Run the script

    bashnode index.js
  5. Response

    bashLatest block: 11,979,753
  1. Setup project

    bashmkdir peaq-api-quickstart && cd peaq-api-quickstart
    python -m venv venv && source venv/bin/activate
  2. Install dependency

    bashpip install requests
  3. Add code

    main.py

    pythonimport requests
    import json
    
    url = "https://shared.us-east-1.getblock.io/<ACCESS-TOKEN>/"
    
    payload = json.dumps({
        "jsonrpc": "2.0",
        "method": "eth_blockNumber",
        "params": [],
        "id": "getblock.io"
    })
    
    headers = {
        'Content-Type': 'application/json'
    }
    
    response = requests.post(url, headers=headers, data=payload)
    print(response.text)
  4. Run the script

    bashpython main.py

Support

For technical support and questions:

See Also