Setup

To use the ItemModifiers API, install the @wix/restaurants package using npm or Yarn:

Copy
1
npm install @wix/restaurants

or

Copy
1
yarn add @wix/restaurants

Then import { itemModifiers } from @wix/restaurants:

Copy
1
import { itemModifiers } from '@wix/restaurants'
Was this helpful?
Yes
No

bulkCreateModifiers( )

Developer Preview

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

Creates multiple item modifiers.

To create only one item modifier, use Create Modifier.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function bulkCreateModifiers(modifiers: Array<Modifier>, options: BulkCreateModifiersOptions): Promise<BulkCreateModifiersResponse>
Method Parameters
modifiersArray<Modifier>Required

List of item modifiers to create.


optionsBulkCreateModifiersOptions
Returns
Return Type:Promise<BulkCreateModifiersResponse>
Was this helpful?
Yes
No

bulkUpdateModifiers( )

Developer Preview

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

Updates multiple item modifiers.

Each time a item modifier is updated, revision increments by 1. The current revision must be passed when updating an item modifier. This ensures you're working with the latest item modifier and prevents unintended overwrites.

To update only one modifier, use Update Modifier.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function bulkUpdateModifiers(modifiers: Array<MaskedModifier>, options: BulkUpdateModifiersOptions): Promise<BulkUpdateModifiersResponse>
Method Parameters
modifiersArray<MaskedModifier>Required

List of item modifiers to update.


optionsBulkUpdateModifiersOptions
Returns
Return Type:Promise<BulkUpdateModifiersResponse>
Was this helpful?
Yes
No

createModifier( )

Developer Preview

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

Creates an item modifier.

To create multiple item modifiers at once, use Bulk Create Modifiers.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function createModifier(modifier: Modifier): Promise<Modifier>
Method Parameters
modifierModifierRequired

Item modifier to create.

Returns
Return Type:Promise<Modifier>
Was this helpful?
Yes
No

getModifier( )

Developer Preview

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

Retrieves an item modifier.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function getModifier(modifierId: string): Promise<Modifier>
Method Parameters
modifierIdstringRequired

ID of the item modifier to retrieve.

Returns
Return Type:Promise<Modifier>
Was this helpful?
Yes
No

listModifiers( )

Developer Preview

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

Retrieves a list of item modifiers.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function listModifiers(options: ListModifiersOptions): Promise<ListModifiersResponse>
Method Parameters
optionsListModifiersOptions
Returns
Return Type:Promise<ListModifiersResponse>
Was this helpful?
Yes
No

queryModifiers( )

Developer Preview

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

Retrieves a list of item modifiers, given the provided paging, filtering, and sorting.

Query Modifiers runs with these defaults, which you can override:

  • createdDate is sorted in ASC order
  • paging.limit is 200

For field support for filters and sorting, see Item Modifiers: Supported Filters and Sorting.

To learn about working with Query endpoints, see API Query Language and Sorting and Paging.

PROPERTYSUPPORTED FILTERS & SORTING
_ideq(),ne(),in()
_createdDateeq(),ne(),gt(),ge(),lt(),le()
_updatedDateeq(),ne(),gt(),ge(),lt(),le()
nameeq(),ne(),in()

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function queryModifiers(): ModifiersQueryBuilder
Request
This method does not take any parameters
Returns
Was this helpful?
Yes
No

updateModifier( )

Developer Preview

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

Updates an item modifier.

Each time the item modifier is updated, revision increments by 1. The current revision must be passed when updating the item modifier. This ensures you're working with the latest item modifier and prevents unintended overwrites.

To update multiple item modifiers at once, use Bulk Update Modifiers.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Bookings Services and Settings
Manage Restaurants Menus
Learn more about permission scopes.
Copy
function updateModifier(_id: string, modifier: UpdateModifier): Promise<Modifier>
Method Parameters
_idstringRequired

Item modifier ID.


modifierUpdateModifierRequired
Returns
Return Type:Promise<Modifier>
Was this helpful?
Yes
No