> ## Documentation Index
> Fetch the complete documentation index at: https://rain-sandbox-trial.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a quote

> Creates a quote for a transfer with an exchange rate and fee breakdown. Quotes expire after a short period (typically 15 minutes).



## OpenAPI

````yaml /openapi.json post /quotes
openapi: 3.0.3
info:
  title: Issuing API
  description: This is the specification for Rain's Issuing API.
  termsOfService: https://www.rain.xyz/legal/authorized-user-terms
  contact:
    email: support@rain.xyz
  version: 1.3.0
servers:
  - url: https://api-dev.rain.xyz/v1
    description: Sandbox server
  - url: https://api.rain.xyz/v1
    description: Production server
security: []
tags:
  - name: paymentRoutes
    description: >-
      **Endpoint Migration:** The `/v1/automations` endpoints have been renamed
      to `/v1/payment-routes`. The old `/v1/automations` paths remain available
      as deprecated aliases during migration. Update your integrations to use
      `/v1/payment-routes` as the deprecated endpoints will be removed in a
      future release.
  - name: simulate
    description: >-
      Transaction simulation endpoints for testing integration flows in
      non-production environments. These endpoints let you trigger transaction
      events programmatically to automate integration tests and verify webhook
      handling without depending on external systems or staging real deposits.
      **Sandbox only** — all simulation endpoints return `404 Not Found` in
      production.
  - name: raindrops
    description: >-
      Rewards and points management endpoints. Custom API keys need
      `raindrops:read`/`raindrops:write` for general rewards endpoints and
      `raindrops-travel:read`/`raindrops-travel:write` for travel redemption
      endpoints.
    x-group: rewards
