Skip to main content
skill CX Codex

headless-bff-architecture — Claude Code skill

Design a VTEX BFF for headless storefronts and keep private APIs, credentials, and shopper tokens out of browser code.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add vtex/skills --skill headless-bff-architecture -a claude-code
Open on GitHub

What headless-bff-architecture does

This skill guides BFF design for headless VTEX storefronts. It helps classify API routes, decide which requests need a server proxy, and keep private calls away from frontend bundles. Intelligent Search is treated as the sole VTEX API that may be called directly by the frontend; public Checkout routes still pass through the BFF because they handle sensitive data.

Shopper authentication uses VtexIdclientAutCookie inside a server-side session, never in localStorage, sessionStorage, or browser JavaScript. Machine-to-machine requests use X-VTEX-API-AppKey and X-VTEX-API-AppToken, with separate least-privilege keys for BFF modules. /pvt/ routes must be proxied, and exposing private credentials in client code violates the skill’s security rules.

What it helps with

  • design a BFF for a headless VTEX storefront
  • classify VTEX routes by access level
  • move private API calls out of browser code
  • store VtexIdclientAutCookie in a server session
  • split API keys across BFF modules

Example prompts for the agent

  • Design a BFF for this headless VTEX storefront and classify every API route.
  • Audit the project for browser calls to /pvt/ endpoints and client-side use of VtexIdclientAutCookie.
  • Suggest a server session flow and least-privilege API keys for separate BFF modules.

How to install headless-bff-architecture

1Skills CLI (Vercel)

npx skills add vtex/skills --skill headless-bff-architecture -a claude-code

2Manually: put the files in place

~/.claude/skills/headless-bff-architecture/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/headless-bff-architecture/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about headless-bff-architecture

How do I install headless-bff-architecture in Claude Code?

Run npx skills add vtex/skills --skill headless-bff-architecture -a claude-code, then check ~/.claude/skills/headless-bff-architecture/SKILL.md.

What does headless-bff-architecture do?

The skill provides rules for building a VTEX BFF, routing private requests through it, classifying APIs, and protecting credentials and shopper sessions.

Which VTEX API can the frontend call directly?

Only Intelligent Search is marked safe for direct frontend calls. Private /pvt/ routes and public Checkout endpoints must use the BFF.

Similar skills

All skills for Backend and APIs →

From the same set38

headless-caching-strategy Sets caching rules and TTL values for headless VTEX storefronts. Keeps public endpoints fast while preventing accidental caching of sensitive shopper data. CX Codex +1 1,100installs headless-intelligent-search Build VTEX Intelligent Search into a headless storefront, with facets, autocomplete and search analytics. Useful when a custom frontend needs product discovery. CX Codex +1 1,100installs payment-idempotency A skill for payment connector code that keeps Gateway retries from hitting the acquirer twice and charging the customer again. CX Codex +1 1,100installs headless-checkout-proxy Guides agents when building cart and checkout flows for headless VTEX via a BFF. Ensures safe OrderForm proxying and strict PCI DSS compliance. CX Codex +1 1,100installs vtex-io-observability-and-ops Adds structured logs and client metrics to VTEX IO backend services, so production failures are easy to trace before and after a release. CX Codex +1 1,100installs faststore-storefront Guides AI coding agents through VTEX FastStore storefront development: React 18 components, section overrides, SCSS styling constraints, and CMS schema sync. CX Codex +1 1,100installs vtex-io-service-paths-and-cdn Picks the right path prefix in service.json and matches Cache-Control to the data, so edge caching does not serve one shopper's payload to another. CX Codex +1 1,100installs vtex-io-messages-and-i18n Keeps user-facing copy in the VTEX IO messages infrastructure instead of hardcoded strings in JSX and resolvers. CX Codex +1 1,100installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor