openapi: 3.0.3
info:
  title: 'Blazonpay Payment APIs Documentation'
  description: 'API documentation for Blazon Payment Gateway Application'
  version: 1.0.0
servers:
  -
    url: 'https://blazonpay.com'
paths:
  /v1/payments/pay:
    post:
      summary: 'Receive Payment'
      operationId: receivePayment
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  redirect_url: 'https://checkout.montypay.com/auth/ZXlKMGVYQWlPaUpLVjFRaUxDSmhiR2NpT2lKU1V6STFOaUo5LmV5SnBZWFFpT2pFM01qRXhNRGc0TnpBc0ltcDBhU0k2SW1Zd016RmpNemd5TFRRek16WXRNVEZsWmkxaFlUUTNMVEl5WVRWbFkySmlNR1JsWlNJc0ltVjRjQ0k2TVRjeU1URXhNalEzTUgwLnZ6T2JmbGFJWDNqQ2tYOENVbk84WGUtTTVuQTJzQXFPeDFFRFFjLVI5SGF6Y1ltSzJySklYcEZCU29tVWw4WnJiZVZDczgxcFpWZjFWbGs0X2V1OVVJV0hJZDBQX2o4TGxIYnlDUElJVGZoNlpiMnp4WW9obDZUbXBUQkJOeWJWenh0QkVBdFFGblZtWW81SmVJN1IxQlhQYThob0g2UkM4dXpBUUFwZXFnamQ2TjIwZUR4VHhzc0k2aXJtdFd6X0JpbWV4OWxsQ0xjNkdLdndYSGlVX21pRHc3MVoxTVlPRmdWSm12bkFlZ0dlZVQzNHZyNEFtcVlkdk1TODJZc2QxSG9SaFZXc3J3OTI0YTBHRnRWQXZ1aDZXdGp1OU5Nck5VUDllZEU2S2cwa0EybGNoNDlueTVfWXBNZ0kwNmZIZUlXRFNlTDVaaFduWTkxVENQMThudFdGU016a3pNQ3ZSb3IyYkNDQUxudUtLaHRkTjd4cDBRUjVmSUd6cmxfQlBOeW9uVWhTYXdYdFVJMzJ1ekpINEVsbXZUWGJuaExQSVBSbk13S2lNSjNFaTk1azltc3lIQlhLWkJGMWNxSmNVdkVLMFBqQVBMbmxLR2R2Ym9zOHFnUWFzWTFQUTJpVmFuRzRtNmRRQXZvLXB3NkdvZ3ZsR09abmxwR1psbzBhbV9FZWVmRlh2QWU1dWlOX3Y3bzBJYllTdU9tX0lGRGtIVkV3M3JmSXdEWHhueGVhYUkyNDRoUTlyVm1TdWhBZDhKTUFBeXJLdGxMZGdQUDdyVy1aZG5xWDh4eGIwNWdZLWo5bTNrWUV4c3NIeWZmUVF5WnpVS0kwbXZtS25PZ1poLWRpVVBPZG1lendPNG5hX0F4NHZ1ejVoakVUZ1JnMFk0ajNGQU9wVEJz'
                properties:
                  redirect_url:
                    type: string
                    example: 'https://checkout.montypay.com/auth/ZXlKMGVYQWlPaUpLVjFRaUxDSmhiR2NpT2lKU1V6STFOaUo5LmV5SnBZWFFpT2pFM01qRXhNRGc0TnpBc0ltcDBhU0k2SW1Zd016RmpNemd5TFRRek16WXRNVEZsWmkxaFlUUTNMVEl5WVRWbFkySmlNR1JsWlNJc0ltVjRjQ0k2TVRjeU1URXhNalEzTUgwLnZ6T2JmbGFJWDNqQ2tYOENVbk84WGUtTTVuQTJzQXFPeDFFRFFjLVI5SGF6Y1ltSzJySklYcEZCU29tVWw4WnJiZVZDczgxcFpWZjFWbGs0X2V1OVVJV0hJZDBQX2o4TGxIYnlDUElJVGZoNlpiMnp4WW9obDZUbXBUQkJOeWJWenh0QkVBdFFGblZtWW81SmVJN1IxQlhQYThob0g2UkM4dXpBUUFwZXFnamQ2TjIwZUR4VHhzc0k2aXJtdFd6X0JpbWV4OWxsQ0xjNkdLdndYSGlVX21pRHc3MVoxTVlPRmdWSm12bkFlZ0dlZVQzNHZyNEFtcVlkdk1TODJZc2QxSG9SaFZXc3J3OTI0YTBHRnRWQXZ1aDZXdGp1OU5Nck5VUDllZEU2S2cwa0EybGNoNDlueTVfWXBNZ0kwNmZIZUlXRFNlTDVaaFduWTkxVENQMThudFdGU016a3pNQ3ZSb3IyYkNDQUxudUtLaHRkTjd4cDBRUjVmSUd6cmxfQlBOeW9uVWhTYXdYdFVJMzJ1ekpINEVsbXZUWGJuaExQSVBSbk13S2lNSjNFaTk1azltc3lIQlhLWkJGMWNxSmNVdkVLMFBqQVBMbmxLR2R2Ym9zOHFnUWFzWTFQUTJpVmFuRzRtNmRRQXZvLXB3NkdvZ3ZsR09abmxwR1psbzBhbV9FZWVmRlh2QWU1dWlOX3Y3bzBJYllTdU9tX0lGRGtIVkV3M3JmSXdEWHhueGVhYUkyNDRoUTlyVm1TdWhBZDhKTUFBeXJLdGxMZGdQUDdyVy1aZG5xWDh4eGIwNWdZLWo5bTNrWUV4c3NIeWZmUVF5WnpVS0kwbXZtS25PZ1poLWRpVVBPZG1lendPNG5hX0F4NHZ1ejVoakVUZ1JnMFk0ajNGQU9wVEJz'
      tags:
        - 'PAYMENTS OPERATIONS'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                customer_name:
                  type: string
                  description: optional
                  example: 'John Doe'
                customer_email:
                  type: string
                  description: ''
                  example: example@gmail.com
                description:
                  type: Alphanumeric
                  description: 'min: 2 max: 1024 [a-z A-Z 0-9 !"#$%&''()*+,./:;&@] Product name'
                  example: 'Very important gift'
                currency:
                  type: string
                  description: '3 characters [A-Z] ISO 4217 Ex ample: NGN'
                  example: iste
                txnID:
                  type: Alphanumeric
                  description: ''
                  example: FDFD687676M
                amount:
                  type: string
                  description: 'Greater then 0 [0-9] max: 255 Format depends on currency. Send Integer type value for currencies with zero-exponent.'
                  example: '3.00'
                success_url:
                  type: string
                  description: 'Valid URL max: 1024 URL to redirect the Customer in case of the successful payment'
                  example: 'https://example.domain.com/success'
                cancel_url:
                  type: string
                  description: 'optional Valid URL min: 0 max: 1024 URL to return Customer in case of a payment cancellation (“Close” button on the Checkout page).'
                  example: 'https://example.domain.com/cancel'
                req_token:
                  type: Boolean
                  description: optional
                  example: 'false'
              required:
                - customer_email
                - description
                - currency
                - txnID
                - amount
                - success_url
  /v1/get_trans_status/pay_id:
    post:
      summary: 'By Payment ID'
      operationId: byPaymentID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  payment_id: 2e11e454-484e-11ef-a2a5-7606dde8358e
                  date: '2024-07-22 17:16:48'
                  status: settled
                  order:
                    number: 193388DFZ80
                    amount: '2'
                    currency: NGN
                    description: 'Demo Payment'
                  customer:
                    name: 'Johne Doe'
                    email: example@gmail.com
                properties:
                  payment_id:
                    type: string
                    example: 2e11e454-484e-11ef-a2a5-7606dde8358e
                  date:
                    type: string
                    example: '2024-07-22 17:16:48'
                  status:
                    type: string
                    example: settled
                  order:
                    type: object
                    properties:
                      number:
                        type: string
                        example: 193388DFZ80
                      amount:
                        type: string
                        example: '2'
                      currency:
                        type: string
                        example: NGN
                      description:
                        type: string
                        example: 'Demo Payment'
                  customer:
                    type: object
                    properties:
                      name:
                        type: string
                        example: 'Johne Doe'
                      email:
                        type: string
                        example: example@gmail.com
      tags:
        - 'TRANSACTION STATUS'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                payment_id:
                  type: string
                  description: ''
                  example: e4cbdd80-4637-11ef-ad38-b6c034b4336d
                hash:
                  type: string
                  description: ''
                  example: 6f74819406c9bc2bb180690a749a6beba3b80c79
  /v1/get_trans_status/order_id:
    post:
      summary: 'By Order ID'
      operationId: byOrderID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  payment_id: 2e11e454-484e-11ef-a2a5-7606dde8358e
                  date: '2024-07-22 17:16:48'
                  status: settled
                  order:
                    number: 193388DFZ80
                    amount: '2'
                    currency: NGN
                    description: 'Demo Payment'
                  customer:
                    name: 'Johne Doe'
                    email: example@gmail.com
                properties:
                  payment_id:
                    type: string
                    example: 2e11e454-484e-11ef-a2a5-7606dde8358e
                  date:
                    type: string
                    example: '2024-07-22 17:16:48'
                  status:
                    type: string
                    example: settled
                  order:
                    type: object
                    properties:
                      number:
                        type: string
                        example: 193388DFZ80
                      amount:
                        type: string
                        example: '2'
                      currency:
                        type: string
                        example: NGN
                      description:
                        type: string
                        example: 'Demo Payment'
                  customer:
                    type: object
                    properties:
                      name:
                        type: string
                        example: 'Johne Doe'
                      email:
                        type: string
                        example: example@gmail.com
      tags:
        - 'TRANSACTION STATUS'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                order_id:
                  type: string
                  description: ''
                  example: 63c781cc-de3d-11eb-a1f1-0242ac130006
                hash:
                  type: string
                  description: ''
                  example: 6f74819406c9bc2bb180690a749a6beba3b80c79
tags:
  -
    name: 'PAYMENTS OPERATIONS'
    description: ''
  -
    name: 'TRANSACTION STATUS'
    description: ''
components:
  securitySchemes:
    default:
      type: http
      scheme: bearer
      description: 'You can retrieve your token by login into your admin area, click on the Setting Main menu, then click on <b>API Key</b>.'
security:
  -
    default: []

