Update maximum cycles for a subscription contract
Updates the maximum number of billing cycles (orders) after which a subscription will automatically terminate. This creates a fixed-duration subscription that ends after a specific number of orders.
Full behavior, validation rules, and side effects
What are Maximum Cycles? Maximum cycles define subscription duration limits where:
- Subscription automatically cancels after the specified number of orders
- No further orders are generated once maximum is reached
- Useful for fixed-term offers, trials, or seasonal subscriptions
- Customer is notified before final order (if configured)
Key Features:
- Cannot set below current cycle count (prevents immediate cancellation)
- Setting to null creates an indefinite subscription
- Automatically reschedules order queue based on new limit
- Preserves all other subscription settings
- Validates against current subscription progress
Current Cycle Calculation:
- Current cycle = Successful billing attempts + 1
- Failed payments don’t count toward maximum
- First order is cycle 1, second is cycle 2, etc.
- System prevents setting max below current position
Common Use Cases:
- Trial Subscriptions: ‘3-box trial’ that auto-ends
- Seasonal Programs: ‘6-month summer subscription’
- Limited Series: ‘12-issue magazine subscription’
- Promotional Offers: ‘First 5 boxes at special price’
- Gift Subscriptions: Fixed duration gifts that don’t renew
What Happens at Maximum: When a subscription reaches its maximum cycles:
- Final order is processed normally
- Subscription status changes to CANCELLED
- No future orders are scheduled
- Customer receives cancellation notification
- Cannot be reactivated (new subscription required)
Interaction with Min Cycles:
- Can have both min and max (e.g., 3 min, 12 max)
- Min cycles enforces commitment period
- Max cycles enforces termination
- Common pattern: Commitment with defined end
Queue Management: After updating max cycles:
- System recalculates future order schedule
- Removes orders beyond the new maximum
- Adjusts upcoming order notifications
- Updates subscription end date projections
Important Notes:
- Validation prevents accidental immediate cancellation
- Changes apply to future billing cycles only
- Activity log tracks old and new values
- Consider customer communication for changes
- Setting null removes any duration limit
Authentication: Requires valid X-API-Key header
Documentation Index
Fetch the complete documentation index at: https://appstleinc-aeca3e0a.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Headers
Query Parameters
Contract ID
API Key (Deprecated - Use Header X-API-Key instead)
Maximum Cycles. The total number of orders after which the subscription will automatically terminate. Must be greater than or equal to the current cycle count and any configured minimum cycles. Common values:
- 3: Three-order trial
- 6: Six-month seasonal subscription
- 12: Annual subscription
- 24: Two-year commitment
- null: Ongoing subscription with no end date
1 <= x <= 9999Response
Maximum cycles updated successfully
ACTIVE, PAUSED, CANCELLED, EXPIRED, FAILED, $UNKNOWN SUCCEEDED, FAILED, $UNKNOWN