releases.shpreview
Cloudflare/Workers SDK

Workers SDK

Mon
Wed
Fri
JunJulAugSepOctNovDecJanFebMarAprMayJun
Less
More
Releases288Avg88/moVersions@cloudflare/edge-preview-authenticated-proxy@0.3.2 to wrangler@4.100.0
@cloudflare/workers-auth@0.2.0
Minor Changes
  • #14185 98c9afe Thanks @penalosa! - Make the OAuth identity and token storage injectable, and add a shared env-credential resolver

    createOAuthFlow now takes the consumer's OAuth identity (clientId, consent, redirectUri) and token storage on its context, so other Cloudflare CLIs can reuse the flow under their own OAuth app and store tokens in their own location/format. Also adds a shared env→credential resolver (getAuthFromEnv, getAPIToken, requireApiToken).

Patch Changes
  • #14213 10b5538 Thanks @dario-piotrowicz! - Improve authentication error messages with specific failure reasons

    When authentication fails (e.g. during wrangler dev --remote or when using remote bindings), the error message now explains exactly what went wrong -- whether no credentials were found, the token expired, or the environment is non-interactive -- and lists actionable steps to fix it, including a wrangler whoami tip.

    Previously, auth failures could produce multiple confusing errors (e.g. "Failed to fetch auth token: 400 Bad Request" followed by "Failed to start the remote proxy session"). Now a single, clear error is shown.

@cloudflare/vite-plugin@1.40.2
Patch Changes
  • #14184 e305126 Thanks @penalosa! - Drop the --config flag from the experimental internal cf-vite delegate binary.

    The wrangler config file is now discovered by cloudflare() itself rather than being passed through, keeping cf-vite's flag surface (--mode, --port, --host, --local) in sync with the sibling cf-wrangler delegate. cf-vite is an internal integration point spawned by Cloudflare tooling and is not intended to be run directly by users.

  • Updated dependencies [98c9afe, e305126, f3990b2, 4597f08, 25722ac, 41f75c0, 10b5538, 818c105, 2ae6099, 2047a32, 2047a32, e8561c2]:

    • wrangler@4.100.0
    • miniflare@4.20260611.0
miniflare@4.20260611.0
Minor Changes
  • #14119 2047a32 Thanks @tahmid-23! - Add support for serving R2 bucket objects publicly via the dev server

    Each local R2 bucket is now exposed under /cdn-cgi/local/r2/public/<bucket-id>/<key> on the existing user-facing dev server. The <bucket-id> is the bucket's id when set, otherwise its binding name. Buckets with a remoteProxyConnectionString are not exposed. The endpoint supports GET and HEAD, range requests, conditional headers, and forwards stored HTTP metadata.

Patch Changes
  • #14246 f3990b2 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260609.11.20260610.1
  • #14256 4597f08 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260610.11.20260611.1
wrangler@4.100.0
Minor Changes
  • #14119 2047a32 Thanks @tahmid-23! - Serve local R2 bucket objects publicly via the dev server

    When running wrangler dev locally, objects in each local R2 binding are now reachable under /cdn-cgi/local/r2/public/<bucket-id>/<key> on the existing dev server, simulating a public bucket. The <bucket-id> is the bucket's bucket_name when set, otherwise its binding. Bindings configured with remote: true are not exposed.

  • #14202 e8561c2 Thanks @jamesopstad! - Add experimental --x-new-config flag for authoring config in TypeScript

    This is an experimental, opt-in feature. When enabled, wrangler dev, wrangler build, wrangler deploy, wrangler versions upload, and wrangler versions deploy load the Worker's configuration from a cloudflare.config.ts file instead of wrangler.json / wrangler.jsonc / wrangler.toml. Additionally, an optional wrangler.config.ts file can be provided for Wrangler-specific dev/build configuration.

    • cloudflare.config.ts (required) — Worker runtime configuration (bindings, triggers, observability, placement, limits, compatibility, routes, etc.). Authored via defineWorker from wrangler/experimental-config.
    • wrangler.config.ts (optional) — Tooling / bundling / dev-server configuration (noBundle, minify, alias, define, rules, tsconfig, build, dev, assetsDirectory, etc.). Authored via defineWranglerConfig from wrangler/experimental-config.

    Per-environment configuration is via ctx.mode branching inside the function form of either file.

    Example cloudflare.config.ts:

    import { defineWorker, bindings } from "wrangler/experimental-config";
    import * as entrypoint from "./src/index.ts" with { type: "cf-worker" };
    
    export default defineWorker((ctx) => ({
    	name: "my-worker",
    	entrypoint,
    	compatibilityDate: "2026-05-18",
    	env: {
    		MY_KV: bindings.kv(),
    		MY_TEXT: bindings.text(`The mode is ${ctx.mode}`),
    	},
    }));

    Example wrangler.config.ts:

    import { defineWranglerConfig } from "wrangler/experimental-config";
    
    export default defineWranglerConfig({
      minify: true,
      assetsDirectory: "./public",
    });

    Because this is experimental, the flag, the config formats, and the wrangler/experimental-config exports may change in any release.

