Subscriptions

Preview a plan change (v2, swap in place)

Changed on

Preview a subscription plan change without writing. Swap-in-place: subscription id, billing anchor and period bounds are preserved.

post/subscriptions/{id}/change/v2/preview

Request

  • Base URL
    https://us.api.flexprice.io/v1
  • URL
    https://us.api.flexprice.io/v1/subscriptions/{id}/change/v2/preview
  • Auth
    API key in header x-api-key

Path parameters

idstring required

Subscription ID

Request body

billing_period_behaviour'unchanged' | 'anchor_at_effect' | 'anchor_at_config'
change_at'immediate' | 'end_of_period'
idempotency_keystring
metadataobject
proration_behavior'create_prorations' | 'none' required
target_plan_idstring required

Response

OK

change_type'upgrade' | 'downgrade' | 'lateral'
effective_atstring date-time
is_scheduledboolean

IsScheduled is true when the change was deferred to the period end instead of being applied immediately.

metadataobject
schedule_idstring
scheduled_atstring date-time
superseded_schedulesstring[]

SupersededSchedules lists the plan-change schedules this request cancelled under on_conflict_policies.on_pending_schedule. Preview reports what execute would cancel.

warningsstring[]

Changes

    • info

      added the optional property //// to the response with the status

    • info

      added the optional property /// to the response with the status

    • info

      added the optional property /// to the response with the status