This guide covers how to manage subscriptions after creation — including checking mandate status, managing recurring payments, modifying or cancelling mandates, and viewing payment history.This version features automatic recurring payments. Once a mandate is active, the payment gateway automatically processes recurring debits and sends webhook notifications with the subscription ID for each payment.
Check Mandate Status
Verify that the mandate is active before proceeding
Automatic Payments
Recurring payments processed automatically
Modify or Cancel
Update mandate amount/end date or cancel
Adhoc Payment
Trigger a recurring payment for ADHOC subscriptions
View Payments
Fetch all payments associated with a subscription
Sandbox Testing
Simulate payments and fetch PG payments in sandbox
Check Mandate Status
After the customer approves the UPI mandate, use the Get Subscription Mandate Status API to verify that it is active.Sample Request
Response
mandate_is_active is true.
Subscription Status Values
A subscription can have the following statuses:| Status | Description |
|---|---|
PENDING | Subscription created but mandate not yet approved by customer |
ACTIVE | Subscription mandate is active and recurring payments will be processed automatically |
PAUSED | Subscription temporarily paused, no recurring payments will be processed |
CANCELLED | Subscription mandate cancelled, no further payments will be processed |
EXPIRED | Subscription reached its end date |
FAILED | Subscription mandate creation or activation failed |
Active Subscriptions: Only subscriptions with
ACTIVE status will have automatic recurring payments processed. Monitor the subscription status via webhooks to track lifecycle changes.Automatic Recurring Payments
The recurring payments are processed automatically by the payment gateway based on the billing cycle defined in the standing instruction. You don’t need to manually trigger recurring payments via API.
standing_instruction block.
How Automatic Payments Work
- Mandate Activation: After the customer approves the mandate, it becomes active
- Scheduled Debit: On each billing date, the payment gateway automatically debits the specified amount
- Webhook Notification: Upon successful payment, you’ll receive a webhook notification with the payment details
Monitoring Recurring Payments
You can monitor recurring payments through:- Webhooks: Real-time notifications for each successful/failed payment
- Payment API: Use the Get Payment endpoint to fetch payment details
- Order API: Use the Get Order endpoint to check order status
- Subscription Payments API: Use the Get Subscription Payments endpoint to list all payments for a subscription
- Subscription Status Webhook: Receive updates about subscription lifecycle events
Modify or Cancel Mandate
Production Only: Cancel mandate and modify mandate operations are only supported in production environment. These features are not available in test/sandbox environments.
Modify Mandate
To change the billing amount or end date of an active subscription, use the Modify Subscription Mandate API.Sample Request
Response
At least one of
amount or end_date must be provided to modify the mandate.Cancel Mandate
To fully stop future debits and revoke the subscription mandate, use the Cancel Subscription Mandate API.Sample Request
Response
CANCELLED on success.
Trigger Adhoc Recurring Payment
For ADHOC subscriptions, recurring payments are not automatic — you must trigger each charge via the Trigger Recurring Payment API. The subscription must have an active mandate before a payment can be triggered.This step applies only to ADHOC subscriptions. For standard billing cycle subscriptions (MONTHLY, WEEKLY, DAILY), payments are processed automatically — see Automatic Recurring Payments.
How Adhoc Payments Work
- Initiate Payment — Call the recurring payment API with an
invoice_display_numberand optionalamount - Asynchronous Processing — Payments will Made one day after the api is called.
- Webhook Delivery — The payment outcome (
SUCCESS,FAILED, orCANCELLED) is delivered via webhook, at which point the order and payment records are created in the system
Sample Request
Response
A
success response means the payment was initiated, not captured. The actual payment outcome arrives asynchronously via webhooks (SUBSCRIPTION_PAYMENT_SUCCESS, SUBSCRIPTION_PAYMENT_FAILED, or SUBSCRIPTION_PAYMENT_CANCELLED).Constraints
- Only ADHOC billing cycle subscriptions are supported
invoice_display_numberis mandatory for all recurring payments- If
amountis provided, it must not exceed the subscription’sbilling_amount - You can optionally pass a
transaction_id(max 64 chars); otherwise aREC-prefixed ID is auto-generated
View Subscription Payments
Use the Get Subscription Payments API to fetch all payments associated with a subscription from the internal system. This is available for all payment gateways and all environments (including production).Sample Request
Response
Sandbox Testing
The following endpoints are available only in sandbox/UAT environments. Use them to test subscription payment flows without processing real transactions.Testing Flow
To test subscription payments in sandbox, follow this sequence:- Fetch PG Payments — List all payments from the payment gateway for the subscription
- Identify pending payments — Find payments with
PENDINGstatus in the response - Simulate Payment — Pass the
payment_idof a pending payment to simulateSUCCESSorFAILED
Fetch PG Payments
First, use the Fetch PG Payments API to fetch all payments for a subscription directly from the payment gateway.Sample Request
Response
PENDING status. Use their payment_id in the next step to simulate a payment outcome.
For full response schema, see the Fetch PG Payments endpoint in API Reference.
Simulate Payment
Once you have apayment_id with PENDING status from the PG payments response, use the Simulate Payment API to simulate a success or failure for that payment.
Sample Request
Response
payment_status field accepts SUCCESS or FAILED. The payment_id should be a pending payment obtained from the Fetch PG Payments response.
For full request and response schema, see the Simulate Payment endpoint in API Reference.
Webhooks
EximPe sends webhook notifications for both subscription lifecycle events and recurring payment events. Configure webhooks to receive real-time updates.Payment Successful Webhook (for Recurring Payments)
For each automatic recurring payment, you’ll receive a Payment Successful webhook. This webhook includes thesubscription_id field, allowing you to track which subscription the payment belongs to.
Key Fields in Payment Webhook:
subscription_id: The unique identifier of the subscriptionorder_id: The order ID for this specific paymentpayment_id: The payment transaction IDamount: The amount chargedstatus: Payment status (SUCCESS)
Subscription Status Webhook
The Subscription Status webhook is triggered when a subscription status changes or subscription information is updated. This allows you to track subscription lifecycle events and update your billing records accordingly. Common Subscription Events:PENDING→ACTIVE: Mandate created and activated successfullyACTIVE→PAUSED: Subscription temporarily pausedPAUSED→ACTIVE: Subscription resumedACTIVE→CANCELLED: Subscription cancelled by merchant or customerACTIVE→EXPIRED: Subscription reached its end datePENDING→FAILED: Mandate creation or activation failed
- New subscriptions start with
PENDINGstatus - Once mandate is approved, status changes to
ACTIVE - Subscriptions can be paused/resumed or cancelled at any time
- Subscriptions automatically expire when
payment_end_dateis reached
For general webhook setup, security, and verification, see the Webhooks Integration Guide.