> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

## Resource: wix-search

## Namespace: wix-search-builder

## Article: Introduction

## Article Link: https://dev.wix.com/docs/velo/apis/wix-search/wix-search-builder/introduction.md

## Article Content:

# Introduction
The `WixSearchBuilder` functions enable you to run, filter, sort, apply facets (categorize), and control
 which results a search returns.

 Typically, you build a search using the [`search()`](https://dev.wix.com/docs/velo/apis/wix-search/search.md) function,
 refine the search by chaining `WixSearchBuilder` functions, and then execute the
 search by chaining a [`find()`](#find) function.

 For example, the following searches a site for all store products containing the phrase
 "shoe" in English that are on sale, sorts them alphabetically according to their SKU, 
 and logs the first 5 results to the console:

 ```javascript
 import wixSearch from 'wix-search';

 wixSearch.search("shoe")
   .language("en")
   .documentType("Stores/Products")
   .eq("onSale", true)
   .ascending("sku")
   .limit(5)
   .find()
   .then( (results) => {
     console.log(results.documents);
   } );
 ```

Only some fields can be searched, filtered, sorted, or faceted. Check the supported schemas for each [`documentType`](#documentType):


 - [Blog/Posts schema](https://support.wix.com/en/article/velo-wix-blog-schema-for-wix-search)
 - [Bookings/Services schema](https://support.wix.com/en/article/velo-wix-bookings-schema-for-wix-search) 
 - [Forum/Content schema](https://support.wix.com/en/article/velo-wix-forum-schema-for-wix-search)
 - [Stores/Products schema](https://support.wix.com/en/article/velo-wix-stores-schema-for-wix-search)


To use the [`and()`](#and), [`or()`](#or), and [`not()`](#not) filtering functions, you first need to create 
`WixSearchFilters` using the [`filter()`](https://dev.wix.com/docs/velo/apis/wix-search/filter.md) function
and the [`WixSearchFilterBuilder`](https://dev.wix.com/docs/velo/apis/wix-search/wix-search-filter-builder/introduction.md) filtering functions. You can then 
pass the `WixSearchFilters` to the `and()`, `or()`, and `not()` functions.

Note that when you chain multiple filtering functions to a `WixSearchBuilder`, an `and` condition is assumed.