Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Vendure Knowledge Patch?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/nevaberry-vendure-knowledge-patch)
---
name: vendure-knowledge-patch
description: Vendure
version: null
license: MIT
metadata:
author: Nevaberry
---
# Vendure compatibility guidance
Load this skill when upgrading Vendure, configuring security or background jobs,
changing catalog and checkout behavior, or building Dashboard extensions.
Use the references for detailed behavior and the version conditions that apply
to the task. The quick reference prioritizes upgrade requirements and common APIs.
## Reference index
| Reference | Topics |
| --- | --- |
| [Security and access](references/security-and-access.md) | Authentication, API keys, channel authorization, CORS, CSRF, job redaction, security fixes |
| [Catalog, assets, and search](references/catalog-assets-and-search.md) | MIME changes, asset delivery and translations, product options, channel assignment, stock locks, search indexing |
| [Orders, checkout, and payments](references/orders-checkout-and-payments.md) | Cart mutations, coupons, promotions, tax, shipping, order transitions, events, payment providers |
| [Platform configuration and operations](references/platform-configuration-and-operations.md) | Package alignment, migrations, Settings Store, custom fields, startup, scheduled tasks, queues, Redis cache |
| [Dashboard and project tooling](references/dashboard-and-project-tooling.md) | Dashboard installation, builds, extensions, permissions, order operations, CLI, scaffolding, Console linking |
| [Integrations and observability](references/integrations-and-observability.md) | Email, health checks, Sentry, tracing, usage telemetry, GraphiQL, MCP |
## Upgrade requirements and deprecations
Upgrade all `@vendure/*` packages together to the target version. The 3.8.2
upgrade uses the existing database schema. Earlier migration requirements and
migration diagnostics are detailed in the platform reference.
- Production startup refuses the default superadmin password from 3.7.0.
Set a non-default password before upgrading.
- From 3.7.0, a custom `AuthenticationStrategy` must return `verified: true`
for provider-verified emails to link an external login to an existing account.
- Coupon codes compare case-insensitively in 3.7.0. Resolve case-only promotion
collisions before upgrading, and handle `CouponRemovedDuringCheckoutError`
in the Shop API's `AddPaymentToOrderResult`.
- `adminApiDebug` and `shopApiDebug` are deprecated no-ops from 3.8.0.
GraphQL error responses omit stack traces in every environment in 3.8.1.
- External-component health checks were deprecated in 3.6.0. Version 3.7.0
removes the transitive `@nestjs/terminus` dependency; install it directly
if custom health checks import it. The `/health` endpoint skips health-check
strategies, so run dependency checks separately.
- Check custom MJML templates and Nodemailer transport settings against MJML v5
and Nodemailer v9 when upgrading to 3.7.0.
- Version 3.6.4 accepts `graphql` `^16.11.0`; remove workarounds added
specifically for the 3.6.3 incompatibility.
- The Dashboard honors `authTokenHeaderKey` from 3.5.1, which deprecates
the legacy Admin UI plugin's `compatibilityMode`.
### Asset MIME compatibility
The `file-type` update to `^21.3.1` fixes a file parsing denial of service and
ships in both core and the asset server plugin in 3.7.3. Replace explicit
`assetOptions.permittedFileTypes` entries to keep these uploads working:
| Previous MIME type | Replacement |
| --- | --- |
| `audio/x-flac` | `audio/flac` |
| `video/x-matroska` | `video/matroska` |
| `application/x-apache-arrow` | `application/vnd.apache.arrow.file` |
| `application/x-parquet` | `application/vnd.apache.parquet` |
In 3.7.3, the asset server sends SVG, HTML, and XML as
`Content-Disposition: attachment`. Link directly for a download or embed SVG
with `<img src>` to display it on a page.
### Redis cache compatibility
In 3.8.2, `RedisCacheStrategy` stores tags in expiring sorted sets at
`<namespace>:ztag:<tag>`. Tagged writes use `EVAL`: grant the Redis ACL user
`@scripting` and use Redis 3.2 or a compatible server such as Valkey.
`invalidateTags()` batches 1,000 entries, throws on Redis command errors,
and still clears legacy `<namespace>:tag:<tag>` sets.
During a rolling upgrade, invalidations from older instances leave entries
tagged by upgraded instances cached until their TTL expires or an upgraded
instance invalidates them.
## Authentication and request security
From 3.4.0, set `apiOptions.trustProxy` to match the deployment's trusted proxies.
In 3.7.3, startup warns about the default CORS configuration that reflects
origins with credentials. Set an explicit production allowlist in
`apiOptions.cors.origin`, or use `CORS_ORIGINS` in a newly scaffolded project.
`apiOptions.csrfPrevention` defaults to `false` in 3.7.3. Set it to `true`
to enable Apollo CSRF protection on both APIs:
```ts
const apiOptions = {
cors: { origin: ['https://shop.example.com', 'https://admin.example.com'], credentials: true },
csrfPrevention: true,
}
```
With CSRF protection enabled, send `Apollo-Require-Preflight: true` on GET
queries and file uploads, including custom `apollo-upload-client` clients.
The packaged Admin UI, Dashboard, and test clients already send the header.
For an existing external-auth customer without a native password in 3.7.3,
`registerCustomerAccount` emails a verification token regardless of
`authOptions.requireVerification`; `verifyCustomerAccount` sets the password
using that token. Registration ignores supplied `firstName`, `lastName`,
`phoneNumber`, and custom fields whenever a `User` already exists for the email.
In 3.7.4, API key creation, update, rotation, and deletion require the caller
to hold every permission granted by the key's roles. Out-of-scope keys are omitted from
lists and return not-found on lookup. Plugins can import `ApiKeyService`
from `@vendure/core`.
In 3.7.3, Admin API job responses redact session tokens, but
`RequestContext.serialize()` still persists them. After upgrading, purge
settled job data and consider invalidating existing administrator sessions.
In 3.8.1, job queries return redacted copies of `Job.data`, `Job.result`,
and `Job.error`; see the security reference for the redaction details.
## Stock, cancellation, and promotions
In 3.7.4, `DefaultStockLocationStrategy` caps allocations at the sum of
`stockOnHand - stockAllocated - outOfStockThreshold` across stock locations.
Subscribe to `StockShortfallEvent` to backorder, refund, or notify on partial
or absent allocation. Saleable-stock checks and allocation lock `StockLevel`
rows; SQLite and SQL.js use unlocked reads with one warning per process.
Overrides of `BaseStockLocationStrategy.init()` must call `super.init(injector)`.
`StockAllocationStrategy.shouldAllocateStock()` must be deterministic and
side-effect-free because it can run multiple times per transition. The catalog
reference lists the core locking APIs available to custom strategies in 3.7.4.
In 3.8.2, cancel all order lines before moving an order from
`ArrangingAdditionalPayment` to `Cancelled` so allocated stock is released.
The transition fails while any line remains uncancelled.
In 3.8.2, `updatePromotion` validates required action conditions whenever input
includes `conditions` or `actions`. A `buy_x_get_y_free` action needs its
corresponding condition. To rename or disable a saved promotion with a missing
condition, omit both fields.
In 3.7.4, a promotion applying no discount is left off the order and consumes
neither `usageLimit` nor `perCustomerUsageLimit`. Promotions with side effects,
such as a free gift, still attach to the order.
## Settings and checkout APIs
The Settings Store persists global and scoped settings, with separate read and
write permissions from 3.5.0. `SettingsStoreService` supports context-first
calls alongside the older context-last forms from 3.4.2:
```ts
await settingsStore.set(ctx, key, value)
const current = await settingsStore.get(ctx, key)
await settingsStore.setMany(ctx, values)
const selected = await settingsStore.getMany(ctx, keys)
```
- Use `addItemsToOrder` to add multiple cart items in one Shop API mutation
from 3.4.0. A Shop API mutation to change order currency is available in 3.6.0.
- Query `activePaymentMethods` and `activeShippingMethods` for public method
lists from 3.2.0; both expose custom fields from 3.3.3.
- Use `OrderTaxCalculationStrategy` to customize tax calculation from 3.6.0,
and `OrderLineDiscountDistributionStrategy` to control discount proration
from 3.7.0. Custom `OrderMergeStrategy` implementations can run asynchronously
from 3.6.0.
## Dashboard extension essentials
`DashboardPlugin` ships in `@vendure/dashboard` from 3.4.0. In 3.7.0, use
`useExperimentalBundle` to opt into the prebundled Dashboard; activate plugins
in the runtime config to load their Dashboard extensions.
- The CLI `codemod` command migrates Dashboard code from Radix to Base UI in
3.6.0. Extensions can use Zod v4 re-exported by `@vendure/dashboard` in 3.6.1.
- Use custom-field config `dashboard: false` to hide a field from the Dashboard
from 3.5.6. Widget permissions use `requiresPermissions` from 3.6.1.
- A `ListPage` additional column can use `enableColumnFilter: true` from 3.5.1.
In 3.7.3, `ListPage` forwards `transformQueryKey` and view options to the list.
- In 3.8.2, Dashboard builds generate new JavaScript chunk filenames on every
build, even with identical source, to keep immutable cached chunks from
breaking extension pages after redeploy. Set `disablePlugins.chunkHash` to
`true` in the Dashboard Vite plugin options to disable this behavior.
- In 3.8.2, use `defaultSize.x` and `defaultSize.y` to place a widget when the
user has no saved layout and the requested position is free.
## Development and Console linking
The CLI adds `dev`, `build`, `start`, and `doctor` in 3.7.0:
```sh
npx vendure doctor
npx vendure dev
```
In 3.7.4, `vendure dev` keeps watching after server or worker TypeScript compile
errors. Read `vendure migrate` diagnostics for migration patterns matching zero
files or a schema differing from entities, even if the command exits successfully.
In 3.8.2, pass `--console-project <id|slug>` to skip the project picker.
With `--non-interactive`, linking uses the login stored by `vendure auth login`:
```sh
vendure console link --console-project my-project --non-interactive
```
`vendure auth status` exits with code 1 when login renewal is unavailable;
its `--json` output includes `renewable` and `renewalError` in 3.8.2.