Create Subscription
Introducing our Create Subscription API, a powerful tool designed to streamline subscription management processes with utmost simplicity and efficiency. With this API, businesses can seamlessly create subscriptions for their services or products, providing customers with a hassle-free experience.
Upon successful creation of a subscription, the API generates a unique authorization link tailored for the end customer. This link offers a gateway to authorize transactions conveniently using multiple payment methods including eNACH (Electronic National Automated Clearing House), UPI Autopay, or credit/debit card.
By leveraging our Create Subscription API, businesses can enhance customer satisfaction and retention by offering flexible payment options while minimizing administrative overhead. Simplify subscription management and empower your customers with seamless authorization capabilities today.
This API employs API Keys for request authentication. It's crucial to safeguard your API Keys, as they grant various privileges. To obtain the Access Key, kindly reach out to our Support/CSM team. Once obtained, please utilize this access key in the Authorization header.
Authentication for the API is executed through the Authorization header.
Feel free to replace 'YOUR_ACCESS_KEY_HERE' with the actual Access Key provided by our Support/CSM team.
The details of the API can be found here.
Here's a table outlining the key parameters, descriptions, whether they are mandatory or optional, and their data types.
Key | Description | M/O | Type |
customerName | Specify the name of the customer | Optional | String |
customerEmail | Specify the customer email | Mandatory | String |
customerPhone | Specify the contact number of the customer. Phone number registered in India (only digits, 8 - 12 characters after excluding +91). | Mandatory | String |
mandateName | Name of the mandate, for example, netflix subscription, etc. | Mandatory | String |
mandateType | The type can be PERIODIC or ON_DEMAND. PERIODIC - Payments are triggered automatically at fixed intervals defined by the merchant. ON_DEMAND - Merchant needs to trigger/charge the customer explicitly with the required amount. | Mandatory | Enums |
mandateFlow | Pass this as DEFAULT | Mandatory | String |
maxCycles | Maximum number of debits set for the plan. The subscription will automatically change to COMPLETED status once this limit is reached. | Optional | String |
description | Description | Optional | String |
notificationChannels | The checkout link is sent through the given notification channels. Possible values: EMAIL, SMS. | Mandatory | Array of Strings |
expiresOn | (Date,pattern :yyyy-MM-dd HH:mm:ss) This is the date from which the subscription stands invalid, and is no longer active. Any charge raised on this date will not be deducted. The default value is 2 years from date of subscription creation. | Optional | String |
authAmount | (Decimal upto 2 precision) The amount that will be charged to authenticate the payment. It is applicable only for UPI and Card payments. The default amount is Re. 1 and minimum amount is Re. 1. This amount will not be refunded to the customer. | Optional | String |
amount | The amount to be charged for PERIODIC plan. This is a conditional parameter, not applicable for on-demand plans. | Optional | String |
intervalType | The type of interval for a PERIODIC plan like day, week, month, or year. This is a conditional parameter. Not applicable for on-demand plans. | Optional | Enums |
intervals | Number of intervals of intervalType between every subscription payment. For example, to charge a customer bi-weekly use intervalType as “week” and intervals as 2. Required for PERIODIC plan. The default value is 1. | Optional | String |
firstChargeDate | This will be the date at which the first payment takes place. Applicable for periodic subscriptions only. The default value is 30 days. | Optional | Date |
maxAmount | MaxAmount is the max amount that can be charged on a subscription. it is applicable for both ON_DEMAND and PERIODIC subscriptions. | Mandatory | String |
callbackUrl | Callback URL | Mandatory | String |
returnUrl | Return URL | Mandatory | String |
tpvEnabled | Third party validation. Set it as true when third party validation is required. Default value is false. TPV is applicable only for eNACH and UPI. | Optional | Boolean |
payerAccountDetails.accountNumber | Specify the bank account number of the customer. Conditional parameter. Account number is mandatory when ‘tpvEnabled’ is true. | Conditioanlly Mandatory | String |
payerAccountDetails.accountHolderName | Specify the name of the account holder. Conditional parameter. Account holder name is mandatory when 'tpvEnabled' is true. | Conditioanlly Mandatory | String |
payerAccountDetails.accountType | Specify the account type whether it is a savings account or current account. Possible values are: SAVINGS or CURRENT. | Conditioanlly Mandatory | String |
payerAccountDetails.ifsc | Specify the IFSC code of the bank account. Conditional parameter. IFSC is mandatory when ‘tpvEnabled’ is true | Conditioanlly Mandatory | String |
Key | Description | Type |
result | Object containing the result data | Object |
result.status | Indicates the status of the result | String |
result.message | Message regarding the result | String |
result.subReferenceId | Unique identifier for the subscription | Integer |
result.authLink | Link for authentication | String |
result.subStatus | Status of the subscription | String |
result.eventTime | Time when the event occurred | String |
Key | Description | Type |
error | Main error object | Object |
error.name | Error name | String |
error.message | Error message | String |
error.status | Error status code | String |
error.reason | Error reason | String |
error.type | Type of error | String |
error.statusCode | HTTP status code | String |
Error Code | Error Message | Explanation |
400 | Bad Request | Input parameter has a missing required parameter or invalid inputs |
401 | Authorization Failed | Authorization token is invalid |
404 | Not Found | The eneterd Sub Reference ID is not found |
500 | Internal Server Error | Internal error at Signzy, Please reach out to [email protected] |