I’m working with a GraphQL query to fetch subscription data, including the billing policy fields from Shopify’s subscriptionContracts. Here’s a simplified snippet of my query:
query getSubscriptionData($cursor: String) {
subscriptionContracts(first: 250, after: $cursor) {
edges {
node {
id
status
createdAt
billingPolicy {
interval
intervalCount
}
…
}
}
pageInfo {
hasNextPage
endCursor
}
}
}
I’m trying to understand how to correctly interpret the billingPolicy.interval and billingPolicy.intervalCount fields.
My current interpretation:
If the interval is MONTHLY and intervalCount is 12, then it means the customer is billed once a year (i.e., annual billing).
However, this doesn’t seem to align with the billing behavior we’re seeing in the data — customers with interval: MONTHLY and intervalCount: 12 appear to be billed monthly, not annually.
Has anyone worked with this schema before? Am I misunderstanding the meaning of interval and intervalCount in the context of Shopify subscriptions?
Any clarification or real-world examples would be greatly appreciated.