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

# Get a BRE-B quote

> Cached USD→COP rate (default 6 hours) plus the fee stack.
Omit `destinationCop` to receive only the effective rate.
Amounts below 4000 COP or 2 USDC to Bridge return `below_minimum`.




## OpenAPI

````yaml /openapi.yaml get /api/integrations/breb/quote
openapi: 3.1.0
info:
  title: COP By Integrations API
  version: 0.1.0
  description: |
    Non-custodial Celo API for partners. Prepare swaps and BRE-B COP payouts;
    the user signs from their wallet. Confirm with the transaction hash.
servers:
  - url: http://localhost:3000
    description: Local Next.js app
  - url: https://app.copby.co
    description: Production (replace if your origin differs)
security:
  - bearerAuth: []
tags:
  - name: BRE-B
    description: Quote, KYC, and COP payouts via Bridge Bre-B
  - name: Swaps
    description: Prepare and confirm onchain COPm swaps
  - name: Webhooks
    description: Bridge callbacks. Not authenticated with a partner key.
paths:
  /api/integrations/breb/quote:
    get:
      tags:
        - BRE-B
      summary: Get a BRE-B quote
      description: |
        Cached USD→COP rate (default 6 hours) plus the fee stack.
        Omit `destinationCop` to receive only the effective rate.
        Amounts below 4000 COP or 2 USDC to Bridge return `below_minimum`.
      operationId: getBrebQuote
      parameters:
        - $ref: '#/components/parameters/destinationCop'
        - $ref: '#/components/parameters/fromToken'
        - $ref: '#/components/parameters/userAddressQuery'
      responses:
        '200':
          description: Quote
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BrebQuote'
              example:
                quoteId: q_11111111-1111-1111-1111-111111111111
                fromToken: USDC
                destinationCop: '10000'
                effectiveUsdCop: '3902'
                display: 1 USD = 3902 COP
                sourceAmount: '2563065'
                sourceAmountUsd: '2.563065'
                netUsdcToBridge: '2.537688'
                sellRate: '4000'
                swapProvider: none
                cached: false
                expiresAt: '2026-09-18T22:00:00.000Z'
                fees:
                  - code: bridge_fx
                    amountUsd: '0.03'
                    to: null
                    status: quoted
                  - code: bridge
                    amountUsd: '0.01'
                    to: null
                    status: quoted
                  - code: copby
                    amountUsd: '0.03'
                    to: '0x1111111111111111111111111111111111111111'
                    status: quoted
        '400':
          $ref: '#/components/responses/BrebError'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  parameters:
    destinationCop:
      name: destinationCop
      in: query
      schema:
        type: string
        example: '10000'
      description: Integer COP to deliver. Optional; omitted returns rate only.
    fromToken:
      name: fromToken
      in: query
      schema:
        type: string
        enum:
          - USDC
          - COPm
        default: USDC
    userAddressQuery:
      name: userAddress
      in: query
      schema:
        $ref: '#/components/schemas/Address'
      description: Used when quoting COPm so the swap route can be built
  schemas:
    BrebQuote:
      type: object
      properties:
        quoteId:
          type: string
        fromToken:
          type: string
          enum:
            - USDC
            - COPm
        destinationCop:
          type:
            - string
            - 'null'
        effectiveUsdCop:
          type: string
        display:
          type: string
          example: 1 USD = 3902 COP
        sourceAmount:
          type:
            - string
            - 'null'
          description: Atomic units of fromToken
        sourceAmountUsd:
          type:
            - string
            - 'null'
        netUsdcToBridge:
          type:
            - string
            - 'null'
        sellRate:
          type: string
        swapProvider:
          type:
            - string
            - 'null'
          enum:
            - none
            - squid
            - uniswap_v3
            - mock
            - null
        cached:
          type: boolean
        expiresAt:
          type: string
          format: date-time
        fees:
          type: array
          items:
            $ref: '#/components/schemas/FeeLeg'
    Address:
      type: string
      pattern: ^0x[a-fA-F0-9]{40}$
      example: '0x2222222222222222222222222222222222222222'
    FeeLeg:
      type: object
      properties:
        code:
          type: string
          enum:
            - swap
            - bridge_fx
            - bridge
            - copby
        amountUsd:
          type: string
        to:
          type:
            - string
            - 'null'
        status:
          type: string
          enum:
            - quoted
            - verified
            - pending
    ErrorBody:
      type: object
      properties:
        error:
          type: string
        errorCode:
          type: string
          enum:
            - below_minimum
            - needs_kyc
            - destination_mismatch
            - requote
            - tx_hash_reused
            - otp_invalid
            - mercado_cerrado
            - invalid_webhook_signature
  responses:
    BrebError:
      description: API error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorBody'
    Unauthorized:
      description: Missing or invalid integration API key
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Integration API key. Send as `Bearer copby_live_pk_…`.

````