API Endpoints
Mainnet:API Categories
The Sui JSON-RPC API is organized into several namespaces:Core APIs (sui namespace)
- ReadApi - Query objects, transactions, checkpoints, and protocol state
- WriteApi - Execute and inspect transactions
Extended APIs (suix namespace)
- CoinReadApi - Query coin balances and metadata
- EventApi - Query and subscribe to on-chain events
- GovernanceApi - Access staking and validator information
Transaction Builder (unsafe namespace)
- TransactionBuilder - Build unsigned transactions (use SDKs for production)
Making Requests
HTTP Example
WebSocket Subscriptions
WebSocket connections enable real-time event subscriptions:Request Format
All JSON-RPC requests must include:jsonrpc: Version string, always"2.0"id: Request identifier (number or string)method: API method name (e.g.,"sui_getObject")params: Array of parameters (order matters)
Response Format
Successful responses:Rate Limits
Public RPC endpoints have rate limits. For production applications:- Run your own full node
- Use a managed RPC provider
- Implement exponential backoff for retries
API Discovery
Query available methods using therpc.discover method:
Next Steps
- Explore specific APIs in the sidebar
- Use the Rust SDK for type-safe interactions
- Try the GraphQL API for flexible queries