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

# Preview order details

> Calculates and returns preview details for an order



## OpenAPI

````yaml /openapi.yaml post /ramp/order-preview
openapi: 3.1.0
info:
  title: FX API
  version: 1.0.0
  description: >
    API for managing FX operations including onboarding, quotes, orders, and
    customer management.

    This API provides endpoints for managing customers, bank accounts, crypto
    wallets, orders, and webhooks.
servers:
  - url: https://api.etherfuse.com
    description: Production API
  - url: https://api.sand.etherfuse.com
    description: Sandbox API (for testing)
security: []
tags:
  - name: Lookup
    description: Public endpoints for looking up stablebond and exchange rate data
  - name: Assets
    description: Get available assets for ramping
  - name: Onboarding
    description: Customer onboarding and KYC
  - name: Bank Accounts
    description: Manage customer bank accounts
  - name: Agreements
    description: Handle customer agreements and consents
  - name: Quotes
    description: Get quotes for conversions
  - name: Orders
    description: Create and manage orders
  - name: Swaps
    description: Create and manage swaps
  - name: Customers
    description: Manage customers
  - name: Crypto Wallets
    description: Manage crypto wallets
  - name: Webhooks
    description: Manage webhook subscriptions
  - name: Organizations
    description: Manage organizations and child organizations
paths:
  /ramp/order-preview:
    post:
      tags:
        - Orders
      summary: Preview order details
      description: Calculates and returns preview details for an order
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OrderPreviewPayload'
      responses:
        '200':
          description: Order preview generated successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  amountFiat:
                    type: number
                    format: decimal
                    description: Amount in fiat currency
                  amountCrypto:
                    type: number
                    format: decimal
                    description: Amount in crypto currency
                  direction:
                    type: string
                    enum:
                      - onramp
                      - offramp
                    description: Transaction direction
                  settlementTime:
                    type: string
                    description: Estimated settlement time
        '400':
          description: Invalid request parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    OrderPreviewPayload:
      type: object
      properties:
        amountFiat:
          type: number
          format: decimal
          nullable: true
          description: Amount in fiat currency
        amountCrypto:
          type: number
          format: decimal
          nullable: true
          description: Amount in crypto currency
        direction:
          type: string
          enum:
            - onramp
            - offramp
          description: Transaction direction
      example:
        amountFiat: 100
        direction: onramp
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
      example:
        error: Invalid request parameters
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        API key for authentication. Pass the key directly (e.g., `Authorization:
        your-api-key`). Do not use a `Bearer` prefix.

````