Introduction
Developer Preview
APIs in Developer Preview are subject to change and are not intended for use in production.
Send us your suggestions for improving this API. Your feedback is valuable to us.
APIs in Developer Preview are subject to change and are not intended for use in production.
Send us your suggestions for improving this API. Your feedback is valuable to us.
The Back In Stock Settings API allows you to manage whether or not to collect requests from customers to receive back in stock notifications.
Learn more about back in stock notification settings.
To use the Back In Stock Settings API, import { backInStockSettings } from the ‘wix-ecom-backend’ module:
javascript | Copy Codeimport { backInStockSettings } from `wix-ecom-backend`;
Before you begin
It’s important to note the following points before starting to code:
- To start collecting back in stock requests, the
collectionStates
must be set totrue
. UsestartCollectingRequests()
to update collection states. - Customize the design of the notification email that will be sent.
Terminology
- Collection state: The collection state determines whether the selected app is actively collecting requests for back in stock notifications. When the collection state is set to `true``, collecting requests is enabled and customers may request notifications for out of stock products.
Permissions information
The following functions in Back In Stock Settings API are restricted and only run if you elevate permissions using the wix-auth
elevate()
function:
Warning: Elevating a function allows it to be called by any site visitor. Exercise caution to prevent security vulnerabilities.
Was this helpful?