queryPackages( )


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 packages, given the provided paging, filtering, and sorting.

You must pass the ID of the Wix account that the packages belong to in the header of the call. The call returns packages that belong to the parent account, regardless if you pass the ID of a parent or sub-account. In case you want to retrieve only packages that belong to a sub-account, you must pass the sub-account ID as filter in the query object like this:

Copy

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

  • createdDate is sorted in DESC order
  • cursorPaging.limit is 100

By default pagingMetadata.cursors are returned, unless you specifically pass query.paging.

The maximum for cursorPaging.limit is 100.

If you pass a cursor token that you have received in a previous Query Package response, passing additional sort or filter information results in an invalid cursor error. Since the received cursor token already holds all the needed information for sort and filter. Changing the sort and filter properties during the span of a cursor query isn't supported. But you can provide a different limit.

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

Important: This call requires an account level API key and cannot be authenticated with the standard authorization header.

Authentication

This method may require higher-level permissions than the caller has, based on their identity and roles and permissions. In these cases, you can ensure the method is called with the required level of authorization by using one of the following:

Permissions
Manage Reseller Packages
Learn more about app permissions.
Method Declaration
Copy
Request
This method does not take any parameters
Returns
Errors

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

Did this help?