queryPolicies( )


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 up to 100 booking policies (SDK | REST), and information about the services that are connected to them, given the provided filtering, paging, and sorting.

Defaults

Query Policies has the following default settings, which you can override:

  • Sorted by id in ascending order.
  • cursorPaging.limit set to 100.

Filters

For a complete list of supported filters, refer to Booking Policies API: Supported Filters (REST).

When using date filters, you must use UTC time.

Returned services

If a booking policy is connected to more than 5 services, only a subset of those services is returned. The bookingPolicies.totalServiceCount values indicate the total number of services linked to each policy. You can call Search Services (SDK | REST) and specify the relevant policy ID in the filter to retrieve all services connected to the booking policy.

See also

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

Permissions
Manage Bookings Services and Settings
Manage Bookings - all permissions
Read Bookings - all read permissions
Manage Bookings
Read Bookings - Public Data
Read Bookings - Including Participants
Learn more about app permissions.
Method Declaration
Copy
Method Parameters
queryCursorQueryRequired

Information about filters, paging, and sorting. See the article about booking policy filters (REST) for all supported filters and sorting options.

Returns
Return Type:Promise<QueryPoliciesResponse>
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?