Overview
Last updated
Last updated
There are a few ways to interact with the Carbon blockchain. The simplest way would be to use the official TypeScript / Javascript SDK here:
Alternatively, there are APIs accessible for direct interaction with Carbon nodes, offering improved control and reliability.
Here are the APIs available:
Carbon WebSocket: This API streams formatted data on the state of all Carbon modules, rather than exposing the raw state of the blockchain. However, transactions cannot be sent through this API. This API is ideal for applications such as trading bots, decentralized exchanges, and explorers.
Carbon API: This API enables the sending of transactions, and provides queries for i) Cosmos-SDK core module states, ii) Carbon module states, as well as iii) Additional off-chain data stored by Carbon nodes running the off-chain persistence module. For applications that do not support gRPC, a gRPC-gateway is available, allowing the same GRPC endpoints to be accessed via REST.
Command Line Interface: You may also use the CLI that comes with the Carbon node binary to query the blockchain or send transactions.
Carbon Insights: This is a separate API service that aggregates time-series data and statistical information.
For a reliable end-user experience, we recommend utilizing a combination of WebSockets (for monitoring state) and gRPC (for sending transactions).
If you are developing an extensive application or serving a large user base, it is advisable to run your own Carbon Testnet or Mainnet node for better reliability and scalability as the public nodes listed here (and in the SDK) have no guarantees in terms of performance or uptime.