> ## Documentation Index
> Fetch the complete documentation index at: https://docs.scripxhq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Exporter: sell a scrip for cash

> The sell-side flow for exporters on ScripX: connect a firm, list its sellable duty credits, take a firm quote per credit at the Scrip Reference Rate, place an order with a price floor, and get paid out with a UTR the same day.

An exporter holding matured RoDTEP or RoSCTL credits that would otherwise sit idle sells them for cash, at a firm price benchmarked to the [Scrip Reference Rate](/core-concepts#the-scrip-reference-rate-srr), settled the same business day.

<Note>
  All calls below use the base URL and header from [Authentication](/authentication):
  `export BASE_URL=https://api.scripxhq.com` and `X-ScripX-Key: $SCRIPX_KEY`. Run the whole flow first with a `scripx_test_…` key in the [sandbox](/environments).
</Note>

## 1. Connect the exporter firm

Register the firm, then verify it under the firm's own mandate.

```bash theme={"dark"}
curl -X POST "$BASE_URL/v1/firms" \
  -H "X-ScripX-Key: $SCRIPX_KEY" \
  -H "Content-Type: application/json" \
  -d '{"iec": "0512345678", "name": "Acme Exports", "role": "exporter"}'
```

Then [verify](/api-reference/firms/verify) the firm's customs account and complete it with the one-time [authorization code](/api-reference/firms/authorize). The firm can sell once its `state` is `connected`.

## 2. List the sellable credits

```bash theme={"dark"}
curl "$BASE_URL/v1/firms/0512345678/credits" \
  -H "X-ScripX-Key: $SCRIPX_KEY"
```

Each credit carries `scheme`, `face_paise`, `balance_paise`, `expiry_date` and a `sellable` flag. A credit with `sellable: true` has already cleared [provenance screening](/core-concepts#provenance-screening) and is ready to quote.

## 3. Quote each credit

Price one specific credit directly by its `scrip_no`:

```bash theme={"dark"}
curl -X POST "$BASE_URL/v1/quote" \
  -H "X-ScripX-Key: $SCRIPX_KEY" \
  -H "Content-Type: application/json" \
  -d '{"side": "sell", "scrip_no": "SCRIP204188"}'
```

```json theme={"dark"}
{
  "side": "sell",
  "scrip_no": "SCRIP204188",
  "scheme": "RODTEP",
  "face_paise": 100000000,
  "price_bps": 9650,
  "all_in_paise": 96500000,
  "valid_until": "2026-07-25T14:32:00+05:30",
  "quote_ref": "qt_01J0..."
}
```

`all_in_paise` is the one number the seller receives: net, [GST-exempt](/core-concepts#hsn-4907-and-gst), nothing deducted after. `valid_until` is the firm window; `quote_ref` is your support reference.

## 4. Place the order with a floor

```bash theme={"dark"}
curl -X POST "$BASE_URL/v1/orders" \
  -H "X-ScripX-Key: $SCRIPX_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: acme-scrip204188-1" \
  -d '{"side": "sell", "scheme": "RODTEP", "amount_paise": 100000000, "min_pct_bps": 9600}'
```

`min_pct_bps` is the seller's structural price floor: the order never fills below it. The `Idempotency-Key` makes a retry safe.

## 5. Get paid, with a UTR

Settlement is [delivery-versus-payment](/core-concepts#delivery-versus-payment-settlement). Title moves seller to buyer on ICEGATE, and the payout fires on ICEGATE confirmation by IMPS with a UTR, in minutes, same business day (T+0). Watch it with a webhook rather than polling:

```bash theme={"dark"}
curl -X POST "$BASE_URL/v1/webhooks" \
  -H "X-ScripX-Key: $SCRIPX_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/hooks/scripx", "event": "*"}'
```

The happy path is `order.matched` then `settlement.settled` then `payout.sent`. The [audit export](/api-reference/account/audit-export) carries the UTR into a tamper-evident record your auditor can verify offline.

## Related

* [Quote reference](/api-reference/trading/quote)
* [Place an order](/api-reference/trading/orders-create)
* [Webhook events](/annexure/webhook-events)
