openapi: 3.0.1
info:
  title: Payall M2M Authentication API
  version: '2.0'
  description: |
    This is Payall's public API for Machine to Machine communication.
  contact:
    name: Payall Payment Systems Inc.
    url: https://payall.com
tags:
  - name: Authorization
    x-displayName: Authorization
  - name: Discovery
    x-displayName: Discovery
  - name: Payments
    x-displayName: Payments
  - name: Payments instruments
    x-displayName: Payments instruments
  - name: Exchange
    x-displayName: Exchange
  - name: Accounts
    x-displayName: Accounts
  - name: Recipients
    x-displayName: Recipients
  - name: Payers
    x-displayName: Payers
  - name: Compliance
    x-displayName: Compliance
  - name: Events
    x-displayName: Events
  - name: Exchange rates
    x-displayName: Exchange rates
  - name: Tokenization
    x-displayName: Tokenization
paths:
  /v2/oauth/token:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Authorization
      summary: Get an access token
      description: |
        This endpoint is used to get an access token.
      operationId: getAccessToken
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  access_token:
                    type: string
                  token_type:
                    type: string
                    example: Bearer
                  expires_in:
                    type: integer
                    example: 300
                    description: The lifetime in seconds of the access token
        '400':
          description: Bad request
        '401':
          description: Unauthorized
      security:
        - basicAuth: []
  /v2/discovery/fields:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Discovery
      summary: Get required payment fields
      description: >
        Provides information about the fields required to make a payment

        based on supplied parameters. Different payment channels will yield

        various results based on payment processors and compliance requirements.


        Data provided by this endpoint can be used to build UI for customers

        to provide relevant payment data or to just collect it from internal

        system to execute the payment swiftly by avoiding holdups due to

        missing data.


        Please note that response from this endpoint will not include base
        fields

        required by Recipient entities (like first or last name of a person).


        Sample response for B2P payment of 100 PLN to Poland from EUR account:

        ```

        {
            "dob": {
              "title": "Date of birth",
              "data_type": "DATE",
            },
            "registration_address": {
              "city": {
                "mask": "^[a-zA-Z\/\\\\-:().,='+0-9\\\\s]{1,35}$",
                "title": "City",
                "data_type": "STRING",
                "max_length": 255,
                "min_length": 1,
              },
              "street": {
                "mask": "^[a-zA-Z\/\\-:().,='+0-9\\s]{1,35}$",
                "title": "Street name",
                "data_type": "STRING",
                "max_length": 255,
                "min_length": 1,
              },
              "country": {
                "title": "Country of residence",
                "data_type": "COUNTRY",
              }
            }
        }

        ```


        Sample response for B2B payment of 100 PLN to Poland from EUR account:

        ```

        {
            "registration_address": {
              "city": {
                "mask": "^[a-zA-Z\/\\\\-:().,='+0-9\\\\s]{1,35}$",
                "title": "City",
                "data_type": "STRING",
                "max_length": 255,
                "min_length": 1,
              },
              "street": {
                "mask": "^[a-zA-Z\/\\-:().,='+0-9\\s]{1,35}$",
                "title": "Street name",
                "data_type": "STRING",
                "max_length": 255,
                "min_length": 1,
              },
              "country": {
                "title": "Country of residence",
                "data_type": "COUNTRY",
              }
            }
        }

        ```
      parameters:
        - name: recipient_country
          in: query
          required: true
          schema:
            type: string
            format: iso-3166-alpha-2
            example: IT
        - name: payment_type
          in: query
          required: true
          schema:
            type: string
            enum:
              - B2P
              - B2B
              - P2B
              - P2P
        - name: payer_currency
          in: query
          required: true
          schema:
            type: string
            format: iso-4217
            maxLength: 3
            minLength: 3
            example: USD
        - name: instrument_category
          in: query
          required: true
          schema:
            type: string
            enum:
              - BankAccount
              - MobileWallet
              - CashPickup
              - Card
        - name: amount
          in: query
          required: true
          schema:
            type: integer
            example: 100023
            description: |
              Amounts are always in the smallest currency unit.
              Example: 1000.23 USD is represented as 100023 cents.
        - name: recipient_currency
          in: query
          required: true
          schema:
            type: string
            format: iso-4217
            maxLength: 3
            minLength: 3
            example: EUR
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RequiredFieldsResponse'
              example:
                recipient:
                  type: Person
                  registration_address:
                    city:
                      title: i18n.city
                      description: null
                      mask: ^[\p{L}/:().,='+0-9\s-]{1,35}$
                      required: true
                      data_type: STRING
                      min_length: 1
                      max_length: 255
                      data_values: null
                      placeholder: null
                    street:
                      title: i18n.streetAddress
                      description: null
                      mask: ^[\p{L}\/:()#.,='+0-9\s-]{1,100}$
                      required: true
                      data_type: STRING
                      min_length: 1
                      max_length: 255
                      data_values: null
                      placeholder: null
                    country:
                      title: i18n.countryOfResidence
                      description: null
                      mask: null
                      required: true
                      data_type: COUNTRY
                      min_length: null
                      max_length: null
                      data_values: null
                      placeholder: null
                    postal_code:
                      title: i18n.postalCode
                      description: null
                      mask: null
                      required: false
                      data_type: STRING
                      min_length: 1
                      max_length: 255
                      data_values: null
                      placeholder: null
                    unit_number:
                      title: i18n.unitNumber
                      description: null
                      mask: ^([a-zA-Z0-9\s\-.])*$
                      required: false
                      data_type: STRING
                      min_length: 1
                      max_length: 20
                      data_values: null
                      placeholder: null
                    building_name:
                      title: i18n.buildingName
                      description: null
                      mask: null
                      required: false
                      data_type: STRING
                      min_length: 1
                      max_length: 255
                      data_values: null
                      placeholder: null
                    state_province:
                      title: i18n.stateOrProvince
                      description: null
                      mask: null
                      required: false
                      data_type: STRING
                      min_length: 2
                      max_length: 255
                      data_values: null
                      placeholder: null
                    building_number:
                      title: i18n.buildingNumber
                      description: null
                      mask: ^([a-zA-Z0-9\s\-.])*$
                      required: false
                      data_type: STRING
                      min_length: 1
                      max_length: 20
                      data_values: null
                      placeholder: null
                payment_instrument:
                  category: BankAccount
                  iban:
                    title: i18n.iban
                    description: i18n.internationalBankAccountNumber
                    mask: ^IT[0-9]{2}[A-Z][0-9]{10}[a-zA-Z0-9]{12}
                    required: true
                    data_type: IBAN
                    min_length: null
                    max_length: null
                    data_values: null
                    placeholder: null
                kyt:
                  payment_purpose:
                    title: i18n.purposeOfPayment
                    description: i18n.purposeOfPayment
                    mask: null
                    required: true
                    data_type: SELECT
                    min_length: null
                    max_length: null
                    data_values:
                      - key: business_investment
                        value: Business/Investment
                      - key: salary
                        value: Salary
                      - key: payment_of_goods_and_services
                        value: Payment of goods and services
                      - key: employee_colleague
                        value: Employee Colleague
                      - key: savings
                        value: Savings
                      - key: education
                        value: Education
                      - key: payment_of_bills
                        value: Payment of bills
                      - key: wedding_expenses
                        value: Wedding Expenses
                      - key: medical_expenses
                        value: Medical Expenses
                      - key: funeral_expenses
                        value: Funeral Expenses
                      - key: purchase_of_property
                        value: Purchase of Property
                      - key: payment_of_loan
                        value: Payment of Loan
                      - key: household_maintenance
                        value: Household Maintenance
                      - key: family_maintenance
                        value: Family Maintenance
                    placeholder: null
                example:
                  recipient:
                    type: Person
                    first_name: John
                    last_name: Doe
                    middle_name: James
                    mobile_number: '373261912905'
                    email: user@mailinator.com
                    registration_address:
                      city: ''
                      street: ''
                      country: ''
                      postal_code: ''
                      unit_number: ''
                      building_name: ''
                      state_province: ''
                      building_number: ''
                  payment_instrument:
                    category: BankAccount
                    currency: ''
                    iban: ''
                  kyt:
                    payment_purpose: ''
      security:
        - OAuth2: []
  /v2/single-payment:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Payments
      summary: Initiate a single payment
      description: |
        Use this method to initiate a single Payment.
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/PaymentRequest'
                - $ref: '#/components/schemas/LegacyPaymentRequest'
        required: true
      responses:
        '201':
          description: |
            Created

            Returns new payment details.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentResponse'
        '400':
          description: |
            BAD REQUEST

            This response will be sent if request is invalid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '409':
          description: >
            CONFLICT


            This response will be sent if conflicting fields have been
            submitted.

            Please refer to `PaymentRequest` schema for more information about

            potential conflicts.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - OAuth2: []
  /v2/payments/{id}:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payments
      summary: Get payment information by its ID
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentResponse'
        '404':
          description: Payment not found
      security:
        - OAuth2: []
    patch:
      tags:
        - Payments
      summary: Update payment details
      description: >
        Update Payment after it has been stopped due to insufficient KYC/B/T
        information.

        This call allows updating only KY related information. If additional
        recipient

        information is required please use `PATCH Recipient` operation.


        This operation is allowed only for transactions in KYT pending status.
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                supporting_documents:
                  description: |
                    Documents that will be considered as proof for the payment.

                    This field may be required depending on your KYT settings.
                    Consult the discovery endpoint for more information.

                    This field can be updated only for payments with pending KYT
                    for which a request for additional documents was issued.
                  type: array
                  items:
                    $ref: '#/components/schemas/SupportingDocument'
                exchange_rate_id:
                  description: >
                    New exchange rate ID in case previous one expired.

                    New exchange rate must use the same parameters as original
                    one.

                    Use `/v2/exchange-rates/{id}/refresh` endpoint to obtain new
                    exchange rate.


                    This field can be updated only for payments with expired
                    exchange rate.
                  type: string
                  format: uuid
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentResponse'
        '404':
          description: |
            Payment not found
        '405':
          description: >
            Not allowed


            This response will be sent if request was made for transaction

            that does not allow PATCH operations (for instance completed
            payments).
        '409':
          description: >
            Conflict


            This response will be sent if conflicting fields have been
            submitted.

            Please refer to the request schema for more information about

            potential conflicts.


            Only one of two fields can be sent at the same time:

            `exchange_rate_id` and `supporting_documents`.


            New `exchange_rate_id` must refer to the exchange rate that uses

            the same parameters as the original one.
      security:
        - OAuth2: []
  /v3/payment-instruments:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payments instruments
      summary: Get list of payment instruments
      parameters:
        - in: query
          name: recipient_id
          schema:
            type: string
            format: uuid
          required: false
          description: >
            ID of the recipient to get payment instruments belonging to this
            recipient.
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  pagination:
                    $ref: '#/components/schemas/Pagination'
                  accounts:
                    type: array
                    items:
                      oneOf:
                        - $ref: '#/components/schemas/MobileWallet'
                        - $ref: '#/components/schemas/BankAccount'
                        - $ref: '#/components/schemas/CashPickup'
                        - $ref: '#/components/schemas/Card'
        '404':
          description: |
            Payment instrument is missing
      security:
        - OAuth2: []
  /v2/payment-instruments:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payments instruments
      summary: Get list of payment instruments
      parameters:
        - in: query
          name: recipient_id
          schema:
            type: string
            format: uuid
          required: false
          description: >
            ID of the recipient to get payment instruments belonging to this
            recipient.
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
      responses:
        '200':
          description: OK
          headers:
            X-Pagination-Total-Pages:
              $ref: '#/components/headers/X-Pagination-Total-Pages'
            X-Pagination-Page-Size:
              $ref: '#/components/headers/X-Pagination-Page-Size'
            X-Pagination-Total-Elements:
              $ref: '#/components/headers/X-Pagination-Total-Elements'
            X-Pagination-Page-Number:
              $ref: '#/components/headers/X-Pagination-Page-Number'
            X-Pagination-Offset:
              $ref: '#/components/headers/X-Pagination-Offset'
          content:
            application/json:
              schema:
                type: array
                items:
                  oneOf:
                    - $ref: '#/components/schemas/MobileWallet'
                    - $ref: '#/components/schemas/BankAccount'
                    - $ref: '#/components/schemas/CashPickup'
                    - $ref: '#/components/schemas/Card'
        '404':
          description: |
            Payment instrument is missing
      security:
        - OAuth2: []
    post:
      tags:
        - Payments instruments
      summary: Create a payment instrument
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/MobileWalletCreate'
                - $ref: '#/components/schemas/BankAccountCreate'
                - $ref: '#/components/schemas/CashPickupCreate'
                - $ref: '#/components/schemas/CardCreate'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    description: ID of the newly created payment instrument.
                    type: string
                    format: uuid
        '303':
          description: Identical payment instrument already exists. See the returned ID.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    description: ID of the existing payment instrument.
                    type: string
                    format: uuid
      security:
        - OAuth2: []
  /v2/payment-instruments/{id}:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payments instruments
      summary: Get payment instrument by its ID
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/MobileWallet'
                  - $ref: '#/components/schemas/BankAccount'
                  - $ref: '#/components/schemas/CashPickup'
                  - $ref: '#/components/schemas/Card'
        '404':
          description: Payment instrument not found
      security:
        - OAuth2: []
  /v2/exchange-rates/{id}:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Exchange
      summary: Get exchange rate information by its ID
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExchangeRateInstance'
      security:
        - OAuth2: []
  /v2/exchange-rates/{id}/refresh:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Exchange
      summary: Get new exchange rate based on already existing rate.
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '201':
          description: |
            Created

            Returns new exchange rate.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExchangeRateInstance'
        '404':
          description: |
            Not found

            This response will be sent if exchange rate with provided ID
            does not exist.
        '405':
          description: |
            Not allowed
            This response will be sent if existing rate is not expired.
        '409':
          description: |
            Conflict

            This response will be sent if the exchange rate between currency
            pairs is no longer available.
        '429':
          description: |
            Too many requests

            There is a limit of 10 requests per minute for this endpoint.
      security:
        - OAuth2: []
  /v2/exchange-rates:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Exchange
      summary: Request exchange rate information.
      description: |
        The exchange rate can be later used to initiate a new payment.
        Obtaining the exchange rate before payment is optional.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ExchangeRateRequest'
        required: true
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExchangeRateInstance'
        '409':
          description: |
            Conflict

            This response is returned in following scenarios:
              1. If both source and target currencies are the same and there is no need for exchange.
              2. If `source_account_id` is provided together with `source_amount` but `source_amount` currency
                 is different than the one of the source account - this is because source account
                 already has associated currency.
              3. If both `source_account_id` and `source_currency` are provided - this is because
                 source account already has associated currency.
              4. If both `source_currency` and `source_amount` are provided - this is because
                 the currency is already part of the source amount.
              5. If both `recipient_instrument_id` and either `payment_instrument_category`
                 are provided - this is because instrument category id already a part of existing payment instrument.
              6. If both `source_account_id` and `recipient_instrument_id` are provided and
                 `payment_type` is present - this is because payment type is already defined by payer and recipient.
      security:
        - OAuth2: []
  /v2/exchange-rates/confirm:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Exchange
      summary: Confirm exchange rate
      description: |
        Confirm the exchange rate to lock it for future use.
        This operation is required if you want to use the exchange rate
        for a payment after exchange rate quote expires. This is valid
        only for quoted rates program configurations.

        **This operation will block funds on the source account.**
        The funds will be release automatically if the payment is not initiated
        within the timeframe configured for your program.

        If needed you can cancel the quote to unblock funds earlier.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                exchange_rate_id:
                  description: ID of the exchange rate to confirm.
                  type: string
                  format: uuid
        required: true
      responses:
        '200':
          description: OK
        '404':
          description: |
            Not found

            This response will be sent if exchange rate with provided ID
            does not exist.
        '405':
          description: |
            Not allowed

            This response will be sent if exchange rate is already confirmed
            or if the configuration of your program does not offer this feature.
      security:
        - OAuth2: []
  /v2/exchange-rates/cancel:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Exchange
      summary: Cancel exchange rate
      description: >
        Cancel the exchange rate to unblock funds on the source account.

        This operation is allowed only for exchange rates that have been
        confirmed.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                exchange_rate_id:
                  description: ID of the exchange rate to cancel.
                  type: string
                  format: uuid
        required: true
      responses:
        '200':
          description: OK
        '404':
          description: |
            Not found

            This response will be sent if exchange rate with provided ID
            does not exist.
        '405':
          description: |
            Not allowed

            This response will be sent in the following cases:
              1. If exchange rate has not been confirmed.
              2. If the exchange rate already expired.
              3. If the configuration of your program does not offer this feature.
      security:
        - OAuth2: []
  /v2/carded-rates:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      operationId: getCardedRates
      tags:
        - Exchange
      summary: Get carded exchange rates
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CardedRates'
      security:
        - OAuth2: []
  /v2/accounts:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Accounts
      summary: Get list of payment accounts
      parameters:
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
      responses:
        '200':
          description: OK
          headers:
            X-Pagination-Total-Pages:
              $ref: '#/components/headers/X-Pagination-Total-Pages'
            X-Pagination-Page-Size:
              $ref: '#/components/headers/X-Pagination-Page-Size'
            X-Pagination-Total-Elements:
              $ref: '#/components/headers/X-Pagination-Total-Elements'
            X-Pagination-Page-Number:
              $ref: '#/components/headers/X-Pagination-Page-Number'
            X-Pagination-Offset:
              $ref: '#/components/headers/X-Pagination-Offset'
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AccountDetails'
      security:
        - OAuth2: []
  /v3/accounts:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Accounts
      summary: Get list of payment accounts
      parameters:
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  pagination:
                    $ref: '#/components/schemas/Pagination'
                  accounts:
                    type: array
                    items:
                      $ref: '#/components/schemas/AccountDetails'
      security:
        - OAuth2: []
  /v3/recipients:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Recipients
      summary: Get list of recipients
      parameters:
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
        - in: query
          name: id
          schema:
            type: string
            format: uuid
          required: false
          description: |
            ID of the recipient to get.
        - in: query
          name: external_id
          schema:
            type: string
          required: false
          description: |
            External ID of the recipient to get.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  pagination:
                    $ref: '#/components/schemas/Pagination'
                  recipients:
                    type: array
                    items:
                      oneOf:
                        - $ref: '#/components/schemas/Person'
                        - $ref: '#/components/schemas/Business'
      security:
        - OAuth2: []
  /v2/recipients:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Recipients
      summary: Get list of recipients
      parameters:
        - in: query
          name: page_number
          schema:
            type: integer
            minimum: 1
            default: 1
          required: false
          description: |
            Page number.
        - in: query
          name: page_size
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 20
          required: false
          description: |
            Page size.
        - in: query
          name: id
          schema:
            type: string
            format: uuid
          required: false
          description: |
            ID of the recipient to get.
        - in: query
          name: external_id
          schema:
            type: string
          required: false
          description: |
            External ID of the recipient to get.
      responses:
        '200':
          description: OK
          headers:
            X-Pagination-Total-Pages:
              $ref: '#/components/headers/X-Pagination-Total-Pages'
            X-Pagination-Page-Size:
              $ref: '#/components/headers/X-Pagination-Page-Size'
            X-Pagination-Total-Elements:
              $ref: '#/components/headers/X-Pagination-Total-Elements'
            X-Pagination-Page-Number:
              $ref: '#/components/headers/X-Pagination-Page-Number'
            X-Pagination-Offset:
              $ref: '#/components/headers/X-Pagination-Offset'
          content:
            application/json:
              schema:
                type: array
                items:
                  oneOf:
                    - $ref: '#/components/schemas/Person'
                    - $ref: '#/components/schemas/Business'
      security:
        - OAuth2: []
    post:
      tags:
        - Recipients
      summary: Create a recipient
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/Person'
                - $ref: '#/components/schemas/Business'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    description: ID of the newly created recipient.
                    type: string
                    format: uuid
        '303':
          description: Identical recipient already exists. See the returned ID.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    description: ID of the existing recipient.
                    type: string
                    format: uuid
      security:
        - OAuth2: []
  /v2/recipients/{id}:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Recipients
      summary: Get recipient information by its ID
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Recipient found
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/Person'
                  - $ref: '#/components/schemas/Business'
        '404':
          description: |
            Not found

            This response will be sent if recipient with provided ID
            does not exist.
      security:
        - OAuth2: []
    patch:
      tags:
        - Recipients
      summary: Update a recipient
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/PersonUpdate'
                - $ref: '#/components/schemas/BusinessUpdate'
      responses:
        '200':
          description: Updated
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/Person'
                  - $ref: '#/components/schemas/Business'
      security:
        - OAuth2: []
    delete:
      tags:
        - Recipients
      summary: Delete a recipient
      description: |
        This operation is allowed only for recipients without payments
        (past, pending, scheduled or recurring)
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '204':
          description: Deleted
        '403':
          description: |
            Forbidden

            Deleting of this recipient is not allowed at the moment.
      security:
        - OAuth2: []
  /v2/recipients/{id}/limits:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Recipients
      summary: Get recipient amount limits
      description: This operation fetches amount limits for recipient.
      operationId: recipientLimits
      parameters:
        - name: id
          in: path
          description: The ID of the recipient for which to provide payment limits
          required: true
          schema:
            type: string
            format: uuid
        - name: payment_type
          in: query
          required: true
          schema:
            $ref: '#/components/schemas/PaymentType'
        - name: country
          in: query
          required: true
          description: |
            Country for the payment. ISO-3166-1 alpha-2 value.
            Hint: It is `GB`, not `UK`.
          schema:
            type: string
            format: iso-3166-alpha-2
            example: GB
        - name: instrument_category
          in: query
          required: true
          schema:
            $ref: '#/components/schemas/PaymentInstrumentCategory'
        - name: currency
          in: query
          required: true
          description: >
            The currency for which the limit should be provided. 

            If there is no limit set in specified currency then limit will be
            returned in the base currency set for this account. 

            Currency format ISO-4217
          schema:
            type: string
            format: iso-4217
            maxLength: 3
            minLength: 3
            example: EUR
      responses:
        '200':
          description: Recipient amount limits
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LimitsResponse'
        '404':
          description: Not found - recipient could not be found
      security:
        - OAuth2: []
  /v2/payers:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Payers
      summary: Create a payer
      description: |
        Payer accounts will be created automatically however
        depending on configurations of your account,
        the payer may first be subject to KYC or KYB checks.
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/PersonPayer'
                - $ref: '#/components/schemas/BusinessPayer'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
        '303':
          description: Identical payer already exists. See the returned ID.
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
      security:
        - OAuth2: []
  /v2/payers/{id}:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payers
      summary: Get payer by its ID
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
      security:
        - OAuth2: []
    patch:
      tags:
        - Payers
      summary: Update a payer
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/PersonPayer'
                - $ref: '#/components/schemas/BusinessPayer'
      responses:
        '200':
          description: Updated
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
        '303':
          description: Payer already exists
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
      security:
        - OAuth2: []
  /v2/payers/{id}/limits:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payers
      summary: Get payer amount limits
      description: This operation fetches amount limits for payer.
      operationId: payerLimits
      parameters:
        - name: id
          in: path
          description: The ID of the payer for which to provide payment limits
          required: true
          schema:
            type: string
            format: uuid
        - name: payment_type
          in: query
          required: true
          schema:
            $ref: '#/components/schemas/PaymentType'
        - name: country
          in: query
          required: true
          description: |
            Country for the payment. ISO-3166-1 alpha-2 value.
            Hint: It is `GB`, not `UK`.
          schema:
            type: string
            format: iso-3166-alpha-2
            example: GB
        - name: instrument_category
          in: query
          required: true
          schema:
            $ref: '#/components/schemas/PaymentInstrumentCategory'
        - name: currency
          in: query
          required: true
          description: >
            The currency for which the limit should be provided. 

            If there is no limit set in specified currency then limit will be
            returned in the base currency set for this account. 

            Currency format ISO-4217
          schema:
            type: string
            format: iso-4217
            maxLength: 3
            minLength: 3
            example: EUR
      responses:
        '200':
          description: Payer amount limits
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LimitsResponse'
        '404':
          description: Not found - payer could not be found
      security:
        - OAuth2: []
  /v3/payers:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    get:
      tags:
        - Payers
      summary: Get payer by its ID or external ID
      description: |
        This endpoint allows to retrieve payer by its ID or external ID.
        Either `id` or `external_id` must be provided.
        If both are provided then they both must match the same payer.
      parameters:
        - name: id
          in: query
          required: false
          schema:
            type: string
            format: uuid
            description: |
              ID of the payer to get.
        - name: external_id
          in: query
          required: false
          schema:
            type: string
            description: |
              External ID of the payer to get.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/PersonPayer'
                  - $ref: '#/components/schemas/BusinessPayer'
        '404':
          description: Not found - payer could not be found
      security:
        - OAuth2: []
  /v2/documents:
    servers:
      - url: https://api.sandbox.payall.com
        description: Sandbox environment
      - url: https://api.stage.payall.com
        description: Staging environment
      - url: https://api.payall.com
        description: Production environment
      - url: https://api-mtls.sandbox.payall.com
        description: Sandbox environment with mTLS
      - url: https://api-mtls.stage.payall.com
        description: Staging environment with mTLS
      - url: https://api-mtls.payall.com
        description: Production environment with mTLS
    post:
      tags:
        - Compliance
      summary: Upload new compliance document
      description: |
        Use this method to upload documents.

        Supported file types are: PDF, PNG, JPEG.
      requestBody:
        content:
          image/png:
            schema:
              type: string
              format: binary
          image/jpeg:
            schema:
              type: string
              format: binary
          application/pdf:
            schema:
              type: string
              format: binary
      responses:
        '201':
          description: |
            Created

            Returns new document ID.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                    description: >
                      New document ID. Use this ID to reference the document in
                      future.
        '413':
          description: |
            Payload Too Large

            The file size is too large.
            Max file size is 10MB.
      security:
        - OAuth2: []
  /v2/payall/payment/{event_type}/{tenant_id}:
    servers:
      - url: https://callbacks.example.com
        description: Example server - this is not a real server
    post:
      operationId: postPaymentEvent
      tags:
        - Events
      summary: Payment event
      description: >
        Post payment related events.


        Payall will retry to deliver the event for 24 hours

        until receiving HTTP response code `200`. After 24 hours 

        there will be no further attempts to deliver the event.

        Attempts are repeated as follows:
          * Every 10 seconds for first minute
          * Every minute for the following 9 minutes
          * Every 10 minutes for the following 50 minutes
          * Every hour for the following 23 hours

        Payall expects the response within 3 seconds.

        Lack of response within 3 seconds is considered to be failed delivery
        attempt.


        No response body is expected.
      parameters:
        - name: event_type
          in: path
          required: true
          schema:
            type: string
            enum:
              - StatusChange
              - Documents
        - name: tenant_id
          in: path
          required: true
          schema:
            type: string
        - name: X-Attempt-Number
          in: header
          required: true
          schema:
            type: integer
          description: Delivery attempt number. First attempt value is 1.
        - name: X-Signature
          in: header
          required: false
          schema:
            type: string
          description: |
            HMAC signature of the request body. Sent only when HMAC request
            signing is enabled for your webhook configuration.

            The value has the form `<scheme>=<hex-digest>`,
            for example `sha256=9f86d081884c7d659a2feaa0c55ad015...`, where:
              * `<scheme>` identifies the hash function used, one of:
                `md5`, `sha1`, `sha224`, `sha256`, `sha384`, `sha512`,
                `sha512-224`, `sha512-256`, `sha3-224`, `sha3-256`,
                `sha3-384`, `sha3-512`.
              * `<hex-digest>` is the lowercase hex HMAC computed over the
                exact UTF-8 bytes of the request body using the shared secret
                you configured.

            To verify, recompute the HMAC over the received raw body with your
            shared secret and compare using a constant-time comparison.

            The header name is `X-Signature` by default but can be changed in
            your webhook configuration.
        - name: X-Timestamp
          in: header
          required: false
          schema:
            type: integer
            format: int64
          description: |
            UTC Unix timestamp, in seconds, captured when the event was signed
            and sent. Sent only when HMAC request signing is enabled.

            Use it to reject stale or replayed deliveries, for example by
            discarding requests whose timestamp falls outside an acceptable
            clock-skew window.
        - name: X-Nonce
          in: header
          required: false
          schema:
            type: string
            format: uuid
          description: |
            Unique per-delivery identifier (UUID). Sent only when HMAC request
            signing is enabled.

            Use it together with `X-Timestamp` for replay protection: remember
            recently seen nonces and reject duplicates.
      requestBody:
        description: |
          The event payload. Its serialization format depends on the template
          type configured for your webhook:
            * `application/json` for the default and Mastercard templates.
            * `application/xml` for the ISO 20022 template, where payment status
              events are delivered as an ISO 20022 FIToFIPaymentStatusReport
              (`pacs.002.001.16`) document.
        content:
          application/json:
            schema:
              oneOf:
                - $ref: '#/components/schemas/StatusChangeEvent'
                - $ref: '#/components/schemas/DocumentsEvent'
                - $ref: '#/components/schemas/CreatedEvent'
          application/xml:
            schema:
              type: string
              description: |
                ISO 20022 FIToFIPaymentStatusReport (`pacs.002.001.16`) XML
                document. Sent for payment status events when the webhook is
                configured to use the ISO template type. The root element is
                `<Document>` in the
                `urn:iso:std:iso:20022:tech:xsd:pacs.002.001.16` namespace.
      responses:
        '200':
          description: OK
      security:
        - ApiKeyAuth: []
  /v2/payall/carded-rates/{event_type}/{tenant_id}:
    servers:
      - url: https://callbacks.example.com
        description: Example server - this is not a real server
    post:
      operationId: postCardedRates
      tags:
        - Exchange rates
      summary: Post carded exchange rates
      parameters:
        - name: event_type
          in: path
          description: Event type for the rates
          required: true
          schema:
            type: string
            enum:
              - Publish
        - name: tenant_id
          in: path
          description: Tenant identifier
          required: true
          schema:
            type: string
      requestBody:
        description: Currency exchange rates data
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CardedRates'
      responses:
        '200':
          description: |
            OK

            Accepted new exchange rates.
      security:
        - ApiKeyAuth: []
  /token/{clientId}:
    servers:
      - url: https://vault.sandbox.payall.com
        description: Sandbox environment
      - url: https://vault.payall.com
        description: Production environment
    post:
      tags:
        - Tokenization
      security: []
      summary: Tokenize card details
      description: >
        Tokenize provided card details.

        Returns a token that can be used to reference the card

        in other API methods.


        This endpoint is not idempotent.


        Card number needs to be stripped of any non-digit characters before
        encrypting.

        Expected pattern match is `^[1-9][0-9]{7,19}$`.


        We recommend validation of card number using Luhn algorithm before
        encrypting using Luhn algorithm.


        We don't do card brand validation during this call.

        Any brand will be accepted by the vault but the payment may fail

        if the token is used for a payment with a vendor that does not support
        given brand.
      operationId: token
      parameters:
        - name: clientId
          in: path
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CardDetails'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TokenMetadata'
        '400':
          description: Input data validation error. See error code and message for details.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VaultErrorResponse'
        '404':
          description: Invalid id supplied
  /configuration/{id}:
    servers:
      - url: https://vault.sandbox.payall.com
        description: Sandbox environment
      - url: https://vault.payall.com
        description: Production environment
    get:
      tags:
        - Tokenization
      security: []
      summary: Get configuration
      description: Get encryption key and parameters for a specific id
      operationId: getClientConfiguration
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Configuration'
        '404':
          description: Configuration not found
components:
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
    OAuth2:
      type: oauth2
      description: >
        This API uses OAuth 2 with the Client Credentials flow.

        [More
        info](https://auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow)
      flows:
        clientCredentials:
          tokenUrl: /v2/oauth/token
          scopes: {}
    ApiKeyAuth:
      description: >
        This is just a sample scheme. We recognise that the needs of our
        customers

        are unique and we offer variety of authentication options for Events
        API.
      type: apiKey
      in: header
      name: X-API-Key
  schemas:
    RequiredFieldsResponse:
      type: object
      properties:
        payer:
          type: object
          properties:
            registration_address:
              type: object
              additionalProperties:
                $ref: '#/components/schemas/Field'
          additionalProperties:
            $ref: '#/components/schemas/Field'
        recipient:
          type: object
          properties:
            type:
              $ref: '#/components/schemas/Type'
            registration_address:
              type: object
              additionalProperties:
                $ref: '#/components/schemas/Field'
          additionalProperties:
            $ref: '#/components/schemas/Field'
        payment_instrument:
          type: object
          properties:
            category:
              $ref: '#/components/schemas/PaymentInstrumentCategory'
          additionalProperties:
            $ref: '#/components/schemas/Field'
        kyt:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/Field'
        example:
          type: object
      additionalProperties:
        $ref: '#/components/schemas/Field'
    Field:
      properties:
        title:
          type: string
          description: Field title
        description:
          type: string
          nullable: true
          description: Describes field value
        mask:
          type: string
          nullable: true
          description: Regex pattern
        required:
          type: boolean
          description: True or False
        data_type:
          type: string
          description: |-
            Describes the expected data type for the field. One of:

              * `EMAIL` - Email address.
              * `STRING` - Free-form text string.
              * `COUNTRY` - ISO 3166-1 alpha-2 country code (e.g. US, GB, PL).
              * `PHONE_CODE` - International dialing code (e.g. +1, +44).
              * `PHONE` - Phone number (without dialing code).
              * `SELECT` - Value must be chosen from the list provided in `data_values` keys.
              * `CURRENCY` - ISO 4217 currency code for the recipient's bank account (e.g. EUR, USD). Allowed values are provided in `data_values`.
              * `IBAN` - International Bank Account Number.
              * `BIC` - Bank Identifier Code (8 or 11 characters).
              * `BOOLEAN` - Boolean value (`true` / `false`).
              * `DATE` - Date string (ISO 8601 format, e.g. YYYY-MM-DD).
              * `DATETIME` - DateTime string with offset in ISO 8601 format with timezone offset (e.g., YYYY-MM-DDTHH:mm:ss.sssZ or YYYY-MM-DDTHH:mm:ss+HH:MM).
              * `SWIFT_CODE` - SWIFT/BIC code used for international wire transfers.
              * `ROUTING_NUMBER` - US ABA routing transit number (9 digits).
              * `IFSC` - Indian Financial System Code (11 characters).
              * `SORT_CODE` - UK bank sort code (6 digits).
              * `BSB` - Australian Bank-State-Branch number (6 digits).
              * `CLABE` - Mexican standardized bank account number (18 digits).
        min_length:
          type: number
          nullable: true
          description: Minimum length number
        max_length:
          type: number
          nullable: true
          description: Maximum length number
        data_values:
          type: array
          nullable: true
          items:
            $ref: '#/components/schemas/DataValue'
        placeholder:
          type: string
          nullable: true
          description: Example placeholder
    DataValue:
      type: object
      properties:
        key:
          type: string
          description: Key name
        value:
          type: string
          description: Data value
    Type:
      type: string
      enum:
        - Person
        - Business
    PaymentInstrumentCategory:
      type: string
      enum:
        - BankAccount
        - MobileWallet
        - CashPickup
        - Card
    PaymentResponse:
      type: object
      required:
        - client_payment_id
        - id
        - status
        - initiated_at
        - updated_at
      properties:
        end_to_end_id:
          $ref: '#/components/schemas/EndToEndId'
        client_payment_id:
          description: External reference provided when initiating the payment.
          type: string
        transaction_id:
          type: string
          description: >-
            External reference provided when initiating the payment. (Same as
            `client_payment_id`)
        instruction_id:
          type: string
          description: Id of the instruction registered in Payall system.
        uetr:
          $ref: '#/components/schemas/UETR'
        integration_id:
          description: Identifier used in communication with the Clearing Institution.
          type: string
        id:
          description: Id of the newly initiated payment.
          type: string
          format: uuid
        initiated_at:
          description: |
            The date-time when the payment was initiated.
            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
          type: string
          format: date-time
        updated_at:
          description: |
            The date-time when the payment was updated last time.
            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z.
          type: string
          format: date-time
        status:
          type: string
        fees:
          $ref: '#/components/schemas/Fees'
        exchange_rate:
          $ref: '#/components/schemas/ExchangeRateInstance'
        recipient_id:
          description: >
            Id of the recipient used for this payment.


            If `recipient_id` was provided for the `PaymentRequest`

            then its value is returned unchanged. If new recipient information

            was provided then this field will contain the ID under which the new
            recipient

            information has been stored.
          type: string
          format: uuid
        payment_instrument_id:
          description: >
            Id of the payment instrument used for this payment.


            If `payment_instrument_id` was provided for the `PaymentRequest`

            then its value is returned unchanged. If new payment instrument
            information

            was provided then this field will contain the ID under which the new
            payment

            instrument has been stored.
          type: string
          format: uuid
        code:
          description: >
            Decline or error code as received from the payment provider or
            Payall.

            Only present when the payment was declined.
          type: string
        decline_issuer:
          description: |
            Entity that issued the decline: `PAYALL` for internal failures,
            the service provider name for external failures.
          type: string
        error:
          $ref: '#/components/schemas/ErrorResponse'
    ExchangeRateRequest:
      type: object
      required:
        - destination_country
      description: >
        Use either `source_amount` and `target_currency` or just `target_amount`

        to receive rate in the currency of the source account referenced by the
        `source_account_id`.


        `source_amount` represents a value in the currency **from** which the
        exchange is made.

        `target_amount` represents a value in the currency **to** which the
        exchange is made.


        Examples:
          1. Exchange 10 EUR (`source_amount`) **to** `target_currency` GBP
          2. Get amount in EUR (`source_account_id`'s currency) for the `target_amount` being 10 GBP

        `source_currency` and `source_account_id` are mutually exclusive.

        Also there is no need to provide `source_currency` if you're providing
        `source_amount` 

        as it is already contains currency. Providing both will result in an
        error with 409 status code.


        `recipient_instrument_id` and `payment_instrument_category` are mutually
        exclusive.

        Providing both will result in an error with 409 status code.

        This is because instrument category is already part of existing payment
        instrument.


        `payment_type` is not needed when providing `source_account_id` and
        `recipient_instrument_id` and `payment_type`. 

        Providing both will result in an error with 409 status code.

        This is because payment type is defined by payer and recipient types.
      properties:
        source_account_id:
          description: >
            ID of the account to use as source of funds.


            Provide either source or target amount to receive the opposite
            value.
          type: string
          format: uuid
        source_currency:
          description: >
            Currency of the source amount.


            This field is required only if both `source_amount` and
            `source_account_id` are NOT provided.

            This is useful if you're not using currency exchange markup based

            on payer segmentation (ie high volume business payers having
            different rates than individuals).
          type: string
          format: iso-4217
          maxLength: 3
          minLength: 3
          example: EUR
        source_amount:
          $ref: '#/components/schemas/Amount'
        target_amount:
          $ref: '#/components/schemas/Amount'
        recipient_instrument_id:
          type: string
          description: >
            Represents recipient's payment instrument id of already existent
            entity.


            This field is for backward compatibility and will be removed in the
            future.

            Please use `payment_instrument_category` instead.
        payment_instrument_category:
          $ref: '#/components/schemas/PaymentInstrumentCategory'
        payment_type:
          $ref: '#/components/schemas/PaymentType'
        target_currency:
          type: string
          format: iso-4217
          maxLength: 3
          minLength: 3
          example: GBP
        destination_country:
          description: |
            Destination country for the payment. 3166-1 alpha-2 value.
            Hint: It is `GB`, not `UK`.
          type: string
          format: iso-3166-alpha-2
          example: GB
    EndToEndId:
      type: string
      maxLength: 35
      example: PA-ecf87cf814cd4d95a970ac7e8d7e7ef3
      description: >
        End To End Identification

        This filed follows ISO 20022 guidelines.


        Unique identification, as assigned by the initiating party, to
        unambiguously identify the transaction.

        This identification is passed on, unchanged, throughout the entire
        end-to-end chain.


        Usage: The end-to-end identification can be used for reconciliation or
        to link tasks relating to the transaction.

        It can be included in several messages related to the transaction.


        If not provided, a random UUID based identifier will be generated.
    Identity:
      description: Abstract class. Use it's implementations instead.
      type: object
      required:
        - type
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        type:
          $ref: '#/components/schemas/Type'
        external_id:
          description: ID from external system.
          type: string
      discriminator:
        propertyName: type
        mapping:
          Business: '#/components/schemas/Business'
          Person: '#/components/schemas/Person'
    Address:
      type: object
      properties:
        city:
          type: string
          maxLength: 35
        street:
          type: string
          maxLength: 35
        country:
          type: string
          maxLength: 255
        postal_code:
          type: string
          maxLength: 50
        unit_number:
          type: string
          maxLength: 20
        building_name:
          type: string
          maxLength: 255
        state_province:
          type: string
          maxLength: 255
        building_number:
          type: string
          maxLength: 20
    Business:
      description: Identity representing a legal entity.
      type: object
      required:
        - legal_name
      allOf:
        - $ref: '#/components/schemas/Identity'
        - type: object
          properties:
            legal_name:
              type: string
            country:
              description: |
                Country of registration. 3166-1 alpha-2 value.

                Hint: It is `GB`, not `UK`.
              type: string
              format: iso-3166-alpha-2
              example: PL
            trade_name:
              type: string
            phone_number:
              type: string
            registration_number:
              type: string
            email:
              type: string
              format: email
            registration_address:
              $ref: '#/components/schemas/Address'
    Person:
      description: Identity representing a natural person.
      type: object
      required:
        - first_name
        - last_name
      allOf:
        - $ref: '#/components/schemas/Identity'
        - type: object
          properties:
            email:
              type: string
              format: email
            first_name:
              type: string
            last_name:
              type: string
            middle_name:
              type: string
            mobile_number:
              type: string
            dob:
              type: string
              format: date
            occupation:
              oneOf:
                - type: string
                  enum:
                    - general_worker
                    - businessman
                    - others
                    - professional
                    - tourist
                    - security_guard
                    - supervisor
                    - house_maid
                    - domestic_helper
                    - house_wife
            registration_address:
              $ref: '#/components/schemas/Address'
            identity_document:
              $ref: '#/components/schemas/IdentityDocument'
    IdentityDocument:
      type: object
      properties:
        type:
          type: string
        type_version_number:
          type: string
        country_issuing:
          type: string
        number:
          type: string
        national_id_number:
          type: string
        national_id_number_type:
          type: string
        series:
          type: string
        issue_date:
          type: string
          format: date
          description: >
            Issue date of the identity document, in `YYYY-MM-DD` format. When
            provided,

            it must not be in the future — an issue date later than today is
            rejected when

            creating or updating a payer or recipient (see error codes PUB4221
            for payers

            and PUB4222 for recipients).
        place_of_issue:
          type: string
        authority_of_issue:
          type: string
        expiry_date:
          type: string
          format: date
          description: >
            Expiry date of the identity document, in `YYYY-MM-DD` format. When
            provided,

            it must not be in the past — an expired document is rejected when
            creating or

            updating a payer or recipient (see error codes PUB4219 for payers
            and PUB4220

            for recipients).
        driver_license_number:
          type: string
        driver_license_serial_number:
          type: string
        driver_license_version_number:
          type: string
    MobileWallet:
      type: object
      required:
        - mobile_number
      allOf:
        - $ref: '#/components/schemas/PaymentInstrument'
        - type: object
          properties:
            currency:
              type: string
            mobile_number:
              type: string
            phone_operator:
              type: string
    PaymentInstrument:
      description: Abstract class. Use it's implementations instead.
      type: object
      required:
        - category
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        category:
          $ref: '#/components/schemas/PaymentInstrumentCategory'
      discriminator:
        propertyName: category
        mapping:
          MobileWallet: '#/components/schemas/MobileWallet'
          BankAccount: '#/components/schemas/BankAccount'
          CashPickup: '#/components/schemas/CashPickup'
          Card: '#/components/schemas/Card'
    BankAccount:
      type: object
      allOf:
        - $ref: '#/components/schemas/PaymentInstrument'
        - type: object
          properties:
            currency:
              type: string
            routing_number:
              type: string
            swift_bic_code:
              type: string
            bank_domestic_code:
              type: string
            iban:
              type: string
            swift_intermediary:
              type: string
            routing_number_intermediary:
              type: string
            iban_intermediary:
              type: string
            account_id:
              type: string
            bank_name:
              type: string
            bank_branch_name:
              type: string
            bank_branch_code:
              type: string
            bank_country:
              type: string
            bank_address:
              type: string
            account_number:
              type: string
            sub_account_number:
              type: string
            account_type:
              type: string
            account_name:
              type: string
            urgency_flag_preference:
              type: string
    CashPickup:
      type: object
      allOf:
        - $ref: '#/components/schemas/PaymentInstrument'
        - type: object
          properties:
            currency:
              type: string
            service_provider_name:
              type: string
            first_name:
              type: string
            last_name:
              type: string
    Card:
      type: object
      required:
        - token
      allOf:
        - $ref: '#/components/schemas/PaymentInstrument'
        - type: object
          properties:
            currency:
              type: string
            token:
              description: |
                Card token can be generated using Payall Vault iframe or API.
                Unencrypted card data should never be sent to this API directly.
              type: string
              format: uuid
            masked_number:
              type: string
              example: 1234 **** **** 3456
              readOnly: true
    Amount:
      type: object
      required:
        - currency
        - value
      properties:
        currency:
          type: string
          format: iso-4217
          maxLength: 3
          minLength: 3
          example: EUR
        value:
          type: integer
          example: 10023
          description: |
            Amounts are always in the smallest currency unit.
            Example: 1000.23 EUR is represented as 100023 euro cents.
    ForwardPaymentOperation:
      description: |
        Forward payment operation details.
        All amounts should be provided in the smallest currency unit.

        For example, 1000.23 EUR should be provided as 100023.
      properties:
        type:
          description: Type of the operation.
          type: string
          enum:
            - Forward
        source_amount:
          $ref: '#/components/schemas/Amount'
        target_currency:
          description: |
            Target currency for the operation.
            The recipient amount will be calculated based on the exchange rate
            and fees configuration.
          type: string
          format: iso-4217
          maxLength: 3
          minLength: 3
          example: PLN
    ReversePaymentOperation:
      description: >
        Reverse payment operation details.

        Source currency is implicitly derived from the source account.

        Source amount is calculated based on the target amount, the exchange
        rate

        and fees configuration.


        All amounts should be provided in the smallest currency unit.

        For example, 1000.23 EUR should be provided as 100023.
      properties:
        type:
          description: Type of the operation.
          type: string
          enum:
            - Reverse
        target_amount:
          $ref: '#/components/schemas/Amount'
    BankAccountType:
      description: |
        Beneficiary bank account type
      type: string
      enum:
        - checking
        - ordinary
        - savings
    SupportingDocument:
      type: object
      properties:
        document_id:
          type: string
          format: uuid
        document_type:
          description: |
            The type of the document.
          type: string
          enum:
            - invoice
            - contract_or_agreement
            - proof_of_funds
            - bill_of_lading
            - relationship_proof
            - other
      required:
        - document_id
    KYT:
      description: |
        Transaction information required for KYT process.
      type: object
      required:
        - destination_country
      properties:
        destination_country:
          description: |
            Destination country for the payment. 3166-1 alpha-2 value.

            Hint: It is `GB`, not `UK`.
          type: string
          format: iso-3166-alpha-2
          example: GB
        payment_purpose:
          description: |
            The purpose of payment.
          type: string
          enum:
            - family_maintenance
            - household_maintenance
            - donation_or_gifts
            - payment_of_loan
            - purchase_of_property
            - funeral_expenses
            - medical_expenses
            - wedding_expenses
            - payment_of_bills
            - education_savings
            - employee_colleague
            - business_investment
            - salary
            - payment_of_goods_and_services
            - business
            - payment_of_loan_and_payment_of_bills
        commercial_activity:
          description: |
            Commercial activity.
          type: string
          enum:
            - transportation
            - warehousing
            - insurance
            - banking_and_finance
            - acquiring
            - selling_of_goods_and_services
        payment_description:
          description: |
            Additional information about the payment.
          type: string
        beneficiary_bank_account_type:
          deprecated: true
          description: >
            Beneficiary bank account type

            Deprecated: should be used account type from Bank account payment
            instrument
          $ref: '#/components/schemas/BankAccountType'
        supporting_documents:
          description: |
            Documents that will be considered as proof for the payment.

            This field may be required depending on your KYT settings.
            Consult the discovery endpoint for more information.
          type: array
          items:
            $ref: '#/components/schemas/SupportingDocument'
        source_of_funds:
          description: |
            Source of funds.
          type: string
          enum:
            - salary
            - business
            - savings
            - investments
            - government_funding
            - loan
            - personal_income
        relationship_with_sender:
          description: |
            Relationship of the recipient with the sender.
          type: string
          enum:
            - father
            - mother
            - daughter
            - son
            - sister
            - brother
            - wife
            - husband
            - father_in_law
            - mother_in_law
            - aunty
            - uncle
            - cousin
            - nephew
            - niece
            - grand_mother
            - grand_father
            - grand_daughter
            - grand_son
            - friend
            - friends_mother
            - friends_father
            - self
    PaymentRequest:
      description: >
        All amounts should be provided in the smallest currency unit.

        For example, 1000.23 EUR should be provided as 100023.


        Please note that this request contains mutually exclusive fields as
        described in the table:


        |         Field         | recipient_id | recipient | payment_instrument
        | payment_instrument_id |

        |:---------------------:|:------------:|:---------:|:------------------:|:---------------------:|

        |     recipient_id      |      /       |     -     |         +         
        |           -           |

        |       recipient       |      -       |     /     |         +         
        |           -           |

        |  payment_instrument   |      +       |     +     |         /         
        |           -           |

        | payment_instrument_id |      -       |     -     |         -         
        |           /           |


        At least `payment_instrument_id` is required or any other combination

        of recipient and payment instrument information as described in the
        table.


        If you're building a flow with explicit exchange rates then you should

        either use the `exchange_rate_id` or `carded_rate_id` but not both.

        Providing both will result in an error with 409 status code.


        When using `exchange_rate_id` the `operation` field should not be
        provided.

        Providing both will result in an error with 409 status code.
      required:
        - source_account_id
        - kyt
      type: object
      properties:
        end_to_end_id:
          $ref: '#/components/schemas/EndToEndId'
        client_payment_id:
          description: >-
            External reference identifying the payment in your (the client)
            system.
          type: string
        recipient:
          description: >
            [Optional] New recipient information.


            This recipient will be persisted for the future and linked to the
            payment

            instrument provided via the `payment_instrument` field.

            When creating new recipient you can not reuse existing payment
            instrument

            as it will be already tied to other existing recipient.


            If recipient data matches existing recipient in the system then
            existing recipient

            will be used and it's ID will be returned in the corresponding
            `PaymentResponse`.


            Matching is done based on the required fields for `Person` or
            `Business` respectively.


            Alternatively `recipient_id` can be used instead to send payment to
            existing recipient.

            `recipient` and `recipient_id` are mutually exclusive fields.
          oneOf:
            - $ref: '#/components/schemas/Person'
            - $ref: '#/components/schemas/Business'
        payment_instrument:
          description: >
            [Optional] New payment instrument information.

            This payment instrument will be persisted and linked to the
            recipient

            provided via the `recipient` or `recipient_id` fields.


            Alternatively `payment_instrument_id` can be used instead

            to reuse existing payment instrument.
          oneOf:
            - $ref: '#/components/schemas/MobileWallet'
            - $ref: '#/components/schemas/BankAccount'
            - $ref: '#/components/schemas/CashPickup'
            - $ref: '#/components/schemas/Card'
        recipient_id:
          description: >
            [Optional] Id of exiting recipient.


            Alternatively `recipient` can be used instead to send payment to a
            new recipient.

            `recipient` and `recipient_id` are mutually exclusive fields.
          type: string
          format: uuid
        payment_instrument_id:
          description: |
            [Optional] Id of existing payment instrument.

            When payment_instrument_id is provided then
            `recipient_id`, `recipient` and `payment_instrument` are not allowed
            because existing instances of `PaymentInstrument` are tied to
            specific existing recipients.
          type: string
          format: uuid
        source_account_id:
          description: |
            Id of the account to use as source of funds.
          type: string
          format: uuid
        operation:
          oneOf:
            - $ref: '#/components/schemas/ForwardPaymentOperation'
            - $ref: '#/components/schemas/ReversePaymentOperation'
        exchange_rate_id:
          description: >
            [Optional] Id of the exchange rate to use for the payment.

            If not provided then the best available exchange rate will be used.


            Note that this is the ID of the exchange rate obtained from the

            `/v2/exchange-rates` endpoint. For carded rates use the
            `carded_rate_id`.


            You can either use the `exchange_rate_id` or `carded_rate_id` but
            not both.


            Response with HTTP code 400 will be sent if provided exchange rate
            expired.
          type: string
          format: uuid
        carded_rate_id:
          description: >
            [Optional] Id of the carded exchange rate to use for the payment.

            If not provided then the best available carded exchange rate will be
            used.


            Note that this is the ID of the exchange rate obtained from the
            carded rates feed.

            For non-carded rates use the `exchange_rate_id`.


            You can either use the `exchange_rate_id` or `carded_rate_id` but
            not both.


            Response with HTTP code 400 will be sent if provided exchange rate
            expired.
          type: string
          format: uuid
        kyt:
          $ref: '#/components/schemas/KYT'
    LegacyPaymentRequest:
      description: >
        **Deprecation warning**: This request is deprecated and will be removed
        in the future.

        Please refer to `PaymentRequest` together with `ReversePaymentOperation`

        and `ForwardPaymentOperation` for the new payment requests schemas.


        Payment information required to initiate the payment.

        Payments initiated with this request are always reverse payments

        and the provided amount is treated as the target amount.


        All amounts should be provided in the smallest currency unit.

        For example, 1000.23 EUR should be provided as 100023.


        Please note that this request contains mutually exclusive fields as
        described in the table:


        |         Field         | recipient_id | recipient | payment_instrument
        | payment_instrument_id |

        |:---------------------:|:------------:|:---------:|:------------------:|:---------------------:|

        |     recipient_id      |      /       |     -     |         +         
        |           -           |

        |       recipient       |      -       |     /     |         +         
        |           -           |

        |  payment_instrument   |      +       |     +     |         /         
        |           -           |

        | payment_instrument_id |      -       |     -     |         -         
        |           /           |


        At least `payment_instrument_id` is required or any other combination

        of recipient and payment instrument information as described in the
        table.


        If you're building a flow with explicit exchange rates then you should

        either use the `exchange_rate_id` or `carded_rate_id` but not both.

        Providing both will result in an error with 409 status code.
      required:
        - source_account_id
        - amount
        - kyt
      deprecated: true
      type: object
      properties:
        client_payment_id:
          description: >-
            External reference identifying the payment in your (the client)
            system.
          type: string
        recipient:
          description: >
            [Optional] New recipient information.


            This recipient will be persisted for the future and linked to the
            payment

            instrument provided via the `payment_instrument` field.

            When creating new recipient you can not reuse existing payment
            instrument

            as it will be already tied to other existing recipient.


            If recipient data matches existing recipient in the system then
            existing recipient

            will be used and it's ID will be returned in the corresponding
            `PaymentResponse`.


            Matching is done based on the required fields for `Person` or
            `Business` respectively.


            Alternatively `recipient_id` can be used instead to send payment to
            existing recipient.

            `recipient` and `recipient_id` are mutually exclusive fields.
          oneOf:
            - $ref: '#/components/schemas/Person'
            - $ref: '#/components/schemas/Business'
        payment_instrument:
          description: >
            [Optional] New payment instrument information.

            This payment instrument will be persisted and linked to the
            recipient

            provided via the `recipient` or `recipient_id` fields.


            Alternatively `payment_instrument_id` can be used instead

            to reuse existing payment instrument.
          oneOf:
            - $ref: '#/components/schemas/MobileWallet'
            - $ref: '#/components/schemas/BankAccount'
            - $ref: '#/components/schemas/CashPickup'
            - $ref: '#/components/schemas/Card'
        recipient_id:
          description: >
            [Optional] Id of exiting recipient.


            Alternatively `recipient` can be used instead to send payment to a
            new recipient.

            `recipient` and `recipient_id` are mutually exclusive fields.
          type: string
          format: uuid
        payment_instrument_id:
          description: |
            [Optional] Id of existing payment instrument.

            When payment_instrument_id is provided then
            `recipient_id`, `recipient` and `payment_instrument` are not allowed
            because existing instances of `PaymentInstrument` are tied to
            specific existing recipients.
          type: string
          format: uuid
        source_account_id:
          description: |
            Id of the account to use as source of funds.
          type: string
          format: uuid
        amount:
          $ref: '#/components/schemas/Amount'
        exchange_rate_id:
          description: >
            [Optional] Id of the exchange rate to use for the payment.

            If not provided then the best available exchange rate will be used.


            Note that this is the ID of the exchange rate obtained from the

            `/v2/exchange-rates` endpoint. For carded rates use the
            `carded_rate_id`.


            You can either use the `exchange_rate_id` or `carded_rate_id` but
            not both.


            Response with HTTP code 400 will be sent if provided exchange rate
            expired.
          type: string
          format: uuid
        carded_rate_id:
          description: >
            [Optional] Id of the carded exchange rate to use for the payment.

            If not provided then the best available carded exchange rate will be
            used.


            Note that this is the ID of the exchange rate obtained from the
            carded rates feed.

            For non-carded rates use the `exchange_rate_id`.


            You can either use the `exchange_rate_id` or `carded_rate_id` but
            not both.


            Response with HTTP code 400 will be sent if provided exchange rate
            expired.
          type: string
          format: uuid
        kyt:
          $ref: '#/components/schemas/KYT'
    UETR:
      description: >
        Universally unique identifier to provide an end-to-end reference of a
        payment transaction.
      type: string
      example: bb1ccd4b-5072-4731-944f-45425c2b9e97
      format: uuid
    Fees:
      type: object
      description: |
        `payer` is the total fee carried by the payer.
        `recipient` is the total fee carried by the recipient.
      readOnly: true
      properties:
        payer:
          $ref: '#/components/schemas/Amount'
        recipient:
          $ref: '#/components/schemas/Amount'
    ExchangeRateInstance:
      type: object
      description: >
        `source_amount` represents a value in the currency **from** which the
        exchange is made.

        `target_amount` represents a value in the currency **to** which the
        exchange is made.


        For example 10 EUR (`source_amount`) converted **to** GBP will result in
        8 GBP (`target_amount`).
      properties:
        id:
          type: string
          format: uuid
        source_amount:
          $ref: '#/components/schemas/Amount'
        target_amount:
          $ref: '#/components/schemas/Amount'
        expiration_date:
          description: Exchange rate is valid until this date and time.
          type: string
          format: date-time
    ErrorResponse:
      type: object
      properties:
        code:
          type: string
          example: '00005'
        message:
          type: string
          example: Only recipient_id or recipient values are allowed but not both.
        trace_id:
          type: string
          format: uuid
        details:
          additionalProperties:
            type: string
    Pagination:
      type: object
      properties:
        pageNumber:
          type: integer
          format: int32
        totalPages:
          type: integer
          format: int32
        totalElements:
          type: integer
          format: int32
        pageSize:
          type: integer
          format: int32
        offset:
          type: integer
          format: int32
    MobileWalletCreate:
      type: object
      required:
        - mobile_number
      allOf:
        - $ref: '#/components/schemas/PaymentInstrumentCreate'
        - type: object
          properties:
            currency:
              type: string
            mobile_number:
              type: string
            phone_operator:
              type: string
            country:
              description: >
                If a country is provided, pre-validation of the request is
                performed.
              type: string
    PaymentInstrumentCreate:
      description: Abstract class. Use it's implementations instead.
      type: object
      required:
        - category
        - recipient_id
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        recipient_id:
          description: >-
            ID of an existing recipient that this instrument belongs to. It is
            required for new payment instrument creation.
          type: string
          format: uuid
        category:
          $ref: '#/components/schemas/PaymentInstrumentCategory'
      discriminator:
        propertyName: category
        mapping:
          MobileWallet: '#/components/schemas/MobileWalletCreate'
          BankAccount: '#/components/schemas/BankAccountCreate'
          CashPickup: '#/components/schemas/CashPickupCreate'
          Card: '#/components/schemas/CardCreate'
    BankAccountCreate:
      type: object
      allOf:
        - $ref: '#/components/schemas/PaymentInstrumentCreate'
        - type: object
          properties:
            currency:
              type: string
            routing_number:
              type: string
            swift_bic_code:
              type: string
            bank_domestic_code:
              type: string
            iban:
              type: string
            swift_intermediary:
              type: string
            routing_number_intermediary:
              type: string
            iban_intermediary:
              type: string
            account_id:
              type: string
            bank_name:
              type: string
            bank_branch_name:
              type: string
            bank_branch_code:
              type: string
            bank_country:
              type: string
            bank_address:
              type: string
            account_number:
              type: string
            sub_account_number:
              type: string
            account_type:
              $ref: '#/components/schemas/BankAccountType'
            account_name:
              type: string
            urgency_flag_preference:
              type: string
            country:
              description: >
                If a country is provided, pre-validation of the request is
                performed.
              type: string
    CashPickupCreate:
      type: object
      allOf:
        - $ref: '#/components/schemas/PaymentInstrumentCreate'
        - type: object
          properties:
            currency:
              type: string
            service_provider_name:
              type: string
            first_name:
              type: string
            last_name:
              type: string
    CardCreate:
      type: object
      required:
        - token
      allOf:
        - $ref: '#/components/schemas/PaymentInstrumentCreate'
        - type: object
          properties:
            currency:
              type: string
            token:
              description: |
                Card token can be generated using Payall Vault iframe or API.
                Unencrypted card data should never be sent to this API directly.
              type: string
              format: uuid
            country:
              description: >
                If a country is provided, pre-validation of the request is
                performed.
              type: string
    PaymentType:
      type: string
      enum:
        - B2B
        - B2P
        - P2B
        - P2P
    CardedRateTier:
      type: object
      required:
        - id
        - from_amount
        - rate
      properties:
        id:
          type: string
          format: uuid
          description: |
            Unique identifier of the exchange rate.
            This identifier can be used to identify the exchange rate
            when making payments with explicit exchange rate flow.
        from_amount:
          type: integer
          description: >
            The amount in the `from_currency` from which the exchange rate is
            valid.

            Amounts are always in the smallest currency unit.

            Example: 1000.23 USD is represented as 100023 cents.


            For partners utilizing tiered pricing,

            this value will represent the starting amount for the tier.
          example: 100023
        rate:
          type: number
          description: |
            Exchange rate for the currency pair
            defined by `from_currency` and `to_currency`.
            For example `0.8783` for USD to EUR.
          example: 0.8801
    CardedRate:
      type: object
      required:
        - id
        - from_currency
        - to_currency
        - valid_from
        - valid_to
        - rate
      description: |
        Currency exchange rate information.

        The exchange rate is valid from `valid_from` date-time
        until `valid_to` date-time. New rates should be published
        before the `valid_from` date-time of the new rate.

        Note that `payment_instrument_category` is optional and
        will be used only if there is a specific exchange rate
        defined for a payment instrument category. If there is no
        specific exchange rate defined for a payment instrument category
        and currency pair then the exchange rate defined for the currency pair
        should be used for all payment instrument categories.
      properties:
        id:
          type: string
          format: uuid
          description: |
            Unique identifier of the exchange rate.
            This identifier can be used to identify the exchange rate
            when making payments with explicit exchange rate flow.
        from_currency:
          type: string
          description: |
            Currency code as defined by ISO 4217.
            For example `USD` for US Dollar.
          example: USD
        to_currency:
          type: string
          description: |
            Currency code as defined by ISO 4217.
            For example `EUR` for Euro.
          example: EUR
        valid_from:
          type: string
          format: date-time
          description: |
            The date-time from which the exchange rate is valid.

            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
          example: '2023-03-01T00:00:00Z'
        valid_to:
          type: string
          format: date-time
          description: |
            The date-time until which the exchange rate is valid.

            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
          example: '2023-03-01T04:00:00Z'
        payment_instrument_category:
          $ref: '#/components/schemas/PaymentInstrumentCategory'
        rate:
          type: number
          description: |
            Exchange rate for the currency pair
            defined by `from_currency` and `to_currency`.
            For example `0.8783` for USD to EUR.

            For partners utilizing tiered pricing,
            this value will represent the exchange rate for the lowest tier.
          example: 0.8783
        tiers:
          type: array
          items:
            $ref: '#/components/schemas/CardedRateTier'
    CardedRates:
      type: object
      required:
        - rates
      properties:
        rates:
          type: array
          items:
            $ref: '#/components/schemas/CardedRate'
    AccountDetails:
      type: object
      properties:
        id:
          type: string
          format: uuid
          description: Account id
          example: 550e8400-e29b-41d4-a716-446655440000
        owner_id:
          type: string
          format: uuid
          description: Owner id
          example: f47ac10b-58cc-4372-a567-0e02b2c3d479
        owner_name:
          type: string
          description: >-
            For individuals First name + Last name and for businesses Business
            Entity Title
          example: John Doe vs Trade Company
        created:
          type: string
          format: date-time
          description: Account creation date
          example: '2023-10-27T08:57:09.374902'
        number:
          type: string
          description: Account reference
          example: CC002200MONE00012398064447EUR
        name:
          type: string
          description: Account name
          example: Digital Account
        currency:
          type: string
          maxLength: 3
          minLength: 3
          description: Account currency
          example: EUR
        balance:
          $ref: '#/components/schemas/Amount'
    PersonUpdate:
      description: Person update request.
      type: object
      required:
        - type
      properties:
        type:
          type: string
          enum:
            - Person
        registration_address:
          $ref: '#/components/schemas/Address'
        identity_document:
          $ref: '#/components/schemas/IdentityDocument'
    BusinessUpdate:
      description: Legal entity update request.
      type: object
      required:
        - type
      properties:
        type:
          type: string
          enum:
            - Business
        registration_address:
          $ref: '#/components/schemas/Address'
    LimitsResponse:
      type: object
      properties:
        minimum:
          $ref: '#/components/schemas/Amount'
        maximum:
          $ref: '#/components/schemas/Amount'
    Payer:
      description: Abstract class. Use it's implementations instead.
      type: object
      required:
        - type
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        accounts:
          type: array
          readOnly: true
          items:
            $ref: '#/components/schemas/AccountDetails'
        type:
          type: string
          enum:
            - Business
            - Person
        external_id:
          description: ID from external system.
          type: string
      discriminator:
        propertyName: type
        mapping:
          Business: '#/components/schemas/BusinessPayer'
          Person: '#/components/schemas/PersonPayer'
    BusinessOwner:
      type: object
      required:
        - first_name
        - last_name
      properties:
        first_name:
          type: string
        middle_name:
          type: string
        last_name:
          type: string
        date_of_birth:
          description: Date of birth in ISO 8601 format (YYYY-MM-DD)
          type: string
          format: date
          pattern: /([0-9]{4})-(?:[0-9]{2})-([0-9]{2})/
          example: '2001-05-17'
        job_title:
          description: Job title of the person at the related business.
          type: string
        ownership:
          description: >-
            Represents a share percentage of the related business owned by this
            person.
          type: number
          minimum: 0
          maximum: 100
    AuthorizedPerson:
      type: object
      required:
        - first_name
        - last_name
      properties:
        first_name:
          type: string
        middle_name:
          type: string
        last_name:
          type: string
        job_title:
          description: Job title of the person at the related business.
          type: string
        email:
          type: string
          format: email
        phone_number:
          type: string
          pattern: ^\+?[1-9]\d{1,14}$
          description: E.164 phone number format
    BusinessPayer:
      description: Base contract for business payer creation
      type: object
      required:
        - legal_name
      allOf:
        - $ref: '#/components/schemas/Payer'
        - type: object
          properties:
            legal_name:
              type: string
            trade_name:
              type: string
            country:
              description: |
                Country of registration. 3166-1 alpha-2 value.

                Hint: It is `GB`, not `UK`.
              type: string
              format: iso-3166-alpha-2
              example: PL
            registration_number:
              type: string
            registration_date:
              type: string
              format: date
            email:
              description: Business email
              type: string
              maxLength: 500
            phone_number:
              description: Business phone number
              type: string
              maxLength: 30
            registration_address:
              $ref: '#/components/schemas/Address'
            owners:
              type: array
              items:
                $ref: '#/components/schemas/BusinessOwner'
            authorized_persons:
              type: array
              items:
                $ref: '#/components/schemas/AuthorizedPerson'
            organization_legal_structure:
              description: Specifies the legal structure of the organisation.
              type: string
              enum:
                - limited_liability_company
                - limited_liability_partnership
                - limited_partnership
                - private_corporation
                - public_corporation
                - non_profit_corporation
                - government_entity
    PersonPayer:
      description: Base contract for person payer creation
      type: object
      required:
        - first_name
        - last_name
      allOf:
        - $ref: '#/components/schemas/Payer'
        - type: object
          properties:
            first_name:
              type: string
            middle_name:
              type: string
            last_name:
              type: string
            phone_number:
              type: string
            registration_address:
              $ref: '#/components/schemas/Address'
            nationality:
              type: string
            government_id:
              type: string
              deprecated: true
              description: >
                Deprecated. Use `identity_document` instead. When
                `identity_document`

                is omitted, this value is used as the identity document number.
            identity_document:
              $ref: '#/components/schemas/IdentityDocument'
            date_of_birth:
              type: string
              format: date
            source_of_income:
              type: string
            email:
              type: string
            place_of_birth:
              type: string
            occupation:
              oneOf:
                - type: string
                  enum:
                    - general_worker
                    - businessman
                    - others
                    - professional
                    - tourist
                    - security_guard
                    - supervisor
                    - house_maid
                    - domestic_helper
                    - house_wife
            relationship_with_beneficiary:
              type: string
            employer_name:
              type: string
            employer_country:
              type: string
              description: |
                Country of registration. 3166-1 alpha-2 value.
                Hint: It is `GB`, not `UK`.
              format: iso-3166-alpha-2
              example: PL
            employer_industry:
              type: string
    StatusChangeEvent:
      type: object
      required:
        - status
        - id
        - client_payment_id
        - timestamp
      properties:
        status:
          type: string
          enum:
            - Created
            - PendingCompliance
            - Completed
            - Declined
            - ExchangeRateExpired
            - PendingSettlement
            - PendingClearingInstitution
            - PendingFinance
            - PendingServiceProvider
            - PendingDocument
          description: >
            `ExchangeRateExpired` status means that an action by

            the payer is required in order to approve new exchange rate

            in order to proceed with the payment.


            Exchange rate will usually expire for payments that will have to

            undergo additional KYT checks. Event related to this status

            will be emitted only after the KYT process finishes meaning

            that the date of the event and exchange rate expiry date will not
            match.


            `PendingSettlement` status means that the payment can

            be processed but needs the settlement account to be funded first.

            This status will be applicable depending on configuration of the

            originating institution program.


            In case you are controlling the settlement funding on your side

            this status informs you that you need to fund the settlement account

            in order to process the payment.


            `PendingClearingInstitution` status means that the payment was

            processed on our side and sent to the clearing institution.


            `PendingFinance` status means that the payment requires manual

            approval by the finance officer of the originating institution.

            This status will be applicable depending on configuration of the

            originating institution program.


            `PendingServiceProvider` status means that the payment has been

            processed on our side and sent to the service provider for further

            processing before sending to the Clearing Institution. This status

            will be applicable depending on configuration of the originating

            institution program.


            `PendingDocument` status means that the payment requires additional

            documents to be uploaded before it can be processed. Refer to the

            `DocumentsEvent` and `/v2/documents` endpoint for more details.
        id:
          type: string
          format: uuid
          description: Id of the payment in Payall system.
        client_payment_id:
          type: string
          description: External reference provided when initiating the payment.
        transaction_id:
          type: string
          description: >-
            External reference provided when initiating the payment. (Same as
            `client_payment_id`)
        instruction_id:
          type: string
          description: Id of the instruction registered in Payall system.
        end_to_end_id:
          $ref: '#/components/schemas/EndToEndId'
        uetr:
          $ref: '#/components/schemas/UETR'
        integration_id:
          description: Identifier used in communication with the Clearing Institution.
          type: string
        timestamp:
          type: string
          format: date-time
          description: |
            The date-time of the event.

            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
        code:
          type: string
          description: |
            Optional status code associated with the event.
            For example in case of rejected payments
            it will identify the reason of rejection.
        external_error:
          type: object
          properties:
            code:
              type: string
              description: |
                Code from external system
            message:
              type: string
              description: |
                Details from external system
        source_amount:
          $ref: '#/components/schemas/Amount'
        target_amount:
          $ref: '#/components/schemas/Amount'
        fees:
          $ref: '#/components/schemas/Fees'
    DocumentsEvent:
      type: object
      required:
        - status
        - id
        - client_payment_id
        - timestamp
        - type
      properties:
        status:
          type: string
          enum:
            - Requested
            - Pending
            - Approved
            - Rejected
        id:
          type: string
          format: uuid
          description: Id of the payment in Payall system.
        client_payment_id:
          type: string
          format: uuid
          description: External reference provided when initiating the payment.
        document_id:
          type: string
          format: uuid
          description: Id of the document registered in Payall system.
        timestamp:
          type: string
          format: date-time
          description: |
            The date-time of the event.

            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
        type:
          $ref: '#/components/schemas/DocumentType'
        code:
          type: string
          description: |
            Optional status code associated with the event.
            For example in case of rejected documents
            it will identify the reason of rejection.
    DocumentType:
      description: |
        Document types available. Note that some types are related strictly to
        onboarding and some to payments and KYT process.
      type: string
      enum:
        - PASSPORT
        - NATIONAL_IDENTITY_CARD
        - DRIVER_LICENSE
        - OTHER_GOVERNMENTAL_ISSUED_ID
        - INVOICE
        - BILL_OF_LADING
        - RELATIONSHIP_PROOF
        - OTHER
        - SHIPPING_RECEIPT
        - ARTICLES_OF_INCORPORATION
        - CERTIFICATE_OF_INCORPORATION
        - BUSINESS_LICENSE
        - PROOF_OF_BUSINESS_ADDRESS
        - FINANCIALS
        - BANK_STATEMENT
        - FINANCIAL_STATEMENT
        - BALANCE_SHEET
        - AUDITED_ANNUAL_REPORTS
        - BUSINESS_PLAN
        - TAX_STATEMENT
        - EXCERPT_OF_COMMERCIAL_REGISTER
        - POWER_OF_ATTORNEY
        - BANK_REFERENCE_LETTER
        - PROOF_OF_TIN
        - CERTIFICATE_OF_GOOD_STANDING
        - AUTHORIZED_SIGNATORIES_LIST
        - DIRECTORS_LIST
        - SHAREHOLDERS_LIST
        - OWNERSHIP_STRUCTURE
        - CONTROL_STRUCTURE
    CreatedEvent:
      type: object
      required:
        - client_payment_id
        - id
        - status
        - fees
        - source_amount
        - target_amount
        - exchange_rate
        - payer
        - recipient
        - payment_instrument
      properties:
        end_to_end_id:
          $ref: '#/components/schemas/EndToEndId'
        client_payment_id:
          description: External reference provided when initiating the payment.
          type: string
        id:
          description: Id of the newly created payment.
          type: string
          format: uuid
        status:
          type: string
        source_amount:
          $ref: '#/components/schemas/Amount'
        target_amount:
          $ref: '#/components/schemas/Amount'
        fees:
          $ref: '#/components/schemas/Fees'
        exchange_rate:
          $ref: '#/components/schemas/ExchangeRateInstance'
        payer:
          description: |
            Payer information.
          oneOf:
            - $ref: '#/components/schemas/Person'
            - $ref: '#/components/schemas/Business'
        recipient:
          description: |
            Recipient information.
          oneOf:
            - $ref: '#/components/schemas/Person'
            - $ref: '#/components/schemas/Business'
        payment_instrument:
          description: |
            Payment instrument information.
          oneOf:
            - $ref: '#/components/schemas/MobileWallet'
            - $ref: '#/components/schemas/BankAccount'
            - $ref: '#/components/schemas/CashPickup'
            - $ref: '#/components/schemas/Card'
        timestamp:
          description: |
            Timestamp of when the payment was created.

            This is the time when the payment was created, not when it was
            processed or completed.

            Notation as defined by RFC 3339, section 5.6,
            for example, 2017-07-21T17:32:28Z
          type: string
          format: date-time
    CardDetails:
      required:
        - card_number
      type: object
      properties:
        card_number:
          type: string
          description: >
            Encrypted card number using client public key.


            Card number needs to be stripped of any non-digit characters before
            encrypting.

            Expected pattern match is `^[1-9][0-9]{7,19}$`.


            We recommend validation of card number using Luhn algorithm before
            encrypting using Luhn algorithm.
          example: >-
            ZiudIxi1h3P57k8OwmfOx1wpqIBeTGMu560uvdQoGYm2wfg/AIj8QkFpi2XTaCT4sO9drQvLSH9rSk3njQOGpSUmCzlPsA6ahG7Mg/0fMP2V6ahdMUmgmZPU1KVqL48p0pwjgSG6pTbLj6ROQFpPNkhs3ilrrQccKg7FamV34WC6hzEVyVRreR54LQeOAIFX5zQLOD4ldV/z8ikYdktKiFMkghQnF2oqzsd/rNTkL2DwzWTahgiA6gYZpoOhXt4rr1KoENC4hV4yT7iefyIFCGQu7EzeD15XB3v2+Q0Xj9ifOynADek3Mjxn6Bmg7fELGuUEkkxFgeLZrxrEcqAFbg==
        expiration_date:
          type: string
          description: ISO/EIC 7813 Expiration date of the card
          example: 12/30
    ErrorMessage:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: PCX111
        message:
          type: string
          description: Error message
          example: Input data validation error
    VaultErrorResponse:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/ErrorMessage'
    TokenMetadata:
      type: object
      properties:
        token:
          type: string
          description: Token representing the card.
          format: uuid
          example: f7b3b3b4-0b3d-4b3b-8b3b-3b3b3b3b3b3b
        created_at:
          type: string
          description: Date and time when the token was created.
          format: date-time
          example: '2021-03-03T16:27:54.378693Z'
        masked_pan:
          type: string
          description: Masked card number that is safe to use outside of the vault.
          example: 5425 **** **** 8113
        client_id:
          type: string
          description: ID of the client that owns the token.
          format: uuid
          example: f0396c8e-a87b-402d-9692-520cbc0947b5
        brand:
          type: string
          description: Brand of the card based on 4 leading digits of the card.
          example: Visa
          enum:
            - Unknown
            - Visa
            - MasterCard
            - AmericanExpress
            - Discover
            - MIR
            - UnionPay
            - RuPay
            - DinersClub
            - Maestro
            - JCB
            - UATP
    Configuration:
      type: object
      properties:
        encryption_key:
          type: string
          description: Encryption key that should be used to encrypt card details.
          example: >-
            MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuNernozTqNnb17qzYof4sYlB7QueXE+7l8B2pa4kaNwGfsquMpD9S6hXKUY2zKlCSovs811+rNWt1x6oxj3H3RSOH6J8RlG+29cDF5OXySeORON8dmPLCtZ4uXMQ4JYtlAlcPNgKJgQmnrnQJ4btb+S3FYZJ0rJyx+wpRJith4BUl0/QA3ldfLQAeWWf+6wXXhkB2n4u0zBGYd3v+L/TdqHDDrJuLVFkG2tXaBvNTQETwyPHJA06cAeqSyHneKb1RIznYL/QxUBoPAfTYdrI9cV5gUJ6bolFMrzSU9QlOR/SEjtXWjEE9sH39QLPqAJvijT1XUDNJOIeFB4E+pxGrQIDAQAB
        created_at:
          type: string
          format: date-time
        encryption_algorithm:
          type: string
          description: Encryption algorithm that should be used to encrypt card details.
          example: RSAES_OAEP_SHA_256
        require_expiration_date:
          type: boolean
          description: >
            True if expiration date is required for card details. False
            otherwise.

            Expiration date is usually not required.
          example: false
  headers:
    X-Pagination-Total-Pages:
      description: Total number of pages
      style: simple
      schema:
        type: integer
    X-Pagination-Page-Size:
      description: Limit of elements per page
      style: simple
      schema:
        type: integer
    X-Pagination-Total-Elements:
      description: Total number of elements
      style: simple
      schema:
        type: integer
    X-Pagination-Page-Number:
      description: Current page number
      style: simple
      schema:
        type: integer
    X-Pagination-Offset:
      description: Offset from the beginning
      style: simple
      schema:
        type: integer
x-tagGroups:
  - name: Payall M2M Authentication API
    tags:
      - Authorization
  - name: Payall M2M Discovery API
    tags:
      - Discovery
  - name: Payall M2M API
    tags:
      - Payments
      - Payments instruments
      - Exchange
      - Accounts
      - Recipients
      - Payers
  - name: Payall M2M Compliance API
    tags:
      - Compliance
  - name: Payall M2M Events API
    tags:
      - Events
      - Exchange rates
  - name: PCI Vault API
    tags:
      - Tokenization
