# Execute Mandate Debit

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /api/v0/upi-mandate/execute:
    post:
      summary: Execute Mandate Debit
      deprecated: false
      description: >-

        :::highlight purple 📌

        Use this API to initiate a debit against an active UPI mandate. This
        allows you to collect recurring payments—such as subscriptions, EMIs, or
        fees—securely and automatically from your customer’s UPI-linked account.

        :::
      tags:
        - Payment Gateway/APIs - Payment Gateway /UPI Autopay
      parameters:
        - name: merchantAccessKey
          in: header
          description: ''
          required: true
          example: ''
          schema:
            type: string
        - name: Authorization
          in: header
          description: ''
          required: true
          example: ''
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                mandateId:
                  type: string
                amount:
                  type: number
                remarks:
                  type: string
              x-apidog-orders:
                - mandateId
                - amount
                - remarks
              required:
                - mandateId
                - amount
                - remarks
              x-apidog-ignore-properties: []
            examples: {}
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApplicationResponseOrderGetResponse'
          headers: {}
          x-apidog-name: Success
      security: []
      x-apidog-folder: Payment Gateway/APIs - Payment Gateway /UPI Autopay
      x-apidog-status: released
      x-run-in-apidog: https://app.apidog.com/web/project/616243/apis/api-13814659-run
