Fetch plans from the recurpay dashboard

📘

Using the APIs in production?

While using the APIs in production, you just need to use your URL (example.recurpay.com) as an endpoint instead of staging.recurpay.com as shown in examples.

Request Params

URL ParametersTypeDescription
productsarray of stringsPass array of product id's.

Response Params

All Plans Object

AttributeTypeDescription
productobjectObject containing product id and the plan details. See Product - Object

Product Object

AttributeTypeDescription
idintegerProduct Id
plansobjectObject containing the plan details. See Plan Object

Plan Object

AttributeTypeDescription
idintegerPlan Id - A globally-unique identifier.
namestringPlan Name - A customer facing name of the plan.
descriptionstringPlan Description - A customer facing description of the plan.
typeenumPlan Type. The value is:

regular - Recurring payment would be received.

prepaid - Upfront payment would be received.
statusenumStatus of the plan.

Active - Plan will be visible on the storefront.
Inactive - Plans will not be
productsobjectProducts belonging to this plan.
delivery_policyobjectPlan policy which describes the delivery details. See Delivery Policy
pricing_policyobjectPlan policy which describes the discounts and pricing details. See Pricing Policy
billing_policyobjectPlan policy which describes the recurring billing details. See Billing Policy
shipping_policyobjectPlan policy which describes the shipping details. See Shipping Policy
trial_policyobjectPlan policy which describes the trial details. See Trial Policy
manual_payment_gatewayobjectStatus and details of manual payment gateway activation on the plan. See Manual Payment Gateway
visibilityenumPlan visibility on storefront.

Visible - Will be visible to the end user.
Hidden - Will be hidden to the end user.
created_atdatetimeThe date and time when the selling plan was created.
updated_atdatetimeThe date and time when the selling plan was updated.

Pricing Policy

AttributeTypeDescription
discountobjectDiscount applicable on plan.
Note: The discount will be applicable on top of the product price and other discounts. See Discount Object

Discount Object

AttributeTypeDescription
typeenumThe type can be of:

percentage: Type of discount applicable on plan
valuefloatThe discount you want to offer on this plan. The discount will be calculated on top of product price and other discounts.

Delivery Policy

AttributeTypeDescription
frequencyintegerThe delivery frequency.
intervalenumThe delivery interval, it can be either: day, week, month or year.

Billing Policy

AttributeTypeDescription
frequencyintegerThe billing frequency.
intervalenumThe billing interval, it can be either: day, week, month or year.
auto_expireobjectDefines billing expiry of the subscription charges. See Auto Expiry Object

Auto Expiry Object

AttributeTypeDescription
statusbooleanStatus of auto expiry. Value : true, false
frequencyintegerThe expiry frequency.
intervalenumThe expiry interval, it can be either: day, week, month or year.

Shipping Policy

AttributeTypeDescription
statusbooleanStatus of plan shipping, it can be either true or false.
typeenumType of Shipping, it can be either

free_shipping - Free shipping for this plan

charge_on_first_order - Charge shipping rate only on the first order for subscription.

charge_on_every_order - Charge shipping on every order created for subscription
pricefloatShipping price of the plan

Trial Policy

AttributeTypeDescription
statusbooleanThe status whether the trial is applicable or not.
frequencyintegerThe trial frequency
intervalenumThe trial interval, it can be either: day, week, month or year.
descriptionstringDescription of the trial plan
productsarrayArray of Variant Id's which needs to be given for trial.

Manual Payment Gateway

AttributeTypeDescription
statusbooleanThe status whether the manual payment gateway needs to be shown on checkout for this specific plan. It can be either true or false.
namestringName of the manual payment gateway.
Language
Click Try It! to start a request and see the response here!