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

# Create trade quote



## OpenAPI

````yaml /coins/api-reference/openapi.json post /quote
openapi: 3.1.0
info:
  contact:
    email: support@daya.co
    name: API Support
  description: >-
    Public developer API for the Coins by Daya product. X-API-Key authenticated.
    Market data, portfolio, balances, transactions, order placement, crypto and
    fiat withdrawals. All responses use the standard envelope: { success,
    message?, data?, error?, timestamp }.
  title: Daya Coins Public API
  version: 1.0.0
servers:
  - url: https://api.daya.co/coins/v1
    description: Production server
security:
  - ApiKeyAuth: []
paths:
  /quote:
    post:
      tags:
        - coins-trading
      summary: Create trade quote
      operationId: postQuote
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/internal_publicapi_v1.PublicQuoteRequest'
        description: Trade quote request
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                allOf:
                  - $ref: >-
                      #/components/schemas/github_com_dayacoins_daya-coins-service_pkg_response.Envelope
                  - properties:
                      data:
                        $ref: '#/components/schemas/internal_publicapi_v1.PublicQuote'
                    type: object
          description: Issued trade quote
        '400':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/github_com_dayacoins_daya-coins-service_pkg_response.Envelope
          description: Malformed body
        '422':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/github_com_dayacoins_daya-coins-service_pkg_response.Envelope
          description: Validation error
        '503':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/github_com_dayacoins_daya-coins-service_pkg_response.Envelope
          description: Rate unavailable upstream
components:
  schemas:
    internal_publicapi_v1.PublicQuoteRequest:
      properties:
        input_amount:
          example: '100.00'
          type: string
        input_asset:
          example: fiat:usd
          type: string
        output_amount:
          example: '0.00153846'
          type: string
        output_asset:
          example: bitcoin:native
          type: string
      type: object
    github_com_dayacoins_daya-coins-service_pkg_response.Envelope:
      properties:
        data: {}
        error:
          $ref: >-
            #/components/schemas/github_com_dayacoins_daya-coins-service_pkg_response.ErrorData
        message:
          description: Message is an optional banner/toast string.
          type: string
        success:
          type: boolean
        timestamp:
          type: string
      type: object
    internal_publicapi_v1.PublicQuote:
      properties:
        created_at:
          example: '2026-01-15T10:30:00Z'
          type: string
        disclaimer:
          description: >-
            Disclaimer is set when the fill is an estimate (Relay swaps), empty
            otherwise.
          type: string
        expires_at:
          example: '2026-01-15T10:30:30Z'
          type: string
        id:
          example: eyJxaWQiOiIzZjI1MDRlMCJ9.c2lnbmF0dXJl
          type: string
        input_amount:
          example: '100.00'
          type: string
        input_asset:
          example: fiat:usd
          type: string
        min_output:
          description: >-
            MinOutput is the expected output under normal execution (equals

            output_amount for CEX quotes; estimate less the slippage tolerance
            for

            swap venues). On a BUY the rate is the firm promise: a partial fill

            delivers the venue's actual quantity and refunds the unfilled
            portion of

            your cash at the quoted rate — you are never charged for more than
            you

            receive, and an over-delivery is yours. A swap-venue SELL settles at
            the

            swap's realised proceeds, capped at the quoted amount.
          example: '0.00152308'
          type: string
        output_amount:
          example: '0.00153846'
          type: string
        output_asset:
          example: bitcoin:native
          type: string
        rate:
          example: '65000.00'
          type: string
        side:
          enum:
            - buy
            - sell
          example: buy
          type: string
      type: object
    github_com_dayacoins_daya-coins-service_pkg_response.ErrorData:
      properties:
        code:
          type: string
        details: {}
        fields:
          additionalProperties:
            type: string
          type: object
        message:
          type: string
      type: object
  securitySchemes:
    ApiKeyAuth:
      description: >-
        Your Daya API key, sent in the X-API-Key header. Issue and scope keys in
        the Daya dashboard.
      in: header
      name: X-API-Key
      type: apiKey

````

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