Notify Redemption


Once the subscription is set up, the next step is to collect the redemption amount based on the selected subscription cycle.

Redemption involves two steps:

  • Notify: Inform the user about the upcoming payment.
  • Execute: Debit the redemption amount from the user.

⚠️ Validate Subscription State Before Notify!


Always verify that the subscription is in the ACTIVE state using the Subscription Status API before calling the Notify API, to prevent avoidable failures.

⚠️ Validate Subscription State Before Notify!


  • When paymentFlow.redemptionRetryStrategy is set to CUSTOM:
    • Merchants must retry until a terminal status (COMPLETED or FAILED) is reached.
    • You are limited to one initial attempt and three retries over a maximum of 48 hours.
    • Retries must be executed only during the non peak periods – 9:31 PM to 9:59 AM and 1:01 PM to 4:59 PM
  • When paymentFlow.redemptionRetryStrategy is set to STANDARD:
    • PhonePe will automatically handle all internal redemption retries for you.
    • Retries are managed internally by PhonePe, with a maximum time window of 48 hours to achieve a terminal status.
    • Retries must be executed only during the non peak periods – 9:31 PM to 9:59 AM and 1:01 PM to 4:59 PM
    • No action or changes are required from the merchant.
  • Default Value: STANDARD.
EnvironmentHTTP MethodAPI
SandboxPOSThttps://api-preprod.phonepe.com/apis/pg-sandbox/subscriptions/v2/notify
ProductionPOSThttps://api.phonepe.com/apis/pg/subscriptions/v2/notify
Request Headers
Header NameHeader Value
Content-Typeapplication/json
AuthorizationO-Bearer <merchant-auth-token>
Request Parameters
Parameter NameData TypeDescriptionMandatory (Yes/No)Constraints
merchantOrderIdStringUnique order ID generated by the Merchant.Yes Maximum length is 63 characters.
Only underscore (_) and hyphen (-) are allowed as special characters.
amountLongOrder amount specified in paisa.YesThe maximum debit or redemption amount allowed for the mandate, specified in paisa.
Note:
For variable recurring debits, this acts as the maximum cap amount.
For PENNY_DROP flow, the amount must be ≥ 200 paisa.
For TRANSACTION flow, the amount must be ≥ 100 paisa.
expireAtDateTimeThe expireAt value is the epoch timestamp (in milliseconds) after which the order will automatically fail or be skipped if it hasn’t reached a terminal state.NoDefault Value: 48hrs
paymentFlow.typeStringType of payment flow.YesPossible Values:
SUBSCRIPTION_REDEMPTION
paymentFlow.merchantSubscriptionIdStringThe merchant reference subscription ID provided during the setup of the subscription.Yes
paymentFlow.redemptionRetryStrategyredemptionRetryStrategy specifies the approach to be followed if redemption attempts fail. It determines whether and how the system should retry the transaction.NoPossible Values:
STANDARD – Automatic retries will be handled internally by the system.
CUSTOM – The merchant is responsible for retrying the redemption.

Default Value – STANDARD
paymentFlow.autoDebitFor CUSTOM redemptionRetryStrategy, auto-debit redemption cannot occur 24 hours after a successful notification.NoPossible Values:
true
false
Default Value: false
metaInfoNoDefault Value: null
Sample Request
{
  "merchantOrderId": "MO1709025691805",
  "amount": 1000,
  "expireAt": 1620891733101,
  "metaInfo": {
    "udf1": <some meta info of max length 256>
    "udf2": <some meta info of max length 256>
    "udf3": <some meta info of max length 256>
    "udf4": <some meta info of max length 256>
    "udf5": <some meta info of max length 256>
  }  
  "paymentFlow": {
    "type": "SUBSCRIPTION_REDEMPTION",
    "merchantSubscriptionId": "MS121312",
    "redemptionRetryStrategy": "CUSTOM",
    "autoDebit": true
  }
}
Sample Request in CURL
curl --location 'https://api-preprod.phonepe.com/apis/pg-sandbox/subscriptions/v2/notify' \
--header 'Accept: application/json' \
--header 'Authorization: O-Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHBpcmVzT24iOjE3MTIyNTM2MjU2NDQsIm1lcmNoYW50SWQiOiJWMlNVQlVBVCJ9.7aVzYI_f_77-bBicEcRNuYx093b2wCsgl_WFNkKqAPY' \
--header 'Content-Type: application/json' \
--data '{
 "merchantOrderId": "MO1709025691805",
 "amount": 1000,
 "expireAt": 1620891733101,
 "paymentFlow": {
   "type": "SUBSCRIPTION_REDEMPTION",
   "merchantSubscriptionId": "MS121312",
   "redemptionRetryStrategy": "CUSTOM",
   "autoDebit": true
 }
}

Response

Sample Response
{
    "orderId" : "OMO12344",
    "state" : "NOTIFICATION_IN_PROGRESS",
    "expireAt": 1707116484762
}
Response Parameters
Parameter NameDescription
orderIdPayment Gateway generated internal order ID
stateOrder state
expireAtExpiry in Epoch Timestamp(in milliseconds)
headers
body params

You can also test this API request directly in Postman for a quick and easy integration check.

Now that you’ve learned how to collect the redemption amount based on the selected subscription cycle, let’s move on to how the amount is executed and debited from the user’s bank account.

Is this article helpful?