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

# Payer un lien



## OpenAPI

````yaml POST /pay/{shortCode}/pay
openapi: 3.1.0
info:
  title: Mysoleas API
  version: 3.0.0
  description: >-
    Nouvelle architecture Mysoleas: gateway de paiement et authentification
    OAuth 2.0.
servers:
  - url: https://api.mysoleas.com
    description: Gateway Mysoleas
  - url: https://account.mysoleas.com
    description: Authentification Mysoleas
security:
  - bearerAuth: []
tags:
  - name: Auth
  - name: Plugin
  - name: Payment links
  - name: Subscriptions
  - name: Collections
  - name: Disbursements
  - name: Catalog
paths:
  /pay/{shortCode}/pay:
    post:
      tags:
        - Payment links
      summary: Payer un lien de paiement
      parameters:
        - $ref: '#/components/parameters/ShortCode'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PaymentLinkPayRequest'
      responses:
        '200':
          $ref: '#/components/responses/TransactionSuccess'
        '400':
          $ref: '#/components/responses/BadRequest'
      security: []
components:
  parameters:
    ShortCode:
      name: shortCode
      in: path
      required: true
      schema:
        type: string
        pattern: ^[A-Za-z0-9]{8,12}$
  schemas:
    PaymentLinkPayRequest:
      type: object
      required:
        - customer_phone
        - transaction_uuid
      properties:
        customer_phone:
          type: string
          example: '237670000000'
        customer_name:
          type: string
        customer_email:
          type: string
          format: email
        transaction_uuid:
          type: string
          format: uuid
        amount:
          type: integer
        provider:
          type: string
        channel:
          type: string
          enum:
            - PROVIDER
            - WALLET
            - AUTO
        otp:
          type: integer
        metadata:
          type: object
          additionalProperties: true
    TransactionApiResponse:
      allOf:
        - $ref: '#/components/schemas/ApiResponseBase'
        - type: object
          properties:
            data:
              $ref: '#/components/schemas/Transaction'
    ErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: false
        code:
          type: integer
          example: 400
        message:
          type: string
          example: empty_data
        error:
          type: object
          properties:
            details:
              type:
                - object
                - array
                - string
                - 'null'
    ApiResponseBase:
      type: object
      properties:
        code:
          type: integer
          example: 200
        success:
          type: boolean
          example: true
        locale:
          type: string
          example: fr
        message:
          type: string
        meta:
          type: object
          additionalProperties: true
    Transaction:
      type: object
      properties:
        transaction_reference:
          type: string
        environment:
          type: string
          example: prod
        invoice_reference:
          type: string
        provider_reference:
          type: string
        status:
          $ref: '#/components/schemas/TransactionStatus'
        operation:
          type: string
          enum:
            - COLLECTION
            - DISBURSEMENT
        channel:
          type: string
          enum:
            - PROVIDER
            - WALLET
        amount:
          type: integer
        currency:
          type: string
        confirmation_method:
          type: string
          enum:
            - MSISDN
            - LINK
            - QRCODE
            - null
        confirmation_url:
          type:
            - string
            - 'null'
        fee:
          type: integer
        required_total:
          type: integer
        settlement_mode:
          type: string
          enum:
            - DIRECT
            - SPLIT
        split_reference:
          type: string
        split_status:
          type: string
          enum:
            - NONE
            - PENDING
            - PROCESSING
            - SUCCESS
            - PARTIAL_SUCCESS
            - FAILED
        created_at:
          type: string
        updated_at:
          type: string
    TransactionStatus:
      type: string
      enum:
        - INITIATED
        - PENDING
        - SUBMITTED
        - PROCESSING
        - SUCCESS
        - COMPLETED
        - FAILED
        - CANCELLED
        - REFUNDED
  responses:
    TransactionSuccess:
      description: Transaction retournee
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/TransactionApiResponse'
    BadRequest:
      description: Requete invalide
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````