components:
  schemas:
    ApplicationResponseOrderGetResponse:
      type: object
      properties:
        response_code:
          type: integer
          format: int32
        response_message:
          type: string
        payload:
          $ref: '#/components/schemas/OrderGetResponse'
      x-apidog-orders:
        - response_code
        - response_message
        - payload
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
    OrderGetResponse:
      type: object
      properties:
        orderId:
          type: string
          description: The unique identifier for the order.
        created:
          type: string
          format: date-time
          description: The timestamp indicating when the order was created.
        lastModified:
          type: string
          format: date-time
          description: The timestamp indicating when the order was last modified.
        merchantOrderId:
          type: string
          description: The merchant-specific identifier for the order.
        merchantIdentifierKey:
          type: string
          description: The merchant's unique identifier key associated with the order.
        amount:
          type: number
          description: The total amount associated with the order.
        currency:
          type: string
          description: The currency in which the order amount is specified.
        returnUrl:
          type: string
          description: >-
            The URL to which the customer will be redirected after completing
            the payment.
        notifyUrl:
          type: string
          description: The URL where notifications regarding the order will be sent.
        status:
          type: string
          description: The current status of the order.
          enum:
            - CREATED
            - PAID
            - CANCELLED
            - ATTEMPTED
            - EXPIRED
          x-apidog-enum:
            - value: CREATED
              name: ''
              description: ''
            - value: PAID
              name: ''
              description: ''
            - value: CANCELLED
              name: ''
              description: ''
            - value: ATTEMPTED
              name: ''
              description: ''
            - value: EXPIRED
              name: ''
              description: ''
        customerInfo:
          type: object
          properties:
            firstName:
              type: string
              description: The first name of the customer. Accepts alphabetic characters.
            lastName:
              type: string
              description: The last name of the customer. Accepts alphabetic characters.
            address:
              type: object
              properties:
                streetName:
                  type: string
                city:
                  type: string
                state:
                  type: string
                country:
                  type: string
                zipcode:
                  type: string
              x-apidog-orders:
                - streetName
                - city
                - state
                - country
                - zipcode
              description: >
                The address of the customer. Accepts alphanumeric characters and
                special symbols.
              x-apidog-ignore-properties: []
            email:
              type: string
              description: >
                The email address of the customer. Must be in a valid email
                format.
            phoneNumber:
              type: string
              description: The phone number of the customer. Please exclude +91 ISD code.
            customerIpAddress:
              type: string
              description: The Ip address of the customer
          x-apidog-orders:
            - firstName
            - lastName
            - address
            - email
            - phoneNumber
            - customerIpAddress
          description: ' Information about the customer associated with the order. It typically includes details such as first name, last name, address, email, and phone number.'
          required:
            - customerIpAddress
          x-apidog-ignore-properties: []
        orderMessage:
          type: string
          description: Additional message or information related to the order.
        orderDate:
          type: string
          format: date-time
          description: The date when the order was placed.
        customParameters:
          type: array
          items:
            type: string
        transactions:
          type: array
          items:
            type: object
            x-apidog-refs:
              01KJDMMWF5PZ0B3XVE7KZBHCX4:
                $ref: '#/components/schemas/OrderTransactionResponse'
                x-apidog-overrides:
                  status: &ref_0
                    type: string
                    description: The current status of the transaction.
                    enum:
                      - CREATED
                      - PENDING_WITH_BANK
                      - SUCCESS
                      - FAILED
                      - CANCELLED
                      - CHECKOUT_RENDERED
                      - REFUNDED
                      - PARTIALLY_REFUNDED
                      - AUTHORIZED
                      - PROCESSING
                      - HOLD
                      - EXPIRED
                    x-apidog-enum:
                      - value: CREATED
                        name: ''
                        description: ''
                      - value: PENDING_WITH_BANK
                        name: ''
                        description: ''
                      - value: SUCCESS
                        name: ''
                        description: ''
                      - value: FAILED
                        name: ''
                        description: ''
                      - value: CANCELLED
                        name: ''
                        description: ''
                      - value: CHECKOUT_RENDERED
                        name: ''
                        description: ''
                      - value: REFUNDED
                        name: ''
                        description: ''
                      - value: PARTIALLY_REFUNDED
                        name: ''
                        description: ''
                      - value: AUTHORIZED
                        name: ''
                        description: ''
                      - value: PROCESSING
                        name: ''
                        description: ''
                      - value: HOLD
                        name: ''
                        description: ''
                      - value: EXPIRED
                        name: ''
                        description: ''
            x-apidog-orders:
              - 01KJDMMWF5PZ0B3XVE7KZBHCX4
            properties:
              transactionId: &ref_1
                type: string
                description: The unique identifier for the transaction.
              created: &ref_2
                type: string
                format: date-time
                description: The timestamp indicating when the transaction was created.
              lastModified: &ref_3
                type: string
                format: date-time
                description: >-
                  The timestamp indicating when the transaction was last
                  modified.
              type:
                type: string
                description: The type of transaction.
                enum: &ref_4
                  - SALE
                  - REFUND
                x-apidog-enum:
                  - value: SALE
                    name: ''
                    description: ''
                  - value: REFUND
                    name: ''
                    description: ''
              amount: &ref_5
                type: number
                description: The amount associated with the transaction.
              currency: &ref_6
                type: string
                description: The currency in which the transaction amount is specified.
              status: *ref_0
              paymentDetail: &ref_7
                $ref: '#/components/schemas/PaymentDetailResponse'
              bankResponse: &ref_8
                $ref: '#/components/schemas/BankResponseModel'
                description: Response from the bank for the transaction.
              txnMessage: &ref_9
                type: string
                description: Additional message or information related to the transaction.
              txnDate: &ref_10
                type: string
                format: date-time
                description: The date when the transaction was initiated.
              surcharge: &ref_11
                type: number
                description: The surcharge amount for the transaction.
              surchargeGst: &ref_12
                type: number
                description: GST applied on the surcharge amount.
              finalAmount: &ref_13
                type: number
                description: The final amount after considering surcharge and GST.
              txnMsg: &ref_14
                type: string
                description: Additional message or information related to the transaction.
              mdr: &ref_15
                type: number
                description: Merchant Discount Rate (MDR) applied on the transaction.
              mdrGst: &ref_16
                type: number
                description: GST applied on the Merchant Discount Rate (MDR).
              transactionAmount: &ref_17
                type: number
                description: The transaction amount.
            x-apidog-ignore-properties:
              - transactionId
              - created
              - lastModified
              - type
              - amount
              - currency
              - status
              - paymentDetail
              - bankResponse
              - txnMessage
              - txnDate
              - surcharge
              - surchargeGst
              - finalAmount
              - txnMsg
              - mdr
              - mdrGst
              - transactionAmount
          description: Details of transactions associated with the order.
        merchantName:
          type: string
        paymentDetail:
          type: object
          properties:
            accountNumber:
              type: string
              description: Required for UPI TPV flow for non seamless integration
              minLength: 9
              maxLength: 36
            ifsc:
              type: string
              description: Required for UPI TPV flow for non seamless integration
              minLength: 11
              examples:
                - KKBK0000432
              maxLength: 11
              pattern: ^[A-Z]{4}0[A-Z0-9]{6}$
          x-apidog-orders:
            - accountNumber
            - ifsc
          description: Payment related information for UPI TPV flow
          x-apidog-ignore-properties: []
      x-apidog-orders:
        - orderId
        - created
        - lastModified
        - merchantOrderId
        - merchantIdentifierKey
        - amount
        - currency
        - returnUrl
        - notifyUrl
        - status
        - customerInfo
        - orderMessage
        - orderDate
        - customParameters
        - transactions
        - merchantName
        - paymentDetail
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
    BankResponseModel:
      type: object
      properties:
        terminalID:
          type: string
        bankTransactionId:
          type: string
      x-apidog-orders:
        - terminalID
        - bankTransactionId
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
    PaymentDetailResponse:
      required:
        - paymentMode
      type: object
      properties:
        paymentMode:
          type: string
          enum:
            - NET_BANKING
            - UPI
            - CREDIT_CARD
            - DEBIT_CARD
            - PREPAID_CARD
            - PAY_LATER
            - WALLET
            - CORPORATE_CARD
            - UPI_CREDIT_CARD
          x-apidog-enum:
            - value: NET_BANKING
              name: ''
              description: ''
            - value: UPI
              name: ''
              description: ''
            - value: CREDIT_CARD
              name: ''
              description: ''
            - value: DEBIT_CARD
              name: ''
              description: ''
            - value: PREPAID_CARD
              name: ''
              description: ''
            - value: PAY_LATER
              name: ''
              description: ''
            - value: WALLET
              name: ''
              description: ''
            - value: CORPORATE_CARD
              name: ''
              description: ''
            - value: UPI_CREDIT_CARD
              name: ''
              description: ''
        cardHolderName:
          type: string
        cardNumber:
          type: string
        expiry:
          type: string
        cardType:
          type: string
          enum:
            - CREDIT_CARD
            - DEBIT_CARD
            - PREPAID_CARD
        cardSchemeType:
          type: string
          enum:
            - VISA
            - MASTERCARD
            - AMEX
            - DINERS
            - DISCOVER
            - JCB
            - MAESTRO
            - RUPAY
            - UNKNOWN
        bankCode:
          type: string
        bankName:
          type: string
        accountNumber:
          type: string
        ifsc:
          type: string
      x-apidog-orders:
        - paymentMode
        - cardHolderName
        - cardNumber
        - expiry
        - cardType
        - cardSchemeType
        - bankCode
        - bankName
        - accountNumber
        - ifsc
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
    OrderTransactionResponse:
      type: object
      properties:
        transactionId: *ref_1
        created: *ref_2
        lastModified: *ref_3
        type:
          type: string
          description: The type of transaction.
          enum: *ref_4
          x-apidog-enum:
            - value: SALE
              name: ''
              description: ''
            - value: REFUND
              name: ''
              description: ''
        amount: *ref_5
        currency: *ref_6
        status:
          type: string
          description: The current status of the transaction.
          enum:
            - CREATED
            - PENDING_WITH_BANK
            - SUCCESS
            - FAILED
            - CANCELLED
            - CHECKOUT_RENDERED
            - REFUNDED
            - PARTIALLY_REFUNDED
            - AUTHORIZED
            - PROCESSING
            - HOLD
          x-apidog-enum:
            - value: CREATED
              name: ''
              description: ''
            - value: PENDING_WITH_BANK
              name: ''
              description: ''
            - value: SUCCESS
              name: ''
              description: ''
            - value: FAILED
              name: ''
              description: ''
            - value: CANCELLED
              name: ''
              description: ''
            - value: CHECKOUT_RENDERED
              name: ''
              description: ''
            - value: REFUNDED
              name: ''
              description: ''
            - value: PARTIALLY_REFUNDED
              name: ''
              description: ''
            - value: AUTHORIZED
              name: ''
              description: ''
            - value: PROCESSING
              name: ''
              description: ''
            - value: HOLD
              name: ''
              description: ''
        paymentDetail: *ref_7
        bankResponse: *ref_8
        txnMessage: *ref_9
        txnDate: *ref_10
        surcharge: *ref_11
        surchargeGst: *ref_12
        finalAmount: *ref_13
        txnMsg: *ref_14
        mdr: *ref_15
        mdrGst: *ref_16
        transactionAmount: *ref_17
      x-apidog-orders:
        - transactionId
        - created
        - lastModified
        - type
        - amount
        - currency
        - status
        - paymentDetail
        - bankResponse
        - txnMessage
        - txnDate
        - surcharge
        - surchargeGst
        - finalAmount
        - txnMsg
        - mdr
        - mdrGst
        - transactionAmount
      x-apidog-ignore-properties: []
      x-apidog-folder: ''
  securitySchemes: {}
servers:
  - url: https://ekpayout-uat.enkash.in
    description: Testing Env
security: []

```
