openapi: 3.0.2
servers:
  - description: Production Environment
    url: https://api.swift.com/bi/banking-premium/v2
  - description: Sandbox Environment
    url: https://sandbox.swift.com/bi/banking-premium/v2
info:
  title: SWIFT Banking Premium Analytics
  description: "SWIFT Watch Banking Analytics Premium allows financial institutions to have direct access to additional payload information on a daily aggregated level per market for payments, trade finance and treasury. \n\n**v2.0.0 Release Notes**\n\n * ISO20022 data and related fields are introduced to the API \n* Following new properties were introduced in new BankingData4 for payments path: message_definition_group, iso20022_flag, service\n * message_definition_identifier property for BankingData4 is Max35Text to accomodate for ISO message definitions \n * Addition of component YesOrNoFlag, Max40Text, Max100Text, Max150Text, PartyDetails2 (with new properties dn)\n* New parameters Iso20022Flag and MessageDefinitionGroup for activity-share endpoint \n\n.**v2.0.1 Release Notes**\n\n * dn property removed from PartyDetails2 \n* Max100Text removed \n* Corrections to some oneOf examples and Pagination format "
  contact:
    name: Developer Hub
    url: https://developer.swift.com
    email: developer-support@swift.com
  license:
    name: API Restricted License
    url: https://developer.swift.com/api-license
  version: 2.0.1
security:
  - oauthPassword:
      - read
      - write
tags:
- name: SWIFT Banking Premium Analytics
  description: This API returns daily data on number of messages and amount sent and received with additional granularity of payload details from the messages with SWIFT totals information.
paths:
  /payments:
    get:
      tags:
      - Market
      summary: Payment data.
      description: 'Returns an array of payments data filtered on reporting period available for the current and previous year.'
      operationId: getPaymentsData
      parameters:
      - $ref: '#/components/parameters/ReportingPeriod'
      - $ref: '#/components/parameters/Limit'
      - $ref: '#/components/parameters/Offset'
      responses:
        "200":
          description: Response for a 200 status code
          headers:
            X-Response-Timestamp:
              $ref: '#/components/headers/X-Response-Timestamp'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentResponse1'
              examples:
                Market_PMTS_Period_2019-07-01_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_PMTS_Period_2019-07-01_Limit_25_Offset_0'
                Market_PMTS_Period_2023-03-21_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_PMTS_Period_2023-03-21_Limit_25_Offset_0'     
        '303':
          $ref: '#/components/responses/SeeOther'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalServerError'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
        '504':
          $ref: '#/components/responses/GatewayTimeout'
        default:
          $ref: '#/components/responses/UnexpectedError'
  /trade:
    get:
      tags:
      - Market
      summary: Trade data.
      description: 'Returns an array of trade finance data filtered on reporting period available for the current and previous year.'
      operationId: getTradeData
      parameters:
      - $ref: '#/components/parameters/ReportingPeriod'
      - $ref: '#/components/parameters/Limit'
      - $ref: '#/components/parameters/Offset'
      responses:
        "200":
          description: Response for a 200 status code
          headers:
            X-Response-Timestamp:
              $ref: '#/components/headers/X-Response-Timestamp'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
          content:
            application/json:
              schema:
               $ref: '#/components/schemas/TradeResponse1'
              examples:
                Market_TRFN_Period_2019-07-01_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_TRFN_Period_2019-07-01_Limit_25_Offset_0'
                Market_TRFN_Period_2019-01-05_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_TRFN_Period_2019-01-05_Limit_25_Offset_0'
        '303':
          $ref: '#/components/responses/SeeOther'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalServerError'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
        '504':
          $ref: '#/components/responses/GatewayTimeout'
        default:
          $ref: '#/components/responses/UnexpectedError'
  /treasury:
    get:
      tags:
      - Market
      summary: Treasury data.
      description: 'Returns an array of treasury data filtered on reporting period available for the current and previous year.'
      operationId: getTreasuryData
      parameters:
      - $ref: '#/components/parameters/ReportingPeriod'
      - $ref: '#/components/parameters/Limit'
      - $ref: '#/components/parameters/Offset'
      responses:
        "200":
          description: Response for a 200 status code
          headers:
            X-Response-Timestamp:
              $ref: '#/components/headers/X-Response-Timestamp'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TreasuryResponse1'
              examples:
                Market_TREA_Period_2019-07-01_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_TREA_Period_2019-07-01_Limit_25_Offset_0'
                Market_TREA_Period_2019-01-05_Limit_25_Offset_0:
                  $ref: '#/components/examples/Market_TREA_Period_2019-01-05_Limit_25_Offset_0'
        '303':
          $ref: '#/components/responses/SeeOther'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalServerError'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
        '504':
          $ref: '#/components/responses/GatewayTimeout'
        default:
          $ref: '#/components/responses/UnexpectedError'
  /activity-share:
    get:
      tags:
      - Activity Share
      summary: Information related to SWIFT Totals.
      description: Get your daily data consisting of transaction count, converted amount, total SWIFT transactions count, total SWIFT converted amount, SWIFT activity share transaction count and SWIFT activity share converted amount per market and country filtered on a particular day in the previous or current year.
      operationId: getActivityShare
      parameters:
      - $ref: '#/components/parameters/ReportingPeriod'
      - $ref: '#/components/parameters/Market'
      - $ref: '#/components/parameters/Direction'
      - $ref: '#/components/parameters/Iso20022Flag'
      - $ref: '#/components/parameters/Country'
      - $ref: '#/components/parameters/CounterpartyCountry'
      - $ref: '#/components/parameters/Bic8'
      - $ref: '#/components/parameters/Currency'
      - $ref: '#/components/parameters/MessageDefinitionGroup'
      - $ref: '#/components/parameters/MessageDefinitionIdentifier'
      - $ref: '#/components/parameters/GeoRoute'
      - $ref: '#/components/parameters/CustomerRoute'
      - $ref: '#/components/parameters/ConversionCurrency'
      responses:
        '200':
          description: Returns daily transaction count, converted amount, total SWIFT transactions count, total SWIFT converted amount, SWIFT activity share transaction count and SWIFT activity share converted amount filtered on  market, direction and reporting period in the previous and current year.
          headers:
            X-Response-Timestamp:
              $ref: '#/components/headers/X-Response-Timestamp'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TotalsData'
              examples:
                2021-07-20_PMTS_DEMOUS01:
                  $ref: '#/components/examples/2021-07-20_PMTS_DEMOUS01'
                2023-03-21_PMTS_DEMOBE33:
                  $ref: '#/components/examples/2023-03-21_PMTS_DEMOBE33'
        '303':
          $ref: '#/components/responses/SeeOther'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalServerError'
        '502':
          $ref: '#/components/responses/BadGateway'
        '503':
          $ref: '#/components/responses/ServiceUnavailable'
        '504':
          $ref: '#/components/responses/GatewayTimeout'
        default:
          $ref: '#/components/responses/UnexpectedError'
