pauseOrder( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Pauses a pricing plan order.

The pauseOrder() function returns a Promise that resolves when the order is successfully paused.

For orders with recurring payments, pauseOrder() also pauses the payment schedule. Buyers are not charged when an order is paused. Use pauseOrder(), for example, if the buyer is away and would like to put their pricing plan membership on hold until they return. Pausing an order affects the end date of the order by adding the time the order is paused to the endDate. You can only pause orders with an "ACTIVE" status.

Pausing an order causes the following changes:

  • The order status changes to "PAUSED".
  • The pausePeriods array is updated.

The endDate and the earliestEndDate for the order are adjusted to include the pause period when the order is resumed.

Paused orders can be continued with the resumeOrder() function.

Admin Method

This function requires elevated permissions and runs only on the backend and on dashboard pages.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Orders
Learn more about permission scopes.
Method Declaration
Copy
Method Parameters
_idstringRequired

Order ID.

Was this helpful?
Yes
No