@wix/agent-skills 1.18.0 → 1.18.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/skills/wix-app/SKILL.md +4 -4
- package/skills/wix-app/references/APP_VALIDATION.md +7 -33
- package/skills/wix-app/references/DASHBOARD_PAGE.md +18 -14
- package/skills/wix-app/references/EDITOR_REACT_COMPONENT.md +75 -92
- package/skills/wix-app/references/WIX_PATTERNS_DOCS.md +23 -26
- package/skills/wix-app/references/dashboard-page/COLLECTION_TOOLKIT.md +7 -6
- package/skills/wix-app/references/dashboard-page/ENTITY_PAGE_TOOLKIT.md +71 -4
- package/skills/wix-app/references/dashboard-page/PATTERNS_BUNDLE_READING.md +67 -7
- package/skills/wix-app/references/editor-react-component/ACCESSIBILITY.md +1 -1
- package/skills/wix-app/references/editor-react-component/ANIMATED-COMPONENTS.md +9 -6
- package/skills/wix-app/references/editor-react-component/COMPONENT-CONTRACT.md +59 -89
- package/skills/wix-app/references/editor-react-component/COMPONENT-PREVIEW.md +23 -4
- package/skills/wix-app/references/editor-react-component/CSS-GUIDELINES.md +29 -14
- package/skills/wix-base44-connector/SKILL.md +168 -48
- package/skills/wix-base44-connector/scripts/{utils.js → utils.cjs} +69 -48
- package/skills/wix-docs/SKILL.md +109 -111
- package/skills/wix-docs/references/API_SPEC_SEARCH.md +35 -23
- package/skills/wix-docs/references/CALLING.md +91 -0
- package/skills/wix-docs/references/EXTRACTING.md +5 -3
- package/skills/wix-headless/references/DOC_DISCOVERY.md +9 -3
- package/skills/wix-headless/references/inline-recipes/setup-forms.md +57 -10
- package/skills/wix-manage/SKILL.md +106 -92
- package/skills/wix-manage/references/dashboard-navigation/routes.json +12 -52
- package/skills/wix-manage/references/ecommerce/shipping/ecom-shipping-api.md +0 -2
- package/skills/wix-manage/references/forms/create-form.md +272 -184
- package/skills/wix-manage/references/forms/forms-dashboard-navigation.md +13 -10
- package/skills/wix-manage/references/forms/update-form.md +122 -0
- package/skills/wix-manage/references/media/generate-image-with-ai.md +86 -0
- package/skills/wix-manage/references/seo/manage-content-plan.md +247 -0
- package/skills/wix-manage/references/seo/manage-seo-tags.md +59 -6
- package/skills/wix-manage/references/stores/change-store-currency.md +10 -0
- package/skills/wix-manage/references/stores/create-product-catalog-v3.md +16 -1
- package/skills/wix-manage/references/stores/update-product-with-options.md +9 -0
- package/skills/wix-vibe-headless/SKILL.md +17 -18
- package/skills/wix-vibe-headless/install/pin-agents-md.cjs +1 -1
- package/skills/wix-vibe-headless/platforms/base44-ecom-light-seed-with-install.md +118 -0
- package/skills/wix-vibe-headless/platforms/base44-ecom-light-seed.md +55 -62
- package/skills/wix-vibe-headless/platforms/base44-ecom-light.md +31 -29
- package/skills/wix-vibe-headless/platforms/base44.md +12 -5
- package/skills/wix-vibe-headless/platforms/generic.md +13 -12
- package/skills/wix-vibe-headless/references/blog/INSTRUCTIONS.md +4 -13
- package/skills/wix-vibe-headless/references/blog/seed/SEED.md +4 -8
- package/skills/wix-vibe-headless/references/blog/seed/{seed-blog.js → seed-blog.cjs} +2 -3
- package/skills/wix-vibe-headless/references/bookings/INSTRUCTIONS.md +5 -14
- package/skills/wix-vibe-headless/references/bookings/seed/SEED.md +5 -9
- package/skills/wix-vibe-headless/references/bookings/seed/{seed-bookings.js → seed-bookings.cjs} +2 -2
- package/skills/wix-vibe-headless/references/bookings/seed/{seed-rentals.js → seed-rentals.cjs} +3 -3
- package/skills/wix-vibe-headless/references/cms/INSTRUCTIONS.md +1 -1
- package/skills/wix-vibe-headless/references/cms/seed/SEED.md +2 -2
- package/skills/wix-vibe-headless/references/events/INSTRUCTIONS.md +4 -13
- package/skills/wix-vibe-headless/references/events/seed/SEED.md +3 -7
- package/skills/wix-vibe-headless/references/events/seed/{seed-events.js → seed-events.cjs} +2 -2
- package/skills/wix-vibe-headless/references/forms/INSTRUCTIONS.md +24 -7
- package/skills/wix-vibe-headless/references/forms/seed/SEED.md +91 -17
- package/skills/wix-vibe-headless/references/members/INSTRUCTIONS.md +4 -13
- package/skills/wix-vibe-headless/references/members/seed/SEED.md +2 -3
- package/skills/wix-vibe-headless/references/portfolio/INSTRUCTIONS.md +4 -13
- package/skills/wix-vibe-headless/references/portfolio/app/components/ProjectMedia.jsx +1 -1
- package/skills/wix-vibe-headless/references/portfolio/seed/SEED.md +3 -7
- package/skills/wix-vibe-headless/references/portfolio/seed/{seed-portfolio.js → seed-portfolio.cjs} +2 -2
- package/skills/wix-vibe-headless/references/pricing-plans/INSTRUCTIONS.md +5 -14
- package/skills/wix-vibe-headless/references/pricing-plans/app/components/OrderCard.jsx +1 -1
- package/skills/wix-vibe-headless/references/pricing-plans/seed/SEED.md +3 -7
- package/skills/wix-vibe-headless/references/pricing-plans/seed/{seed-pricing-plans.js → seed-pricing-plans.cjs} +2 -2
- package/skills/wix-vibe-headless/references/restaurants/INSTRUCTIONS.md +5 -15
- package/skills/wix-vibe-headless/references/restaurants/seed/SEED.md +3 -7
- package/skills/wix-vibe-headless/references/restaurants/seed/{seed-restaurants.js → seed-restaurants.cjs} +2 -2
- package/skills/wix-vibe-headless/references/storefront/INSTRUCTIONS.md +359 -327
- package/skills/wix-vibe-headless/references/storefront/app/context/CartContext.jsx +1 -0
- package/skills/wix-vibe-headless/references/storefront/app/hooks/useProductDetail.js +2 -2
- package/skills/wix-vibe-headless/references/storefront/app/hooks/useShop.js +63 -78
- package/skills/wix-vibe-headless/references/storefront/app/rest/wix-store-catalog.js +59 -43
- package/skills/wix-vibe-headless/references/storefront/seed/SEED.md +46 -10
- package/skills/wix-vibe-headless/references/storefront/seed/{seed-store.js → seed-store.cjs} +163 -25
- package/skills/wix-vibe-headless/references/storefront/app/pages/Shop.jsx +0 -75
|
@@ -20,6 +20,19 @@ Canonical example:
|
|
|
20
20
|
- Assistant: “What product would you like to create? You can upload up to 3 images and I’ll generate the product information from them, or describe the product in text.”
|
|
21
21
|
- Result: **Stop. Do not request structured product fields yet.**
|
|
22
22
|
|
|
23
|
+
## Sections
|
|
24
|
+
|
|
25
|
+
- [Preflight](#preflight-respond-and-return-before-mutation) — whether this turn may mutate at all, and what to answer when it may not
|
|
26
|
+
- [Core flow](#core-flow) — the order the rest of this recipe runs in
|
|
27
|
+
- [Choose the endpoint](#choose-the-endpoint) — single vs bulk, with or without inventory
|
|
28
|
+
- [Build each product](#build-each-product) — the product object: type, media, options, variants, prices, SKUs
|
|
29
|
+
- [Generated descriptions and SEO](#generated-descriptions-and-seo) — what copy written from an image may claim
|
|
30
|
+
- [Add images](#add-images) — uploading a supplied image, or generating one
|
|
31
|
+
- [Wrap the request](#wrap-the-request) — the envelope the chosen endpoint expects
|
|
32
|
+
- [Request projected media](#request-projected-media-when-validating-images) — which fields to project so images are proven on create
|
|
33
|
+
- [Validate before reporting success](#validate-before-reporting-success) — what counts as proof, and what may be claimed
|
|
34
|
+
- [Failure guide](#failure-guide) — reading a rejection
|
|
35
|
+
|
|
23
36
|
## Preflight: respond and return before mutation
|
|
24
37
|
|
|
25
38
|
Name and price are mandatory **workflow inputs for every product**, even when the API schema accepts an omitted price or initializes it to zero. Evaluate the cases below in order. When a case says **RETURN**, end the turn immediately: do not call a create endpoint, do not continue to examples, and do not create first and ask afterward.
|
|
@@ -180,7 +193,9 @@ With no file supplied, create the product and report it as not sellable until on
|
|
|
180
193
|
|
|
181
194
|
## Add images
|
|
182
195
|
|
|
183
|
-
Skip this step when no image was supplied
|
|
196
|
+
Skip this step when no image was supplied — unless the user asked for one to be generated, in which case create it first with [Generate an Image with AI](../media/generate-image-with-ai.md) and continue below with the Media Manager file it returns. Do not offer generation unprompted, and never generate a substitute for a supplied image that failed to upload.
|
|
197
|
+
|
|
198
|
+
Prefer the available dedicated Wix image-upload capability and upload all attachments and public image URLs together. Do not reconstruct that capability inside a general API-execution call. When no dedicated uploader is available, use `POST /site-media/v1/files/import` with the external URL in the body field named exactly `url`—not `importUrl`:
|
|
184
199
|
|
|
185
200
|
```json
|
|
186
201
|
{"url":"https://example.com/product.jpg","mimeType":"image/jpeg","displayName":"Product.jpg","mediaType":"IMAGE"}
|
|
@@ -218,6 +218,14 @@ curl -X PATCH "https://www.wixapis.com/stores/v3/products/{productId}" \
|
|
|
218
218
|
|
|
219
219
|
When updating existing variants, include each existing variant `id`. If no GUID is passed, a variant is created with a new GUID. Each variant object is replaced whole rather than merged, so carry over the fields you are not changing: rebuilding a variant from just its `id` plus the field you want to set drops everything else and is rejected on the first required field it lost (`price must not be empty`). Start from the variant as returned by Get Product and override only what the user asked to change.
|
|
220
220
|
|
|
221
|
+
### Renaming an Existing Choice Is Not Supported
|
|
222
|
+
|
|
223
|
+
`options[].choicesSettings.choices` is immutable once a choice exists — this includes the choice's own `name`. If the user asks to rename, fix a typo in, or standardize the name of an **existing** option choice (for example a shared/reusable customization like "Color" or "Patch Design" that already has variants), do not attempt an Update Product or Update Customization PATCH: it returns `200`, `product.revision`/`customization.revision` increments, but the name is silently left unchanged — confirm this yourself with a fresh Get Product/Get Customization call and you will still see the old name. There is currently no endpoint that renames an existing choice, even when you pass back the same `choiceId` and preserve every other choice, option, and variant exactly.
|
|
224
|
+
|
|
225
|
+
Do not try workarounds that risk the existing variant matrix — do not delete and recreate the choice/option (this destroys all variants using it, along with their prices, SKUs, and inventory), and do not use Set Customization Choices (it fails once the choice is assigned to any product). Tell the user this specific rename isn't possible via the API today and that manually renaming the choice in the Wix dashboard (Site → Products → the product's options) is the only way, or point them to `SupportAndFeedback` to report the gap.
|
|
226
|
+
|
|
227
|
+
This only blocks renaming an *existing* choice. Adding brand-new choices to an option (Add/Bulk Add Customization Choices, or including a new choice name in a full Update Product `options` payload) works normally.
|
|
228
|
+
|
|
221
229
|
### Convert a Simple Product to Color Variants
|
|
222
230
|
|
|
223
231
|
When adding the first option to a simple product, do not preserve a choice-less default variant unchanged. A simple product often has one existing variant with price or stock but no `choices`. After you add a `Color` option, every variant in `variantsInfo.variants` must include choices that match the product options.
|
|
@@ -413,6 +421,7 @@ Confirm from `product.variantsInfo.variants[].digitalProperties.digitalFile` in
|
|
|
413
421
|
- To update `variantsInfo.variants`, also pass `options`, and vice versa. Variants and options are mutually dependent and must stay aligned.
|
|
414
422
|
- When converting a simple product to an optioned product, rebuild the variants list so every variant has `choices`; do not keep an existing choice-less default variant unchanged.
|
|
415
423
|
- Always include `choicesSettings` with the complete list of choices when updating a product with options.
|
|
424
|
+
- An existing choice's `name` can't be changed via Update Product or Update Customization. The request succeeds and revision increments, but the rename is silently dropped — see "Renaming an Existing Choice Is Not Supported" above.
|
|
416
425
|
- Use `optionChoiceNames` rather than `optionChoiceIds` in variants for more reliable updates. Reading them back is not symmetric: Get Product returns each variant's `choices` with `optionChoiceIds` only, and fills in `optionChoiceNames` just when the request's `fields` array includes `"VARIANT_OPTION_CHOICE_NAMES"`. So to find the variant for a named choice such as `Large`, either pass that field and match on the name, or take the choice GUID from `options[].choicesSettings.choices[].choiceId` and match it against `variants[].choices[].optionChoiceIds.choiceId`. Matching on a name the response never carried raises nothing — it just selects no variant.
|
|
417
426
|
- Include the `renderType` in `optionChoiceNames`.
|
|
418
427
|
|
|
@@ -86,34 +86,35 @@ This skill is the deliberately **client-only, REST-only** path. It is independen
|
|
|
86
86
|
genuine gap (a field, an endpoint, or an error the snippets don't cover), extend the client with
|
|
87
87
|
`wixApiRequest` — confirming the exact endpoint, method, and body first. **For that iteration and
|
|
88
88
|
troubleshooting** — finding the right endpoint, reading a method's request/response schema, or
|
|
89
|
-
diagnosing an API error —
|
|
90
|
-
|
|
89
|
+
diagnosing an API error — consult the official Wix API documentation using the documentation
|
|
90
|
+
skill available in your environment to search methods, read pages, and inspect API schemas.
|
|
91
91
|
Reference index: https://dev.wix.com/docs/api-reference.md
|
|
92
92
|
- **Provide the user with deep links to the Wix dashboard**: In many cases, the user will need to modify the default vertical data in the Wix dashboard. Always provide the user with these links. The relevant information for each vertical's links is in its `INSTRUCTIONS.md` file.
|
|
93
93
|
|
|
94
94
|
## How this skill is structured
|
|
95
95
|
|
|
96
|
-
`<SKILL_ROOT>` is this file's directory (strip `/SKILL.md`). Each vertical
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
`<SKILL_ROOT>` is this file's directory (strip `/SKILL.md`). Each vertical supplies integration
|
|
97
|
+
code under `references/<vertical>/app/`: REST helpers in `app/rest/`, and, depending on the
|
|
98
|
+
vertical, utilities, hooks, context, components, or pages. All use the **shared transport** in
|
|
99
99
|
`references/shared/app/` (`app/rest/wix-client.js` + `wix-config.js`, identical for every vertical).
|
|
100
100
|
Set `WIX_CLIENT_ID` (and `WIX_METASITE_ID`) in `wix-config.js`. Deploying `references/<vertical>/app/`
|
|
101
|
-
and `references/shared/app/` into the app's `src/` puts every file in place — the helpers
|
|
101
|
+
and `references/shared/app/` into the app's `src/` puts every file in place — the REST helpers land in
|
|
102
102
|
`src/rest/`, so their relative imports resolve.
|
|
103
103
|
|
|
104
104
|
**Where these files live in the app, and how they get there** (pre-installed at setup, or copied
|
|
105
105
|
in) **is your platform's call — follow your platform instructions for that.**
|
|
106
106
|
|
|
107
|
-
Each vertical's `INSTRUCTIONS.md`
|
|
108
|
-
|
|
109
|
-
|
|
107
|
+
Each vertical's `INSTRUCTIONS.md` specifies its prerequisites, supplied pieces, exported interfaces,
|
|
108
|
+
and the presentation you must build. **Read it before implementation**: reuse the supplied pieces
|
|
109
|
+
and build the missing presentation without reimplementing shipped logic. Follow the platform's
|
|
110
|
+
and vertical's completion guidance where provided.
|
|
110
111
|
|
|
111
112
|
## Routing — pick the vertical(s) from the request
|
|
112
113
|
|
|
113
114
|
Load the vertical(s) the user's app needs; a project may combine several (e.g. a restaurant
|
|
114
115
|
with a blog, or a store with pricing plans).
|
|
115
116
|
|
|
116
|
-
Each vertical's
|
|
117
|
+
Each vertical's integration files ship in `references/<vertical>/app/`; copy that dir plus
|
|
117
118
|
`references/shared/app/` into the app's `src/` (base44 does this at install via `deploy.cjs`).
|
|
118
119
|
|
|
119
120
|
| The user wants… | Vertical | Read |
|
|
@@ -165,14 +166,12 @@ installed, not what the business is about. Never default to store/bookings on si
|
|
|
165
166
|
`references/shared/app/` into the app's `src/`, and set `WIX_CLIENT_ID` in `wix-config.js`. (Where
|
|
166
167
|
and how they get there is your platform's call — see its instructions. On base44 the install step
|
|
167
168
|
writes and verifies `wix-config.js` for you, so there's nothing to set by hand.)
|
|
168
|
-
4. **
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
5. **Verify** against the vertical's checklist before declaring done: token persists across
|
|
175
|
-
reload, live data renders (or a real empty state), and purchases go through the Wix redirect.
|
|
169
|
+
4. **Build the presentation and wire the integration** following the vertical's `INSTRUCTIONS.md`.
|
|
170
|
+
Reuse its supplied pieces through their documented interfaces, build the presentation it leaves
|
|
171
|
+
to you, and connect routes/providers as specified. Do not reimplement shipped logic. Style new
|
|
172
|
+
presentation using the existing platform theme.
|
|
173
|
+
5. **Complete the applicable platform and vertical guidance**, including any required checks and
|
|
174
|
+
handoff instructions they provide.
|
|
176
175
|
|
|
177
176
|
> Some flows need Wix-side setup the user completes later (payments connected, the deployed
|
|
178
177
|
> domain allow-listed on the OAuth client for hosted-checkout return, collection permissions).
|
|
@@ -25,7 +25,7 @@ The Wix skills live under \`.agents/skills/\` — on ANY turn, read them from th
|
|
|
25
25
|
- **events** — publish events and handle RSVPs or ticket sales.
|
|
26
26
|
- **members** — let visitors create an account and sign in — this is **auth**.
|
|
27
27
|
- **restaurants** — publish a menu, take online orders, and manage table reservations.
|
|
28
|
-
-
|
|
28
|
+
- **Documentation fallback** for **frontend code**, **backend code**, or **runtime / API management operations** alike: consult the official Wix API documentation using the documentation skill available in your environment.
|
|
29
29
|
`;
|
|
30
30
|
|
|
31
31
|
const amd = '/app/AGENTS.md';
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# Wix Managed Headless — Base44 storefront client + seed
|
|
2
|
+
|
|
3
|
+
You are building a **Wix Managed** headless storefront inside Base44 — the business is described in your
|
|
4
|
+
initial prompt, and the Wix connector is already configured.
|
|
5
|
+
|
|
6
|
+
The shipped client is already configured. Use its documented hooks and components; no ID lookup
|
|
7
|
+
or configuration changes are needed.
|
|
8
|
+
|
|
9
|
+
> **The Wix skills installed below are the complete build and seed path for this app.** **Do NOT use the Base44 commerce kit (or any Base44 solution kit).**
|
|
10
|
+
|
|
11
|
+
**Banner disabled for this entry flow:** do not add `<WixManageBanner/>`; skip the shared
|
|
12
|
+
storefront instructions' optional banner integration.
|
|
13
|
+
|
|
14
|
+
Follow STEPs 1–4 below exactly (run STEP 3 in parallel with STEP 2).
|
|
15
|
+
|
|
16
|
+
## STEP 1 — Install the Wix skills and deploy the storefront vertical to the app
|
|
17
|
+
|
|
18
|
+
Install three skills — they land under `.agents/skills/`:
|
|
19
|
+
- **`wix-vibe-headless`** — storefront build instructions, hook/component contracts, and seeding modules.
|
|
20
|
+
- **`wix-manage`** — REST recipes for managing and configuring the Wix site.
|
|
21
|
+
- **`wix-base44-connector`** — Wix connector usage, API contracts, and documentation discovery.
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
Run this through exec_tool, exactly as written — installs all three skills, deploys the `storefront` REST scaffolds + UI into `src/`, and pins the AGENTS.md note.
|
|
25
|
+
|
|
26
|
+
```js
|
|
27
|
+
const { execSync } = require('child_process');
|
|
28
|
+
const { existsSync, readdirSync } = require('fs');
|
|
29
|
+
const results = {};
|
|
30
|
+
for (const skill of ['wix-vibe-headless', 'wix-manage', 'wix-base44-connector']) {
|
|
31
|
+
if (existsSync(`/app/.agents/skills/${skill}/SKILL.md`)) { results[skill] = 'already_installed'; continue; }
|
|
32
|
+
try {
|
|
33
|
+
const out = execSync(`CI=1 npx -y skills add wix/skills/skills/${skill} --yes 2>&1`,
|
|
34
|
+
{ cwd: '/app', timeout: 60000, shell: '/bin/bash' }).toString().replace(/\x1b\[[0-9;]*m/g, '');
|
|
35
|
+
results[skill] = /installed 1 skill|found 1 skill/i.test(out) ? 'success'
|
|
36
|
+
: out.includes('No valid skills') ? 'not_found' : 'unknown';
|
|
37
|
+
} catch (e) { results[skill] = 'error: ' + e.message; }
|
|
38
|
+
}
|
|
39
|
+
const deploy = execSync(`node /app/.agents/skills/wix-vibe-headless/install/deploy.cjs storefront`, { cwd: '/app' }).toString();
|
|
40
|
+
const agentsMd = execSync(`node /app/.agents/skills/wix-vibe-headless/install/pin-agents-md.cjs`, { cwd: '/app' }).toString();
|
|
41
|
+
return { results, installed: readdirSync('/app/.agents/skills'), deploy: JSON.parse(deploy), agentsMd: JSON.parse(agentsMd) };
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## STEP 2 — Build the client
|
|
45
|
+
|
|
46
|
+
Read `.agents/skills/wix-vibe-headless/references/storefront/INSTRUCTIONS.md` and follow it **EXACTLY** — the single source of truth for how the storefront client is built.
|
|
47
|
+
|
|
48
|
+
The shipped storefront provides catalog, cart, and checkout. Identify the additional workflows
|
|
49
|
+
in the user's request and implement them alongside the storefront. If a workflow needs an
|
|
50
|
+
external service or missing information, continue the work you can complete and identify the
|
|
51
|
+
remaining dependency.
|
|
52
|
+
|
|
53
|
+
For code or actions not covered by this skill, read and follow the installed connector skill at
|
|
54
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs.
|
|
55
|
+
|
|
56
|
+
Build the client using the component outlines, interfaces, and theme guidance in `INSTRUCTIONS.md`.
|
|
57
|
+
The shipped files are already deployed and configured; you do not need to read their source or
|
|
58
|
+
rebuild them. If you encounter an error after building the client, read or change whatever you
|
|
59
|
+
need to diagnose and fix it.
|
|
60
|
+
|
|
61
|
+
## STEP 3 — Seed the storefront
|
|
62
|
+
|
|
63
|
+
**Never delete or clean up anything on the user's site — seeding is additive only.** It's a live
|
|
64
|
+
user-owned business, so never delete or overwrite existing content, even apparent sample data. If a
|
|
65
|
+
cleanup truly seems needed, ask the user first.
|
|
66
|
+
|
|
67
|
+
Seed by calling the storefront's ready-made seed module, `seed-store.cjs` — `require()` it and use its
|
|
68
|
+
one-call `setupStore` (build-time exec_tool). Read
|
|
69
|
+
`.agents/skills/wix-vibe-headless/references/storefront/seed/SEED.md` for the full `setupStore`
|
|
70
|
+
contract — the `ctx` and the product/category shapes.
|
|
71
|
+
|
|
72
|
+
```js
|
|
73
|
+
const seed = require(require("path").resolve(".agents/skills/wix-vibe-headless/references/storefront/seed/seed-store.cjs"));
|
|
74
|
+
const result = await seed.setupStore(ctx, { products, categories }); // one call: install → products → categories → images
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
For code or actions not covered by this skill, read and follow the installed connector skill at
|
|
78
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs.
|
|
79
|
+
|
|
80
|
+
**Auth for these admin calls is the already-configured Wix headless connector — nothing else.** Get its
|
|
81
|
+
access token and send it as a bearer token:
|
|
82
|
+
|
|
83
|
+
```js
|
|
84
|
+
const { accessToken } = await base44.asServiceRole.connectors.getConnection("wix");
|
|
85
|
+
// then: fetch(url, { headers: { Authorization: `Bearer ${accessToken}`, "Content-Type": "application/json" }, ... })
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Inline via exec_tool, `base44` is already declared — use it directly; do **not** import
|
|
89
|
+
`@base44/sdk`, re-declare it, or call `createClient()` (that's for standalone `.js` files only;
|
|
90
|
+
inline it throws *"Identifier 'base44' has already been declared."*).
|
|
91
|
+
|
|
92
|
+
**Product images.** Generate with **Base44's built-in image generation**, then attach via the
|
|
93
|
+
storefront seed module's image-attach step.
|
|
94
|
+
|
|
95
|
+
**Seed images with the FINAL url, in one call.** Use the real `https://media.base44.com/...` url
|
|
96
|
+
from the **completed** `generate_image` result and pass it straight into your single `setupStore`
|
|
97
|
+
call (images included). `generate_image` runs in the background while you build the client, so the
|
|
98
|
+
urls are ready by the time you seed.
|
|
99
|
+
|
|
100
|
+
## STEP 4 — Wrap up
|
|
101
|
+
|
|
102
|
+
### Preview
|
|
103
|
+
|
|
104
|
+
Images that are still generating may show `/__generating__/…` placeholders;
|
|
105
|
+
the platform replaces these automatically at turn end, with a stock fallback if generation
|
|
106
|
+
fails. You can finish without waiting for those images or replacing their placeholder URLs.
|
|
107
|
+
|
|
108
|
+
### Final text response
|
|
109
|
+
|
|
110
|
+
**Never paste a Wix dashboard link or path.**
|
|
111
|
+
|
|
112
|
+
**Before writing your final text response, make one handoff call** — `search_base44_docs(query="how do I manage my store's products, orders and inventory?", prefer_dashboard=true)`. Use its handoff guidance, note that the seeded catalog is mock data they can edit, replace or delete, and state any requested workflows that remain unfinished and what is needed to complete them.
|
|
113
|
+
|
|
114
|
+
## Additional Wix functionality
|
|
115
|
+
|
|
116
|
+
During the initial build or later, use the installed connector skill at
|
|
117
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs for writing code
|
|
118
|
+
or performing actions not covered by this skill.
|
|
@@ -3,65 +3,64 @@
|
|
|
3
3
|
You are building a **Wix Managed** headless storefront inside Base44 — the business is described in your
|
|
4
4
|
initial prompt, and the Wix connector is already configured.
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
The shipped client is already configured. Use its documented hooks and components; no ID lookup
|
|
7
|
+
or configuration changes are needed.
|
|
8
8
|
|
|
9
|
-
> **The Wix skills
|
|
9
|
+
> **The installed Wix skills are the complete build and seed path for this app.** **Do NOT use the Base44 commerce kit (or any Base44 solution kit).**
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
**Banner disabled for this entry flow:** do not add `<WixManageBanner/>`; skip the shared
|
|
12
|
+
storefront instructions' optional banner integration.
|
|
12
13
|
|
|
13
|
-
## STEP
|
|
14
|
+
## STEP 0 — Setup already completed by Base44
|
|
14
15
|
|
|
15
|
-
|
|
16
|
-
- **`wix-vibe-headless`** —
|
|
17
|
-
- **`wix-manage`** — REST recipes for managing and configuring the site
|
|
18
|
-
|
|
19
|
-
- **`wix-base44-connector`** — building on Wix from the Base44 sandbox: site context, API
|
|
20
|
-
contracts, and the docs **fallback** — find + read the Wix API docs for anything
|
|
21
|
-
`wix-vibe-headless` doesn't cover.
|
|
16
|
+
These skills are already installed under `.agents/skills/`:
|
|
17
|
+
- **`wix-vibe-headless`** — storefront build instructions, hook/component contracts, and seeding modules.
|
|
18
|
+
- **`wix-manage`** — REST recipes for managing and configuring the Wix site.
|
|
19
|
+
- **`wix-base44-connector`** — Wix connector usage, API contracts, and documentation discovery.
|
|
22
20
|
|
|
23
|
-
|
|
21
|
+
Base44 has also deployed the storefront hooks, cart components/context, image helpers, and REST
|
|
22
|
+
scaffolds into `src/`, configured the Wix connector/client, and added the Wix note to `AGENTS.md`.
|
|
23
|
+
No installation, deployment, or AGENTS.md update is needed.
|
|
24
|
+
The deployed implementation and configuration files do not need to be read; use the build and seed
|
|
25
|
+
guides below for their contracts and usage. Continue with STEP 1.
|
|
24
26
|
|
|
25
|
-
|
|
26
|
-
const { execSync } = require('child_process');
|
|
27
|
-
const { existsSync, readdirSync } = require('fs');
|
|
28
|
-
const results = {};
|
|
29
|
-
for (const skill of ['wix-vibe-headless', 'wix-manage', 'wix-base44-connector']) {
|
|
30
|
-
if (existsSync(`/app/.agents/skills/${skill}/SKILL.md`)) { results[skill] = 'already_installed'; continue; }
|
|
31
|
-
try {
|
|
32
|
-
const out = execSync(`CI=1 npx -y skills add wix/skills/skills/${skill} --yes 2>&1`,
|
|
33
|
-
{ cwd: '/app', timeout: 60000, shell: '/bin/bash' }).toString().replace(/\x1b\[[0-9;]*m/g, '');
|
|
34
|
-
results[skill] = /installed 1 skill|found 1 skill/i.test(out) ? 'success'
|
|
35
|
-
: out.includes('No valid skills') ? 'not_found' : 'unknown';
|
|
36
|
-
} catch (e) { results[skill] = 'error: ' + e.message; }
|
|
37
|
-
}
|
|
38
|
-
const deploy = execSync(`node /app/.agents/skills/wix-vibe-headless/install/deploy.cjs storefront`, { cwd: '/app' }).toString();
|
|
39
|
-
const agentsMd = execSync(`node /app/.agents/skills/wix-vibe-headless/install/pin-agents-md.cjs`, { cwd: '/app' }).toString();
|
|
40
|
-
return { results, installed: readdirSync('/app/.agents/skills'), deploy: JSON.parse(deploy), agentsMd: JSON.parse(agentsMd) };
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
Read skills with **`read_file`** using workspace-relative paths (e.g. `.agents/skills/wix-vibe-headless/SKILL.md`) — absolute `/app/...` fails. Always read from `.agents/skills/` exactly on every turn; ignore stray copies like `agent/skills/`.
|
|
27
|
+
Follow STEPs 1–3 below exactly (run STEP 2 in parallel with STEP 1).
|
|
44
28
|
|
|
45
|
-
## STEP
|
|
29
|
+
## STEP 1 — Build the client
|
|
46
30
|
|
|
47
31
|
Read `.agents/skills/wix-vibe-headless/references/storefront/INSTRUCTIONS.md` and follow it **EXACTLY** — the single source of truth for how the storefront client is built.
|
|
48
32
|
|
|
49
|
-
|
|
33
|
+
The shipped storefront provides catalog, cart, and checkout. Identify the additional workflows
|
|
34
|
+
in the user's request and implement them alongside the storefront. If a workflow needs an
|
|
35
|
+
external service or missing information, continue the work you can complete and identify the
|
|
36
|
+
remaining dependency.
|
|
50
37
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
rejects the write. Wire routes/imports in with `find_replace`, leave the rest as-is.
|
|
38
|
+
For code or actions not covered by this skill, read and follow the installed connector skill at
|
|
39
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs.
|
|
54
40
|
|
|
55
|
-
|
|
41
|
+
Build the client using the component outlines, interfaces, and theme guidance in `INSTRUCTIONS.md`.
|
|
42
|
+
The shipped files are already deployed and configured; you do not need to read their source or
|
|
43
|
+
rebuild them. If you encounter an error after building the client, read or change whatever you
|
|
44
|
+
need to diagnose and fix it.
|
|
45
|
+
|
|
46
|
+
## STEP 2 — Seed the storefront
|
|
56
47
|
|
|
57
48
|
**Never delete or clean up anything on the user's site — seeding is additive only.** It's a live
|
|
58
49
|
user-owned business, so never delete or overwrite existing content, even apparent sample data. If a
|
|
59
50
|
cleanup truly seems needed, ask the user first.
|
|
60
51
|
|
|
61
|
-
Seed by calling the storefront's ready-made seed module —
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
52
|
+
Seed by calling the storefront's ready-made seed module, `seed-store.cjs` — `require()` it and use its
|
|
53
|
+
one-call `setupStore` (build-time exec_tool). Read
|
|
54
|
+
`.agents/skills/wix-vibe-headless/references/storefront/seed/SEED.md` for the full `setupStore`
|
|
55
|
+
contract — the `ctx` and the product/category shapes.
|
|
56
|
+
|
|
57
|
+
```js
|
|
58
|
+
const seed = require(require("path").resolve(".agents/skills/wix-vibe-headless/references/storefront/seed/seed-store.cjs"));
|
|
59
|
+
const result = await seed.setupStore(ctx, { products, categories }); // one call: install → products → categories → images
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
For code or actions not covered by this skill, read and follow the installed connector skill at
|
|
63
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs.
|
|
65
64
|
|
|
66
65
|
**Auth for these admin calls is the already-configured Wix headless connector — nothing else.** Get its
|
|
67
66
|
access token and send it as a bearer token:
|
|
@@ -76,35 +75,29 @@ Inline via exec_tool, `base44` is already declared — use it directly; do **not
|
|
|
76
75
|
inline it throws *"Identifier 'base44' has already been declared."*).
|
|
77
76
|
|
|
78
77
|
**Product images.** Generate with **Base44's built-in image generation**, then attach via the
|
|
79
|
-
storefront seed module's image-attach step
|
|
80
|
-
doesn't cover it.
|
|
78
|
+
storefront seed module's image-attach step.
|
|
81
79
|
|
|
82
80
|
**Seed images with the FINAL url, in one call.** Use the real `https://media.base44.com/...` url
|
|
83
81
|
from the **completed** `generate_image` result and pass it straight into your single `setupStore`
|
|
84
|
-
call (images included).
|
|
85
|
-
— Wix can't fetch it. `generate_image` runs in the background while you build the client, so the
|
|
82
|
+
call (images included). `generate_image` runs in the background while you build the client, so the
|
|
86
83
|
urls are ready by the time you seed.
|
|
87
84
|
|
|
88
|
-
## STEP
|
|
85
|
+
## STEP 3 — Wrap up
|
|
89
86
|
|
|
90
|
-
|
|
87
|
+
### Preview
|
|
91
88
|
|
|
92
|
-
|
|
89
|
+
Images that are still generating may show `/__generating__/…` placeholders;
|
|
90
|
+
the platform replaces these automatically at turn end, with a stock fallback if generation
|
|
91
|
+
fails. You can finish without waiting for those images or replacing their placeholder URLs.
|
|
93
92
|
|
|
94
|
-
|
|
93
|
+
### Final text response
|
|
95
94
|
|
|
96
|
-
|
|
95
|
+
**Never paste a Wix dashboard link or path.**
|
|
97
96
|
|
|
98
|
-
|
|
97
|
+
**Before writing your final text response, make one handoff call** — `search_base44_docs(query="how do I manage my store's products, orders and inventory?", prefer_dashboard=true)`. Use its handoff guidance, note that the seeded catalog is mock data they can edit, replace or delete, and state any requested workflows that remain unfinished and what is needed to complete them.
|
|
99
98
|
|
|
100
|
-
|
|
101
|
-
const { accessToken } = await base44.asServiceRole.connectors.getConnection("wix");
|
|
102
|
-
const res = await fetch("https://www.wixapis.com/<api-path>", {
|
|
103
|
-
method: "POST",
|
|
104
|
-
headers: { Authorization: `Bearer ${accessToken}`, "Content-Type": "application/json" },
|
|
105
|
-
body: JSON.stringify({ /* request body */ }),
|
|
106
|
-
});
|
|
107
|
-
return await res.json();
|
|
108
|
-
```
|
|
99
|
+
## Additional Wix functionality
|
|
109
100
|
|
|
110
|
-
|
|
101
|
+
During the initial build or later, use the installed connector skill at
|
|
102
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs for writing code
|
|
103
|
+
or performing actions not covered by this skill.
|
|
@@ -3,22 +3,23 @@
|
|
|
3
3
|
You are building a **Wix Managed** headless storefront inside Base44 — the business is described in your
|
|
4
4
|
initial prompt, and the Wix connector is already configured.
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
The shipped client is already configured. Use its documented hooks and components; no ID lookup
|
|
7
|
+
or configuration changes are needed.
|
|
8
8
|
|
|
9
9
|
> **The Wix skills installed below are the complete build path for this app.** **Do NOT use the Base44 commerce kit (or any Base44 solution kit).** **This flow builds the client only — there is no seeding step.**
|
|
10
10
|
|
|
11
|
+
**Banner disabled for this entry flow:** do not add `<WixManageBanner/>`; skip the shared
|
|
12
|
+
storefront instructions' optional banner integration.
|
|
13
|
+
|
|
11
14
|
Follow STEPs 1–3 below exactly.
|
|
12
15
|
|
|
13
16
|
## STEP 1 — Install the Wix skills and deploy the storefront vertical to the app
|
|
14
17
|
|
|
15
18
|
Install three skills — they land under `.agents/skills/`:
|
|
16
|
-
- **`wix-vibe-headless`** —
|
|
17
|
-
- **`wix-manage`** — REST recipes for managing and configuring the site
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
contracts, and the docs **fallback** — find + read the Wix API docs for anything
|
|
21
|
-
`wix-vibe-headless` doesn't cover.
|
|
19
|
+
- **`wix-vibe-headless`** — storefront build instructions, hook/component contracts, and seeding modules.
|
|
20
|
+
- **`wix-manage`** — REST recipes for managing and configuring the Wix site.
|
|
21
|
+
- **`wix-base44-connector`** — Wix connector usage, API contracts, and documentation discovery.
|
|
22
|
+
|
|
22
23
|
|
|
23
24
|
Run this through exec_tool, exactly as written — installs all three skills, deploys the `storefront` REST scaffolds + UI into `src/`, and pins the AGENTS.md note.
|
|
24
25
|
|
|
@@ -40,40 +41,41 @@ const agentsMd = execSync(`node /app/.agents/skills/wix-vibe-headless/install/pi
|
|
|
40
41
|
return { results, installed: readdirSync('/app/.agents/skills'), deploy: JSON.parse(deploy), agentsMd: JSON.parse(agentsMd) };
|
|
41
42
|
```
|
|
42
43
|
|
|
43
|
-
Read skills with **`read_file`** using workspace-relative paths (e.g. `.agents/skills/wix-vibe-headless/SKILL.md`) — absolute `/app/...` fails. Always read from `.agents/skills/` exactly on every turn; ignore stray copies like `agent/skills/`.
|
|
44
|
-
|
|
45
44
|
## STEP 2 — Build the client
|
|
46
45
|
|
|
47
46
|
Read `.agents/skills/wix-vibe-headless/references/storefront/INSTRUCTIONS.md` and follow it **EXACTLY** — the single source of truth for how the storefront client is built.
|
|
48
47
|
|
|
49
|
-
|
|
48
|
+
The shipped storefront provides catalog, cart, and checkout. Identify the additional workflows
|
|
49
|
+
in the user's request and implement them alongside the storefront. If a workflow needs an
|
|
50
|
+
external service or missing information, continue the work you can complete and identify the
|
|
51
|
+
remaining dependency.
|
|
50
52
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
53
|
+
For code or actions not covered by this skill, read and follow the installed connector skill at
|
|
54
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs.
|
|
55
|
+
|
|
56
|
+
Build the client using the component outlines, interfaces, and theme guidance in `INSTRUCTIONS.md`.
|
|
57
|
+
The shipped files are already deployed and configured; you do not need to read their source or
|
|
58
|
+
rebuild them. If you encounter an error after building the client, read or change whatever you
|
|
59
|
+
need to diagnose and fix it.
|
|
54
60
|
|
|
55
61
|
## STEP 3 — Wrap up
|
|
56
62
|
|
|
57
63
|
**No seeding in this flow** — the client is the only deliverable. Do not seed, populate, or write data to Wix.
|
|
58
64
|
|
|
59
|
-
|
|
65
|
+
### Preview
|
|
60
66
|
|
|
61
|
-
|
|
67
|
+
Images that are still generating may show `/__generating__/…` placeholders;
|
|
68
|
+
the platform replaces these automatically at turn end, with a stock fallback if generation
|
|
69
|
+
fails. You can finish without waiting for those images or replacing their placeholder URLs.
|
|
62
70
|
|
|
63
|
-
|
|
71
|
+
### Final text response
|
|
64
72
|
|
|
65
|
-
|
|
73
|
+
**Never paste a Wix dashboard link or path.**
|
|
66
74
|
|
|
67
|
-
|
|
75
|
+
**Before writing your final text response, make one handoff call** — `search_base44_docs(query="how do I manage my store's products, orders and inventory?", prefer_dashboard=true)`. Use its handoff guidance, state any requested workflows that remain unfinished and what is needed to complete them.
|
|
68
76
|
|
|
69
|
-
|
|
70
|
-
const { accessToken } = await base44.asServiceRole.connectors.getConnection("wix");
|
|
71
|
-
const res = await fetch("https://www.wixapis.com/<api-path>", {
|
|
72
|
-
method: "POST",
|
|
73
|
-
headers: { Authorization: `Bearer ${accessToken}`, "Content-Type": "application/json" },
|
|
74
|
-
body: JSON.stringify({ /* request body */ }),
|
|
75
|
-
});
|
|
76
|
-
return await res.json();
|
|
77
|
-
```
|
|
77
|
+
## Additional Wix functionality
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
During the initial build or later, use the installed connector skill at
|
|
80
|
+
`.agents/skills/wix-base44-connector/SKILL.md` to find Wix documentation and APIs for writing code
|
|
81
|
+
or performing actions not covered by this skill.
|
|
@@ -8,11 +8,14 @@ only), safe in the frontend; use it directly for the Wix client setup.
|
|
|
8
8
|
|
|
9
9
|
> **The Wix skills installed below are the complete build and seed path for this app — the Wix connector supplies the token for admin API calls.** **Do NOT use the Base44 commerce kit (or any Base44 solution kit).**
|
|
10
10
|
|
|
11
|
+
**Banner enabled for this entry flow:** mount `<WixManageBanner/>` once in the Layout, above
|
|
12
|
+
the header in the fixed top region, per the vertical instructions. It is preview-only.
|
|
13
|
+
|
|
11
14
|
Follow STEPs 1–5 below exactly (run STEP 4 in parallel with STEP 3 — **except `forms`**, see STEP 3).
|
|
12
15
|
|
|
13
16
|
## STEP 1 — Install the Wix skills locally
|
|
14
17
|
|
|
15
|
-
Install three skills under `.agents/skills/`: **`wix-vibe-headless`** (the client build + seed guide — your main source of truth), **`wix-manage`** (REST recipes to manage/configure the site), and **`wix-base44-connector`** (site context + API-doc discovery
|
|
18
|
+
Install three skills under `.agents/skills/`: **`wix-vibe-headless`** (the client build + seed guide — your main source of truth), **`wix-manage`** (REST recipes to manage/configure the site), and **`wix-base44-connector`** (site context + API-doc discovery).
|
|
16
19
|
|
|
17
20
|
Run this through exec_tool, exactly as written — installs all three skills, deploys REST scaffolds + UI into `src/`, writes `wix-config.js`, and pins the AGENTS.md note.
|
|
18
21
|
|
|
@@ -96,7 +99,7 @@ rejects the write. Wire routes/imports in with `find_replace`, leave the rest as
|
|
|
96
99
|
Seed by calling your vertical's ready-made seed module — read
|
|
97
100
|
`.agents/skills/wix-vibe-headless/references/<vertical>/seed/SEED.md` and follow it (the loader
|
|
98
101
|
snippet, admin connector token, entity images with the final `media.base44.com` url, and every field
|
|
99
|
-
shape are there). Gaps or an unexpected shape → the
|
|
102
|
+
shape are there). Gaps or an unexpected shape → the documentation skill available in your environment.
|
|
100
103
|
Seeding is **admin-only** — not part of the client, which is built solely per the `wix-vibe-headless` skill.
|
|
101
104
|
|
|
102
105
|
- **Additive only:** never delete or overwrite the user's content, even apparent sample data; ask first if a cleanup truly seems needed.
|
|
@@ -104,14 +107,18 @@ Seeding is **admin-only** — not part of the client, which is built solely per
|
|
|
104
107
|
|
|
105
108
|
## STEP 5 — Wrap up
|
|
106
109
|
|
|
107
|
-
|
|
108
|
-
2. **Ask the user to open** `https://manage.wix.com/dashboard/{metaSiteId}` (your metasite id) to complete setup in Wix.
|
|
110
|
+
**Ask the user to open** `https://manage.wix.com/dashboard/{metaSiteId}` (your metasite id) to complete setup in Wix.
|
|
109
111
|
|
|
110
112
|
**Don't chase images.** A `/__generating__/…` placeholder is swapped for the final url automatically at turn end — do **not** edit, re-seed, or debug image urls.
|
|
111
113
|
|
|
112
114
|
## Later admin requests
|
|
113
115
|
|
|
114
116
|
For any later admin/management request, work as in STEP 4: your vertical's seed module first, else
|
|
115
|
-
|
|
117
|
+
consult official Wix API documentation using the documentation skill available in your environment.
|
|
118
|
+
Keep admin calls on the connected Wix connector.
|
|
119
|
+
|
|
120
|
+
**A change to what the business data COLLECTS is one of these, however UI it sounds** — a new form
|
|
121
|
+
field, product option or service setting. Change it on Wix first per the vertical's `seed/SEED.md`,
|
|
122
|
+
then edit the client against the verified result.
|
|
116
123
|
|
|
117
124
|
version: v1341
|