Patch Changes
  • #14185 98c9afe Thanks @penalosa! - Use the shared env-credential resolver from @cloudflare/workers-auth

    No user-facing behaviour change. Credential resolution order (global API key + email → CLOUDFLARE_API_TOKEN → stored OAuth token) is preserved.

  • #14184 e305126 Thanks @penalosa! - Add an experimental cf-wrangler delegate entrypoint for projects that can't use @cloudflare/vite-plugin (service workers, old compatibility dates, Python, Rust, etc.).

    cf-wrangler dev starts the same local dev server as wrangler dev — it sits directly on wrangler's internal dev server, so the bundling and runtime behaviour are identical — but exposes a deliberately narrow CLI surface (--mode, --port, --host, --local) for a parent CLI to delegate to, and other dev server config options are read from the wrangler config file.

    This replaces the separate @cloudflare/wrangler-bundler package. This is an internal integration point and is not intended to be run directly by users.

  • #14246 f3990b2 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260609.11.20260610.1
  • #14256 4597f08 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260610.11.20260611.1
  • #14243 25722ac Thanks @com6056! - Fix a memory leak that could make long-running headless wrangler dev sessions unresponsive

    Long-running wrangler dev sessions with no DevTools attached (for example using the containers feature under sustained traffic) could gradually consume unbounded memory and eventually stop accepting connections. The inspector proxy now only enables network tracking while a DevTools client is connected, so the buildup no longer happens. Interactive debugging is unaffected. Fixes #14191.

  • #14230 41f75c0 Thanks @dario-piotrowicz! - Improve D1 error messages for missing or conflicting options

    Error messages for d1 execute, d1 export, d1 time-travel restore, and d1 insights now clearly state which option is missing or conflicting, explain why the combination is invalid, and suggest how to fix the issue.

    Additionally, duration validation errors in d1 insights are now thrown as UserError instead of plain Error, ensuring they are displayed cleanly to users rather than as unexpected crashes.

  • #14213 10b5538 Thanks @dario-piotrowicz! - Improve authentication error messages with specific failure reasons

    When authentication fails (e.g. during wrangler dev --remote or when using remote bindings), the error message now explains exactly what went wrong -- whether no credentials were found, the token expired, or the environment is non-interactive -- and lists actionable steps to fix it, including a wrangler whoami tip.

    Previously, auth failures could produce multiple confusing errors (e.g. "Failed to fetch auth token: 400 Bad Request" followed by "Failed to start the remote proxy session"). Now a single, clear error is shown.

  • #14233 818c105 Thanks @dario-piotrowicz! - Improve R2 Sippy error messages

    Now error messages in wrangler r2 bucket sippy follow a consistent pattern: they describe what is missing, name the exact --flag to use, and provide context (e.g. example values, links to the dashboard). Previously, many errors said only "Error: must provide --flag." with no guidance on what the flag does or how to obtain the value.

  • #14259 2ae6099 Thanks @emily-shen! - Move worker build step earlier in deploy/upload step, before upload specific config validation

  • Updated dependencies [f3990b2, 4597f08, 2047a32]:

    • miniflare@4.20260611.0
create-cloudflare@2.70.2
Patch Changes
  • #14193 88519f9 Thanks @petebacondarwin! - Fix create cloudflare exiting with code 0 even after an unhandled error

  • #14235 13abd5a Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    @tanstack/cli0.69.10.69.2
  • #14193 88519f9 Thanks @petebacondarwin! - Fix create cloudflare aborting with ERR_PNPM_IGNORED_BUILDS on pnpm 11

    pnpm 11 flipped strictDepBuilds to true by default, which makes the install fail when dependencies have unapproved build scripts. wrangler depends on workerd and esbuild, and (via miniflare) on sharp — all three need their postinstall scripts to produce platform binaries.

    C3 now writes or merges in a pnpm-workspace.yaml in the generated project that approves exactly those three packages. If other packages trigger this error, C3 also now interactively offers to retry with pnpm approve-builds <pkg>…

