Get subscription details

Returns one subscription by ID, including billing details, status, schedule, coupon snapshot, and refund history when present.

GET/v1/subscriptions/:subscriptionId

Authorization

api_key_auth
AuthorizationBearer <token>

API key authentication. Use "Bearer YOUR_API_KEY" format.

In: header

Path Parameters

subscriptionId*string

The ID of the subscription to retrieve. Use the list subscriptions endpoint first if you need to discover a subscription ID by email, name, customer, page, or date range.

Match^[0-9a-fA-F]{24}$

Query Parameters

livemode?string

Set to false to return test-mode records created while a page was in test mode. Defaults to the mode of the API key. Test API keys can only read test data.

Value in"true" | "false"

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://api.checkoutpage.com/v1/subscriptions/:subscriptionId"
{
  "data": {
    "id": "string",
    "orderId": "string",
    "stripeSubscriptionId": "string",
    "stripeCustomerId": "string",
    "customerEmail": "string",
    "customerName": "string",
    "currency": "string",
    "amount": 0,
    "amountUsd": 0,
    "taxSource": "fixed_tax_rate",
    "taxRates": [
      {
        "taxRate": "string",
        "stripeId": "string",
        "displayName": "VAT",
        "default": true,
        "active": true,
        "inclusive": true,
        "percentage": 0,
        "createdAt": "2019-08-24T14:15:22Z",
        "updatedAt": "2019-08-24T14:15:22Z"
      }
    ],
    "interval": "string",
    "intervalCount": 0,
    "planIterations": 0,
    "fees": [
      {
        "name": "string",
        "amount": 0,
        "percentage": 0,
        "stripeProductId": "string"
      }
    ],
    "setupFee": 0,
    "setupFeeDiscountAmount": 0,
    "setupFeeFees": [
      {
        "name": "string",
        "amount": 0,
        "percentage": 0,
        "stripeInvoiceItemId": "string"
      }
    ],
    "setupFeeTotal": 0,
    "setupFeeUsd": 0,
    "setupFeeInvoiceItemId": "string",
    "setupFeeInvoiceItemPaid": true,
    "quantity": 0,
    "productPrice": 0,
    "priceId": "string",
    "priceSnapshot": {
      "priceId": "string",
      "label": "string",
      "description": "string",
      "badge": "string",
      "reference": "string",
      "billingType": "string",
      "amount": 0,
      "currency": "string",
      "discountedFromPrice": 0,
      "setupFee": 0,
      "setupFeeMultipliesWithQuantity": true,
      "stripePriceId": "string",
      "stripePriceLivemode": true,
      "managedInStripe": true,
      "payWhatYouWant": true,
      "pwywSuggestedPrice": 0,
      "recurring": {
        "interval": "string",
        "intervalCount": 0,
        "trialPeriodDays": 0,
        "billingCycleAnchorConfig": {
          "enabled": true,
          "dayOfMonth": 0,
          "month": 0
        },
        "startDate": "2019-08-24T14:15:22Z"
      },
      "paymentPlan": {
        "interval": "string",
        "intervalCount": 0,
        "trialPeriodDays": 0,
        "billingCycleAnchorConfig": {
          "enabled": true,
          "dayOfMonth": 0,
          "month": 0
        },
        "startDate": "2019-08-24T14:15:22Z",
        "planIterations": 0
      }
    },
    "dynamicPrice": 0,
    "discountedFromPrice": 0,
    "sku": "string",
    "billing": {
      "name": "string",
      "companyName": "string",
      "email": "string",
      "billingEmail": "string",
      "phone": "string",
      "address": {
        "line1": "string",
        "line2": "string",
        "city": "string",
        "state": "string",
        "postalCode": "string",
        "country": "string"
      }
    },
    "shipping": {
      "name": "string",
      "phone": "string",
      "address": {
        "line1": "string",
        "line2": "string",
        "city": "string",
        "state": "string",
        "postalCode": "string",
        "country": "string"
      }
    },
    "fields": [
      {
        "fieldId": "string",
        "label": "string",
        "value": "string",
        "element": "checkbox",
        "type": "",
        "meta": {
          "property1": null,
          "property2": null
        },
        "reference": "string"
      }
    ],
    "variants": [
      {
        "name": "string",
        "variantId": "string",
        "reference": "string",
        "selectionType": "single",
        "selectedOptions": [
          {
            "optionId": "string",
            "optionType": "one_time",
            "optionName": "string",
            "sku": "string",
            "quantity": 0,
            "additionalChargeAmount": 0,
            "discountAmount": 0,
            "fees": [
              {
                "name": "string",
                "amount": 0,
                "percentage": 0,
                "stripeInvoiceItemId": "string"
              }
            ],
            "additionalChargeAmountTotal": 0,
            "additionalChargeAmountUsd": 0,
            "optionStripePriceId": "string",
            "optionStripeProductId": "string",
            "optionInvoiceItemId": "string",
            "optionInvoiceItemPaid": true
          }
        ],
        "fees": [
          {
            "name": "string",
            "amount": 0,
            "percentage": 0,
            "stripeInvoiceItemId": "string"
          }
        ]
      }
    ],
    "couponId": "string",
    "couponSnapshot": {
      "label": "string",
      "code": "string",
      "amountOff": 0,
      "percentOff": 0,
      "appliesToSetupFee": true,
      "duration": "once",
      "durationInMonths": 0,
      "redeemBy": "2019-08-24T14:15:22Z",
      "maxRedemptions": 0,
      "timesRedeemed": 0,
      "currency": "string",
      "deleted": true,
      "pageIds": [
        "string"
      ]
    },
    "licenseKeyId": "string",
    "livemode": true,
    "status": "draft",
    "paymentStatus": "draft",
    "paymentError": "string",
    "paymentMethod": {
      "gateway": "stripe",
      "method": "string",
      "wallet": "string",
      "mode": "default",
      "brand": "string",
      "last4": "string",
      "country": "string",
      "exp_month": 0,
      "exp_year": 0,
      "expMonth": 0,
      "expYear": 0,
      "funding": "string"
    },
    "locale": "string",
    "sessionId": "string",
    "clientIp": "string",
    "userAgent": "string",
    "screenWidth": 0,
    "visitId": "string",
    "queryParameters": {
      "property1": "string",
      "property2": "string"
    },
    "stripePaymentIntentId": "string",
    "stripeSetupIntentId": "string",
    "startDate": "2019-08-24T14:15:22Z",
    "trialEnd": "2019-08-24T14:15:22Z",
    "trialStart": "2019-08-24T14:15:22Z",
    "cancelAt": "2019-08-24T14:15:22Z",
    "cancelAtPeriodEnd": true,
    "currentPeriodStart": "2019-08-24T14:15:22Z",
    "currentPeriodEnd": "2019-08-24T14:15:22Z",
    "upsell": true,
    "upsellPageId": "string",
    "upsellChargeId": "string",
    "upsellSubscriptionId": "string",
    "sellerId": "string",
    "customerId": "string",
    "pageId": "string",
    "productId": "string",
    "productTitle": "string",
    "lastRefundAt": "2019-08-24T14:15:22Z",
    "lastRefundReason": "string",
    "lastRefundReasonNote": "string",
    "canceledAt": "2019-08-24T14:15:22Z",
    "canceledBy": "string",
    "canceledByApiKey": "string",
    "canceledByApiKeyName": "string",
    "reason": "string",
    "isAbandoned": true,
    "recoveredAt": "2019-08-24T14:15:22Z",
    "abandonmentStatus": "abandoned",
    "abandonedCartEmailStatus": "pending",
    "abandonedCartEmailSentAt": "2019-08-24T14:15:22Z",
    "pageSlug": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}
{
  "status": "error",
  "type": "error",
  "message": "Not Found",
  "errors": [
    {
      "param": "string",
      "message": "string",
      "value": null
    }
  ],
  "property1": null,
  "property2": null
}