> For the complete documentation index, see [llms.txt](https://docs.hanji.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hanji.io/for-developers/api.md).

# API

* Contract API: All trades are executed within contracts on Etherlink. To set an order, you call the contract entry point.
* The HTTP API allows you to retrieve information about past and current prices, orders, and trades.
* The WebSocket API is used to receive events about recent changes.

**API Endpoints by Network:**

Etherlink Testnet

* HTTP base endpoint  <https://api-dev.hanji.io/>
* WebSocket endpoint `wss://sockets-dev.hanji.io/`

Etherlink Mainnet

* HTTP base endpoint  [https://api.hanji.io/](https://api-dev.hanji.io/)
* WebSocket endpoint `wss://sockets.hanji.io/`

Monad Mainnet

* HTTP base endpoint  <https://api-monad.hanji.io/>
* WebSocket endpoint `wss://sockets-monad.hanji.io/`

Base Mainnet

* HTTP base endpoint  <https://api-base.hanji.io/>
* WebSocket endpoint `wss://sockets-base.hanji.io/`

You can find an example of how to interact with the Hanji API in the [SDK](https://github.com/longgammalabs/hanji-ts-sdk).
