A single item inside a SubscriptionSchedule phase.
A phase item is a template that Stripe materializes into a real
%LatticeStripe.SubscriptionItem{} when the phase activates. Its shape
differs from a live SubscriptionItem:
- NO
id,object,subscription,created,current_period_start,current_period_end— a template has no identity yet. - HAS
price_data(inline price creation) andtrial_data(phase-scoped trial settings) — a live item would use the parent subscription's trial settings instead.
See also: LatticeStripe.SubscriptionItem for live items on an active
subscription.
Fields
billing_thresholds- Per-item billing threshold mapdiscounts- List of discount IDs or objectsmetadata- Set of key-value pairsplan- Plan object (legacy)price- Price ID for an existing Priceprice_data- Inline price data for ad-hoc pricingquantity- Quantity for this itemtax_rates- List of tax rate objectstrial_data- Phase-scoped trial configuration mapextra- Unknown fields from Stripe not yet in this struct
Summary
Functions
Converts a decoded Stripe API map to a %PhaseItem{} struct.
Types
@type t() :: %LatticeStripe.SubscriptionSchedule.PhaseItem{ billing_thresholds: map() | nil, discounts: list() | nil, extra: map(), metadata: map() | nil, plan: map() | nil, price: String.t() | map() | nil, price_data: map() | nil, quantity: integer() | nil, tax_rates: list() | nil, trial_data: map() | nil }
A phase-item template on a Stripe Subscription Schedule phase.