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

# Onramp Quickstart

> Fiat to crypto — quote, create order, collect pay-in, and settle.

Convert customer fiat into crypto delivered to a wallet address. Use a single `POST /orders` endpoint; order type is inferred from the quote legs (fiat `from` → crypto `to`).

<Note>
  All write endpoints require a **secret key** (`sk_*`) and [HMAC request signing](/getting-started/authentication). Examples assume you have set `CLIENT_ID`, `SECRET_KEY`, `ENC_KEY`, and computed `TIMESTAMP` / `SIGNATURE`.
</Note>

## Prerequisites

* KYB-approved partner account with API keys (`pk_*`, `sk_*`, `enc_*`)
* KYC completed on the end user, preferably via a KYC provider (required for onramp)
* A valid customer wallet address on the target network
* [Authentication](/getting-started/authentication) and signing implemented

## End-to-end flow

<Steps>
  <Step title="Create a quote">
    Reserve an exchange rate for a fiat amount and target crypto currency/network.
  </Step>

  <Step title="Create the order">
    Submit the quote ID, recipient wallet, and customer details via `POST /orders`.
  </Step>

  <Step title="Collect fiat payment">
    Present `payin` deposit instructions (bank account) from the order response to your customer.
  </Step>

  <Step title="Wait for payment confirmation">
    Liquidramp auto-detects the transfer. Optionally call `POST /orders/:reference/fulfill` with the bank reference if confirmation is delayed.
  </Step>

  <Step title="Track settlement">
    Poll `GET /orders/:reference` or subscribe to [webhooks](/quickstarts/webhooks) for `order.settled`.
  </Step>
</Steps>

```mermaid theme={null}
sequenceDiagram
    participant App as Your App
    participant API as Liquidramp API
    participant User as Customer

    App->>API: POST /v1/orders/quote
    API-->>App: quote_id, pricing
    App->>API: POST /v1/orders
    API-->>App: order + payin (fiat account)
    App->>User: Show bank transfer instructions
    User->>API: Fiat transfer
    opt Delayed confirmation
        App->>API: POST /v1/orders/:ref/fulfill
    end
    API-->>App: webhook order.fiat_recieved
    API-->>App: webhook order.settled
```

## 1. Create a quote

```bash theme={null}
curl -X POST "$BASE_URL/orders/quote" \
  -H "Content-Type: application/json" \
  -H "liquidramp-client-id: $CLIENT_ID" \
  -H "Authorization: Bearer $SECRET_KEY" \
  -H "liquidramp-timestamp: $TIMESTAMP" \
  -H "liquidramp-signature: $SIGNATURE" \
  -d '{
  "from": { "currency": "NGN", "amount": 50000 },
  "to": { "currency": "USDT", "network": "BSC" },
  "partner_fee": 0
}'
```

Save `data.quote_id` from the response. Quotes expire — create the order promptly. See [Quotes](/concepts/quotes).

## 2. Create the order

```bash theme={null}
curl -X POST "$BASE_URL/orders" \
  -H "Content-Type: application/json" \
  -H "liquidramp-client-id: $CLIENT_ID" \
  -H "Authorization: Bearer $SECRET_KEY" \
  -H "liquidramp-timestamp: $TIMESTAMP" \
  -H "liquidramp-signature: $SIGNATURE" \
  -d '{
  "quote_id": "QUOTE_ID_FROM_STEP_1",
  "merchant_reference": "merchant-ref-001",
  "recipient": { "address": "0x34DF48981ce4d1899a2b1139CC0fDDb6951C4053" },
  "customer": {
    "reference": "cust-001",
    "name": "Jane Doe",
    "email": "jane@example.com",
    "phone": "+2348012345678"
  }
}'
```

The response includes `reference`, `type`, `from`, `to`, `pricing`, optional `fee`, `status`, and `payin`.

There is no wallet-management API. Pass the customer's destination as `recipient.address`. The network is taken from the quote's `to.network` leg. Validate address format and chain before creating the order — sending to the wrong network is irreversible.

Present `payin` deposit instructions to the customer:

```json theme={null}
"payin": {
  "currency": "NGN",
  "account_name": "Liquidramp Collections",
  "account_number": "1234567890",
  "institution_code": "000013",
  "amount": 50000,
  "expires_at": "2026-06-27T13:00:00.000Z",
  "paid_at": null
}
```

## 3. Confirm pay-in (optional)

Liquidramp auto-detects and confirms the customer's bank transfer. Call fulfill only if confirmation is delayed:

```bash theme={null}
curl -X POST "$BASE_URL/orders/ORD-REFERENCE/fulfill" \
  -H "Content-Type: application/json" \
  -H "liquidramp-client-id: $CLIENT_ID" \
  -H "Authorization: Bearer $SECRET_KEY" \
  -H "liquidramp-timestamp: $TIMESTAMP" \
  -H "liquidramp-signature: $SIGNATURE" \
  -d '{
  "reference": "bank-tx-ref-001",
  "institution": "gtbank"
}'
```

`institution` is optional. After confirmation, crypto is released to `recipient.address`.

## 4. Poll or listen

```bash theme={null}
curl -X GET "$BASE_URL/orders/ORD-REFERENCE?include=payout,timeline" \
  -H "liquidramp-client-id: $CLIENT_ID" \
  -H "Authorization: Bearer $SECRET_KEY" \
  -H "liquidramp-timestamp: $TIMESTAMP" \
  -H "liquidramp-signature: $SIGNATURE"
```

Prefer [webhooks](/quickstarts/webhooks) over tight polling in production.

## Related

| Endpoint                                                      | Method | Purpose                                          |
| ------------------------------------------------------------- | ------ | ------------------------------------------------ |
| [`/orders/quote`](/api-reference/create-quote)                | POST   | Reserve rate                                     |
| [`/orders`](/api-reference/create-order)                      | POST   | Create onramp order                              |
| [`/orders/{reference}/fulfill`](/api-reference/fulfill-order) | POST   | Optional pay-in proof if confirmation is delayed |
| [`/orders/{reference}`](/api-reference/get-order)             | GET    | Order status                                     |

* [Orders](/concepts/orders)
* [Settlement](/concepts/settlement)
