> 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: Function Library Resources Reference

## Article: Function Library Resources Reference

## Article Link: https://dev.wix.com/docs/site-extensions/function-libraries/function-library-resources-reference.md

## Article Content:

# Function Library Resources Reference

The `resources` section of a function library manifest points to the library's implementation code. On the published site, Wix loads this code and calls a connected function when its slot is triggered.

## Example

The following example points to the implementation for a generated price-formatting library:

```ts
resources: {
  client: {
    url: './extensions/site/function-libraries/my-function-library/my-function-library.ts',
  },
  moduleSpecifier: '@/my-function-library',
}
```

## Resources fields

A `resources` section has the following fields:

| Field | Required | Description |
| --- | --- | --- |
| `client` | Yes | The library's [implementation](#client-resource). |
| `moduleSpecifier` | No | Module identifier that Wix registers the library under. Maximum 100 characters. See [Module specifier](#module-specifier). |

## Module specifier

Wix registers a library under its `moduleSpecifier`. Give every new function library in a Studio Two site a `moduleSpecifier` that follows these rules:

- It starts with `@/`, followed by the library folder name, such as `@/my-function-library`.
- It's unique in your site. Another function library or Data Source in the site can't use the same value.
- It's 100 characters or fewer, including the prefix.
- You can't change or remove it. After Wix registers a library with a `moduleSpecifier`, Wix rejects a manifest that sets a different value or leaves it out.

`moduleSpecifier` goes directly under `resources`, not under `client`. The generated manifest doesn't include it, so add it yourself. When Wix's AI tools create a function library, they add it for you.

For a library published as an npm package, `moduleSpecifier` is that package's name.

## Client resource

The `client` field points to the library implementation that runs on the live site:

| Field | Required | Description |
| --- | --- | --- |
| `url` | Yes | Path to the library's implementation file. Each function is a named export matching its key in `functions`. |

## See also

- [About Function Libraries](https://dev.wix.com/docs/site-extensions/function-libraries/about-function-libraries.md)
- [Function Libraries](https://dev.wix.com/docs/overview/extensions-framework/site-extensions/function-libraries.md)
- [About Function Libraries in Studio Two](https://dev.wix.com/docs/studio-two/code-your-site/code-model/function-libraries/about-function-libraries.md)
- [About the Function Library Manifest](https://dev.wix.com/docs/site-extensions/function-libraries/about-the-function-library-manifest.md)
- [Function Reference](https://dev.wix.com/docs/site-extensions/function-libraries/function-reference.md)