Query
Parameters
Input parameters for retrieving active subscriptions
Return Type
Returns an array ofCustomerSubscription objects with:
| Field | Type | Description |
|---|---|---|
subscriptionId | String | Unique subscription ID |
status | SubscriptionStatus | ACTIVE or IN_TRIAL |
startDate | DateTime | When subscription started |
endDate | DateTime | End date of the subscription |
effectiveEndDate | DateTime | Effective end date, accounting for cancellation or trial end behavior |
currentBillingPeriodStart | DateTime | Start date of the current billing period |
currentBillingPeriodEnd | DateTime | Current period end |
billingPeriod | BillingPeriod | Billing cadence (e.g. MONTHLY, ANNUALLY) |
additionalMetaData | JSON | Custom metadata (key-value pairs) attached to the subscription |
customer | Customer | The subscription’s customer, including customerId and email |
payingCustomer | Customer | The paying customer (for payment delegation scenarios), including customerId and email |
plan | Plan | The subscribed plan, including refId, displayName, description, and nested product with refId, displayName, and downgradePlan |
addons | [SubscriptionAddon] | Applied addons |
prices | [Price] | List of price items, each with billingModel and price (containing billingPeriod and nested price with amount, currency) |
totalPrice | TotalPrice | Simplified total with subTotal and total (each containing amount and currency). Does not account for per-unit quantities, discounts, minimum spend, or usage-based pricing |
trialEndDate | DateTime | Trial end (if applicable) |
Common Use Cases
Determine current access
Determine current access
Check what plan(s) a customer currently has access to.
Multi-product access
Multi-product access
For products with multiple subscription products, get all active subscriptions.
Display current plan
Display current plan
Show the customer their current subscription in your app.
Example: Check Customer Access
Related Operations
- Get Subscription - Get single subscription details
- List Subscriptions - Query all subscriptions with filters
- Entitlements State - Get customer entitlements
