{"packs":[{"id":"stripe-subscription-item-periods","revision":1,"provider":"stripe","api_version":"2025-07-30.basil","topic":"subscription-item-periods","billing_mode":"flexible","provenance":"synthetic_from_stripe_docs","sources":["https://docs.stripe.com/changelog/basil/2025-03-31/deprecate-subscription-current-period-start-and-end","https://docs.stripe.com/changelog/basil/2025-07-30/support-mixed-intervals","https://docs.stripe.com/api/subscription_items/list?api-version=2025-07-30.basil"],"contract":"Given input.event and optional input.item_pages, return the current subscription ID and item periods sorted by item ID. Continue pagination using the provided pages only. Return {\"error\":\"incomplete_item_list\"} if a required page is missing. Periods are integer Unix seconds.","match_fields":["provider","api_version","topic"],"use_when":"Changing the Stripe subscription webhook projection or upgrading its endpoint version.","case_count":8,"coverage":["A monthly item and an annual item have different end dates","Monthly renewal leaves the annual item period unchanged","Both item periods renew at an aligned boundary","A quantity change preserves the current period","Include the new item from the current subscription snapshot","Omit items found only in the previous snapshot","Use the supplied next item page before building a complete result","Report an incomplete item list when another page is unavailable"],"pack_sha256":"b248cea07337ec2f3696cc870d816d916cd463162667c059168d5251011e04f4","preview_case":{"id":"one-item-period","title":"Read the item period when the subscription has no top-level period","input":{"event":{"id":"evt_one_item_period","object":"event","type":"customer.subscription.updated","api_version":"2025-07-30.basil","livemode":false,"created":1767225600,"data":{"object":{"id":"sub_demo","object":"subscription","billing_mode":{"type":"flexible"},"items":{"object":"list","has_more":false,"data":[{"id":"si_monthly","object":"subscription_item","subscription":"sub_demo","current_period_start":1767225600,"current_period_end":1769904000,"quantity":1,"price":{"id":"price_monthly","object":"price","currency":"usd","recurring":{"interval":"month","interval_count":1}}}]}}}}},"expected":{"subscription_id":"sub_demo","items":[{"id":"si_monthly","start":1767225600,"end":1769904000}]}},"preview_url":"https://naturalflavo.life/v1/replay-packs/stripe-subscription-item-periods/1/preview","price":{"amount":"0.05","asset":"USDC","checkout_available":true},"purchase":{"method":"POST","url":"https://naturalflavo.life/v1/replay-packs/stripe-subscription-item-periods/1/purchases","payment_protocol":"x402-v2","network":"eip155:8453"}}]}