POST
/
api
/
v2
/
subscription-plans
Create a Subscription Plan
curl --request POST \
  --url https://sandbox.cashfree.com/api/v2/subscription-plans \
  --header 'Content-Type: application/json' \
  --header 'X-Client-Id: <x-client-id>' \
  --header 'X-Client-Secret: <x-client-secret>' \
  --data '{
  "planId": "1682406696",
  "planName": "Plan 1682406656",
  "type": "PERIODIC",
  "recurringAmount": 10,
  "maxAmount": 100,
  "intervals": 1,
  "intervalType": "month"
}'
{
"message": "Plan created successfully",
"status": "OK",
"data": {
"planId": "1682406696",
"planName": "Plan 1682406656",
"type": "PERIODIC",
"currency": "INR",
"amount": 10,
"maxAmount": 100,
"intervals": 1,
"intervalType": "month",
"isActive": true,
"addedOn": "2023-04-25 13:50:17"
}
}

Headers

X-Client-Id
string
required

Client ID provided by Cashfree.

Example:

"asdf1234"

X-Client-Secret
string
required

Client Secret provided by Cashfree.

Example:

"qwer9876"

Body

application/json

Response

200
application/json

Subscription plan created successfully.

The response is of type any.