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

# Simulate crypto payout

> Simulate an cryptocurrency payout to calculate fees and exchange rates.



## OpenAPI

````yaml post /api/v1/account/users/{uid}/accounts/{aid}/crypto-payouts/simulate
openapi: 3.0.1
info:
  title: RALIO API
  description: Banking as a service API.
  contact:
    name: Tropipay Support
    url: https://help.tropipay.com/contacto/
    email: support@tropipay.com
  version: '1.0'
servers:
  - url: https://sandbox-revo-api.raliopay.com/
security: []
paths:
  /api/v1/account/users/{uid}/accounts/{aid}/crypto-payouts/simulate:
    post:
      tags:
        - payouts
      summary: Simulate crypto payout
      description: Simulate an cryptocurrency payout to calculate fees and exchange rates.
      parameters:
        - name: uid
          in: path
          description: User ID
          required: true
          schema:
            type: string
        - name: aid
          in: path
          description: Account ID
          required: true
          schema:
            type: string
      requestBody:
        description: Payout details
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/dto.SimulateCryptoPayoutRequest'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/dto.SimulatePayoutResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/httperror.ErrResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/httperror.ErrResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/httperror.ErrResponse'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    dto.SimulateCryptoPayoutRequest:
      required:
        - amounts
        - recipient
      type: object
      properties:
        amounts:
          $ref: '#/components/schemas/dto.CryptoPayoutAmounts'
        recipient:
          $ref: '#/components/schemas/dto.SimulateCryptoPayoutRecipient'
    dto.SimulatePayoutResponse:
      type: object
      properties:
        destination:
          $ref: '#/components/schemas/domain.Money'
        fee:
          $ref: '#/components/schemas/dto.FeeResponse'
        origin:
          $ref: '#/components/schemas/domain.Money'
        quote:
          $ref: '#/components/schemas/dto.FXQuote'
        quoteId:
          type: string
          example: q1a2b3c4-d5e6-4f7a-8b9c-0d1e2f3a4b5c
    httperror.ErrResponse:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/httperror.ErrorData'
    dto.CryptoPayoutAmounts:
      required:
        - debitedAmount
        - receivedAmount
      type: object
      properties:
        debitedAmount:
          $ref: '#/components/schemas/domain.Money'
        receivedAmount:
          $ref: '#/components/schemas/domain.Money'
    dto.SimulateCryptoPayoutRecipient:
      required:
        - network
      type: object
      properties:
        network:
          type: string
          example: SOLANA
    domain.Money:
      required:
        - currency
      type: object
      properties:
        amount:
          type: integer
          description: 'Amount in cents. Ex: 12345 = 123.45€'
          example: 1000
        currency:
          type: string
          description: USD, EUR, etc.
          example: CURRENCY
          enum:
            - EUR
            - USD
            - MXN
            - CAD
            - BRL
            - COP
            - PEN
            - BOB
            - CLP
            - ARS
            - UYU
            - PYG
            - CNY
            - HKD
            - MYR
            - USDT
            - USDC
            - EURC
            - BTC
            - ETH
    dto.FeeResponse:
      type: object
      properties:
        amount:
          type: integer
          example: 100
        breakdown:
          $ref: '#/components/schemas/dto.FeeBreakdown'
        currency:
          type: string
          example: EUR
    dto.FXQuote:
      type: object
      properties:
        rate:
          type: number
          example: 1.08
        timestamp:
          type: string
          example: '2025-01-15T10:30:00.000Z'
        validUntil:
          type: string
          example: '2025-01-15T10:30:30.000Z'
    httperror.ErrorData:
      type: object
      properties:
        code:
          $ref: '#/components/schemas/httperror.ErrorCode'
        details:
          type: array
          items:
            $ref: '#/components/schemas/httperror.ErrorDetails'
        message:
          type: string
        type:
          $ref: '#/components/schemas/httperror.ErrorType'
    dto.FeeBreakdown:
      type: object
      properties:
        merchantFee:
          type: integer
          example: 40
        systemFee:
          type: integer
          example: 60
    httperror.ErrorCode:
      type: string
      enum:
        - INVALID_REQUEST
        - UNAUTHORIZED
        - FORBIDDEN
        - NOT_FOUND
        - INTERNAL_SERVER_ERROR
        - UNKNOWN_ERROR
        - NOT_IMPLEMENTED
        - TOO_MANY_REQUESTS
        - QUOTE_EXPIRED
      x-enum-varnames:
        - InvalidRequestCode
        - UnauthorizedCode
        - ForbiddenCode
        - NotFoundCode
        - InternalServerCode
        - UnknownErrorCode
        - NotImplementedCode
        - TooManyRequestsCode
        - QuoteExpiredCode
    httperror.ErrorDetails:
      type: object
      properties:
        field:
          type: string
        message:
          type: string
    httperror.ErrorType:
      type: string
      enum:
        - VALIDATION_ERROR
        - CONFLICT_ERROR
        - UNPROCESSABLE_ERROR
        - AUTHENTICATION_ERROR
        - AUTHORIZATION_ERROR
        - NOT_FOUND_ERROR
        - INTERNAL_ERROR
        - NOT_IMPLEMENTED_ERROR
        - UNKNOWN_ERROR
        - RATE_LIMIT_ERROR
      x-enum-varnames:
        - ValidationError
        - ConflictError
        - UnprocessableError
        - AuthenticationError
        - AuthorizationError
        - NotFoundError
        - InternalError
        - NotImplementedError
        - UnknownError
        - RateLimitError
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: API Key for accessing management endpoints
      x-mint-auth-type: bearer

````