Celenium API Docs
PlansExplorer
PlansExplorer
  1. Websocket
  • Introduction
  • Celenium API
    • Address
      • Get addresses
      • Get count of addresses in network
      • Get address info
      • Get blobs pushed by address
      • Get delegations made by address
      • Get grants where address is grantee
      • Get grants made by address
      • Get address messages
      • Get redelegations made by address
      • Get address stats
      • Get address transactions
      • Get undelegations made by address
      • Get vesting for address
    • Namespace
      • List all blobs with filters
      • Get namespace blob by commitment on height
      • Get blob metadata by commitment on height
      • Get namespaces
      • Get namespace info
      • Get namespace info by id and version
      • Get blob metadata for namespace
      • Get namespace messages by id and version
      • List rollups using the namespace
      • Get namespace info by base64
      • Get namespace blobs on height
    • Block
      • Get blocks
      • Get count of blocks in network
      • Get block info
      • List blobs which was pushed in the block
      • Count of blobs which was pushed in block
      • Get events from begin and end of block
      • Get messages contained in the block
      • ODS for block
      • Get block stats by height
    • General
      • Get network constants
      • Get celenium enumerators
      • Get current indexer head
    • Gas
      • Get estimated gas for pay for blob
      • Get estimated gas price
    • Rollup
      • Get rollups
      • Get count of rollups in network
      • Get rollup by slug
      • Get rollup info
      • Get rollup blobs
      • Get rollup distribution
      • Export rollup blobs
      • Get rollup namespaces info
      • Get rollup stats
    • Search
      • Search by hash
    • Stats
      • Get histogram for namespace with precomputed stats
      • Get namespaces with sorting by size.
      • Get current TIA price
      • Get histogram with TIA price
      • Get histogram with precomputed stats
      • Get cumulative histogram with precomputed stats​
      • Get histogram for staking with precomputed stats
      • Get value by table and function
      • Get tps
    • Transactions
      • Get transactions
      • Get count of transactions in network
      • List genesis transactions info
      • Get transaction by hash
      • List blobs which was pushed by transaction
      • Count of blobs which was pushed by transaction
      • Get transaction events
      • Get transaction messages
    • Validator
      • Get validators
      • Get validator's count by status
      • Get validator info
      • Get blocks which was proposed by validator
      • Get validator's delegators
      • Get validator's jails
      • Get validator's uptime and history of signed block
    • Vesting
      • Periods vesting periods by id
    • Websocket
      • Websocket API
        CONNECT
  1. Websocket

Websocket API

Mainnet
wss://api-mainnet.celenium.io
Mainnet
wss://api-mainnet.celenium.io
CONNECT
wss://api-mainnet.celenium.io
/v1/ws
websocket
Last modified:2024-12-17 10:40:24

Documentation for websocket API#

Notification#

The structure of notification is following in all channels:
{
    "channel": "channel_name",
    "body": "<object or array>"  // depends on channel
}

Subscribe#

To receive updates from websocket API send subscribe request to server.
{
    "method": "subscribe",
    "body": {
        "channel": "<CHANNEL_NAME>",
        "filters": {
            // pass channel filters
        }
    }
}
Now 3 channels are supported:
head - receive information about indexer state. Channel does not have any filters. Subscribe message should looks like:
{
    "method": "subscribe",
    "body": {
        "channel": "head"
    }
}
Notification body of responses.State type will be sent to the channel.
blocks - receive information about new blocks. Channel does not have any filters. Subscribe message should looks like:
{
    "method": "subscribe",
    "body": {
        "channel": "blocks"
    }
}
Notification body of responses.Block type will be sent to the channel.
gas_price - receive information about current gas price. Channel does not have any filters. Subscribe message should looks like:
{
    "method": "subscribe",
    "body": {
        "channel": "gas_price"
    }
}
Notification body of responses.GasPrice type will be sent to the channel.

Unsubscribe#

To unsubscribe send unsubscribe message containing one of channel name describing above.
{
    "method": "unsubscribe",
    "body": {
        "channel": "<CHANNEL_NAME>",
    }
}

Code example#

Request

Authorization
Add parameter in header
apiKey
Example:
apiKey: ********************

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request CONNECT 'wss://api-mainnet.celenium.io/v1/ws' \
--header 'apiKey;'

Responses

🟢200Success
application/json
Body
object {0}
Example
{}
Modified at 2024-12-17 10:40:24
Previous
Periods vesting periods by id
Built with