Skip to main content

Kafka Streams for Elysium: Topics, Message Types and a Python Consumer

Bitquery publishes Elysium (chain ID 99901) to Kafka as four protobuf topics. One message carries the parsed data of one block: its transactions with calls and events, its token transfers and balance changes, its DEX trades, or its pool events. Kafka suits consumers that need the whole chain feed with consumer groups and offsets. For filtered data, a WebSocket subscription is simpler. This page is part of the Elysium API docs.

Separate credentials

Kafka uses its own username and password. An IDE or API token does not work on the Kafka brokers. To get Kafka access, fill out the form on our website. Plans are on the pricing page.


Elysium topics​

Topics and message classes were checked on 14 November 2026 by reading and parsing the newest message of each topic.

TopicMessage typeContentsPartitions
elysium.transactions.protoParsedAbiBlockMessageBlock header, transactions, calls and decoded events6
elysium.tokens.protoTokenBlockMessageToken and native transfers, balance changes per transaction6
elysium.dextrades.protoDexBlockMessageDEX trades6
elysium.dexpools.protoDexPoolBlockMessagePool liquidity events, as in the DEXPools cube6

Every message has a Chain field (chain ID 99901), a Header with the Elysium block, and an L1Header with the HyperEVM block that the Elysium block refers to. Message schemas are in Bitquery Streaming Protobuf, under evm.


Connection settings​

SettingValue
Brokersrpk0.bitquery.io:9092,rpk1.bitquery.io:9092,rpk2.bitquery.io:9092
Security protocolSASL_PLAINTEXT
SASL mechanismSCRAM-SHA-512
Username and passwordIssued by Bitquery for Kafka
Group IDMust start with your username, for example <username>-elysium-trades

An SSL listener on port 9093 is also available. Its settings and certificates are described in Kafka streaming concepts.


Python consumer for Elysium DEX trades​

Install the Kafka client and the Bitquery protobuf classes:

pip install confluent-kafka protobuf bitquery-pb2-kafka-package

The script below reads elysium.dextrades.proto from the newest offset and prints the block number and the number of trades in each message. Replace the two placeholders with your Kafka username and password.

from confluent_kafka import Consumer
from evm import dex_block_message_pb2

USERNAME = "<YOUR USERNAME HERE>"
PASSWORD = "<YOUR PASSWORD HERE>"

consumer = Consumer({
"bootstrap.servers": "rpk0.bitquery.io:9092,rpk1.bitquery.io:9092,rpk2.bitquery.io:9092",
"security.protocol": "SASL_PLAINTEXT",
"sasl.mechanism": "SCRAM-SHA-512",
"sasl.username": USERNAME,
"sasl.password": PASSWORD,
"group.id": USERNAME + "-elysium-trades",
"auto.offset.reset": "latest",
"enable.auto.commit": False,
})
consumer.subscribe(["elysium.dextrades.proto"])

try:
while True:
msg = consumer.poll(1.0)
if msg is None or msg.error():
continue
block = dex_block_message_pb2.DexBlockMessage()
block.ParseFromString(msg.value())
number = int.from_bytes(block.Header.Number, "big")
print(number, len(block.Trades), "trades")
finally:
consumer.close()

For the other topics, change the topic name and the message class:

TopicImportClass
elysium.transactions.protofrom evm import parsed_abi_block_message_pb2ParsedAbiBlockMessage
elysium.tokens.protofrom evm import token_block_message_pb2TokenBlockMessage
elysium.dextrades.protofrom evm import dex_block_message_pb2DexBlockMessage
elysium.dexpools.protofrom evm import dex_pool_block_message_pb2DexPoolBlockMessage

What to know before you build​

  • Rate. Elysium produced about 6 to 7 blocks per second on 14 November 2026, and the transactions and tokens topics carry about one message per block. Size your consumer for that rate.
  • Partitions. Each topic has 6 partitions. Run several consumers in one group to share them. Messages keep their order inside a partition only.
  • Amounts. Native amounts and fees are in HYPE. USD fields use the HYPE price.
  • L1 header. L1Header is a HyperEVM block, because Elysium settles to HyperEVM.
  • Token symbols. Look-alike WHYPE and USDC tokens exist on Elysium. Match tokens by contract address. WHYPE is 0xba876237b0f021a6c6d852d6c26e107997cc5e81 and USDC is 0xb47c4c8f73f009cc0c0d3f92b388d13e293f0b65.
  • More on Kafka. Offsets, consumer groups and the topic list for other chains are in Kafka streaming concepts. Filtering messages in your consumer is covered in Filtering Kafka streams.

FAQ​

Which Kafka topics does Elysium have?​

Four: elysium.transactions.proto, elysium.tokens.proto, elysium.dextrades.proto and elysium.dexpools.proto.

Can I use my API token for Kafka?​

No. Kafka needs a separate username and password issued by Bitquery.

What format are the messages in?​

Protobuf. The Python classes are in the bitquery-pb2-kafka-package package, and the .proto files are in the Bitquery Streaming Protobuf repository.

Is there a mempool (broadcasted) topic for Elysium?​

No broadcasted topic is listed for Elysium. The four topics above carry data from produced blocks.

Build with Bitquery

Ready to run this in production?

Get an API key and run these queries in minutes, or talk to us about plans and enterprise delivery.