create-cloudflare@2.70.1
Patch Changes
  • #14205 d6fd677 Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    create-react-router7.16.07.17.0
  • #14206 9c07154 Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    sv0.15.30.15.4
  • #14207 33ab99b Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    create-analog2.5.22.6.0
  • #14208 82c4d93 Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    create-next-app16.2.616.2.7
  • #14209 e13b8c0 Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    @angular/create21.2.1322.0.0
  • #14216 6b903e5 Thanks @dependabot! - Update dependencies of "create-cloudflare"

    The following dependency versions have been updated:

    DependencyFromTo
    @tanstack/cli0.68.00.69.1
miniflare@4.20260609.0
Patch Changes
  • #14192 d076bcc Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260603.11.20260605.1
  • #14217 24497d0 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260605.11.20260608.1
  • #14231 4bb572f Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260608.11.20260609.1
  • #14177 48c4ff0 Thanks @ktKongTong! - Enable local scheduled handler dispatch for Workers + Assets (#9882)

    It is now possible to trigger a scheduled handler on a Worker that has assets.

wrangler@4.99.0
Minor Changes
  • #14169 0706fbf Thanks @edmundhung! - Introduce createTestHarness() for integration testing Workers

    It runs Workers in a local preview environment using production build output and works with both Wrangler projects and Workers built by the Cloudflare Vite plugin.

    Use it from any Node.js test runner to send requests to individual Workers, trigger scheduled events, reset the server between tests, and mock outbound requests with libraries that intercept globalThis.fetch(), such as MSW.

    You can also capture structured logs from your Workers with getLogs(), or dump out a diagnostic timeline with debug() when tests fail:

    import { createTestHarness } from "wrangler";
    
    const server = createTestHarness({
      workers: [
        { configPath: "./dist/web_worker/wrangler.json" },
        { configPath: "./dist/api_worker/wrangler.json" },
      ],
    });
    
    await server.listen();
    await server.fetch("http://example.com");
    
    const apiWorker = server.getWorker("api-worker");
    await apiWorker.fetch("http://example.com/users/123");
    await apiWorker.scheduled({ cron: "0 0 * * *" });
    
    server.getLogs();
    
    if (testFailed) {
      server.debug();
    }
    
    await server.reset();
    await server.close();
  • #14174 8cf8c61 Thanks @oliy! - Surface pipeline status and failure reasons in wrangler pipelines list and wrangler pipelines get

    wrangler pipelines list now includes a Status column, and when any pipelines are in a failed state it prints a summary of each failing pipeline along with the reason reported by the API.

    wrangler pipelines get now shows the pipeline Status in the general details and, for failed pipelines, highlights the failure with the reason returned by the server so it is clear why a pipeline is not running.

  • #14211 a61ac29 Thanks @james-elicx! - Add --version-tag support to wrangler versions deploy to deploy a version by its tag

    You can now roll out or roll back a version by the tag it was uploaded with (e.g. a commit SHA passed to --tag at upload time) instead of first looking up its Version ID:

    wrangler versions deploy --version-tag <sha>@100%

    The tag is resolved to a Version ID against the worker's deployable versions, and the <version-tag>@<percentage> shorthand works just like the existing <version-id>@<percentage> notation, including splitting traffic across multiple --version-tag values. If a tag matches no deployable version, or matches more than one, the command errors and asks you to deploy by Version ID directly. Note that tags can only be resolved against recent (deployable) versions — older versions that have aged out of that window must still be deployed by Version ID.