components:
  securitySchemes:
      oauthPassword:
        type: oauth2
        description: OAuth 2 with the password grant type.
        flows:
          password:
            tokenUrl: /oauth2/v1/token
            scopes: {}
  ## PARAMETERS ##
  parameters:
    ReportingPeriod:
      name: reporting_period
      description: specifies the day the reported data covers.
      required: true
      in: query
      style: form
      explode: false
      schema:
        $ref: '#/components/schemas/ISODate'
      examples:
        ReportingDate1:
          value: "2021-07-01"
        ReportingDate2:
          value: "2022-01-05"
        ReportingDate3:
          value: "2023-03-21"
    Limit:
      name: limit
      description: Limits the maximum number of results to be displayed on a page with a minimum of 25 (putting less defaults to 25) and a maximum of 1000 (putting more defaults to 1000).
      required: false
      in: query
      schema:
        type: integer
        minimum: 25
        maximum: 1000
        default: 1000
      examples:
        25:
          value: "25"
        50:
          value: "50"
        500:
          value: "500"
        1000:
          value: "1000"
    Offset:
      name: offset
      description: Specifies the number of items from which to start returning results.
      required: false
      in: query
      schema:
        type: integer
        minimum: 0
      examples:
        0:
          value: "0"
        25:
          value: "25"
        500:
          value: "500"
        1000:
          value: "1000"
    Market:
      name: market
      description: Specifies the market to which the banking data belongs.
      required: true
      in: query
      schema:
        $ref: '#/components/schemas/Market1Code'
      examples:
        PMTS_payments:
          value: "PMTS_payments"
        TRFN_trade_finance:
          value: "TRFN_trade_finance"
        TREA_treasury:
          value: "TREA_treasury"
    Bic8:
      name: bic8
      description: BIC8 to be reported on. If not present all BIC8s in scope are returned.
      required: false
      in: query
      style: form
      explode: false
      schema:
        $ref: '#/components/schemas/AnyBICDec2014Identifier'
      examples:
        DEMOUS33:
          value: "DEMOUS33"
        DEMOBE33:
          value: "DEMOBE33"
    Currency:
      name: currency
      description: The original currency used in the transaction. If the parameter is not present all currencies will be included in the output.
      required: false
      in: query
      style: form
      explode: false
      schema:
        $ref: '#/components/schemas/CurrencyCode'
      examples:
        EUR:
          value: "EUR"
        USD:
          value: "USD"
    Direction:
      in: query
      name: direction
      description:  "| Filters messages on whether they were sent (outbound) or received (inbound).\n* `RECE_received` - Only received (inbound) messages are considered.\n* `SENT_sent` - Only sent (outbound) messages are considered."
      required: true
      schema:
        type: string
        enum: 
        - RECE_received
        - SENT_sent
      example: "RECE_received"
    MessageDefinitionGroup:
      name: message_definition_group
      description: Message type grouped into different categories. If the parameter is not present all message definition groups will be included in the output.
      required: false
      in: query
      style: form
      explode: false
      schema:
        $ref: '#/components/schemas/Max150Text'
      examples:
        MT102/MT103/pacs.008:
          value: "MT102/MT103/pacs.008"
    MessageDefinitionIdentifier:
      name: message_definition_identifier
      description: Message Type to be reported on. If the parameter is not present all Message Types will be in scope.
      required: false
      in: query
      style: form
      explode: false
      schema:
        $ref: '#/components/schemas/Min3Max4Text'
      examples:
        103:
          value: "103"
    GeoRoute:
      in: query
      name: geo_route
      description: Specifies the geographical route of the message.
      required: false
      schema:
        $ref: '#/components/schemas/GeoRoute1Code'
      examples:
        DMST_domestic:
          value: "DMST_domestic"
        INTL_international:
          value: "INTL_international"
        SWFT_swift:
          value: "SWFT_swift"
    CustomerRoute:
      in: query
      name: customer_route
      description: Specifies the customer route of the message.
      required: false
      schema:
        $ref: '#/components/schemas/CustomerRoute1Code'
      examples:
        SWFT_swift:
          value: "SWFT_swift"
        ITER_inter_customer_group:
          value: "ITER_inter_customer_group"
        ITRA_intra_customer_group:
          value: "ITRA_intra_customer_group"
    ConversionCurrency:
      in: query
      name: conversion_currency
      description: Currency into which an amount is to be converted in a currency conversion. Valid currency codes are registered with the ISO 4217 Maintenance Agency, and consist of three contiguous letters.
      required: false
      style: form
      explode: true
      schema:
        $ref: '#/components/schemas/ActiveCurrencyCode'
      examples: 
        USD:
          value: "USD"
        EUR:
          value: "EUR"
    Country:
      in: query
      name: country
      description:   "Filters messages on the country of your institution."
      required: false
      schema:
         $ref: '#/components/schemas/CountryCode'
      example: "US"
    CounterpartyCountry:
      in: query
      name: counterparty_country
      description:   "Filters messages on the country where the traffic is coming from or going to (depending on direction). If not present all countries will be in scope."
      required: false
      schema:
         $ref: '#/components/schemas/CountryCode'
      example: "US"
    Iso20022Flag:
      in: query
      name: iso20022_flag
      description:   "Indicates whether the messages are ISO20022 messages or FIN messages. If the parameter is not present both types of messages will be in scope."
      required: false
      style: form
      explode: false
      schema:
         $ref: '#/components/schemas/YesOrNoFlag'
      example: "Y"
  ## ERROR RESPONSES ##
  responses:
    SeeOther:
      description: See Other
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
        Location:
          description: Specifies a redirection URI because the original request cannot be handled by the server. 
          schema:
            $ref: '#/components/schemas/Max256Text'
    BadRequest:
      description: Bad request
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            missingParameter:
              $ref: '#/components/examples/missingParameter'
            parameterInvalid:
              $ref: '#/components/examples/parameterInvalid'
            bodyIsNotWellFormed:
              $ref: '#/components/examples/bodyIsNotWellFormed'
            headerNotIncluded:
              $ref: '#/components/examples/headerNotIncluded'
            xbicHeaderNotValid:
              $ref: '#/components/examples/xbicHeaderNotValid'
    Unauthorized:
      description: Unauthorized
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            invalidOAuthToken:
              $ref: '#/components/examples/invalidOAuthToken'
            OAuthTokenHasInsufficentScopeForRequestedService:
              $ref: '#/components/examples/OAuthTokenHasInsufficentScopeForRequestedService'
            OAuthTokenNotProvided:
              $ref: '#/components/examples/OAuthTokenNotProvided'
    Forbidden:
      description: Forbidden
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            invalidContract:
              $ref: '#/components/examples/invalidContract'
    NotFound:
      description: Not Found
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            notFound:
              $ref: '#/components/examples/notFound'
    NotAcceptable:
      description: Server cannot produce a response matching the list of media types accepted by the client
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            noAcceptableReturnType:
              $ref: '#/components/examples/noAcceptableReturnType'
    TooManyRequests:
      description: Too Many Requests
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            tooManyRequest:
              $ref: '#/components/examples/tooManyRequest'
    Conflict:
      description: Conflict
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
    InternalServerError:
      description: Internal server error
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            internalServerError:
              $ref: '#/components/examples/internalServerError'
    BadGateway:
      description: Bad Gateway
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            badGateway:
              $ref: '#/components/examples/badGateway'
    ServiceUnavailable:
      description: Service Unavailable
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            unavailable:
              $ref: '#/components/examples/unavailable'
    GatewayTimeout:
      description: Gateway timeout
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            timeOut:
              $ref: '#/components/examples/timeOut'
    UnexpectedError:
      description: Unexpected Error
      headers:
        X-Response-Timestamp:
          $ref: '#/components/headers/X-Response-Timestamp'
        X-Request-ID:
          $ref: '#/components/headers/X-Request-ID'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorMessage'
          examples:
            unexpectedError:
              $ref: '#/components/examples/unexpectedError'
  schemas:
    ActiveCurrencyCode:
      type: string
      pattern: ^[A-Z]{3,3}$
      description: '> A code allocated to a currency by a Maintenance Agency under an international identification scheme as described in the latest edition of the international standard ISO 4217 "Codes for the representation of currencies and funds".'
    ActiveOrHistoricCurrencyCode:
      type: string
      pattern: ^[A-Z]{3,3}$
      description: '> A code allocated to a currency by a Maintenance Agency under an international identification scheme, as described in the latest edition of the international standard ISO 4217 "Codes for the representation of currencies and funds".'
    AnyBICDec2014Identifier:
      type: string
      description: 'Code allocated to a financial or non-financial institution by the ISO 9362 Registration Authority, as described in ISO 9362: 2014 - "Banking - Banking telecommunication messages - Business identifier code (BIC)".'
      pattern: ^[A-Z0-9]{4,4}[A-Z]{2,2}[A-Z0-9]{2,2}([A-Z0-9]{3,3}){0,1}$
    BankingData2:
      type: object
      additionalProperties: false
      properties:
        market:
          #  Specifies the market to which the banking data belongs.
          $ref: '#/components/schemas/Market1Code'
        reporting_period:
          #  Specifies the day the reported data covers.
          $ref: '#/components/schemas/ISODate'
        delivery_status:
          #  Delivery status of a message.
          $ref: '#/components/schemas/DeliveryStatus1Choice'
        message_definition_identifier:
          #  Contains the MessageIdentifier that defines the BusinessMessage.
          $ref: '#/components/schemas/MessageType1Choice'
        my_institution:
          #  Specifies information about the reporting institution.
          $ref: '#/components/schemas/PartyDetails1'
        counterparty:
          #  Counterparty data details.
          $ref: '#/components/schemas/PartyDetails1'
        geo_route:
          #  Specifies the geographical route of a message.
          $ref: '#/components/schemas/GeoRoute1Choice'
        customer_route:
          #  Specifies the customer route of the message.
          $ref: '#/components/schemas/CustomerRoute1Choice'
        transactions_sent:
          #  Transactions (number of messages) sent from my institution to the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        transactions_received:
          #  Transactions (number of messages) received by my institution from the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_sent:
          #  Transactions (number of messages) sent in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_received:
          #  Transactions (number of messages) received in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
      required:
      - market
      - reporting_period
      - delivery_status
      - message_definition_identifier
      - my_institution
      - counterparty
      - geo_route
      - customer_route
    BankingData3:
      type: object
      description: Data model describing the banking data resource.
      additionalProperties: false
      properties:
        market:
          #  Specifies the market to which the banking data belongs.
          $ref: '#/components/schemas/Market1Code'
        reporting_period:
          #  Specifies the day the reported data covers.
          $ref: '#/components/schemas/ISODate'
        delivery_status:
          #  Delivery status of a message.
          $ref: '#/components/schemas/DeliveryStatus1Choice'
        message_definition_identifier:
          #  Contains the MessageIdentifier that defines the BusinessMessage.
          $ref: '#/components/schemas/MessageType1Choice'
        my_institution:
          #  Specifies information about the reporting institution.
          $ref: '#/components/schemas/PartyDetails1'
        counterparty:
          #  Counterparty data details.
          $ref: '#/components/schemas/PartyDetails1'
        geo_route:
          #  Specifies the geographical route of a message.
          $ref: '#/components/schemas/GeoRoute1Choice'
        customer_route:
          #  Specifies the customer route of the message.
          $ref: '#/components/schemas/CustomerRoute1Choice'
        transactions_sent:
          #  Transactions (number of messages) sent from my institution to the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        transactions_received:
          #  Transactions (number of messages) received by my institution from the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_sent:
          #  Transactions (number of messages) sent in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_received:
          #  Transactions (number of messages) received in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
        currency:
          #  Specifies the currency,
          $ref: '#/components/schemas/CurrencyDetails1Choice'
        amount_sent:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions sent from my institution to the counterparty.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        amount_received:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions received by my institution from the counterparty.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_sent:
          #  'Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions sent in same corridor by the entire SWIFT community. '
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_received:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions received in same corridor by the entire SWIFT community.
          $ref: '#/components/schemas/CurrencyAndAmount5'
      required:
      - market
      - reporting_period
      - delivery_status
      - message_definition_identifier
      - my_institution
      - counterparty
      - geo_route
      - customer_route
    BankingData4:
      type: object
      description: Data model describing the banking data resource.
      additionalProperties: false
      properties:
        market:
          #  Specifies the market to which the banking data belongs.
          $ref: '#/components/schemas/Market1Code'
        reporting_period:
          #  Specifies the day the reported data covers.
          $ref: '#/components/schemas/ISODate'
        delivery_status:
          #  Delivery status of a message.
          $ref: '#/components/schemas/DeliveryStatus1Choice'
        message_definition_identifier:
          #  Contains the MessageIdentifier that defines the BusinessMessage.
          $ref: '#/components/schemas/Max35Text'
        message_definition_group:
          #  Contains the MessageGroup that defines the BusinessMessage Group.
          $ref: '#/components/schemas/Max150Text'
        iso20022_flag:
          # description: "Specifies if message is ISO20022."
          $ref: '#/components/schemas/YesOrNoFlag'
        service:
          # description: "Specifies the service in which the message is delivered."
          $ref: '#/components/schemas/Max40Text'
        my_institution:
          #  Specifies information about the reporting institution.
          $ref: '#/components/schemas/PartyDetails2'
        counterparty:
          #  Counterparty data details.
          $ref: '#/components/schemas/PartyDetails2'
        geo_route:
          #  Specifies the geographical route of a message.
          $ref: '#/components/schemas/GeoRoute1Choice'
        customer_route:
          #  Specifies the customer route of the message.
          $ref: '#/components/schemas/CustomerRoute1Choice'
        transactions_sent:
          #  Transactions (number of messages) sent from my institution to the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        transactions_received:
          #  Transactions (number of messages) received by my institution from the counterparty.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_sent:
          #  Transactions (number of messages) sent in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
        total_swift_transactions_received:
          #  Transactions (number of messages) received in the same corridor (as defined by the list of properties) by the entire SWIFT community.
          $ref: '#/components/schemas/Max15NumericText'
        currency:
          #  Specifies the currency,
          $ref: '#/components/schemas/CurrencyDetails1Choice'
        amount_sent:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions sent from my institution to the counterparty.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        amount_received:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions received by my institution from the counterparty.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_sent:
          #  'Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions sent in same corridor by the entire SWIFT community. '
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_received:
          #  Resulting debit or credit amount of the netted amounts for all debit and credit entries of transactions received in same corridor by the entire SWIFT community.
          $ref: '#/components/schemas/CurrencyAndAmount5'
      required:
      - market
      - reporting_period
      - delivery_status
      - message_definition_identifier
      - iso20022_flag
      - service
      - my_institution
      - counterparty
      - geo_route
      - customer_route
    ChargeBearerType3Code:
      type: string
      description: |-
        > Specifies which party/parties will bear the charges associated with the processing of the payment transaction.
        *`SHAR_shared`-In a credit transfer context, means that transaction charges on the sender side are to be borne by the debtor, transaction charges on the receiver side are to be borne by the creditor. In a direct debit context, means that transaction charges on the sender side are to be borne by the creditor, transaction charges on the receiver side are to be borne by the debtor.
        *`DEBT_borne_by_debtor`-All transaction charges are to be borne by the debtor.
        *`CRED_borne_by_creditor`-All transaction charges are to be borne by the creditor.
      enum:
      - SHAR_shared
      - DEBT_borne_by_debtor
      - CRED_borne_by_creditor
    ConfirmationInstructionsCode:
      type: string
      description: "> This attribute identifies the confirmation instructions (field 49, mandatory field). The confirmation instructions can be either of the following:\r\n- Confirm\r\n- May add\r\n- Without\r\nAvailable for MT 700 and MT 710.\n*`CONF_confirm`-Confirmation\n*`MAYA_may_add`-May add\n*`WITO_without`-Without"
      enum:
      - CONF_confirm
      - MAYA_may_add
      - WITO_without
    CountryCode:
      type: string
      pattern: ^[A-Z]{2,2}$
      description: '> Code to identify a country, a dependency, or another area of particular geopolitical interest, on the basis of country names obtained from the United Nations (ISO 3166, Alpha-2 code).'
    CountryIdentification2Choice:
      type: object
      description: Identifies a country through an ISO 3166 country code, or a proprietary code.
      additionalProperties: false
      properties:
        code:
          #  Country code from the  ISO 3166, Alpha-2 code list.
          $ref: '#/components/schemas/CountryCode'
        proprietary:
          #  Proprietary identification of a country, in case the ISO 3166 list cannot be used.
          $ref: '#/components/schemas/ProprietaryCountryInformation1'
      example:
        code: US
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    CreditAvailableCode:
      type: string
      description: "> This attributes identifies when the credit is available (field 41A, mandatory field). The credit availability can be either of the following:\r\n- By acceptance\r\n- By deferred payment\r\n- By mixed payments\r\n- By negotiation\r\n- By payment\r\nAvailable for MT 700, MT 710 and MT 740.\n*`ACCE_by_acceptance`-By acceptance\n*`DPAY_by_deferred_payment`-By deferred payment\n*`MPAY_by_mixed_payment`-By mixed payment\n*`NEGO_by_negotiation`-By negotiation\n*`PAYM_by_payment`-By payment"
      enum:
      - ACCE_by_acceptance
      - DPAY_by_deferred_payment
      - MPAY_by_mixed_payment
      - NEGO_by_negotiation
      - PAYM_by_payment
    CreditTypeCode:
      type: string
      description: |-
        > The type of credit available in field 40A. Available for MT 700.
        *`IRRE_irrevocable`-Irrevocable
        *`REVO_revocable`-Revocable
        *`IRTR_irrevocable_transferable`-Irrevocable transferable
        *`RETR_revocable_transferable`-Revocable transferable
        *`IRST_irrevocable_standby`-Irrevocable standby
        *`REST_revocable_standby`-Revocable standby
        *`IRTS_irrevocable_transferable_standby`-Irrevocable transferable standby
      enum:
      - IRRE_irrevocable
      - REVO_revocable
      - IRTR_irrevocable_transferable
      - RETR_revocable_transferable
      - IRST_irrevocable_standby
      - REST_revocable_standby
      - IRTS_irrevocable_transferable_standby
    CurrencyAndAmount5:
      type: object
      description: 'Specifies the amount in its original currency, in US Dollar and in Euro. '
      additionalProperties: false
      properties:
        original:
          #  Specifies the amount in its original currency.
          $ref: '#/components/schemas/ImpliedCurrencyAndAmount'
        us_dollar:
          #  Specifies the amount in US Dollar.
          $ref: '#/components/schemas/ImpliedCurrencyAndAmount'
        euro:
          #  Specifies the amount in Euro.
          $ref: '#/components/schemas/ImpliedCurrencyAndAmount'
      example:
        original: '200000.00'
        us_dollar: '200000.00'
        euro: '195000.00'
      required:
      - original
      - us_dollar
      - euro
    CurrencyCode:
      type: string
      pattern: ^[A-Z]{3,3}$
      description: 'Code allocated to a currency, by a maintenance agency, under an international identification scheme as described in the latest edition of the international standard ISO 4217 "Codes for the representation of currencies and funds". Valid currency codes are registered with the ISO 4217 Maintenance Agency, and consist of three contiguous letters.'
    CurrencyDetails1Choice:
      type: object
      description: Offers different (coded) formats to describe a currency.
      additionalProperties: false
      properties:
        code:
          #  Valid currency code as described in the latest edition of the international standard ISO 4217.
          $ref: '#/components/schemas/ActiveCurrencyCode'
        proprietary:
          #  Contains proprietary information on a currency, in case the ISO 4127 code is not used.
          $ref: '#/components/schemas/ProprietaryCurrencyInformation1'
      example:
        proprietary:
          code: NCFD_no_currency_and_value_found
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    CustomerRoute1Choice:
      type: object
      description: Specifies  the customer route of the message, either in coded or proprietary form.
      additionalProperties: false
      properties:
        code:
          #  Specifies the customer route of the message in coded form.
          $ref: '#/components/schemas/CustomerRoute1Code'
        proprietary:
          #  Specifies the customer route of the message, in a proprietary format.
          $ref: '#/components/schemas/Max4Text'
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    CustomerRoute1Code:
      type: string
      description: |-
        > Specifies the customer route of the message.
        *`SWFT_swift`-Traffic exchanged with SWIFT.
        *`ITER_inter_customer_group`-Traffic exchanged between different institutions.
        *`ITRA_intra_customer_group`-Traffic exchanged within the same institution group of branches.
      enum:
      - SWFT_swift
      - ITER_inter_customer_group
      - ITRA_intra_customer_group
    DeliveryStatus1Choice:
      type: object
      description: Specifies the delivery status of a message, in coded or proprietary form.
      additionalProperties: false
      properties:
        code:
          #  Specifies the delivery status of a message in coded form.
          $ref: '#/components/schemas/DeliveryStatus2Code'
        proprietary:
          #  Specifies the delivery status of a message, in a proprietary format.
          $ref: '#/components/schemas/Max35Text'
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    DeliveryStatus2Code:
      type: string
      description: |-
        > Specifies the status of the delivery of a message, in coded form.
        *`ABRT_aborted`-Sending of message was aborted by sender.
        *`DLVR_delivered`-Message was delivered to receiver.
        *`NACK_nacked`-Message was not acknowledged by receiver.
        *`RFUS_refused_by_infrastructure`-Message was refused by the infrastructure (e.g. SWIFT)
      enum:
      - ABRT_aborted
      - DLVR_delivered
      - NACK_nacked
      - RFUS_refused_by_infrastructure
    DurationBucketCode:
      type: string
      description: "> This attribute identifies the length of the letters of credits (field 31E minus field 31C), split in the following buckets (in days):\r\n- L/C length 0 - 30\r\n- L/C length 31 - 60\r\n- L/C length 61 - 90\r\n- L/C length 91 - 180\r\n- L/C length 181 - 360\r\n- L/C length 361+\r\n- L/C length negative\r\n\r\nAvailable for MT 700 and MT 707.\r\n\r\n*`LC01_lc_length_from_0_to_30`-L/C length 0 - 30\n*`LC02_lc_length_from_31_to_60`-L/C length 31 - 60\n*`LC03_lc_length_from_61_to_90`-L/C length 61 - 90\n*`LC04_lc_length_from_91_to_180`-L/C length 91 - 180\n*`LC05_lc_length_from_181_to_360`-L/C length 181 - 360\n*`LC06_lc_length_from_361_and_greater`-L/C length 360+\n*`LC07_lc_length_negative`-L/C length negative"
      enum:
      - LC01_lc_length_from_0_to_30
      - LC02_lc_length_from_31_to_60
      - LC03_lc_length_from_61_to_90
      - LC04_lc_length_from_91_to_180
      - LC05_lc_length_from_181_to_360
      - LC06_lc_length_from_361_and_greater
      - LC07_lc_length_negative
    ElementState4Code:
      type: string
      description: |-
        > Contains additional information about the state of data element.
        *`EPTY_empty`-Indicates an empty element.
        *`FREE_free_format`-Indicates a free format.
        *`OPTA_option_a`-Option A.
      enum:
      - EPTY_empty
      - FREE_free_format
      - OPTA_option_a
    GeoRoute1Choice:
      type: object
      description: Specifies  the geographical route of the message, either in coded or proprietary form.
      additionalProperties: false
      properties:
        code:
          #  Specifies the geographical route in coded form.
          $ref: '#/components/schemas/GeoRoute1Code'
        proprietary:
          #  Specifies the geographical route in a proprietary format
          $ref: '#/components/schemas/Max35Text'
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    GeoRoute1Code:
      type: string
      description: |-
        > Specifies information about the geographic route the message is following.
        *`DMST_domestic`-Sender and receiver of the information are in the same country.
        *`INTL_international`-Sender and Receiver in different countries or the location of at least one of them is unknown.
        *`SWFT_swift`-Message involved SWIFT.
      enum:
      - DMST_domestic
      - INTL_international
      - SWFT_swift
    ISODate:
      type: string
      description: 'A particular point in the progression of time in a calendar year expressed in the YYYY-MM-DD format. This representation is defined in "XML Schema Part 2: Datatypes Second Edition - W3C Recommendation 28 October 2004" which is aligned with ISO 8601.'
      format: date
      pattern: ^(?:[1-9]\d{3}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1\d|2[0-8])|(?:0[13-9]|1[0-2])-(?:29|30)|(?:0[13578]|1[02])-31)|(?:[1-9]\d(?:0[48]|[2468][048]|[13579][26])|(?:[2468][048]|[13579][26])00)-02-29)$
    ImpliedCurrencyAndAmount:
      type: string
      description: |-
        Number of monetary units specified in a currency where the unit of currency is implied by the context and compliant with ISO 4217. The decimal separator is a dot.
        Note: a zero amount is considered a positive amount.
      maxLength: 19
      pattern: ^-?0*(([0-9]{0,5}\.[0-9]{1,13})|([0-9]{0,6}\.[0-9]{1,12})|([0-9]{0,7}\.[0-9]{1,11})|([0-9]{0,8}\.[0-9]{1,10})|([0-9]{0,9}\.[0-9]{1,9})|([0-9]{0,10}\.[0-9]{1,8})|([0-9]{0,11}\.[0-9]{1,7})|([0-9]{0,12}\.[0-9]{1,6})|([0-9]{0,13}\.[0-9]{1,5})|([0-9]{0,14}\.[0-9]{1,4})|([0-9]{0,15}\.[0-9]{1,3})|([0-9]{0,16}\.[0-9]{1,2})|([0-9]{0,17}\.[0-9]{1,1})0*|([0-9]{0,18}))$
    InstitutionRoleCode:
      type: string
      description: "> This attribute provides the role of the insitution.\n\r\n\r*`ITER_intermediary_inter_bank`-Intermediary inter bank\n\r\n\r*`ITRA_intermediary_intra_bank`-Intermediary intra bank\n\r\n\r*`ORIG_originator`-Originator\n\r\n\r*`BENF_beneficiary`-Beneficiary"
      enum:
      - ITER_intermediary_inter_bank
      - ITRA_intermediary_intra_bank
      - ORIG_originator
      - BENF_beneficiary
    Market1Code:
      type: string
      description: "> Specifies the business market.\r\n\r\n
        *`PMTS_payments`-Specifies the payments market.\r\n\r\n
        *`TRFN_trade_finance`-Specifies the trade finance market.\r\n\r\n
        *`TREA_treasury`-Specifies the treasury market."
      enum:
      - PMTS_payments
      - TRFN_trade_finance
      - TREA_treasury
    Max15NumericText:
      type: string
      description: Specifies a numeric string with a maximum length of 15 digits.
      pattern: ^[0-9]{1,15}$
    Max256Text:
      type: string
      description: Specifies a character string with a maximum length of 256 characters.
      minLength: 1
      maxLength: 256
    Max35Text:
      type: string
      description: Specifies a character string with a maximum length of 35 characters.
      minLength: 1
      maxLength: 35
    Max4Text:
      type: string
      description: Specifies a character string with a maximum length of 4 characters.
      minLength: 1
      maxLength: 4
    Max40Text:
      type: string
      description: Specifies a character string with a maximum length of 40 characters.
      maxLength: 40
    Max150Text:
      type: string
      description: Specifies a character string with a maximum length of 150 characters.
      maxLength: 150
    MessageType1Choice:
      type: object
      description: Specifies the MessageDefinition in different types of format.
      additionalProperties: false
      properties:
        code:
          #  Message Type (MT), in coded form.
          $ref: '#/components/schemas/Min3Max4Text'
        proprietary:
          #  Contains a proprietary identification of a Message Definition.
          $ref: '#/components/schemas/Max35Text'
      example:
        code: '103'
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    Min3Max4Text:
      type: string
      description: Specifies a character string with a minimum length of 3 characters, and a maximum length of4 characters.
      minLength: 3
      maxLength: 4
    PaginationLinks:
      type: object
      description: Links to help to find the self, next, previous, first and last pages of the response
      properties:
        self:
          description: The URI to the current page in the response
          type: string
        next:
          description: The URI to the next page of response data
          type: string
        previous:
          description: The URI to the previous page of response data
          type: string
        first:
          description: The URI to the first page in the response
          type: string
        last:
          description: The URI to the last page in the response
          type: string
    PartyDetails1:
      type: object
      description: Specifies a party through a number of properties of that party.
      additionalProperties: false
      properties:
        id:
          #  Identification of the party.
          $ref: '#/components/schemas/PartyIdentification180Choice'
        country:
          #  Country of the party.
          $ref: '#/components/schemas/CountryIdentification2Choice'
        region:
          #  Specifies the region of the institution.
          $ref: '#/components/schemas/Region1Choice'
      example:
        id:
          any_bic: ABNANL2A
        country:
          code: US
        region:
          proprietary:
            code: OTHR_other
      required:
      - id
      - country
    PartyDetails2:
      type: object
      description: Specifies a party through a number of properties of that party.
      additionalProperties: false
      properties:
        id:
          #  Identification of the party.
          $ref: '#/components/schemas/PartyIdentification180Choice'
        country:
          #  Country of the party.
          $ref: '#/components/schemas/CountryIdentification2Choice'
        region:
          #  Specifies the region of the institution.
          $ref: '#/components/schemas/Region1Choice'
      example:
        id:
          any_bic: ABNANL2A
        country:
          proprietary:
           code: GIMI_global_imi
        region:
          proprietary:
            code: OTHR_other
      required:
      - id
      - country
    PartyIdentification180Choice:
      type: object
      description: Identification of a party using a BIC, a proprietary structure or another structure.
      additionalProperties: false
      properties:
        any_bic:
          #  Code allocated to a financial or non-financial institution by the ISO 9362 Registration Authority, as described in ISO 9362 "Banking - Banking telecommunication messages - Business identifier code (BIC)".
          $ref: '#/components/schemas/AnyBICDec2014Identifier'
        proprietary:
          #  Unique and unambiguous identifier, as assigned to a financial institution using a proprietary identification scheme.
          $ref: '#/components/schemas/Max35Text'
      example:
        any_bic: ABNANL2A
      oneOf:
      - required:
        - any_bic
      - required:
        - proprietary
    PaymentData1:
      type: object
      additionalProperties: false
      properties:
        banking_data:
          $ref: '#/components/schemas/BankingData4'
        payment_data:
          $ref: '#/components/schemas/PaymentData2'
      required:
      - banking_data
      - payment_data
    PaymentData2:
      type: object
      description: This is the information pertaining to the Payment data service.
      additionalProperties: false
      properties:
        my_role:
          #  This attribute provides the role of the insitution.
          $ref: '#/components/schemas/InstitutionRoleCode'
        counter_party_role:
          $ref: '#/components/schemas/InstitutionRoleCode'
        charge_detail:
          $ref: '#/components/schemas/ChargeBearerType3Code'
        instructed_currency:
          $ref: '#/components/schemas/ActiveOrHistoricCurrencyCode'
        initial_ordering_country:
          $ref: '#/components/schemas/CountryIdentification2Choice'
        corrected_initial_ordering_country:
          $ref: '#/components/schemas/CountryIdentification2Choice'
        initial_ordering_bic8:
          $ref: '#/components/schemas/PartyIdentification180Choice'
        corrected_initial_ordering_bic8:
          $ref: '#/components/schemas/PartyIdentification180Choice'
        initial_ordering_country_option:
          $ref: '#/components/schemas/ElementState4Code'
        ultimate_beneficiary_country:
          $ref: '#/components/schemas/CountryIdentification2Choice'
        corrected_ultimate_beneficiary_country:
          $ref: '#/components/schemas/CountryIdentification2Choice'
        ultimate_beneficiary_bic8:
          $ref: '#/components/schemas/PartyIdentification180Choice'
        corrected_ultimate_beneficiary_bic8:
          $ref: '#/components/schemas/PartyIdentification180Choice'
        ultimate_beneficiary_country_option:
          $ref: '#/components/schemas/ElementState4Code'
        standard_value_bucket_eur:
          $ref: '#/components/schemas/ValueBucketCode'
        standard_value_bucket_usd:
          $ref: '#/components/schemas/ValueBucketCode'
      required:
      - standard_value_bucket_eur
      - standard_value_bucket_usd
    PaymentResponse1:
      type: object
      additionalProperties: false
      properties:
        payment_data:
          type: array
          items:
            $ref: '#/components/schemas/PaymentData1'
        links:
          $ref: '#/components/schemas/PaginationLinks'
      required:
      - payment_data
    ProprietaryCountryInformation1:
      type: object
      description: Identifies a country in a proprietary way.
      additionalProperties: false
      properties:
        code:
          #  Specifies the country in a proprietary, coded format.
          $ref: '#/components/schemas/ProprietaryGeoRegionInformation1Code'
        legacy:
          #  Specifies the country in a legacy proprietary format.
          $ref: '#/components/schemas/Max4Text'
      example:
        code: GIMI_global_imi
      oneOf:
      - required:
        - code
      - required:
        - legacy
    ProprietaryCurrency1Code:
      type: string
      description: |-
        > Specifies a currency in a proprietary, coded form.
        *`NCFD_no_currency_and_value_found`-No currency and value found during recon.
        *`NTAV_not_available`-Information is not available.
        *`OTHR_other`-Other than an ISO 4217 currency code.
      enum:
      - NCFD_no_currency_and_value_found
      - NTAV_not_available
      - OTHR_other
    ProprietaryCurrencyInformation1:
      type: object
      description: Identifies a currency in a proprietary way.
      additionalProperties: false
      properties:
        code:
          #  Specifies information about a currency in a proprietary, coded format.
          $ref: '#/components/schemas/ProprietaryCurrency1Code'
        legacy:
          #  Specifies information about a currency in a legacy proprietary format.
          $ref: '#/components/schemas/Max4Text'
      example:
        code: NCFD_no_currency_and_value_found
      oneOf:
      - required:
        - code
      - required:
        - legacy
    ProprietaryGeoRegionInformation1:
      type: object
      description: Specifies the geographical region in a proprietary format, using a code or a legacy structure.
      additionalProperties: false
      properties:
        code:
          #  Contains proprietary coded information about the region in case no region code is available.
          $ref: '#/components/schemas/ProprietaryGeoRegionInformation2Code'
        legacy:
          #  Contains proprietary coded information about the region in a legacy format, in case no region code is available.
          $ref: '#/components/schemas/Max35Text'
      oneOf:
      - required:
        - code
      - required:
        - legacy
    ProprietaryGeoRegionInformation1Code:
      type: string
      description: |-
        > Contains information about a country or geographical region in a proprietary, coded form.
        *`EPTY_empty`-Empty element.
        *`FREE_free_format`-Free format.
        *`GIMI_global_imi`-Global IMI
        *`INTI_international_instrument`-International Instrument.
        *`NOTA_not_available`-Not available.
        *`SWFT_swift`-SWIFT
        *`TGT2_target2`-Target 2
        *`TCKS_ticker_symbol`-Ticker Symbol
      enum:
      - EPTY_empty
      - FREE_free_format
      - GIMI_global_imi
      - INTI_international_instrument
      - NOTA_not_available
      - SWFT_swift
      - TGT2_target2
      - TCKS_ticker_symbol
    ProprietaryGeoRegionInformation2Code:
      type: string
      description: |-
        > Contains information about a country or geographical region in a proprietary, coded form.
        *`IMIR_imi_and_related_copies`-IMI and related copies.
        *`NOTA_not_available`-Not available.
        *`OTHR_other`-Other.
        *`SWFT_swift`-SWIFT
      enum:
      - IMIR_imi_and_related_copies
      - NOTA_not_available
      - OTHR_other
      - SWFT_swift
    Region1Choice:
      type: object
      description: Specifies the region in various ways.
      additionalProperties: false
      properties:
        code:
          #  Specifies the region, in coded form.
          $ref: '#/components/schemas/Region1Code'
        proprietary:
          #  Contains information about the region in case no region code is available.
          $ref: '#/components/schemas/ProprietaryGeoRegionInformation1'
      oneOf:
      - required:
        - code
      - required:
        - proprietary
    Region1Code:
      type: string
      description: |-
        > Specifies the geographical region, in coded form.
        *`AFRC_africa`-African region.
        *`APAC_asia_pacific`-Asia-Pacific region.
        *`CLAM_central_and_latin_america`-Central and Latin-American region.
        *`EURO_euro_zone`-Region of European countries that use the Euro currency.
        *`MDEA_middle_east`-Middle eastern region.
        *`NEUR_non_euro_zone`-Region of European countries that don't use the Euro currency.
        *`NOAM_north_america`-North American region.
      enum:
      - AFRC_africa
      - APAC_asia_pacific
      - CLAM_central_and_latin_america
      - EURO_euro_zone
      - MDEA_middle_east
      - NEUR_non_euro_zone
      - NOAM_north_america
    TotalsData:
      type: object
      additionalProperties: false
      properties:
        transactions:
          description: This metric represents the total number of FIN messages of your institution.
          type: integer
        total_swift_transactions:
          description: This metric represents the total number of FIN messages of the SWIFT community (all SWIFT customers).
          type: integer
        activity_share_transactions:
          description: This metric represents your activity share in terms of number of messages. The activity share is the ratio of the number of messages of your institution vs the total number of messages of the SWIFT community.
          type: number
        converted_amount:
          # This metric represents the total value of the messages of your institution.
          $ref: '#/components/schemas/ImpliedCurrencyAndAmount'
        total_swift_converted_amount:
          # This metric represents the total value of the messages of of the SWIFT community (all SWIFT customers).
          $ref: '#/components/schemas/ImpliedCurrencyAndAmount'
        activity_share_converted_amount:
          # This metric represents your activity share in terms of value of messages. The activity share is the ratio of the total amount in messages of your institution vs the total amount in messages of the SWIFT community.
          type: number
    TradeData17:
      type: object
      additionalProperties: false
      properties:
        banking_data:
          $ref: '#/components/schemas/BankingData3'
        trade_data:
          $ref: '#/components/schemas/TradeData18'
      required:
      - banking_data
      - trade_data
    TradeData18:
      type: object
      additionalProperties: false
      properties:
        applicant_bank_bic8:
          $ref: '#/components/schemas/PartyIdentification180Choice'
        confirmation_instructions:
          $ref: '#/components/schemas/ConfirmationInstructionsCode'
        credit_available:
          $ref: '#/components/schemas/CreditAvailableCode'
        credit_type:
          $ref: '#/components/schemas/CreditTypeCode'
        lc_duration_bucket:
          $ref: '#/components/schemas/DurationBucketCode'
        standard_value_bucket_eur:
          $ref: '#/components/schemas/ValueBucketCode'
        standard_value_bucket_usd:
          $ref: '#/components/schemas/ValueBucketCode'
      example:
        applicant_bank_bic8:
          any_bic: ABNANL2A
        standard_value_bucket_eur: VB01_from_0_to_500
        standard_value_bucket_usd: VB02_from_500_to_2500
      required:
      - standard_value_bucket_eur
      - standard_value_bucket_usd
    TradeResponse1:
      type: object
      properties:
        trade_data:
            type: array
            items:
              $ref: '#/components/schemas/TradeData17'
        links:
            $ref: '#/components/schemas/PaginationLinks'
      required:
        - trade_data
    TreasuryData1:
      type: object
      additionalProperties: false
      properties:
        banking_data:
          $ref: '#/components/schemas/BankingData2'
        treasury_data:
          $ref: '#/components/schemas/TreasuryData2'
      required:
      - banking_data
      - treasury_data
    TreasuryData2:
      type: object
      additionalProperties: false
      properties:
        currency_bought:
          $ref: '#/components/schemas/ActiveOrHistoricCurrencyCode'
        currency_sold:
          $ref: '#/components/schemas/ActiveOrHistoricCurrencyCode'
        amount_bought_sent:
          $ref: '#/components/schemas/CurrencyAndAmount5'
        amount_bought_received:
          $ref: '#/components/schemas/CurrencyAndAmount5'
        amount_sold_sent:
          $ref: '#/components/schemas/CurrencyAndAmount5'
        amount_sold_received:
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_bought_sent:
          #  'The total value sent by the SWIFT community in a specific country, region, or the global figure, in relation to the SWIFT community message volume, for all currencies that were bought (field 32B). Available for MT 300, MT 304, MT 305, MT 306, MT 320. '
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_bought_received:
          #  The total value received by the SWIFT community in a specific country, region, or the global figure, in relation to the SWIFT community message volume, for all currencies that were bought (field 32B). Available for MT 300, MT 304, MT 305, MT 306, MT 320.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_sold_sent:
          #  'The total value sent by the SWIFT community in a specific country, region, or the global figure, in relation to the SWIFT community message volume, for all currencies that were sold (field 33B). Available for MT 300, MT 304, MT 305, MT 306, MT 320. '
          $ref: '#/components/schemas/CurrencyAndAmount5'
        total_swift_amount_sold_received:
          #  The total value received by the SWIFT community in a specific country, region, or the global figure, in relation to the SWIFT community message volume, for all currencies that were sold (field 33B). Available for MT 300, MT 304, MT 305, MT 306, MT 320.
          $ref: '#/components/schemas/CurrencyAndAmount5'
        instrument_type:
          $ref: '#/components/schemas/TreasuryInstrumentTypeCode'
        non_deliverable_indicator:
          $ref: '#/components/schemas/YesNoIndicator'
        function:
          $ref: '#/components/schemas/TreasuryMessageFunctionCode'
        sub_function:
          $ref: '#/components/schemas/TreasuryMessageSubFunctionCode'
        trade_date:
          $ref: '#/components/schemas/ISODate'
        value_date:
          $ref: '#/components/schemas/ISODate'
        standard_value_bucket_eur:
          $ref: '#/components/schemas/ValueBucketCode'
        standard_value_bucket_usd:
          $ref: '#/components/schemas/ValueBucketCode'
      required:
      - standard_value_bucket_eur
      - standard_value_bucket_usd
    TreasuryInstrumentTypeCode:
      type: string
      description: "> Identifies the actual FX instrument (SPOT, FORWARD, SWAP…) confirmed by the MT 300 as derived from Fields 22U, 17F, 17O, 22W, 30T, 30V\r\n\r\n
        *`FXFD_foreign_exchange_forward`-Foreign exchange forward\r\n\r\n
        *`FXNDFOO_foreign_exchange_non_deliverable_forward_open`-Foreign exchange non deliverable forward open\r\n\r\n
        *`FXNDFOC_foreign_exchange_non_deliverable_forward_close`-Foreign exchange non deliverable forward close\r\n\r\n
        *`FXSP_foreign_exchange_spot`-Foreign exchange spot\r\n\r\n
        *`FXSWAPC_foreign_exchange_swap_close`-Foreign exchange swap close\r\n\r\n
        *`FXSWAPO_foreign_exchange_swap_open`-Foreign exchange swap open"
      enum:
      - FXFD_foreign_exchange_forward
      - FXNDFOO_foreign_exchange_non_deliverable_forward_open
      - FXNDFOC_foreign_exchange_non_deliverable_forward_close
      - FXSP_foreign_exchange_spot
      - FXSWAPC_foreign_exchange_swap_close
      - FXSWAPO_foreign_exchange_swap_open
    TreasuryMessageFunctionCode:
      type: string
      description: "> The function of the treasury message, available in field 22A, could be either of the following:\r\n- Amendment\r\n- Cancellation\r\n- Option exercise\r\n- New contract\r\n- New confirmation/Advice/Instruction\r\n- Not available\r\nAvailable for MT 300, MT 304, MT 305, MT 306 and MT 320.\r\n\r\n*`AMND_amendment`-Amendment\r\n\r\n*`AVRF_average_rate_forward`-Average rate forward\r\n\r\n*`CAMN_copy_amendment`-Copy amendment\r\n\r\n*`CANC_cancellation`-Cancellation\r\n\r\n*`CCAN_copy_cancellation`-Copy cancellation\r\n\r\n*`CLOS_close_out`-Close out\r\n\r\n*`CNEW_copy_new`-Copy new\r\n\r\n*`DAVF_double_average_forward`-Double average forward\r\n\r\n*`DUPL_duplicate`-Duplicate\r\n\r\n*`EXOP_option_exercise`-Option exercise\r\n\r\n*`NEW_new_contract`-New contract\r\n\r\n*`NEWT_new_confirmation_advise_instruction`-New confirmation advise instruction"
      enum:
      - AMND_amendment
      - AVRF_average_rate_forward
      - CAMN_copy_amendment
      - CANC_cancellation
      - CCAN_copy_cancellation
      - CLOS_close_out
      - CNEW_copy_new
      - DAVF_double_average_forward
      - DUPL_duplicate
      - EXOP_option_exercise
      - NEW_new_contract
      - NEWT_new_confirmation_advise_instruction
    TreasuryMessageSubFunctionCode:
      type: string
      description: "> The sub function of the treasury message, available in field 22U for MT 300 and MT 305 and field 94A for MT 304, could be either of the following:\r\n- Foreign Exchange Forward\r\n- Foreign Exchange Spot\r\n- Foreign Exchange Swap\r\n- Foreign Exchange Non Deliverable Forward\r\n- Settlement Contract\r\n- Non-Deliverable Forward\r\n- Forward Currency Contract or Hedge\r\n- Not available\r\n\r\n*`AFWD_forward_currency_contract_or_hedge`-Forward currency contract or hedge\r\n\r\n*`ANDF_non_deliverable_forward`-Non deliverable forward\r\n\r\n*`ASET_settlement_contract`-Settlement contract\r\n\r\n*`FXFORW_foreign_exchange_forward`-Foreign exchange forward\r\n\r\n*`FXNDFO_foreign_exchange_non_deliverable_forward`-Foreign exchange non deliverable forward\r\n\r\n*`FXNDOP_foreign_exchange_non_deliverable_option`-Foreign exchange non deliverable option\r\n\r\n*`FXSPOT_foreign_exchange_spot`-Foreign exchange spot\r\n\r\n*`FXSWAP_foreign_exchange_swap`-Foreign exchange swap\r\n\r\n*`FXVAOP_foreign_exchange_vanilla_option`-Foreign exchange vanilla option\r\n\r\n*`FWSWAP_customer_defined_value1`-Customer defined value1\r\n\r\n*`FXNDO_customer_defined_value2`-Customer defined value2\r\n\r\n*`FXOPT_customer_defined_value3`-Customer defined value3\r\n\r\n*`FXSTD_customer_defined_value4`-Customer defined value4\r\n\r\n*`FX_customer_defined_value5`-Customer defined value5\r\n\r\n*`FXV_customer_defined_value6`-Customer defined value6"
      enum:
      - AFWD_forward_currency_contract_or_hedge
      - ANDF_non_deliverable_forward
      - ASET_settlement_contract
      - FXFORW_foreign_exchange_forward
      - FXNDFO_foreign_exchange_non_deliverable_forward
      - FXNDOP_foreign_exchange_non_deliverable_option
      - FXSPOT_foreign_exchange_spot
      - FXSWAP_foreign_exchange_swap
      - FXVAOP_foreign_exchange_vanilla_option
      - FWSWAP_customer_defined_value1
      - FXNDO_customer_defined_value2
      - FXOPT_customer_defined_value3
      - FXSTD_customer_defined_value4
      - FX_customer_defined_value5
      - FXV_customer_defined_value6
    TreasuryResponse1:
      type: object
      properties:
        treasury_data:
          type: array
          items:
            $ref: '#/components/schemas/TreasuryData1'
        links:
          $ref: '#/components/schemas/PaginationLinks'
      required:
      - treasury_data
    ValueBucketCode:
      type: string
      description: "> \n*`VB01_from_0_to_500`-Value bucket from 0 to 500\r\n\r\n*`VB02_from_500_to_2500`-Value bucket from 500 to 2500\r\n\r\n*`VB03_from_2500_to_10k`-Value bucket from 2500 to 10K\r\n\r\n*`VB04_from_10k_to_25k`-Value bucket from 10K to 25K\r\n\r\n*`VB05_from_25k_to_50k`-Value bucket from 25K to 50K\r\n\r\n*`VB06_from_50k_to_100k`-Value bucket from 50k to 100k\r\n\r\n*`VB07_from_100k_to_500k`-Value bucket from 100K to 500K\r\n\r\n*`VB08_from_500k_to_1m`-Value bucket from 500K to 1M\r\n\r\n*`VB09_from_1m_to_10m`-Value bucket from 1M to 10M\r\n\r\n*`VB10_from_10m_to_50m`-Value bucket from 10M to 50M\r\n\r\n*`VB11_from_50m_and_greater`-Value bucket from 50M and greater"
      enum:
      - VB01_from_0_to_500
      - VB02_from_500_to_2500
      - VB03_from_2500_to_10k
      - VB04_from_10k_to_25k
      - VB05_from_25k_to_50k
      - VB06_from_50k_to_100k
      - VB07_from_100k_to_500k
      - VB08_from_500k_to_1m
      - VB09_from_1m_to_10m
      - VB10_from_10m_to_50m
      - VB11_from_50m_and_greater
    YesOrNoFlag:
      type: string
      description: |-
        > Yes/No flag.
      enum:
      - Y
      - N
    YesNoIndicator:
      type: boolean
      description: Indicates a true or false type of answer for an element.
    ErrorMessage:
      required:
      - "code"
      - "severity"
      - "text"
      type: "object"
      properties:
        severity:
          type: "string"
          enum:
          - "Fatal"
          - "Transient"
          - "Logic"
        code:
          type: "string"
        text:
          type: "string"
        user_message:
          type: "string"
        more_info:
          type: "string"
          format: "uri"      
  ## HEADERS ##
  headers:
    X-Response-Timestamp:
      description: Timestamp at which the operation was processed.
      schema:
        type: string
        format: date-time
    X-Request-ID:
      description: "Specify an unique end to end tracking request ID. The element will be populated by the SWIFT API gateway"
      schema:
        type: string
  ## EXAMPLES ##
  examples:
    Market_PMTS_Period_2019-07-01_Limit_25_Offset_0:
      value:
        payment_data:
          - banking_data:
              market: PMTS_payments
              reporting_period: "2019-07-01"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier: "103"
              message_definition_group: "MT102/MT103/pacs.008"
              iso20022_flag: "N"
              service: "n/a"
              my_institution:
                id:
                  any_bic: DEMOUS01
                country:
                  code: US
                region:
                  code: NOAM_north_america
              counterparty:
                id:
                  any_bic: DEMOGB01
                country:
                  code: GB
                region:
                  code: NEUR_non_euro_zone
              geo_route:
                code: INTL_international
              customer_route:
                code: ITER_inter_customer_group
              transactions_sent: '3021'
              transactions_received: '936'
              total_swift_transactions_sent: '1412471'
              total_swift_transactions_received: '922012'
              currency:
                code: EUR
              amount_sent:
                original: '20458210.12'
                us_dollar: '22504031.13'
                euro: '20458210.12'
              amount_received:
                original: '31762211.04'
                us_dollar: '34938432.14'
                euro: '31762211.04'
              total_swift_amount_sent:
                original: '3249744217'
                us_dollar: '3574718639'
                euro: '3249744217'
              total_swift_amount_received:
                original: '4122594413'
                us_dollar: '4534853854'
                euro: '4122594413'
            payment_data:
              my_role: ITER_intermediary_inter_bank
              counter_party_role: BENF_beneficiary
              charge_detail: CRED_borne_by_creditor
              instructed_currency: USD
              initial_ordering_country:
                code: BE
              corrected_initial_ordering_country:
                code: BE
              initial_ordering_bic8:
                any_bic: DEMOBE67
              corrected_initial_ordering_bic8:
                any_bic: DEMOBE67
              initial_ordering_country_option: OPTA_option_a
              ultimate_beneficiary_country:
                code: GB
              corrected_ultimate_beneficiary_country:
                code: GB
              ultimate_beneficiary_bic8:
                any_bic: DEMOGB33
              corrected_ultimate_beneficiary_bic8:
                any_bic: DEMOGB33
              ultimate_beneficiary_country_option: OPTA_option_a
              standard_value_bucket_eur: VB01_from_0_to_500
              standard_value_bucket_usd: VB02_from_500_to_2500
        links:
          self: "/payments?reporting_period=2019-07-01&limit=25&offset=0"
          next: "/payments?reporting_period=2019-07-01&limit=25&offset=25"
          first: "/payments?reporting_period=2019-07-01&limit=25&offset=0"
          last: "/payments?reporting_period=2019-07-01&limit=25&offset=36000"
    Market_PMTS_Period_2023-03-21_Limit_25_Offset_0:
      value:
        payment_data:
          - banking_data:
              market: PMTS_payments
              reporting_period: "2023-03-21"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier: "205"
              message_definition_group: "MT200/MT201/MT202/MT203/MT205/pacs.009"
              iso20022_flag: "N"
              service: "n/a"
              my_institution:
                id:
                  any_bic: DEMOZA02
                country:
                  code: ZA
                region:
                  code: AFRC_africa
              counterparty:
                id:
                  any_bic: DEMOJP01
                country:
                  code: JP
                region:
                  code: APAC_asia_pacific
              geo_route:
                code: INTL_international
              customer_route:
                code: ITER_inter_customer_group
              transactions_sent: '2930'
              transactions_received: '720'
              total_swift_transactions_sent: '1602934'
              total_swift_transactions_received: '782193'
              currency:
                code: EUR
              amount_sent:
                original: '18293041.92'
                us_dollar: '20122346.11'
                euro: '18293041.92'
              amount_received:
                original: '25766212.64'
                us_dollar: '28342833.9'
                euro: '25766212.64'
              total_swift_amount_sent:
                original: '444924418'
                us_dollar: '4894168530'
                euro: '4449244118'
              total_swift_amount_received:
                original: '4024524112'
                us_dollar: '4426976524'
                euro: '4024524112'
            payment_data:
              my_role: ORIG_originator
              counter_party_role: BENF_beneficiary
              initial_ordering_country:
                code: GB
              corrected_initial_ordering_country:
                code: GB
              initial_ordering_bic8:
                any_bic: DEMOZA02
              corrected_initial_ordering_bic8:
                any_bic: DEMOZA02
              initial_ordering_country_option: OPTA_option_a
              ultimate_beneficiary_country:
                code: JP
              corrected_ultimate_beneficiary_country:
                code: JP
              ultimate_beneficiary_bic8:
                any_bic: DEMOJP32
              corrected_ultimate_beneficiary_bic8:
                any_bic: DEMOJP32
              ultimate_beneficiary_country_option: OPTA_option_a
              standard_value_bucket_eur: VB04_from_10k_to_25k
              standard_value_bucket_usd: VB04_from_10k_to_25k
          - banking_data:
              market: PMTS_payments
              reporting_period: "2023-03-21"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier: "pacs.009"
              message_definition_group: "MT200/MT201/MT202/MT203/MT205/pacs.009"
              iso20022_flag: "Y"
              service: "swift.finplus"
              my_institution:
                id:
                  any_bic: DEMOZA02
                country:
                  code: ZA
                region:
                  code: AFRC_africa
              counterparty:
                id:
                  any_bic: DEMOJP01
                country:
                  code: JP
                region:
                  code: APAC_asia_pacific
              geo_route:
                code: INTL_international
              customer_route:
                code: ITER_inter_customer_group
              transactions_sent: '2930'
              transactions_received: '720'
              total_swift_transactions_sent: '1602934'
              total_swift_transactions_received: '782193'
              currency:
                code: EUR
              amount_sent:
                original: '18293041.92'
                us_dollar: '20122346.11'
                euro: '18293041.92'
              amount_received:
                original: '25766212.64'
                us_dollar: '28342833.9'
                euro: '25766212.64'
              total_swift_amount_sent:
                original: '444924418'
                us_dollar: '4894168530'
                euro: '4449244118'
              total_swift_amount_received:
                original: '4024524112'
                us_dollar: '4426976524'
                euro: '4024524112'
            payment_data:
              my_role: ORIG_originator
              counter_party_role: BENF_beneficiary
              initial_ordering_country:
                code: GB
              corrected_initial_ordering_country:
                code: GB
              initial_ordering_bic8:
                any_bic: DEMOZA02
              corrected_initial_ordering_bic8:
                any_bic: DEMOZA02
              initial_ordering_country_option: OPTA_option_a
              ultimate_beneficiary_country:
                code: JP
              corrected_ultimate_beneficiary_country:
                code: JP
              ultimate_beneficiary_bic8:
                any_bic: DEMOJP32
              corrected_ultimate_beneficiary_bic8:
                any_bic: DEMOJP32
              ultimate_beneficiary_country_option: OPTA_option_a
              standard_value_bucket_eur: VB04_from_10k_to_25k
              standard_value_bucket_usd: VB04_from_10k_to_25k

        links:
          self: "/payments?reporting_period=2023-03-21&limit=25&offset=0"
          next: "/payments?reporting_period=2023-03-21&limit=25&offset=25"
          first: "/payments?reporting_period=2023-03-21&limit=25&offset=0"
          last: "/payments?reporting_period=2023-03-21&limit=25&offset=36000"
    Market_TRFN_Period_2019-07-01_Limit_25_Offset_0:
      value:
        trade_data:
          - banking_data:
              market: TRFN_trade_finance
              reporting_period: "2019-07-01"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier:
                code: '799'
              my_institution:
                id:
                  any_bic: DEMOUS01
                country:
                  code: US
                region:
                  code: NOAM_north_america
              counterparty:
                id:
                  any_bic: DEMOGB01
                country:
                  code: GB
                region:
                  code: NEUR_non_euro_zone
              geo_route:
                code: INTL_international
              customer_route:
                code: ITRA_intra_customer_group
              transactions_sent: '9023'
              transactions_received: '8310'
              total_swift_transactions_sent: '92038'
              total_swift_transactions_received: '90022'
              currency:
                code: USD
              amount_sent:
                original: '21293841.12'
                us_dollar: '21293841.12'
                euro: '19358037.38'
              amount_received:
                original: '1923842.44'
                us_dollar: '1923842.44'
                euro: '1748947.673'
              total_swift_amount_sent:
                original: '92402193.11'
                us_dollar: '92402193.11'
                euro: '84001993.74'
              total_swift_amount_received:
                original: '77329299.01'
                us_dollar: '77329299.01'
                euro: '70299362.74'
            trade_data:
              applicant_bank_bic8:
                any_bic: 'DEMOGB01'
              standard_value_bucket_eur: VB01_from_0_to_500
              standard_value_bucket_usd: VB02_from_500_to_2500
        links:
          self: "/trade?reporting_period=2019-07-01&limit=25&offset=0"
          next: "/trade?reporting_period=2019-07-01&limit=25&offset=25"
          first: "/trade?reporting_period=2019-07-01&limit=25&offset=0"
          last: "/trade?reporting_period=2019-07-01&limit=25&offset=36000"
    Market_TRFN_Period_2019-01-05_Limit_25_Offset_0:
      value:
        trade_data:
          - banking_data:
              market: TRFN_trade_finance
              reporting_period: "2019-01-05"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier:
                code: '799'
              my_institution:
                id:
                  any_bic: DEMOUS01
                country:
                  code: US
                region:
                  code: NOAM_north_america
              counterparty:
                id:
                  any_bic: DEMOGB01
                country:
                  code: GB
                region:
                  code: NEUR_non_euro_zone
              geo_route:
                code: INTL_international
              customer_route:
                code: ITRA_intra_customer_group
              transactions_sent: '7029'
              transactions_received: '5023'
              total_swift_transactions_sent: '75892'
              total_swift_transactions_received: '90132'
              currency:
                code: USD
              amount_sent:
                original: '26394881.72'
                us_dollar: '26394881.72'
                euro: '23995347.02'
              amount_received:
                original: '2424842.33'
                us_dollar: '2424842.33'
                euro: '2204402.118'
              total_swift_amount_sent:
                original: '82802497.61'
                us_dollar: '82802497.61'
                euro: '75274997.83'
              total_swift_amount_received:
                original: '69324294.55'
                us_dollar: '69324294.55'
                euro: '63022085.95'
            trade_data:
              applicant_bank_bic8:
                any_bic: 'DEMOGB01'
              standard_value_bucket_eur: VB03_from_2500_to_10k
              standard_value_bucket_usd: VB03_from_2500_to_10k
        links:
          self: "/trade?reporting_period=2019-01-05&limit=25&offset=0"
          next: "/trade?reporting_period=2019-01-05&limit=25&offset=25"
          first: "/trade?reporting_period=2019-01-05&limit=25&offset=0"
          last: "/trade?reporting_period=2019-01-05&limit=25&offset=36000"
    Market_TREA_Period_2019-07-01_Limit_25_Offset_0:
      value:
        treasury_data:
          - banking_data:
              market: TREA_treasury
              reporting_period: "2019-07-01"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier:
                code: '300'
              my_institution:
                id:
                  any_bic: DEMOUS01
                country:
                  code: US
                region:
                  code: NOAM_north_america
              counterparty:
                id:
                  any_bic: DEMOGB01
                country:
                  code: GB
                region:
                  code: NEUR_non_euro_zone
              geo_route:
                code: INTL_international
              customer_route:
                code: ITRA_intra_customer_group
              transactions_sent: '5923'
              transactions_received: '3029'
              total_swift_transactions_sent: '39283'
              total_swift_transactions_received: '58823'
            treasury_data:
              currency_bought: GBP
              currency_sold: AUD
              amount_bought_sent:
                original: '256932'
                us_dollar: '341719.56'
                euro: '287044.4304'
              amount_bought_received:
                original: '645688'
                us_dollar: '858765.04'
                euro: '721362.6336'
              amount_sold_sent:
                original: '928563'
                us_dollar: '677850.99'
                euro: '569394.8316'
              amount_sold_received:
                original: '498567'
                us_dollar: '363953.91'
                euro: '305721.2844'
              total_swift_amount_bought_sent:
                original: '256932456'
                us_dollar: '341720166.5'
                euro: '287044939.8'
              total_swift_amount_bought_received:
                original: '64568845'
                us_dollar: '85876563.85'
                euro: '72136313.63'
              total_swift_amount_sold_sent:
                original: '928563234'
                us_dollar: '677851160.8'
                euro: '569394975.1'
              total_swift_amount_sold_received:
                original: '498567456'
                us_dollar: '363954242.9'
                euro: '305721564'
              instrument_type: FXFD_foreign_exchange_forward
              non_deliverable_indicator: true
              function: NEWT_new_confirmation_advise_instruction
              sub_function: AFWD_forward_currency_contract_or_hedge
              trade_date: "2020-04-22"
              value_date: "2020-04-22"
              standard_value_bucket_eur: VB01_from_0_to_500
              standard_value_bucket_usd: VB01_from_0_to_500
        links:
          self: "/treasury?reporting_period=2019-07-01&limit=25&offset=0"
          next: "/treasury?reporting_period=2019-07-01&limit=25&offset=25"
          first: "/treasury?reporting_period=2019-07-01&limit=25&offset=0"
          last: "/treasury?reporting_period=2019-07-01&limit=25&offset=36000"
    Market_TREA_Period_2019-01-05_Limit_25_Offset_0:
      value:
        treasury_data:
          - banking_data:
              market: TREA_treasury
              reporting_period: "2019-01-05"
              delivery_status:
                code: DLVR_delivered
              message_definition_identifier:
                code: '304'
              my_institution:
                id:
                  any_bic: DEMOUS01
                country:
                  code: US
                region:
                  code: NOAM_north_america
              counterparty:
                id:
                  any_bic: DEMOUS31
                country:
                  code: US
                region:
                  code: NOAM_north_america
              geo_route:
                code: DMST_domestic
              customer_route:
                code: ITRA_intra_customer_group
              transactions_sent: '930'
              transactions_received: '4063'
              total_swift_transactions_sent: '41110'
              total_swift_transactions_received: '57930'
            treasury_data:
              currency_bought: EUR
              currency_sold: USD
              amount_bought_sent:
                original: '345234'
                us_dollar: '407376.12'
                euro: '342195.9408'
              amount_bought_received:
                original: '457865'
                us_dollar: '608960.45'
                euro: '511526.778'
              amount_sold_sent:
                original: '701274'
                us_dollar: '701274'
                euro: '589070.16'
              amount_sold_received:
                original: '129054'
                us_dollar: '129054'
                euro: '108405.36'
              total_swift_amount_bought_sent:
                original: '345234784'
                us_dollar: '407377045.1'
                euro: '342196717.9'
              total_swift_amount_bought_received:
                original: '457865346'
                us_dollar: '608960910.2'
                euro: '511527164.6'
              total_swift_amount_sold_sent:
                original: '70127499'
                us_dollar: '70127499'
                euro: '58907099.16'
              total_swift_amount_sold_received:
                original: '129054999'
                us_dollar: '129054999'
                euro: '108406199.2'
              function: DUPL_duplicate
              sub_function: FXNDFO_foreign_exchange_non_deliverable_forward
              trade_date: "2020-08-23"
              value_date: "2020-08-30"
              standard_value_bucket_eur: VB01_from_0_to_500
              standard_value_bucket_usd: VB02_from_500_to_2500
        links:
          self: "/treasury?reporting_period=2019-01-05&limit=25&offset=0"
          next: "/treasury?reporting_period=2019-01-05&limit=25&offset=25"
          first: "/treasury?reporting_period=2019-01-05&limit=25&offset=0"
          last: "/treasury?reporting_period=2019-01-05&limit=25&offset=36000"
    2021-07-20_PMTS_DEMOUS01:  
      value:
        transactions: 10
        total_swift_transactions: 101
        activity_share_transactions: 10.1
        converted_amount: '5000'
        total_swift_converted_amount: '50000'
        activity_share_converted_amount: 10
    2023-03-21_PMTS_DEMOBE33:
      value:
        transactions: 444
        total_swift_transactions: 888
        activity_share_transactions: 50
        converted_amount: '10000'
        total_swift_converted_amount: '40000'
        activity_share_converted_amount: 25
    ## ERRORS #
    seeOther:
      value:
        code: "BI_303"
        severity: "Transient"
        text: "See Other"
        user_message: "Resource is too big to be returned as one response, the request should use limit and offset. (header Location indicates the url of the first page)."
    missingParameter:
      value:
        code: "SwAP501"
        severity: "Fatal"
        text: "APIRequestIsMalformed"
        user_message: "At least one (of the) required parameter(s) is missing. Add the missing required parameter(s) and try again"
    parameterInvalid:
      value:
        code: "BI_400"
        severity: "Fatal"
        text: "The 'reporting_period' parameter is invalid"
        user_message: " You have sent the value 'reporting_period' although the valid values are '2019-07-01', '2019-01-05', ..."
    bodyIsNotWellFormed:
      value:
        code: "SwAP504"
        severity: "Fatal"
        text: "RequestBodyIsNotWellFormed"
    headerNotIncluded:
      value:
        code: "SwAP521"
        severity: "Fatal"
        text: "HeaderNotIncluded"
        user_message: "Add 'headerName' to your request"
    xbicHeaderNotValid:
      value:
        code: "SwAP522"
        severity: "Fatal"
        text: "XBICHeaderNotValid"
    invalidOAuthToken:
      value:
        code: "SwAP502"
        severity: "Fatal"
        text: "InvalidOAuthToken"
    OAuthTokenHasInsufficentScopeForRequestedService:
      value:
        code: "SwAP503"
        severity: "Fatal"
        text: "OAuthTokenHasInsufficentScopeForRequestedService"
    OAuthTokenNotProvided:
      value:
        code: "SwAP508"
        severity: "Fatal"
        text: "OAuthTokenNotProvided"
    invalidContract:
      value:
        code: "BI_403"
        severity: "Fatal"
        text: "MissingContract"
        user_message: "You have not the right contract to access this API"
    notFound:
      value:
        severity: "Fatal"
        code: "SwAP506"
        text: "Resource does not exist."
    noAcceptableReturnType:
      value:
        code: "BI_406"
        severity: "Fatal"
        text: "NoReturnMediaTypePossible"
        user_message: "You have asked a response format that is not supported by the server. The supported response format is 'JSON'. Change your HTTP header accordingly"
    tooManyRequest:
      value:
        code: "SwAP507"
        severity: "Transient"
        text: "RequestCannotBeProcessedAtThisTime"
        user_message: "Request cannot be processed at this time. Please try later. (header Retry-After indicates how long to wait before making a follow-up request)."
    internalServerError:
      value:
        code: "SwAP599"
        severity: "Fatal"
        text: "UnexpectedError"
        user_message: "Server encountered an unexpected condition and cannot fulfill the request."
    badGateway:
      value:
        code: "SwAP008"
        severity: "Transient"
        text: "Invalid response received from Service Provider."
    unavailable:
      value:
        code: "SwAP590"
        severity: "Transient"
        text: "Service is temporary unavailable (header Retry-After indicates how long to wait before making a follow-up request)."
    timeOut:
      value:
        code: "SwAP591"
        severity: "Transient"
        text: "ServiceProvideTimeOut"
        user_message: "Service Provider time out."
    unexpectedError:
      value:
        code: "SwAP599"
        severity: "Fatal"
        text: "UnexpectedError"
        user_message: "Unexpected error occurs. Try again later and if the problem persists contact SWIFT support"