Retrieve active Subscription

API call used to get the active Stripe Subscription.

HTTP Request retrieve active subriscription

GET https://app.dedit.io/api/v2/payment/subscription/active

Headers

The previous call returns a JSON structured as follows:

{
  "sessionId": "cs_live_a1BCDJVgOtwNYZDnzdQFbxn5pfiiUIejydIIIDRDcH3jkFiMSyOaO2TK0r",
  "id": "sub_JS1abZ2yS3LClN",
  "userId": 123,
  "planId": "price_1IntOARgQaABmNJUlduYqXPM",
  "planNickname": "Dedit Pro",
  "status": "active",
  "created": 1620551070,
  "currentPeriodStart": 1620551070,
  "currentPeriodEnd": 1652087070,
  "canceledAt": 0,
  "customer": "cus_Irn6ndQQ0K3lAJ",
  "defaultPaymentMethod": "pm_1Ab2CdEfGhILmNOPq3aNqxX2",
  "latestInvoice": "in_1Ip8YsG1Ab2CdEfGhILmaDRB"
}

Last updated