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

# Execute a Trade Quote

> Create a trade transaction from a selected quoteId before the quote expires. Returns HTTP 201 with the full Transaction object.

**POST** `/api/external/transactions/intent/create/`

**Example:** executes the trade quote `quote_lp_best_3043`, selling 10,000 USDT for 9,997 USD.

## Request body

**quoteId** `string` *required*

The `quoteId` returned by [Get Quote](https://docs.primevault.com/transactions/trade/get-quote.md).

**intent** `null`

Send `null` when executing a quote. Do not repeat the quote intent.

**externalId** `string`

Client reference.

**memo** `string`

Human-readable note.

## Response

Returns HTTP 201 with a full [Transaction](https://docs.primevault.com/api-basics/data-models.md#transaction). Optional fields depend on the payment route and status.

**id** `string`

Transaction ID. Use it with [Retrieve Transaction](https://docs.primevault.com/transactions/retrieve-transaction.md) to track status.

**status** `string`

Lifecycle status. Track it until `COMPLETED`, `FAILED`, or `DECLINED`.

**quoteResponse** `QuoteResponseItem`

The executed quote, including its `input`, `output`, `source`, `destination`, and `expiresAt`. See [QuoteResponseItem](https://docs.primevault.com/api-basics/data-models.md#quoteresponseitem).

**source** `TransferPartyData`

Where the funds come from, as a [TransferPartyData](https://docs.primevault.com/api-basics/data-models.md#transferpartydata). Which fields are present depends on `type`.

**Properties**

**type** `string`

`VAULT`, `BANK_ACCOUNT`, `CONTACT`, `EXTERNAL_ADDRESS`, or `EXTERNAL_BANK_ACCOUNT`.

**id** `string`

ID of the vault, bank account, or contact.

**name** `string`

Display name.

**address** `string`

Wallet address, for crypto parties.

**chain** `string`

Blockchain, for crypto parties.

**paymentRail** `string`

Payment rail, for bank parties, such as `ACH`.

**destination** `TransferPartyData`

Where the funds go. Same fields as `source`. See [TransferPartyData](https://docs.primevault.com/api-basics/data-models.md#transferpartydata).

**Properties**

**type** `string`

`VAULT`, `BANK_ACCOUNT`, `CONTACT`, `EXTERNAL_ADDRESS`, or `EXTERNAL_BANK_ACCOUNT`.

**id** `string`

ID of the vault, bank account, or contact.

**name** `string`

Display name.

**address** `string`

Wallet address, for crypto parties.

**chain** `string`

Blockchain, for crypto parties.

**paymentRail** `string`

Payment rail, for bank parties, such as `ACH`.

**balanceChanges** `TransactionOperationBalanceChanges | null`

Aggregate balance movements across the transaction, when present: the input asset debited and the output asset credited. See [TransactionOperationBalanceChanges](https://docs.primevault.com/api-basics/data-models.md#transactionoperationbalancechanges).

**Properties**

**changes** `TransactionOperationBalanceChange[]`

One entry per party and asset. See [TransactionOperationBalanceChange](https://docs.primevault.com/api-basics/data-models.md#transactionoperationbalancechange).

**Properties**

**party** `TransferPartyData | null`

Party whose balance changed. Same fields as `source`. See [TransferPartyData](https://docs.primevault.com/api-basics/data-models.md#transferpartydata).

**asset** `string`

Asset symbol.

**amount** `string`

Signed decimal string: negative for a debit, positive for a credit.

**chain** `string`

Blockchain, for crypto movements.

**paymentRail** `string`

Payment rail, for fiat movements.

**depositInstructions** `DepositInstructions`

Present when funding is required. Use the returned details exactly. See [DepositInstructions](https://docs.primevault.com/api-basics/data-models.md#depositinstructions).

> [!NOTE]
>
> Executing a quote creates a transaction in `PENDING` that waits for approval. [Get the approval message](https://docs.primevault.com/approvals/get-approval-message.md) for the transaction `id`, sign it, then [submit the approval](https://docs.primevault.com/approvals/submit-approval-action.md). The SDK's `createTransactionFromIntent()` does this for you and returns the updated transaction. See [Approvals](https://docs.primevault.com/approvals/overview.md).

```json Request example theme={null}
{
  "intent": null,
  "quoteId": "quote_lp_best_3043",
  "externalId": "trade-usdt-usd-3043",
  "memo": "Sell 10000 USDT for USD"
}
```

```bash cURL theme={null}
# Sample only. Generate a new signed token for each request
# (see Authentication). Tokens expire after 120 seconds.
curl --request POST \
  --url "https://api.primevault.com/api/external/transactions/intent/create/" \
  --header "Authorization: Bearer <signed JWT>" \
  --header "Api-Key: <API key>" \
  --header "Content-Type: application/json" \
  --data '{
    "intent": null,
    "quoteId": "quote_lp_best_3043",
    "externalId": "trade-usdt-usd-3043",
    "memo": "Sell 10000 USDT for USD"
  }'
```

```typescript JavaScript SDK theme={null}
const transaction = await apiClient.createTransactionFromIntent({
  quoteId: "quote_lp_best_3043",
  externalId: "trade-usdt-usd-3043",
  memo: "Sell 10000 USDT for USD",
});
console.log(transaction.id, transaction.status);
```

```json Response example theme={null}
{
  "id": "transaction_trade_3043",
  "orgId": "org_456",
  "vaultId": "vault_gsr_lp",
  "status": "PENDING",
  "transactionType": "OUTGOING",
  "createdAt": "2026-09-30T10:00:05Z",
  "updatedAt": "2026-09-30T10:00:05Z",
  "isDeleted": false,
  "externalId": "trade-usdt-usd-3043",
  "memo": "Sell 10000 USDT for USD",
  "source": { "type": "VAULT", "id": "vault_gsr_lp" },
  "destination": { "type": "VAULT", "id": "vault_gsr_lp" },
  "balanceChanges": {
    "changes": [
      {
        "party": { "type": "VAULT", "id": "vault_gsr_lp" },
        "asset": "USDT",
        "amount": "-10000.00"
      },
      {
        "party": { "type": "VAULT", "id": "vault_gsr_lp" },
        "asset": "USD",
        "amount": "9997.00"
      }
    ]
  },
  "quoteResponse": {
    "quoteId": "quote_lp_best_3043",
    "rate": "1.00030009",
    "fees": { "amount": "0", "asset": "USDT" },
    "input": { "asset": "USDT", "amount": "10000.00" },
    "output": { "asset": "USD", "amount": "9997.00" },
    "source": { "type": "VAULT", "id": "vault_gsr_lp" },
    "destination": { "type": "VAULT", "id": "vault_gsr_lp" },
    "expiresAt": "2026-09-30T10:00:30+00:00"
  },
  "depositInstructions": {
    "type": "EXTERNAL_ADDRESS",
    "asset": "USDT",
    "chain": "ETHEREUM",
    "address": "<DEPOSIT_ADDRESS_FROM_RESPONSE>"
  }
}
```

```typescript JavaScript SDK theme={null}
interface Transaction {
  id: string;
  orgId: string;
  vaultId: string;
  status: TransactionStatus | string;
  transactionType: TransactionType | string;
  category: TransactionCategory | string;
  subCategory: TransactionSubCategory | string;
  createdAt: string;
  updatedAt: string;
  isDeleted: boolean;
  amount: string;

  txHash?: string;
  error?: string;
  externalId?: string;
  createdById?: string;
  fees?: Fees;
  memo?: string;
  txnSignature?: string;
  txnSignatureData?: Record<string, unknown>;
  output?: TransactionOutput;
  amountInUSD?: string;
  nonce?: number;
  dAppId?: string;
  source?: TransferPartyData;
  destination?: TransferPartyData;
  quoteResponse?: QuoteResponseItem;
  depositInstructions?: DepositInstructions;
  operations?: TransactionOperation[];
  balanceChanges?: TransactionOperationBalanceChanges | null;
  blockChain?: string;
  asset?: string;

  /** Deprecated: use destination.address. */
  toAddress?: string;
  /** Deprecated: use destination.name. */
  toAddressName?: string;
  /** Deprecated: use destination.id. */
  toVaultId?: string;
  /** Deprecated: use source.address. */
  sourceAddress?: string;
}
```


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