Setup
To use the Categories API, install the @wix/bookings
package using npm or Yarn:
1npm install @wix/bookings
or
1yarn add @wix/bookings
Then import { categories }
from @wix/bookings
:
1import { categories } from '@wix/bookings'
This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
Creates a new category.
Permission Scopes
For app development, you must have one of the following permission scopes:function createCategory(category: Category): Promise<Category>
This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
Deletes a category.
When deleting a category, you have the option to delete all the associated services within this category using the deleteServices
field in the request.
Permission Scopes
For app development, you must have one of the following permission scopes:function deleteCategory(_id: string, options: DeleteCategoryOptions): Promise<DeleteCategoryResponse>
This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
Lists all categories.
Permission Scopes
For app development, you must have one of the following permission scopes:function listCategories(options: ListCategoriesOptions): Promise<ListCategoryResponse>
This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
Updates an existing category.
Permission Scopes
For app development, you must have one of the following permission scopes:function updateCategory(_id: string, category: UpdateCategory): Promise<UpdateCategoryResponse>