> ## 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.

# Importer: cover duty with scrips

> The buy-side flow for importers on ScripX: quote a duty requirement, receive a bundle of whole credits assembled to cover it, see the cash saving versus paying duty in full, and settle delivery-versus-payment so the cover applies against the Bill of Entry on ICEGATE.

The importer motion covers customs duty with scrips instead of cash. An importer facing a Bill of Entry funds the duty below face value: a credit that settles duty at face is worth nearly face to the buyer, and the difference is the saving.

<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 in the [sandbox](/environments) first with a `scripx_test_…` key.
</Note>

## 1. Connect the importer firm

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

[Verify](/api-reference/firms/verify) and [authorize](/api-reference/firms/authorize) exactly as for an exporter. The firm buys once its `state` is `connected`.

## 2. Quote a duty requirement

Pass the duty amount you need covered as `requirement_paise`:

```bash theme={"dark"}
curl -X POST "$BASE_URL/v1/quote" \
  -H "X-ScripX-Key: $SCRIPX_KEY" \
  -H "Content-Type: application/json" \
  -d '{"side": "buy", "scheme": "RODTEP", "requirement_paise": 500000000}'
```

```json theme={"dark"}
{
  "side": "buy",
  "scheme": "RODTEP",
  "requirement_paise": 500000000,
  "price_bps": 9700,
  "all_in_paise": 485000000,
  "savings_paise": 15000000,
  "scrip_nos": ["SCRIP204188", "SCRIP204190"],
  "covered_paise": 500000000,
  "residual_paise": 0,
  "fully_covered": true,
  "quote_ref": "qt_01J0..."
}
```

Because [scrips transfer whole](/core-concepts#scrips), the cover is the cheapest whole-credit bundle assembled to meet the requirement. `all_in_paise` is what the importer pays in cash, `savings_paise` is the gain versus paying duty in full, and `residual_paise` is any duty left to settle in cash when a bundle cannot land exactly on the requirement.

## 3. Place the order with a ceiling

```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-boe-88213-1" \
  -d '{"side": "buy", "scheme": "RODTEP", "amount_paise": 500000000, "max_pct_bps": 9750}'
```

`max_pct_bps` is the buyer's structural price ceiling: the order never fills above it.

## 4. Settlement applies the cover on ICEGATE

Buyer funds are locked before the scrip moves. On match, title transfers to the importer and the cover is applied against the Bill of Entry on ICEGATE. Settlement is [delivery-versus-payment](/core-concepts#delivery-versus-payment-settlement): if it cannot complete, it unwinds and refunds in full the same day. Track it with [webhooks](/webhooks) (`order.matched`, `settlement.settled`) or [positions](/api-reference/trading/positions).

## Related

* [Quote reference](/api-reference/trading/quote)
* [Place an order](/api-reference/trading/orders-create)
* [What is a scrip?](/what-is-a-scrip)
