Sign inConnect your agent
infochanged

Workflows, Workers - Declare Workflows in the `exports` configuration

Announced
Tags
Workflows, Workers
Severity
info, set by reef/rss-rule-v1
Source
https://developers.cloudflare.com/changelog/post/2026-09-24-workflow-exports/

<p>You can now declare the Workflows a Worker defines in the <a href="https://developers.cloudflare.com/workers/wrangler/configuration/#workflow-exports"><code>exports</code></a> field of your Wrangler configuration file. Previously, a Worker could only define a Workflow through a <code>workflows</code> binding, even when the Worker never called the Workflow itself.</p> <p>Key each entry by the name of the class that extends <code>WorkflowEntrypoint</code>:</p> <div data-nb-tabs data-nb-sync-key="wranglerConfig" class><div class="relative flex border-b border-border" role="tablist" data-nb-tabs-list><span class="bg-primary pointer-events-none absolute -bottom-px h-0.5 rounded-t-sm transition-[left,width] duration-200 ease-out" data-nb-tabs-indicator aria-hidden="true"></span></div><div class="mt-3"><div role="tabpanel" data-nb-tabs-content data-nb-tab-label="wrangler.jsonc" class><figure class="nb-code-figure" data-nb-lang="jsonc"><pre class="astro-code astro-code-themes github-light github-dark nb-shiki-c6xiwz" tabindex="0" data-language="jsonc" data-nb-lang="jsonc"><code><span class="line"><span class="nb-shiki-140thh">{</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "exports"</span><span class="nb-shiki-140thh">: {</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "MyWorkflow"</span><span class="nb-shiki-140thh">: {</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "type"</span><span class="nb-shiki-140thh">: </span><span class="nb-shiki-mdbnqw">"workflow"</span><span class="nb-shiki-140thh">,</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "name"</span><span class="nb-shiki-140thh">: </span><span class="nb-shiki-mdbnqw">"my-workflow"</span><span class="nb-shiki-140thh">,</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "limits"</span><span class="nb-shiki-140thh">: {</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "steps"</span><span class="nb-shiki-140thh">: </span><span class="nb-shiki-dzsirb">25000</span><span class="nb-shiki-140thh">,</span></span> <span class="line"><span class="nb-shiki-140thh"> },</span></span> <span class="line"><span class="nb-shiki-dzsirb"> "schedules"</span><span class="nb-shiki-140thh">: [</span><span class="nb-shiki-mdbnqw">"0 * * * *"</span><span class="nb-shiki-140thh">],</span></span> <span class="line"><span class="nb-shiki-140thh"> },</span></span> <span class="line"><span class="nb-shiki-140thh"> },</span></span> <span class="line"><span class="nb-shiki-140thh">}</span></span></code></pre></figure></div><div role="tabpanel" data-nb-tabs-content data-nb-tab-label="wrangler.toml" class><figure class="nb-code-figure" data-nb-lang="toml"><pre class="astro-code astro-code-themes github-light github-dark nb-shiki-c6xiwz" tabindex="0" data-language="toml" data-nb-lang="toml"><code><span class="line"><span class="nb-shiki-140thh">[</span><span class="nb-shiki-1t8gfj">exports</span><span class="nb-shiki-140thh">.</span><span class="nb-shiki-1t8gfj">MyWorkflow</span><span class="nb-shiki-140thh">]</span></span> <span class="line"><span class="nb-shiki-140thh">type = </span><span class="nb-shiki-mdbnqw">"workflow"</span></span> <span class="line"><span class="nb-shiki-140thh">name = </span><span class="nb-shiki-mdbnqw">"my-workflow"</span></span> <span class="line"><span class="nb-shiki-140thh">schedules = [ </span><span class="nb-shiki-mdbnqw">"0 * * * *"</span><span class="nb-shiki-140thh"> ]</span></span> <span class="line"></span> <span class="line"><span class="nb-shiki-140thh"> [</span><span class="nb-shiki-1t8gfj">exports</span><span class="nb-shiki-140thh">.</span><span class="nb-shiki-1t8gfj">MyWorkflow</span><span class="nb-shiki-140thh">.</span><span class="nb-shiki-1t8gfj">limits</span><span class="nb-shiki-140thh">]</span></span> <span class="line"><span class="nb-shiki-140thh"> steps = </span><span class="nb-shiki-dzsirb">25_000</span></span></code></pre></figure></div></div></div><script type="module" src="https://developers.cloudflare.com/home/runner/work/cloudflare-docs/cloudflare-docs/src/components/ui/tabs/Tabs.astro?astro&type=script&index=0&lang.ts"></script> <p>A <code>workflow</code> export accepts the same settings as a <code>workflows</code> binding: <code>limits</code>, <code>schedules</code>, and <code>default_retention</code>. When you run <code>wrangler deploy</code>, Wrangler creates or updates the Workflow with these settings.</p> <p>You can declare a Workflow as both a binding and an export. Both declarations must use the same class, and cannot set the same setting to different values.</p> <p>A <code>workflows</code> binding to a Workflow in another Worker cannot use the same <code>name</code> as a Workflow export in this Worker. Workflow names are unique per account.</p> <p>Workflow exports require Wrangler 4.139.0 or above.</p> <p>For more information, refer to <a href="https://developers.cloudflare.com/workflows/build/workers-api/#declare-workflows-in-exports">Declare Workflows in <code>exports</code></a>.</p>

The text above is the source's. reef added the severity, the dates it could read from the text, and the endpoints and scopes named in code.