Join our community of builders on Discord!

Mainnet API & RPC Reference

The Lightchain AI Mainnet exposes standard Ethereum JSON-RPC endpoints alongside Lightchain-specific extensions for AIVM and PoI interactions.

Endpoints

ProtocolURLUse Case
HTTPShttps://rpc.mainnet.lightchain.aiStandard JSON-RPC over HTTPS
Archivehttps://archive.mainnet.lightchain.aiArchive RPC (eth, net, web3 namespaces only)
WSSwss://relay.mainnet.lightchain.ai/wsSubscriptions & real-time event streams
Beacon APIhttps://beacon.mainnet.lightchain.aiBeacon chain API for blob retrieval (EIP-4844)
The endpoints above resolve to the public load balancer at 34.50.152.106.
RPC endpoints may be rate-limited during periods of high demand. If you experience throttling, consider running your own mainnet node.

Rate Limits

TierRequests/SecondDaily Limit
Public10 req/s100,000/day
Registered50 req/s500,000/day
[!TIP] Register for a free API key at https://developer.lightchain.ai to increase your rate limits.
Pass the key via the X-API-Key header or as a query parameter.

Supported JSON-RPC Methods

Standard Ethereum Methods

All standard Ethereum JSON-RPC methods are supported. Commonly used methods include: Querying State
MethodDescription
eth_blockNumberReturns the latest block number
eth_getBalanceReturns the balance of an address
eth_getTransactionByHashReturns transaction details by hash
eth_getTransactionReceiptReturns the receipt of a transaction
eth_getBlockByNumberReturns block details by number
eth_getBlockByHashReturns block details by hash
eth_getCodeReturns the bytecode at an address
eth_getStorageAtReturns storage at a position
eth_callExecutes a read-only call
eth_getLogsReturns logs matching a filter
Sending Transactions
MethodDescription
eth_sendRawTransactionSubmits a signed transaction
eth_estimateGasEstimates the gas for a transaction
eth_gasPriceReturns the current gas price
eth_getTransactionCountReturns the nonce for an address
Subscriptions (WebSocket)
MethodDescription
eth_subscribeSubscribe to events (newHeads, logs)
eth_unsubscribeUnsubscribe from an event stream

Lightchain-Specific Methods

The following custom RPC methods are available for interacting with the PoI consensus and AIVM layers: AIVM Methods
MethodDescription
lcai_submitInferenceTaskSubmit an AI inference task to the AIVM
lcai_getInferenceResultRetrieve the result of a completed inference task
lcai_getInferenceStatusCheck the status of a pending inference task
lcai_listSupportedModelsList AI models available on the mainnet AIVM
PoI Methods
MethodDescription
lcai_getValidatorInfoGet information about a PoI validator
lcai_getComputeContributionsGet compute contributions for a validator
lcai_getCurrentEpochGet the current PoI epoch details
lcai_getEpochRewardsGet reward distribution for a specific epoch

Example Requests

Get Latest Block Number

CodeBASH
Response:
CodeJSON

Get Account Balance

CodeBASH

Submit an AI Inference Task

CodeBASH
Response:
CodeJSON

Subscribe to New Blocks (WebSocket)

CodeJAVASCRIPT

Error Codes

CodeMessageDescription
-32600Invalid RequestMalformed JSON-RPC request
-32601Method Not FoundThe method does not exist
-32602Invalid ParamsInvalid method parameters
-32603Internal ErrorServer-side processing error
-32000Transaction UnderpricedGas price too low
-32001Nonce Too LowTransaction nonce already used
-32700Parse ErrorInvalid JSON payload

Health Check

Verify that the RPC endpoint is responding:
CodeBASH
Expected result: "9200" (the chain ID as a string).

Resources


Last updated: May 2026