Skip to navigation

Retrieve Rotating Ordinal Subscription Context

View as Markdown

Returns the Ordinal Subscription Context for the given subscription and product. This ordinal represents the number of recurring orders for the given product and subscription combination - see https://docs.ordergroove.com/advanced/ordinal-rotating#example for an example.

product_id must be an ordinal rotating product (otherwise 400) with a recorded ordinal on the subscription (otherwise 404 with No context found). The subscription’s current product always returns a context, with ordinal 0 if nothing is recorded yet. active is true when the product is the subscription’s current product or one of its bundle components, and false for a previous product, for example after a SKU swap; it doesn’t reflect whether the subscription itself is active.

For a bundle, retrieve each component’s context separately. Passing the bundle product returns 400.

Authentication

x-api-keystring

Application API Scope — server-to-server, sent in the x-api-key header. See Authentication.

OR
authorizationstring

Storefront API Scope — client-side, scoped to one customer, sent as a signature in the authorization header. See Authentication.

Path parameters

subscription_idstringRequired
Subscription Public ID
product_idstringRequired
Product ID

Response

200
Active Subscriptionobject
OR
Inactive Subscription + Rotating Productobject