Patch Changes
  • #14163 23aecac Thanks @emily-shen! - Print deploy warnings even in non-interactive contexts when strict mode is off

    Currently, wrangler deploy checks whether the incoming deploy configuration has destructive conflicts with the current configuration. Previously, we only performed this check in interactive contexts, or if the --strict flag was passed in. Now this warning is always printed, and it remains non-blocking in non-interactive contexts.

  • #14173 b932e47 Thanks @gpanders! - Handle API validation errors from wrangler containers ssh

    Wrangler now lets the Containers API validate SSH instance IDs and preserves raw API error bodies such as INVALID_INSTANCE_ID when reporting validation failures.

  • #14192 d076bcc Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260603.11.20260605.1
  • #14217 24497d0 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260605.11.20260608.1
  • #14231 4bb572f Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260608.11.20260609.1
  • #14195 165adb2 Thanks @dario-piotrowicz! - Show actionable error message when authentication fails during remote dev

    When wrangler dev with remote bindings encountered an authentication error (expired token, revoked OAuth, or invalid API token), the user saw a generic "A request to the Cloudflare API failed" message with no indication that authentication was the problem.

    Now, authentication failures during remote dev display a clear error message with actionable steps.

  • #14034 776098c Thanks @matingathani! - Fix wrangler types --check reporting types as out of date in multi-worker setups

    Previously, running wrangler types --check -c primary/wrangler.jsonc in a multi-worker project would incorrectly report types as out of date, even when they were current. This happened because the secondary worker config paths (passed via additional -c flags during generation) were not stored in the generated types file header, so --check had no way to resolve the secondary workers' service bindings when verifying the hash.

    The fix stores secondary config paths in the generated file's header comment so that --check can recover them automatically. Users no longer need to re-pass every -c flag when running --check — only the primary config is required.

  • #14053 7993711 Thanks @fallintoplace! - Prevent delete-only wrangler secret bulk input from creating a new Worker

    Previously, wrangler secret bulk could create a draft Worker when the input only deleted secrets and the target Worker name did not exist. Delete-only bulk secret operations now leave Worker-not-found as an error instead of creating a new Worker.

  • #14055 8923f97 Thanks @dario-piotrowicz! - Preserve all deployment-affecting CLI flags in the interactive deploy config flow

    When running wrangler deploy without a config file and going through the interactive setup flow, CLI flags beyond --compatibility-flags (such as --routes/--route, --domains/--domain, --triggers, --var, --define, --alias, --jsx-factory, --jsx-fragment, --tsconfig, --minify, --upload-source-maps, --no-bundle, --logpush, --keep-vars, --legacy-env, and --dispatch-namespace) were silently dropped. These flags are now persisted to the generated wrangler.jsonc config file (where a config field equivalent exists) and included in the suggested CLI command when the user declines config file generation.

  • #14196 b205fb7 Thanks @odiak! - Validate JSON stdin values for wrangler secret bulk

    JSON input piped through stdin now validates that secret values are strings or null before sending them to the API, matching the existing behavior for file input.

  • Updated dependencies [d076bcc, 24497d0, 4bb572f, 48c4ff0]:

    • miniflare@4.20260609.0