paths:
  /quotes:
    post:
      tags:
        - quotes
      summary: Create a quote
      description: >-
        Creates a quote for a transfer with an exchange rate and fee breakdown.
        Quotes expire after a short period (typically 15 minutes).
      operationId: createQuote
      requestBody:
        description: Quote request with source and destination
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateQuoteRequest'
        required: true
      responses:
        '201':
          description: Quote created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Quote'
        '400':
          description: >-
            Invalid request — unsupported currency pair, invalid amount, or
            invalid quote configuration
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Invalid authorization
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: >-
            Forbidden — team not approved or payment account does not belong to
            team
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Payment account or team not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: Service temporarily unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    CreateQuoteRequest:
      oneOf:
        - $ref: '#/components/schemas/CreateQuoteBodyWithUserId'
        - $ref: '#/components/schemas/CreateQuoteBodyWithCompanyId'
    Quote:
      type: object
      description: A quote for a transfer with exchange rate and fees
      required:
        - id
        - teamId
        - source
        - destination
        - exchangeRate
        - fees
        - expiresAt
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier for the quote
        teamId:
          type: string
          format: uuid
          description: Team ID associated with this quote
        source:
          $ref: '#/components/schemas/QuoteSource'
        destination:
          $ref: '#/components/schemas/QuoteResponseDestination'
        exchangeRate:
          type: number
          description: Exchange rate excluding fees
        fees:
          $ref: '#/components/schemas/FeeDetail'
        expiresAt:
          type: string
          format: date-time
          description: When the quote expires
    ErrorResponse:
      type: object
      required:
        - statusCode
        - error
      properties:
        statusCode:
          type: number
          description: Status code indicating the request failed
        error:
          type: string
          description: >-
            Error type name, e.g. 'NotFoundError', 'BadRequestError',
            'InternalServerError'
        message:
          type: string
          description: Human-readable error message describing what went wrong
    CreateQuoteBodyWithUserId:
      allOf:
        - $ref: '#/components/schemas/CreateQuoteBodyBase'
        - title: Create Quote Body with User ID
          type: object
          required:
            - userId
          properties:
            userId:
              type: string
              format: uuid
              description: User ID to identify the team
    CreateQuoteBodyWithCompanyId:
      allOf:
        - $ref: '#/components/schemas/CreateQuoteBodyBase'
        - title: Create Quote Body with Company ID
          type: object
          required:
            - companyId
          properties:
            companyId:
              type: string
              format: uuid
              description: Company ID to identify the team
    QuoteSource:
      type: object
      description: Crypto source for a quote (currency, rail, amount, optional address)
      required:
        - currency
        - rail
        - amount
      properties:
        currency:
          $ref: '#/components/schemas/CryptoCurrency'
        rail:
          $ref: '#/components/schemas/CryptoRail'
        amount:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Amount to send (decimal string)
        address:
          $ref: '#/components/schemas/OnchainAddress'
    QuoteResponseDestination:
      oneOf:
        - title: Onchain Destination
          type: object
          description: >-
            Destination in quote response — onchain (includes computed amount to
            receive)
          required:
            - currency
            - rail
            - amount
            - address
          properties:
            currency:
              $ref: '#/components/schemas/CryptoCurrency'
            rail:
              $ref: '#/components/schemas/CryptoRail'
            amount:
              type: string
              pattern: ^[0-9]+(\.[0-9]+)?$
              description: Amount to receive after conversion and fees (decimal string)
            address:
              $ref: '#/components/schemas/OnchainAddress'
        - title: Fiat Destination
          type: object
          description: >-
            Destination in quote response — fiat via payment account (includes
            computed amount; address resolves to
            PaymentAccountExternalFiatAccount by id)
          required:
            - currency
            - rail
            - amount
            - address
          properties:
            currency:
              $ref: '#/components/schemas/FiatCurrency'
            rail:
              $ref: '#/components/schemas/FiatRail'
            amount:
              type: string
              pattern: ^[0-9]+(\.[0-9]+)?$
              description: Amount to receive after conversion and fees (decimal string)
            address:
              $ref: '#/components/schemas/PaymentAccountAddress'
            referenceId:
              type: string
              description: Optional reference ID for the fiat transfer
    FeeDetail:
      type: object
      description: Fee breakdown for a transfer
      properties:
        rain:
          allOf:
            - $ref: '#/components/schemas/FeeAmount'
          description: >-
            Rain's fee for the transaction, charged to the partner
            (informational)
        sender:
          allOf:
            - $ref: '#/components/schemas/FeeAmount'
          description: >-
            Sender fee deducted from the end user's sent amount. See [Sender
            Fees](/docs/sender-fees) for details.
        developer:
          allOf:
            - $ref: '#/components/schemas/FeeAmount'
          deprecated: true
          description: Deprecated alias of `sender`; carries the same values.
    CreateQuoteBodyBase:
      type: object
      description: Base quote request with source and destination
      required:
        - source
        - destination
      properties:
        source:
          $ref: '#/components/schemas/QuoteSource'
        destination:
          $ref: '#/components/schemas/QuoteDestination'
    CryptoCurrency:
      type: string
      enum:
        - usdc
        - rusd
      description: Supported cryptocurrencies
    CryptoRail:
      type: string
      enum:
        - ethereum
        - polygon
        - optimism
        - arbitrum
        - base
        - solana
      description: Supported blockchain networks for crypto operations
    OnchainAddress:
      title: Onchain Address
      type: object
      required:
        - type
        - address
      properties:
        type:
          type: string
          enum:
            - onchain
        address:
          type: string
          description: The blockchain address. Format depends on rail.
    FiatCurrency:
      type: string
      enum:
        - usd
      description: Supported fiat currencies
    FiatRail:
      type: string
      enum:
        - ach
        - wire
      description: Supported fiat payment rails
    PaymentAccountAddress:
      title: Payment Account Id
      type: object
      description: >-
        Reference to a payment account by ID; the account holds
        `PaymentAccountExternalFiatAccountDetails` (external fiat bank account).
      required:
        - type
        - id
      properties:
        type:
          type: string
          enum:
            - paymentAccount
        id:
          type: string
          format: uuid
          description: The payment account ID
    FeeAmount:
      type: object
      description: Fee amount details
      required:
        - currency
        - amount
        - amountUSD
      properties:
        currency:
          type: string
          description: Currency the fee was charged in
        amount:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Fee amount in the original currency (decimal string)
        amountUSD:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Fee amount computed in USD at time of transfer (decimal string)
    QuoteDestination:
      oneOf:
        - title: Onchain Destination
          type: object
          description: Onchain destination with direct wallet address
          required:
            - currency
            - rail
            - address
          properties:
            currency:
              $ref: '#/components/schemas/CryptoCurrency'
            rail:
              $ref: '#/components/schemas/CryptoRail'
            address:
              $ref: '#/components/schemas/OnchainAddress'
        - title: Fiat Destination
          type: object
          description: >-
            Fiat destination via payment account (resolves to
            PaymentAccountExternalFiatAccount details by id)
          required:
            - currency
            - rail
            - address
          properties:
            currency:
              $ref: '#/components/schemas/FiatCurrency'
            rail:
              $ref: '#/components/schemas/FiatRail'
            address:
              $ref: '#/components/schemas/PaymentAccountAddress'
            referenceId:
              type: string
              description: Optional reference ID for the fiat transfer
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      name: Api-Key
      in: header

````