(planned) Dhan is the first live broker Sarathi intends to
route to. The connection exists in the product but the adapter does not:
credentials can be saved, orders are not sent. Sarathi has no partnership or
contract with Dhan.

## What works today

| Step | Status | Detail |
| --- | --- | --- |
| Save Dhan credentials | (live) | API key, API secret and an optional client id, entered in Settings. Needs the Starter pack or higher. |
| Encryption at rest | (live) | Envelope encryption: each bundle gets its own data key, wrapped by a versioned master key held only on the server. |
| Route selection | (live) | Saving credentials switches your route to Dhan; disconnecting switches it back to paper. |
| Order placement | (planned) | No orders are sent. A Confirm on a Dhan-routed card is rejected with `Broker "dhan" is not configured`, the signal is marked failed, and the rejection is journaled. |


  The rejection on Confirm is deliberate. A route that cannot execute fails in
  the open rather than quietly filling on paper, so the journal never shows a
  fill that did not happen. Until the adapter ships, keep your account on the
  [paper route](/brokers/paper).


Credentials are decrypted only at the moment an order is placed. The tier gate is enforced on the server: a Free account that tries to connect gets `Connecting a live broker needs the Starter pack or higher`.

## What the adapter will do

The planned adapter is small on purpose. It implements the same interface the paper broker does, so nothing upstream of it changes.

- **One tap, one order.** Confirm places one order on your Dhan account at the quantity you chose (½, 1×, 2×). Skip places nothing. Expiry places nothing, ever.
- **No autonomous mode.** No toggle lets Sarathi act on an alert without you. The human decision is a required column in the data model, not a setting.
- **Journal the broker's answer.** The order id, fill price and quantity Dhan reports, or its rejection reason, go to the same fill table paper uses, with route `dhan`.
- **Your account, your custody.** Sarathi never holds funds or securities. The order goes to the account behind your credentials.

Not planned: order modification, basket or multi-leg placement, position management, or reading your holdings.

## DhanHQ API facts

Checked 30 August 2026 on Dhan's pages.

| Fact | Source |
| --- | --- |
| Trading APIs listed at ₹0; data APIs listed at ₹499 and sold separately | [DhanHQ trading APIs](https://dhanhq.co/trading-apis) |
| Order API rate limit set to 10 orders per second from 8 September 2025, "in accordance with regulations" | [DhanHQ release notes, v2.3](https://dhanhq.co/docs/v2/releases/) |
| API-key login for individuals: key valid one year, a new access token generated each day, access token valid 24 hours | [DhanHQ release notes, v2.4, 22 September 2025](https://dhanhq.co/docs/v2/releases/) |
| Static IP required for all order APIs (place, modify, cancel), configurable through an API | [DhanHQ release notes, v2.4](https://dhanhq.co/docs/v2/releases/) |
| Access token can be generated via API when TOTP is configured on the account | [DhanHQ release notes, v2.5, 9 February 2026](https://dhanhq.co/docs/v2/releases/) |
| A sandbox exists for testing against the API before going live | [DhanHQ trading APIs](https://dhanhq.co/trading-apis) |

Two of these shape the adapter directly. The daily access token means a live Dhan route needs a fresh token each trading day, and a card must show as rejected, not silently retried, when the token has lapsed. The static IP requirement means the address calling Dhan's order API has to be whitelisted; whether that is Sarathi's server or one you supply is an open design question to settle before the adapter ships.

## The SEBI framework, in plain words


  This section describes what the circulars say. It is not a statement that
  Sarathi, or any setup built on it, is compliant. Verify with your broker.


On 4 February 2025 SEBI issued [Safer participation of retail investors in Algorithmic trading](https://www.sebi.gov.in/legal/circulars/feb-2025/safer-participation-of-retail-investors-in-algorithmic-trading_91614.html). Its main points for a retail trader using a broker API:

- The broker is the principal and any algo provider is its agent; the broker deals only with empanelled providers.
- All API orders carry an exchange-issued identifier.
- API access uses a unique key per user, a static IP whitelisted by the broker, OAuth-style authentication and two-factor login.
- Retail traders using self-built algos register them only above an orders-per-second threshold, and may share them with immediate family only.

The [30 September 2025 extension](https://www.sebi.gov.in/sebi_data/attachdocs/sep-2025/1759232056254.pdf) set 1 October 2025 as go-live for brokers that were ready and 1 April 2026 as the date the framework applies to all brokers. Zerodha's [overview of the NSE standards](https://zerodha.com/z-connect/general/a-comprehensive-overview-of-nses-circular-on-the-new-retail-algo-trading-framework) is a readable secondary source.

Sarathi places one human-confirmed order per tap and runs no marketplace. Whether a hosted bridge calling a broker API on your behalf counts as an algo provider under the framework is a question this page does not answer. Ask your broker.

## Get started

Start on the [paper route](/brokers/paper) today; it is the default and never metered. The Starter pack lets you save Dhan credentials now; the live route turns on when the adapter ships. Until then, work through the [pre-live checklist](/learn/pre-live-checklist).
