Wix Vibe Headless
WixOfficialPublished by Wix
- Skill
- Tool integration
- Automation and integrations
- MIT
- Low risk
- Has scripts
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
Wix Vibe Headless provides a set of dependency-free REST helpers and integration guides to connect existing frontend projects to live Wix sites. It enables developers to display Wix business data—such as store products, blog posts, bookings, and events—directly in their own applications without using the Wix SDK, backend infrastructure, or complex build steps. The skill is designed for read-only access to owner content, ensuring that data remains synchronized with the Wix dashboard.
What it does
- Connects frontends to Wix sites using a public WIX_CLIENT_ID.
- Provides REST helpers for Stores, Bookings, Blog, Events, and other Wix business solutions.
- Supports member login and gated content without redirecting to Wix-hosted pages.
- Maintains visitor sessions using tokens persisted in local storage.
- Offers structured guidance for wiring data into HTML, JSX, or Vite projects.
- Ensures consistent data rendering by using formatted values from Wix API objects.
When to use it
- When you need to display live Wix site data in a custom frontend application.
- When you want to add shopping, booking, or membership flows to an existing project.
- When you prefer a client-only, dependency-free integration over the Wix SDK.
- When you are working with a vibe-coded app, HTML/JSX, or a design-tool export.
Advantages
- No backend or build step required for integration.
- Dependency-free implementation using standard REST calls.
- Maintains a single source of truth for business data in the Wix dashboard.
- Supports custom UI design while leveraging Wix's business logic.
Usage examples
- “Connect my React app to my Wix store products.”
- The agent identifies the storefront vertical, copies the necessary REST helpers to the src directory, and provides instructions to wire the product grid component.
- “How do I add a blog feed to my Vite project using my Wix site?”
- The agent verifies the blog vertical, sets up the taxonomy context, and guides the integration of the shipped post-grid and post-detail components.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/wix/wix-vibe-headless/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip wix-vibe-headless.zip -d .agents/skills
Documentation by Wix
Wix Vibe Headless — client-only REST connectors
Wire an existing front end to a live Wix site from the browser, over the site's public
WIX_CLIENT_ID, using hand-rolled REST — no @wix/sdk, no backend, no build step, no
dependencies. One skill, one shared transport, and a copy-as-is REST layer per Wix
business solution. Everything is read-only over the owner's content: render live Wix
data or an honest empty state — never mock, never provision, never invent products,
posts, events, menus, plans, reviews, or counts.
When to use this skill
The user has (or is building) a front end — a vibe-coded app, plain HTML/JSX, a Vite/React project, a design-tool export — and wants it to show live data from their existing Wix site and complete real purchases/bookings, all from the client.
They hand you a public
WIX_CLIENT_IDand ask to "connect this to my Wix store / blog / bookings / events / …".They want to replace placeholder/mock data with real Wix content, or add a cart, checkout, booking, RSVP, ticketing, reservation, form, or subscribe flow over an app they already have.
When NOT to use this skill
| Scenario | Use instead |
|---|---|
| Build a new Wix site end-to-end from one prompt (discovery → design → build → host) | wix-headless |
The project should use the Wix SDK (@wix/sdk) and/or the Wix CLI, or be hosted on Wix | wix-headless |
| Manage/configure the site via REST (install apps, seed catalogs, set up business solutions) | wix-manage |
| Build a Wix app extension (dashboard page, widget, backend, plugin) | wix-app |
This skill is the deliberately client-only, REST-only path. It is independent from
wix-headless (which is SDK + CLI + hosting) — do not mix the two in one project.
The shared model (applies to every vertical)
Auth = one public client id.
WIX_CLIENT_IDis a buyer/visitor-facing credential — it only mints anonymous visitor tokens. It is not a secret; hardcoding and committing it is fine. The user provides it (their vibe/host platform surfaces a copyable prompt with the id filled in). Paste it intowix-config.jsin place of the<YOUR-CLIENT-ID>placeholder.Money/price fields are objects, never scalars. Every price/amount a Wix API returns — Stores
price.actualPrice, Bookings servicepayment.fixed.price, Events ticketregistration.tickets.lowestPrice, and the rest — has the shape{ value, currency, formattedValue }. RenderformattedValue(it already includes the currency symbol), or fall back to building fromvalue+currency. Never drop the object straight into the UI or treat it as a number/string — that renders[object Object]or a bare unformatted number. Donations exception: campaign prices use{ amount, formattedAmount }, with a decimal-stringamount; donation cartoptions.amountmust instead be a JSON number. Follow the Donations recipe.Visitor token = identity.
wix-client.jsmints an anonymous visitor token, persists the refresh token tolocalStorage, and refreshes on expiry. That token IS the identity of the cart / reservation / member session — never re-mint anonymously per load or the cart silently empties.Member login swaps the token set on the same client. The members vertical is custom login — the front owns its login UI; the member is never redirected to a Wix-hosted login page. On success it writes the member's tokens into the same store the visitor token used (
setSessionTokens), so every subsequentwixApiRequestruns as the member and the cart/session carries over. "My …" surfaces (plans, orders, bookings, registrations) light up only once logged in.⚠️ Once you're building on Wix, keep it on Wix — auth, member data, and other business features too. If you're wiring a Wix storefront/blog/etc. over
WIX_CLIENT_ID, prefer Wix for the rest of the app as well, rather than reaching for a host platform's own backend or login. Especially for auth: when the user wants members, log them in as a Wix member (membersvertical) — don't bolt on the host platform's auth. Likewise, member-generated content (likes, reviews, submissions, "my …" lists) goes in a Wix CMS collection (cmsvertical), not a host database.The split-brain trap: the most common failure is mixing the two — e.g. storing "likes" in the host's DB while identifying the member from the Wix session (or logging in with Wix members but keying data on a host user id). The two identities never match, ownership filters silently return nothing (a like vanishes on refresh), and the data never sits with the rest of the Wix content.
Rule of thumb: one store and one identity per feature. For a Wix-backed feature that's the Wix member + the Wix collection, with ownership on Wix's server-stamped
_owner(never a hand-stored or host-supplied member id). Using a host backend for genuinely host-only data is fine — just never straddle a single feature across both.
Never mock, never provision. These scaffolds are read-only over the owner's content. The owner adds products/posts/services/events/menus/plans in the Wix dashboard. If a collection is empty, show the empty state — never fabricate data, reviews, ratings, or counts.
Purchases go through Wix. Checkout/ticketing/plan purchase always complete via the Wix redirect-session / Wix-hosted form — never hand-build a
/checkoutor purchase URL.Fail loudly. The helpers throw on out-of-stock, empty carts, unbookable slots, expired holds, and payment-still-owed. A green path means it really worked — don't swallow the error.
Copy the shipped helpers as-is — don't rewrite their internals. Wire your UI to the exported functions; don't "refactor" or reimplement the helper bodies. Several Wix request shapes are exact and easy to break (the members
createRedirectSessionbody is the classic trap — a rewritten version returns 400 and login dies). Extend by calling the exports or adding a newwixApiRequestcall for a genuine gap — never by editing the shipped ones.Beyond the snippets, look it up — never guess. The templates and the shipped
references/<vertical>/helpers are the implementation — build from them first. When you hit a genuine gap (a field, an endpoint, or an error the snippets don't cover), extend the client withwixApiRequest— confirming the exact endpoint, method, and body first. For that iteration and troubleshooting — finding the right endpoint, reading a method's request/response schema, or diagnosing an API error — consult the official Wix API documentation using the documentation skill available in your environment to search methods, read pages, and inspect API schemas. Reference index: https://dev.wix.com/docs/api-reference.mdProvide 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.mdfile.
How this skill is structured
<SKILL_ROOT> is this file's directory (strip /SKILL.md). Each vertical supplies integration
code under references/<vertical>/app/: REST helpers in app/rest/, and, depending on the
vertical, utilities, hooks, context, components, or pages. All use the shared transport in
references/shared/app/ (app/rest/wix-client.js + wix-config.js, identical for every vertical).
Set WIX_CLIENT_ID (and WIX_METASITE_ID) in wix-config.js. Deploying references/<vertical>/app/
and references/shared/app/ into the app's src/ puts every file in place — the REST helpers land in
src/rest/, so their relative imports resolve.
Where these files live in the app, and how they get there (pre-installed at setup, or copied in) is your platform's call — follow your platform instructions for that.
Each vertical's INSTRUCTIONS.md specifies its prerequisites, supplied pieces, exported interfaces,
and the presentation you must build. Read it before implementation: reuse the supplied pieces
and build the missing presentation without reimplementing shipped logic. Follow the platform's
and vertical's completion guidance where provided.
Routing — pick the vertical(s) from the request
Load the vertical(s) the user's app needs; a project may combine several (e.g. a restaurant with a blog, or a store with pricing plans).
Each vertical's integration files ship in references/<vertical>/app/; copy that dir plus
references/shared/app/ into the app's src/ (base44 does this at install via deploy.cjs).
| The user wants… | Vertical | Read |
|---|---|---|
| Online store: products, categories, cart, checkout | storefront | references/storefront/INSTRUCTIONS.md |
| Donations: fundraising campaigns, one-time or recurring giving, hosted checkout | donations | references/donations/INSTRUCTIONS.md |
| Appointments: services, time slots, booking, checkout — and the form attached to a bookable service | bookings | references/bookings/INSTRUCTIONS.md |
| Rentals: an item hired for a length the customer picks (by the hour or by the day) — Wix Rentals runs on the Bookings APIs, so it is the same vertical | bookings | references/bookings/INSTRUCTIONS.md ("Rentals") |
| Blog/news: post feed, post pages, categories, tags | blog | references/blog/INSTRUCTIONS.md |
Events: browse, event page, RSVP, ticketing — an RSVP is here, not forms, even for one occasion with no tickets | events | references/events/INSTRUCTIONS.md |
| Portfolio/showcase: collections, projects, media galleries | portfolio | references/portfolio/INSTRUCTIONS.md |
| Restaurant: menu, online ordering, table reservations | restaurants | references/restaurants/INSTRUCTIONS.md |
Any visitor-fillable form: contact/enquiry, lead, signup, waitlist, application, feedback/survey, quote request, intake or registration. Not an event RSVP (events), per-service booking form (bookings) or donation contribution (donations) | forms | references/forms/INSTRUCTIONS.md |
CMS content: list/detail, filter/search, data CRUD. A visitor-fillable form is forms — cms only when the app must read the entries back | cms | references/cms/INSTRUCTIONS.md |
| Plans & pricing: memberships/subscriptions, subscribe, my plans | pricing-plans | references/pricing-plans/INSTRUCTIONS.md |
| Member accounts: custom login/sign-up (email+password, Google/Facebook, SSO), account area, gated content | members | references/members/INSTRUCTIONS.md |
⚠️ Anything a visitor fills in and submits is forms — with four exceptions:
The app must read the entries back →
cms. A public gallery, a listing, a member's "my submissions". A visitor cannot read Forms submissions, so those need a collection. Submit-only is alwaysforms: a form wired toinsertDataItemworks, but gives up the dashboard form builder, spam protection, submission notifications and CRM contact mapping, and needs the owner to set collection permissions by hand before anyone can submit at all.Confirming attendance to an event or occasion →
events. A wedding, party or gathering — events ships a built-in RSVP registration form. Route there even for a single occasion with no tickets.A form attached to a bookable service →
bookings.A contribution to a donation campaign →
donations. Recurring giving is not a Pricing Plans purchase; the donation form must preserve the campaign's amount/frequency rules and use its catalog reference.
When the request doesn't name a Wix Business Solution — ask, or check the site
Don't infer which Wix Business Solution to build (stores, bookings, blog, events, portfolio,
restaurants, CMS, pricing plans, members, etc..) from a vague brief. Ask the user one short
question — what do they offer (products? appointments? posts? events?) — or check what the
site actually has: call a cheap read from each likely solution's helper (queryProducts,
queryServices, queryPosts, queryEvents, …) — authenticated with a visitor token minted
from the WIX_CLIENT_ID, or with an admin token if you have one — and build for the solutions
that return real content. A 428 "app not installed" (blog: 401) means
that solution isn't on the site; sample-looking content ("Sample product 3") proves the app is
installed, not what the business is about. Never default to store/bookings on silence.
The run
Get
WIX_CLIENT_ID. It comes from the user (the handoff prompt from their Wix/vibe platform carries it). If it's missing, ask for it before wiring — nothing works without it.Pick the vertical(s) from the routing table — and when the request doesn't name any, ask or check the site (see above) instead of guessing. Open each picked vertical's
INSTRUCTIONS.md.Ensure the vertical's files are in place — copy
references/<vertical>/app/andreferences/shared/app/into the app'ssrc/, and setWIX_CLIENT_IDinwix-config.js. (Where and how they get there is your platform's call — see its instructions. On base44 the install step writes and verifieswix-config.jsfor you, so there's nothing to set by hand.)Build the presentation and wire the integration following the vertical's
INSTRUCTIONS.md. Reuse its supplied pieces through their documented interfaces, build the presentation it leaves to you, and connect routes/providers as specified. Do not reimplement shipped logic. Style new presentation using the existing platform theme.Complete the applicable platform and vertical guidance, including any required checks and handoff instructions they provide.
Some flows need Wix-side setup the user completes later (payments connected, the deployed domain allow-listed on the OAuth client for hosted-checkout return, collection permissions). Those are out of scope here — if a call fails for that reason, flag it and continue; don't fall back to mock data.
Files
- ATTRIBUTION.mdAdded by AutoGineer821 B
- LICENSELicence file added by AutoGineer1.0 KiB
- SKILL.md14.9 KiB
- install/deploy.cjsScript12.3 KiB
- install/pin-agents-md.cjsScript3.0 KiB
- platforms/README.md1.8 KiB
- platforms/base44-ecom-light-seed-with-install.md7.5 KiB
- platforms/base44-ecom-light-seed.md6.8 KiB
- platforms/base44-ecom-light.md5.1 KiB
- platforms/base44.md9.9 KiB
- platforms/generic.md7.9 KiB
- references/_shared/nav/nav.tanstack.jsScript1.2 KiB
- references/_shared/routing.md4.6 KiB
- references/blog/INSTRUCTIONS.md16.9 KiB
- references/blog/app/components/PostCard.jsxScript1.9 KiB
- references/blog/app/components/PostChips.jsxScript1.2 KiB
- references/blog/app/components/PostGrid.jsxScript506 B
- references/blog/app/context/TaxonomyContext.jsxScript1.5 KiB
- references/blog/app/hooks/usePostDetail.jsScript1.6 KiB
- references/blog/app/pages/Blog.jsxScript1.6 KiB
- references/blog/app/pages/CategoryPage.jsxScript2.3 KiB
- references/blog/app/pages/PostDetail.jsxScript2.4 KiB
- references/blog/app/pages/TagPage.jsxScript2.0 KiB
- references/blog/app/rest/wix-blog.jsScript8.0 KiB
- references/blog/seed/SEED.md6.4 KiB
- references/blog/seed/seed-blog.cjsScript14.4 KiB
- references/bookings/INSTRUCTIONS.md21.5 KiB
- references/bookings/app/components/BookingForm.jsxScript3.3 KiB
- references/bookings/app/components/RentalDurationPicker.jsxScript2.9 KiB
- references/bookings/app/components/ServiceCard.jsxScript2.8 KiB
- references/bookings/app/components/ServiceGrid.jsxScript537 B
- references/bookings/app/components/SlotPicker.jsxScript5.6 KiB
- references/bookings/app/hooks/useRentalDuration.jsScript5.1 KiB
- references/bookings/app/hooks/useServiceDetail.jsScript5.3 KiB
- references/bookings/app/hooks/useServices.jsScript2.7 KiB
- references/bookings/app/lib/serviceFacts.jsScript4.1 KiB
- references/bookings/app/pages/ServiceDetail.jsxScript4.4 KiB
- references/bookings/app/pages/Services.jsxScript3.5 KiB
- references/bookings/app/rest/wix-bookings-checkout.jsScript7.1 KiB
- references/bookings/app/rest/wix-bookings-rentals.jsScript11.6 KiB
- references/bookings/app/rest/wix-bookings-services.jsScript15.2 KiB
- references/bookings/seed/SEED.md10.6 KiB
- references/bookings/seed/seed-bookings.cjsScript16.0 KiB
- references/bookings/seed/seed-rentals.cjsScript11.5 KiB
- references/cms/INSTRUCTIONS.md14.3 KiB
- references/cms/app/collection.config.jsScript2.0 KiB
- references/cms/app/lib/wixImage.jsScript1.1 KiB
- references/cms/app/rest/wix-cms.jsScript10.8 KiB
- references/cms/seed/SEED.md9.1 KiB
- references/donations/INSTRUCTIONS.md5.9 KiB
- references/donations/app/rest/wix-donations.jsScript6.1 KiB
- references/donations/seed/SEED.md703 B
- references/donations/tests/donations.test.mjsScript15.0 KiB
- references/events/INSTRUCTIONS.md16.9 KiB
- references/events/app/components/CategoryFilter.jsxScript1.1 KiB
- references/events/app/components/EventCard.jsxScript2.5 KiB
- references/events/app/components/EventGrid.jsxScript502 B
- references/events/app/components/EventRegistration.jsxScript1.2 KiB
- references/events/app/components/RsvpForm.jsxScript2.6 KiB
- references/events/app/components/TicketPicker.jsxScript3.5 KiB
- references/events/app/hooks/useEventDetail.jsScript1.3 KiB
- references/events/app/hooks/useEventsList.jsScript2.3 KiB
- references/events/app/hooks/useRsvpForm.jsScript1.7 KiB
- references/events/app/hooks/useTicketing.jsScript3.3 KiB
- references/events/app/pages/EventDetail.jsxScript2.0 KiB
- references/events/app/pages/Events.jsxScript1.4 KiB
- references/events/app/rest/wix-events-browse.js6.4 KiB
- references/events/app/rest/wix-events-registration.js9.5 KiB
- references/events/seed/SEED.md7.1 KiB
- references/events/seed/seed-events.cjs12.4 KiB
- references/forms/INSTRUCTIONS.md30.6 KiB
- references/forms/app/hooks/useWixForm.js20.9 KiB
- references/forms/app/lib/wix-form-schema-utils.js8.7 KiB
- references/forms/app/rest/wix-forms-submissions.js11.8 KiB
- references/forms/app/rest/wix-forms.js5.6 KiB
- references/forms/seed/SEED.md70.8 KiB
- references/members/INSTRUCTIONS.md21.4 KiB
- references/members/app/components/LoginForm.jsx4.1 KiB
- references/members/app/components/MemberMenu.jsx1.5 KiB
- references/members/app/components/RequireAuth.jsx1.0 KiB
- references/members/app/components/SocialButtons.jsx1.4 KiB
- references/members/app/context/MemberContext.jsx2.3 KiB
- references/members/app/hooks/useLoginForm.js3.1 KiB
- references/members/app/pages/Account.jsx1.8 KiB
- references/members/app/pages/Callback.jsx1.4 KiB
- references/members/app/pages/Login.jsx1.3 KiB
- references/members/app/rest/wix-members-auth.js17.2 KiB
- references/members/install/Register.jsx1.1 KiB
- references/members/seed/SEED.md1.6 KiB
- references/portfolio/INSTRUCTIONS.md16.6 KiB
- references/portfolio/app/components/CollectionCard.jsx1.6 KiB
- references/portfolio/app/components/CollectionGrid.jsx567 B
- references/portfolio/app/components/ProjectCard.jsx1.9 KiB
- references/portfolio/app/components/ProjectGrid.jsx537 B
- references/portfolio/app/components/ProjectMedia.jsx1.3 KiB
- references/portfolio/app/hooks/useCollectionProjects.js1.4 KiB
- references/portfolio/app/hooks/usePortfolioGallery.js1.1 KiB
- references/portfolio/app/hooks/useProjectDetail.js1022 B
- references/portfolio/app/pages/CollectionPage.jsx1.6 KiB
- references/portfolio/app/pages/Portfolio.jsx1.1 KiB
- references/portfolio/app/pages/ProjectDetail.jsx2.3 KiB
- references/portfolio/app/rest/wix-portfolio.js8.9 KiB
- references/portfolio/seed/SEED.md6.1 KiB
- references/portfolio/seed/seed-portfolio.cjs11.4 KiB
- references/pricing-plans/INSTRUCTIONS.md16.9 KiB
- references/pricing-plans/app/components/OrderCard.jsx1.8 KiB
- references/pricing-plans/app/components/PlanCard.jsx2.2 KiB
- references/pricing-plans/app/components/PlanGrid.jsx652 B
- references/pricing-plans/app/components/PlanPrice.jsx1.5 KiB
- references/pricing-plans/app/hooks/useMyPlans.js1.3 KiB
- references/pricing-plans/app/hooks/usePlanDetail.js1.1 KiB
- references/pricing-plans/app/hooks/usePlans.js1.3 KiB
- references/pricing-plans/app/pages/MyPlans.jsx1.4 KiB
- references/pricing-plans/app/pages/PlanDetail.jsx2.1 KiB
- references/pricing-plans/app/pages/Plans.jsx1.1 KiB
- references/pricing-plans/app/rest/wix-pricing-plans.js6.7 KiB
- references/pricing-plans/seed/SEED.md5.3 KiB
- references/pricing-plans/seed/seed-pricing-plans.cjs11.9 KiB
- references/rentals/INSTRUCTIONS.md514 B
- references/restaurants/INSTRUCTIONS.md19.2 KiB
- references/restaurants/app/components/ItemDialog.jsx4.2 KiB
- references/restaurants/app/components/MenuItemCard.jsx3.3 KiB
- references/restaurants/app/components/MenuList.jsx1.9 KiB
- references/restaurants/app/components/OrderCartButton.jsx1.3 KiB
- references/restaurants/app/components/OrderCartDrawer.jsx3.9 KiB
- references/restaurants/app/context/OrderCartContext.jsx3.3 KiB
- references/restaurants/app/hooks/useItemOrder.js1.4 KiB
- references/restaurants/app/hooks/useReservation.js3.3 KiB
- references/restaurants/app/pages/Menu.jsx1.2 KiB
- references/restaurants/app/pages/Reservations.jsx4.8 KiB
- references/restaurants/app/rest/wix-restaurants-menu.js8.6 KiB
- references/restaurants/app/rest/wix-restaurants-ordering.js10.9 KiB
- references/restaurants/app/rest/wix-restaurants-reservations.js5.5 KiB
- references/restaurants/seed/SEED.md12.8 KiB
- references/restaurants/seed/seed-restaurants.cjs25.3 KiB
- references/shared/app/components/WixManageBanner.jsx2.8 KiB
- references/shared/app/lib/nav.js678 B
- references/shared/app/rest/wix-client.js6.5 KiB
- references/shared/app/rest/wix-config.js548 B
- references/storefront/INSTRUCTIONS.md27.4 KiB
- references/storefront/app/components/CartButton.jsx1.2 KiB
- references/storefront/app/components/CartDrawer.jsx9.8 KiB
- references/storefront/app/context/CartContext.jsx3.7 KiB
- references/storefront/app/hooks/useProductCard.js6.3 KiB
- references/storefront/app/hooks/useProductDetail.js8.4 KiB
- references/storefront/app/hooks/useShop.js3.9 KiB
- references/storefront/app/hooks/useVariantOptions.js2.7 KiB
- references/storefront/app/lib/storeImage.js3.5 KiB
- references/storefront/app/rest/wix-store-cart.js9.0 KiB
- references/storefront/app/rest/wix-store-catalog.js12.3 KiB
- references/storefront/seed/SEED.md12.0 KiB
- references/storefront/seed/seed-store.cjs27.6 KiB
references/restaurants/INSTRUCTIONS.md
Wix Restaurants — ready-made client
The restaurant client is shipped as real files, not snippets to regenerate. It's a complete
menu + item ordering + server-cart + checkout, plus a table-reservation flow, styled with your app's
design tokens (base44's src/index.css — the shadcn palette the design phase already set). Copy it
into the app and wire the routes — you generate almost none of the restaurant code (the menu tree
join, the order cart, the reservation hold→reserve flow all ship and are correct).
Talks to Wix directly over the public WIX_CLIENT_ID (anonymous visitor tokens). Never mock the
menu; never hand-build /checkout or reservation URLs — the shipped cart goes through the eCom
redirect-session and reservations go through the hold/reserve flow.
Prerequisites
The site's Wix Restaurants Menus app is the read target for the menu; Restaurant Orders backs online ordering; Table Reservations backs the booking page. They're installed and seeded separately (see Seeding below), in parallel with this build — so the menu may be empty and ordering / reservations may be unconfigured at build time. The client renders the shipped empty / "unavailable" states until content and operations land.
The public headless
WIX_CLIENT_IDfrom your prompt (buyer-facing, safe to hardcode/commit).For Wix-hosted checkout to return, the deployed app domain must be allow-listed on the OAuth client — a separate Wix setup the user completes later, out of scope here. If checkout return fails before that, it's expected; flag it and continue.
STEP 1 — The client is already in src/
The install step (base44.md STEP 1) deployed the whole restaurant UI client + REST scaffolds into
src/ (imports use the @/ alias → src/). Here's every file and what it is — this is your map,
so you don't need to open them:
| file | what it is |
|---|---|
context/OrderCartContext.jsx | useOrderCart() provider: resolves the ordering Operation, server cart, add/update/remove, checkout, ordering flag |
hooks/useItemOrder.js | item-dialog add-to-order logic (stock + ordering-available gating, quantity) |
hooks/useReservation.js | reservation flow (locations → date/party → AVAILABLE slots → hold → reserve) |
components/MenuItemCard.jsx, MenuList.jsx | menu render UI (dish card + the menus→sections→items tree, with empty state) |
components/ItemDialog.jsx | dish detail modal — description, price/variants, modifier groups (display), quantity, add-to-order |
components/OrderCartButton.jsx | header order icon button with a live-count badge |
components/OrderCartDrawer.jsx | slide-over order cart (mount once; opens from useOrderCart) |
components/WixManageBanner.jsx | preview-only manage banner — drop it into your Layout (STEP 3) |
pages/Menu.jsx, pages/Reservations.jsx | the two shipped routes (/menu, /reservations) |
rest/wix-config.js | the two ids, written by the install step |
rest/wix-client.js | REST transport + visitor-token mint/refresh (the refresh token IS the cart identity) |
rest/wix-restaurants-menu.js | menu read helpers — getFullMenu (the assembled tree; start here) + raw list* |
rest/wix-restaurants-ordering.js | ordering — operations, add/update/remove, checkout |
rest/wix-restaurants-reservations.js | reservations — locations, time slots, hold, reserve |
They're already in place — go straight to theming + wiring, nothing to verify first. Don't
read_file the shipped page/component/hook source to inspect it — the table above says what each is
and every field shape you need is in the snippets below. Read a shipped file's source only on a
real fallback — a runtime error, or a field the snippets don't cover (see "Fallback only" at the
end). (Files missing? the install's deploy result lists what it wrote; re-run install, or copy
references/restaurants/app/ → src/.)
STEP 2 — Theme
Use the existing Base44 theme in src/index.css so your pages and the shipped components
share the same colors and typography.
STEP 3 — Wire routes + provider (surgical find_replace on src/App.jsx, never a rewrite)
The template decides this step, and
src/routes/__root.jsxis the question to ask first. Present → TanStack Start, which mounts these pages as route files at the end of this step; absent → React Router, which the wiring below is written for. Ask in that order: ansrc/App.jsxcan exist on a TanStack app because an agent created one, and__root.jsxis never there by mistake. The installedsrc/lib/nav.jsdefaults to the React Router adapter, so on TanStack swap it: both patterns.Import
Link,useParamsand friends from@/lib/navin the pages you write too — same names as the router exports, and nothing you write is pinned to one template.
No file reads needed to wire this. Every shipped page and WixManageBanner is a default export that takes no props — wire them exactly as the snippet shows; nothing in those files needs looking up.
App.jsx carries required platform auth scaffolding (AuthProvider/useAuth) — edit it in, don't
replace it.
Wrap the routed tree in
<OrderCartProvider>(from@/context/OrderCartContext).Put your header + footer in a
Layoutthat renders<Outlet/>between them, and nest every route under one pathless<Route element={<Layout/>}>. Your brand chrome then wraps every page — including the shippedMenu/Reservations— so you never edit the shipped pages to add a header/footer (they render inside<Outlet/>as-is). Mount<OrderCartDrawer/>once in the Layout.Pin the top chrome as one fixed block. Put
<WixManageBanner/>(shipped, preview-only) above your<Header/>inside a singleposition:fixedtop region — the header itself is plain in-flow markup, the region owns the fixing — so banner + header ride together (no scroll drift/gap). Pad the content by the region's measured height so it clears the chrome and self-corrects when the banner is dismissed.Routes under the Layout:
/menu→Menu,/reservations→Reservations(both shipped, as-is). You add/→ your own Home page.
import { useRef, useState, useEffect } from "react";
import { Routes, Route, Outlet } from "react-router-dom";
import { OrderCartProvider } from "@/context/OrderCartContext";
import OrderCartDrawer from "@/components/OrderCartDrawer";
import WixManageBanner from "@/components/WixManageBanner"; // shipped, preview-only · default export, no props
import Menu from "@/pages/Menu"; // shipped · default export, no props
import Reservations from "@/pages/Reservations"; // shipped · default export, no props
import Home from "@/pages/Home"; // YOU build
import Header from "@/components/Header"; // YOU build — plain in-flow markup, NOT position:fixed
import Footer from "@/components/Footer"; // YOU build
function Layout() {
const topRef = useRef(null);
const [offset, setOffset] = useState(0);
useEffect(() => { // measure the fixed region → pad content below it
const ro = new ResizeObserver(() => setOffset(topRef.current?.offsetHeight ?? 0));
if (topRef.current) ro.observe(topRef.current);
return () => ro.disconnect();
}, []);
return (<>
<div ref={topRef} style={{ position: "fixed", top: 0, left: 0, right: 0, zIndex: 50 }}>
<WixManageBanner /> {/* null on the published site / when dismissed */}
<Header /> {/* your brand header, in-flow inside this fixed block */}
</div>
<div style={{ paddingTop: offset }}> {/* clears the chrome; shrinks when the banner is dismissed */}
<Outlet /> {/* shipped Menu/Reservations render here, untouched */}
<Footer />
</div>
<OrderCartDrawer /> {/* overlays every page */}
</>);
}
<OrderCartProvider>
<Routes>
<Route element={<Layout />}> {/* chrome wraps all */}
<Route path="/" element={<Home />} /> {/* yours */}
<Route path="/menu" element={<Menu />} /> {/* shipped, as-is */}
<Route path="/reservations" element={<Reservations />} /> {/* shipped, as-is */}
</Route>
</Routes>
</OrderCartProvider>TanStack Start template — the same pages, mounted as files
Chrome (header, footer, the fixed banner region described above) goes in src/routes/__root.jsx
around its <Outlet/>, and any provider this vertical asks for wraps that <Outlet/> once. Each
route is a two-line file; shipped pages stay in src/pages/ untouched.
| route | file | component |
|---|---|---|
/ | src/routes/index.jsx | Home |
/menu | src/routes/menu.jsx | Menu |
/reservations | src/routes/reservations.jsx | Reservations |
// src/routes/menu.jsx
import { createFileRoute } from "@tanstack/react-router";
import Menu from "@/pages/Menu";
export const Route = createFileRoute("/menu")({ component: Menu });Path params are $name in both the filename and the route path; useParams() from @/lib/nav
reads them unchanged. Full pattern, including ssr: false for per-user routes:
../_shared/routing.md.
What you build (not shipped)
The home / landing page, the Header (mount <OrderCartButton/> in it) and a Footer —
the two you drop into the Layout (STEP 3) so they wrap every route — plus the overall brand story,
styled with the same base44 tokens/classes. The nav is an <OrderCartButton/> (a clean order-icon
button with a live-count badge — render it as-is, don't wrap it in your own text button) + links to
/menu and /reservations:
import { useState, useEffect } from "react";
import { Link } from "react-router-dom";
import OrderCartButton from "@/components/OrderCartButton";
// Responsive header: choose ONE branch with a state flag, so <OrderCartButton/> mounts once.
// Do NOT render a desktop nav AND a mobile nav toggled by `hidden md:flex` / `md:hidden`:
// these navs are inline-styled, and an inline `display` beats a Tailwind class, so `hidden`
// never applies — BOTH branches render and you get two order buttons. One branch = one button.
export function Header() {
const [mobile, setMobile] = useState(() => window.innerWidth < 768);
useEffect(() => {
const onResize = () => setMobile(window.innerWidth < 768);
window.addEventListener("resize", onResize); // keep it reactive to viewport changes
return () => window.removeEventListener("resize", onResize);
}, []);
return (
<nav style={{ display: "flex", alignItems: "center", justifyContent: "space-between" }}>
{/* brand/logo */}
{mobile
? <YourMenu /> // your hamburger + <OrderCartButton/> here
: <div style={{ display: "flex", gap: 24, alignItems: "center" }}>
<Link to="/menu">Menu</Link><Link to="/reservations">Reserve</Link><OrderCartButton />
</div>}
</nav>
);
}Everything visual reads base44's design tokens (index.css), so your home/nav match the shipped pages automatically.
<OrderCartButton/> is an icon button (live-count badge) — drop it in as-is, it inherits currentColor.
Editing a component and the change doesn't show? It's the preview, not your code. The dev preview can serve a stale module after a write. Before diagnosing a visual bug you just "fixed", do a fresh full navigate/reload of the preview and re-check — don't keep rewriting correct code against a stale render.
Using the client from your own UI (menu, order cart)
Migrating from Cart V1 / Checkout V1? These helpers are V2-only — see the migration guide for the before/after.
import { getFullMenu } from "@/rest/wix-restaurants-menu";
import { useOrderCart } from "@/context/OrderCartContext";
// getFullMenu() is the ONLY pre-joined shape and the entry point for any menu surface. It returns
// { menus: [{ ...menu, sections: [{ ...section, items: [assembledItem] }] }] }, already ordered.
// Each item is enriched with a resolved price / variants, modifierGroups, and labels.
const { menus } = await getFullMenu(); // [] when no menus → show the shipped empty state
// useOrderCart() gives:
// { cart, operation, ordering, itemCount, isOpen, setIsOpen, loading,
// addItem(item, { menuId, sectionId }, qty=1), // needs the menu/section the item was shown under
// removeItem(lineItemId), updateQuantity(lineItemId, qty),
// setFulfillment(code, address?), // "PICKUP|ASAP" · "DELIVERY|ASAP" · "<TYPE>|<startMs>|<endMs>"; address for delivery
// checkout(), // pickup ASAP when no fulfillment was set
// refreshCart() }
// `ordering` is false when no ordering Operation is configured — show an "ordering unavailable" state.
// Load-bearing field paths (the shipped components already do these):
// - item.image / section.image / label.icon are OBJECTS → render `.url`, never the object; //-urls → https:
// - MENU prices are plain decimal strings with NO currency symbol ("12.50") — format in the UI.
// The eCom cart line price (line.pricing.unitPrice / line.pricing.totalPrice) is a ConvertedMoney
// { amount, convertedAmount } with NO symbol either — format the number yourself.
// - an item is priced by EITHER item.price (single) OR item.variants[] (one-of, each { name, price }).
// - a cart mutation uses cart.lineItems[].id (the lineItemId), NOT the menu item id.Buying happens in the shipped ItemDialog (opened from MenuList) — it owns quantity + add-to-order
and surfaces out-of-stock / ordering-unavailable errors. Compose a featured strip on your Home from
getFullMenu() + the shipped MenuItemCard if you want.
Extending the client
Building something beyond the shipped pages, or need a path these snippets don't cover?
// The raw list* helpers return UNRESOLVED refs and INCONSISTENT shapes (listMenus → { menus,
// nextCursor }; listSections/listItems/listVariants/listModifierGroups/listModifiers → bare arrays).
// Don't re-join them by hand — build on getFullMenu(). If you truly need a partial fetch, note they
// take an array of GUIDs: listSections(sectionIds), listItems(itemIds).
// Reservation status after reserve: RESERVED = confirmed, REQUESTED = manual approval pending
// (tell the user). firstName + phone (E.164, e.g. "+15551234567") are mandatory; a HELD reservation
// expires in 10 minutes — the hook passes the hold's { id, revision } into reserve for you.Modifier up-charges / price-variant selection / special requests on the cart line are not
wired into addItemToCart — the restaurants catalogReference.options shape for these isn't
documented for client add-to-cart, so ItemDialog displays modifier groups for the diner but sends
only quantity. To wire them, confirm the shape via the documentation skill available in your environment / the reference first,
never guess:
Restaurants API reference: https://dev.wix.com/docs/api-reference/business-solutions/restaurants.md
Sample flows (cart options): https://dev.wix.com/docs/api-reference/business-solutions/restaurants/online-orders/sample-flows.md
Member login + a "my orders" account view → the members vertical (
references/members/INSTRUCTIONS.md): ordering/reserving works anonymously, but signing a member in lets them see their own order/reservation history.
Fallback only — when you hit an error or need something not shown here: read the relevant shipped
file under src/, or look it up via the documentation skill available in your environment.
Hard rules
Header/footer live in a
Layoutaround<Outlet/>(STEP 3) — never edit the shippedMenu/Reservationsto add chrome.The Layout's fixed top region owns positioning:
<WixManageBanner/>above<Header/>; yourHeaderis plain in-flow markup (notposition:fixed).Order through the shipped cart:
addItem()→setFulfillment()→checkout()(redirect-session) — never a hand-built/checkout, ordering, or reservation URL. The hosted checkout has no pickup/delivery or time picker for restaurant orders: a pickup/delivery choice and a time (ASAP, or a slot from the operation'savailable-time-slots-per-date) are set withsetFulfillmentbeforecheckout(); without one,checkout()uses pickup ASAP.Reservations: offer only
AVAILABLEslots; pass the hold'srevisioninto reserve;firstName+phone(E.164) are mandatory.Render live Wix data or the shipped empty / "unavailable" state — never mock menus, items, prices, operations, locations, slots, or reviews.
Point the user to their dashboard
Provide deep links so the owner can edit content across the apps they actually use (substitute the
site's metaSiteId from the handoff / ListWixSites):
Menu (always) —
https://manage.wix.com/dashboard/{metaSiteId}/wix-restaurants-menus-new(Dashboard → Restaurant Menus; click Manage Items to add dishes; only visible menus appear in the app)Online ordering (if wired) —
https://manage.wix.com/dashboard/{metaSiteId}/wix-restaurants-orders-new/settings(Dashboard → Restaurant Orders → Settings). Enable at least one fulfillment method before the site accepts orders: pickup.../wix-restaurants-orders-new/settings/pickup, delivery.../settings/delivery, dine-in.../settings/dine-in.Table reservations (if wired) —
https://manage.wix.com/dashboard/{metaSiteId}/wix-table-reservations/table-reservations(Dashboard → Table Reservations→ Settings; configure tables, availability, and enable online reservations)
Tell the user at least once that they can keep setting up their restaurant (menu / ordering / reservations) in the dashboard, and include the in-dashboard navigation as a fallback.
Seeding
Seed the menu (and ordering/reservation setup) per seed/SEED.md — separate from this client build;
run in parallel.
Verify (before declaring done)
[ ] Client files copied into
src/;WIX_CLIENT_IDset (not the placeholder).[ ] Opened
/menuand/reservations(not just the home page) and confirmed the shipped components render themed (surface, text, brand) with images.[ ]
Layout(fixed<WixManageBanner/>+<Header/>region, then<Outlet/>+ Footer) wraps all routes; shippedMenu/Reservationsuntouched; content clears the fixed chrome;<OrderCartProvider>wraps the tree;<OrderCartDrawer/>mounted;<OrderCartButton/>in the header.[ ]
getFullMenu()renders real sections/items with prices, variants, modifiers, and labels; empty catalog shows the shipped empty state (no mock items).[ ] Add to order works with a real operation (or shows "ordering unavailable"); order survives reload (same visitor); update-qty / remove work; checkout redirects and re-fetches on return.
[ ] Reservations: only
AVAILABLEslots offered; hold → reserve producesRESERVED/REQUESTED; no locations shows the shipped empty state.[ ] Told the user they can continue setting up in the dashboard, with deep links.
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs Node.js
Security
What our scanner noticed· Low risk
- Instructions that use the network
- Scripts that your agent may run
This skill includes scripts that your agent may run. Read them before you use it.
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Wix
- Publisher
- Wix (Official)
- Source
- wix/skills · skills/wix-vibe-headless · commit d168bc2
- Licence
- MIT License (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Wix or Wix.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download wix-vibe-headless.zip