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

# Quotes and transfers

> Request a Swipelux quote for an exact amount, execute one quote safely with idempotency, and track the transfer state machine through settlement.

A quote is time-bound and single-use. Execute it once, and do not reuse it as a transfer template. A transfer is the execution of that quote and continues changing after creation.

## Check resource compatibility

Before quoting, confirm that:

* The capability is ready, belongs to the customer, and matches the intended direction and method.
* A stablecoin source is an active issued wallet that supports the input currency.
* Wallet-to-wallet resources use the same currency and network.
* A fiat payout account or destination is ready and supports the output currency and method.
* Every source and saved destination belongs to the customer in the API key's environment and developer space. A wallet-move destination account can belong to any customer of your merchant. A sandbox key cannot use live accounts or destinations. Out-of-scope resources return `404 not_found`, as an unknown ID does. See [Key scope](https://docs.swipelux.com/integration/authentication.md#key-scope).

## Choose the exact amount

Create a quote with [`POST /v3/quotes`](https://docs.swipelux.com/api-reference/money-movement/post-v3-quotes). Send one amount side, both currencies, and response-derived resource IDs with these headers:

```http Request headers theme={null}
X-API-Key: ${SWIPELUX_API_KEY}
Idempotency-Key: quote-create-001
Content-Type: application/json
```

> [tab] Exact in
>
> Set `in.amount` and omit `out.amount`. The response calculates what the destination receives.
>
> ```json Fixed input amount theme={null}
> {
>   "customerId": "${CUSTOMER_ID}",
>   "capabilityId": "${STABLECOIN_CAPABILITY_ID}",
>   "in": {
>     "amount": "1.234567",
>     "currency": "USDC",
>     "accountId": "${SOURCE_WALLET_ID}"
>   },
>   "destinationId": "${WALLET_DESTINATION_ID}",
>   "out": {
>     "currency": "USDC"
>   }
> }
> ```

> [tab] Exact out
>
> Set `out.amount` and omit `in.amount`. The response calculates what must leave the source.
>
> ```json Fixed output amount theme={null}
> {
>   "customerId": "${CUSTOMER_ID}",
>   "capabilityId": "${CAPABILITY_ID}",
>   "in": {
>     "currency": "USDC",
>     "accountId": "${SOURCE_WALLET_ID}"
>   },
>   "destinationId": "${RECIPIENT_DESTINATION_ID}",
>   "out": {
>     "amount": "100.00",
>     "currency": "USD"
>   }
> }
> ```

Store the quote `data.id`, `data.status`, `data.expiresAt`, returned legs, rate, and fees. Use the returned decimal strings; do not recalculate executable amounts with floating-point arithmetic.

After a stablecoin-funded exact-out quote, read [`GET /v3/customers/{customerId}/accounts/{accountId}`](https://docs.swipelux.com/api-reference/accounts/get-v3-customers-by-customer-id-accounts-by-account-id). Compare the current source `balances[].available` for the input currency with the returned `data.in.amount`. If funds are insufficient, change or fund the source and create a new quote. Fiat-funded exact-out quotes do not use this source-wallet balance gate.

## Execute once and recover safely

Read the current quote with [`GET /v3/quotes/{quoteId}`](https://docs.swipelux.com/api-reference/money-movement/get-v3-quotes-by-quote-id). Execute only while its status and `expiresAt` permit it.

Create the transfer with [`POST /v3/transfers`](https://docs.swipelux.com/api-reference/money-movement/post-v3-transfers):

```http Request headers theme={null}
X-API-Key: ${SWIPELUX_API_KEY}
Idempotency-Key: transfer-create-001
Content-Type: application/json
```

```json Request body theme={null}
{
  "quoteId": "${QUOTE_ID}"
}
```

Generate one new `Idempotency-Key` for this intended transfer and persist it before sending the request. If the response is lost, retry the identical method, path, body, and key. Do not create a second execution key to recover an uncertain result.

If the API returns `quote_already_executed`, use its `transferId` to continue with the existing transfer. An idempotent replay can also return `Idempotency-Replayed: true`.

## Follow the current transfer

Read [`GET /v3/transfers/{transferId}`](https://docs.swipelux.com/api-reference/money-movement/get-v3-transfers-by-transfer-id) after creation and after each webhook. Store the latest `data.state`, `data.stateDetail`, and `data.openTaskIds`.

When task IDs are open, fetch [`GET /v3/transfers/{transferId}/tasks`](https://docs.swipelux.com/api-reference/money-movement/get-v3-transfers-by-transfer-id-tasks) and complete each task using its current revision and requirements.

For an inbound movement, [`GET /v3/transfers/{transferId}/instructions`](https://docs.swipelux.com/api-reference/money-movement/get-v3-transfers-by-transfer-id-instructions) can return transfer-specific funding details. Render only the returned instruction variant and exact reference.

Next, implement [Webhooks](https://docs.swipelux.com/integration/webhooks.md) so every asynchronous transfer update enters the same current-state handling path.


## Related topics

- [Migrate a v1 or v2 integration to Swipelux API v3](https://docs.swipelux.com/api-reference/versioning/migrate-to-v3.md)
- [Common flows](https://docs.swipelux.com/integration/common-flows.md)
- [Swipelux API changelog and release notes](https://docs.swipelux.com/api-reference/versioning/changelog.md)
- [Send funds](https://docs.swipelux.com/integration/send-funds.md)
- [Create transfer (executes a quote)](https://docs.swipelux.com/api-reference/money-movement/post-v3-transfers.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.