Create a schedule

Changed on

Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.

post/v1/subscription_schedules

Request

  • Base URL: https://api.stripe.com
  • URL: https://api.stripe.com/v1/subscription_schedules
  • Auth: one of:
    • HTTP basic
    • HTTP bearer

Request body application/x-www-form-urlencoded

customerstring

The identifier of the customer to create the subscription schedule for.

customer_accountstring

The identifier of the account to create the subscription schedule for.

end_behavior'cancel' | 'none' | 'release' | 'renew'

Behavior of the subscription schedule and underlying subscription when it ends. Possible values are release or cancel with the default being release. release will end the subscription schedule and keep the underlying subscription running. cancel will end the subscription schedule and cancel the underlying subscription.

expandstring[]

Specifies which fields in the response should be expanded.

from_subscriptionstring

Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.

Response

Successful response.

canceled_atinteger nullable

Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.

completed_atinteger nullable

Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.

createdinteger required

Time at which the object was created. Measured in seconds since the Unix epoch.

customer_accountstring nullable

ID of the account who owns the subscription schedule.

end_behavior'cancel' | 'none' | 'release' | 'renew' required

Behavior of the subscription schedule and underlying subscription when it ends. Possible values are release or cancel with the default being release. release will end the subscription schedule and keep the underlying subscription running. cancel will end the subscription schedule and cancel the underlying subscription.

idstring required

Unique identifier for the object.

livemodeboolean required

If the object exists in live mode, the value is true. If the object exists in test mode, the value is false.

metadataobject nullable

Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

object'subscription_schedule' required

String representing the object's type. Objects of the same type share the same value.

released_atinteger nullable

Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.

released_subscriptionstring nullable

ID of the subscription once managed by the subscription schedule (if it is released).

status'active' | 'canceled' | 'completed' | 'not_started' | 'released' required

The present status of the subscription schedule. Possible values are not_started, active, completed, released, and canceled. You can read more about the different states in our behavior guide.

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

    • 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

    • 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

    • info

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

Some revisions have not been checked yet.