wrangler@4.98.0
Minor Changes
  • #14089 c6c61b5 Thanks @alsuren! - Add migrations_pattern to D1 database bindings

    The D1 binding now accepts an optional migrations_pattern field, allowing you to point wrangler d1 migrations apply and wrangler d1 migrations list at migration files in nested layouts (e.g. ORM-generated folders like migrations/0000_init/migration.sql).

    migrations_pattern is a glob (relative to the wrangler config file) and defaults to ${migrations_dir}/*.sql, which preserves today's behaviour. Files that do not match the pattern are not executed.

    {
      "d1_databases": [
        {
          "binding": "DB",
          "database_name": "my-db",
          "database_id": "...",
          "migrations_dir": "migrations",
          "migrations_pattern": "migrations/*/migration.sql"
        }
      ]
    }

    When no migrations match the configured pattern but files matching the common migrations/*/migration.sql (drizzle-style) layout do exist, Wrangler logs a hint suggesting migrations_pattern as an opt-in.

    wrangler d1 migrations create now returns an actionable error if the generated migration filename would not match the configured pattern.

  • #14153 7a6b1a4 Thanks @dario-piotrowicz! - Generalize wrangler deploy and wrangler versions upload positional argument from [script] to [path]

    Both wrangler deploy and wrangler versions upload now accept a generic [path] positional argument that can point to either a Worker entry-point file or a directory of static assets. The type is auto-detected. For example:

    • File: wrangler deploy ./src/index.ts deploys a Worker (same as before)
    • Directory: wrangler deploy ./public deploys a static assets site (no interactive confirmation prompt)

    The --script named option is now hidden and deprecated for both commands. It continues to work for backwards compatibility but only accepts file paths. Passing a directory to --script now produces a clear error message suggesting the positional path argument or --assets flag instead.

  • #13863 3b8b80a Thanks @aslakhellesoy! - getPlatformProxy() now passes through workflow bindings that have a script_name

    Workflows without a script_name are still stripped (and warned about) because the engine for an internal workflow can't run inside the empty proxy worker that backs getPlatformProxy(). Workflows with a script_name are handed to miniflare unchanged; miniflare reroutes the engine's USER_WORKFLOW binding through the dev-registry-proxy when the target worker is running in another Miniflare instance — the same mechanism Durable Objects already use.

    This means SvelteKit/Remix (and similar split-process setups) can call platform.env.MY_WORKFLOW.create({ ... }) directly from their server-side request handlers in dev, as long as the workflow class is exposed by another worker registered in the dev registry.

    Closes #7459.

  • #14164 b502d54 Thanks @G4brym! - Rename the web_search binding kind to websearch

    Pre-launch rename of the public binding type from web_search to websearch so the on-the-wire shape matches the product name (Web Search). The wrangler config key, the binding-type string sent to the Cloudflare API, and the miniflare option key all move from web_search / webSearch to websearch.

    Update your wrangler config:

    - "web_search": { "binding": "WEBSEARCH" }
    + "websearch": { "binding": "WEBSEARCH" }

    The runtime WebSearch type exposed on env.WEBSEARCH is unchanged.

Patch Changes
  • #14089 c6c61b5 Thanks @alsuren! - Restore the D1 executeSql logger level via try/finally

    wrangler d1 execute --json and the internal executeSql helper temporarily lower the global logger to "error" to keep human-readable output out of the JSON payload. Previously the level was restored only on the happy path, so any early return or thrown error left the singleton logger muted, silencing later logger.warn/logger.log output (notably from migration helpers that wrap executeSql and are commonly mocked in tests).

    The level swap is now wrapped in try/finally so it is always restored.

  • #14175 a3eea27 Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"

    The following dependency versions have been updated:

    DependencyFromTo
    workerd1.20260601.11.20260603.1
  • #14121 7539a9b Thanks @petebacondarwin! - Extract the OAuth 2.0 + PKCE flow into a new @cloudflare/workers-auth package.

    The OAuth login / logout / refresh logic, the auth-config TOML file IO, the OAuth token exchange + local callback server, and the Cloudflare Access detection helpers that previously lived in packages/wrangler/src/user/ have moved to the new internal-only @cloudflare/workers-auth package. Wrangler now wires the OAuth flow up via a small glue module that injects its logger, browser opener, interactivity detector, and config cache via a dependency- injection context.

    What stays in wrangler:

    • The yargs login / logout / whoami / auth token commands
    • Environment-based credential resolution (CLOUDFLARE_API_TOKEN, CLOUDFLARE_API_KEY / CLOUDFLARE_EMAIL, etc.)
    • Cloudflare account selection (requireAuth, getOrSelectAccountId)
    • The OAuth scope catalog (passed into the OAuth flow as a generic string[])
    • whoami / account fetching

    No behavior change for end users. The on-disk TOML format and location remain identical, and all telemetry message labels are preserved verbatim.

    @cloudflare/workers-auth is published with prerelease: true and is not intended for external use — its APIs may change without notice.

  • #14162 0bb2d55 Thanks @dario-piotrowicz! - In non-interactive mode remove the skills installation message

    When Wrangler run in non interactive mode and it detected agents that it could install skills for, it would print a message such as:

    Cloudflare agent skills are available for: <DETECTED_AGENTS>. Run wrangler in an interactive terminal to install them, or use '--install-skills' to install without prompting.

    This message seems to be confusing and unhelpful so it has now been removed.

  • #14165 8400fb9 Thanks @NuroDev! - Limit wrangler versions list to the 10 most recent deployable versions

    The versions API ignores pagination when filtering to deployable versions, so Wrangler now caps the command output client-side. This keeps the command aligned with its help text and avoids overwhelming terminal output for Workers with many versions.

  • #14151 7949f81 Thanks @dario-piotrowicz! - Skip stale bundles during dev server reload to avoid redundant restarts

    When rapidly saving a wrangler config file with remote bindings, each save would trigger a full reload cycle (remote connection setup, miniflare restart), causing many sequential "Reloading local server... / Establishing remote connection..." messages (while blocking the user). The runtime controllers now check whether a newer bundle has been queued at each expensive async boundary and bail out early if the current bundle is stale. This ensures that only the latest config change triggers a reload, making wrangler dev much more responsive during repeated config edits.

  • #14072 d462013 Thanks @himanshu-cf! - Update wrangler secret bulk command description to reflect create/update/delete capabilities

    The help text for wrangler secret bulk now accurately describes that the command can create, update, or delete multiple secrets in a single request, with up to 100 secrets per command. The file argument description also clarifies that setting a key to null in JSON will delete it, and that deletion is not supported with .env files.

  • #13979 c2280cd Thanks @matingathani! - Warn when a named environment silently inherits custom_domain routes from the top-level config

    When an env.<name> block does not override routes, it inherits the top-level routes array. If that array contains entries with custom_domain: true, every deploy to the named environment will silently reassign the custom domain away from the top-level Worker and towards the env Worker, causing routing drift. Wrangler now emits a warning in this situation and suggests adding "routes": [] to the env block to prevent inheritance.

  • #14170 ea12b58 Thanks @petebacondarwin! - Tighten on-disk permissions of the OAuth credentials file to 0600

    The user auth config file written by wrangler login (typically ~/.config/.wrangler/config/default.toml on Linux/macOS, or <environment>.toml for non-production Cloudflare API environments) is now written with mode 0600 and re-chmod-ed on every save. This prevents other local users on shared hosts from reading the stored OAuth tokens. Existing files with looser permissions written by older Wrangler versions are tightened the next time Wrangler refreshes the token or the user logs in again. The change is a no-op on Windows, which does not honour POSIX mode bits.

  • #14022 acf7817 Thanks @petebacondarwin! - Show the actual OAuth error instead of hanging when wrangler login is rejected by the OAuth provider (for example with invalid_scope).

    Previously, if the OAuth callback returned with an error other than access_denied, Wrangler would never respond to the browser. Because server.close()'s callback only fires once all open connections have ended, the login command would hang until the 120 second OAuth timeout — at which point it would print a generic timeout message rather than the actual OAuth failure. The same gap existed for the case where the OAuth provider redirected back without an authorisation code, and for failures during the auth-code-to-access-token exchange.

    The OAuth provider's error_description (RFC 6749 §4.1.2.1) is now also surfaced, so the message includes the specific reason for the failure rather than just the bare error code. For example, a misconfigured staging scope now surfaces as:

    OAuth error: invalid_scope
      The OAuth 2.0 Client is not allowed to request scope 'browser:write'.

    instead of hanging silently.

  • Updated dependencies [a3eea27, 1fdd8de, b502d54, 3b8b80a]:

    • miniflare@4.20260603.0
@cloudflare/workers-utils@0.23.0
Minor Changes
  • #14089 c6c61b5 Thanks @alsuren! - Add migrations_pattern to D1 database bindings

    The D1 binding now accepts an optional migrations_pattern field, allowing you to point wrangler d1 migrations apply and wrangler d1 migrations list at migration files in nested layouts (e.g. ORM-generated folders like migrations/0000_init/migration.sql).

    migrations_pattern is a glob (relative to the wrangler config file) and defaults to ${migrations_dir}/*.sql, which preserves today's behaviour. Files that do not match the pattern are not executed.

    {
      "d1_databases": [
        {
          "binding": "DB",
          "database_name": "my-db",
          "database_id": "...",
          "migrations_dir": "migrations",
          "migrations_pattern": "migrations/*/migration.sql"
        }
      ]
    }

    When no migrations match the configured pattern but files matching the common migrations/*/migration.sql (drizzle-style) layout do exist, Wrangler logs a hint suggesting migrations_pattern as an opt-in.

    wrangler d1 migrations create now returns an actionable error if the generated migration filename would not match the configured pattern.

  • #14164 b502d54 Thanks @G4brym! - Rename the web_search binding kind to websearch

    Pre-launch rename of the public binding type from web_search to websearch so the on-the-wire shape matches the product name (Web Search). The wrangler config key, the binding-type string sent to the Cloudflare API, and the miniflare option key all move from web_search / webSearch to websearch.

    Update your wrangler config:

    - "web_search": { "binding": "WEBSEARCH" }
    + "websearch": { "binding": "WEBSEARCH" }

    The runtime WebSearch type exposed on env.WEBSEARCH is unchanged.

  • #14146 c4f45e8 Thanks @dario-piotrowicz! - Simplify constructWranglerConfig to accept a single worker instead of an array

    The constructWranglerConfig function now accepts a single APIWorkerConfig object instead of APIWorkerConfig | APIWorkerConfig[]. The multi-environment array support has been removed since the array use-case was removed and now the only call site already passes a single worker object. This is a breaking change to the function's public signature.

Last Checked
2h ago
Latest
@cloudflare/workers-auth@0.2.0
Tracking since Jan 20, 2026