惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园_首页
IT之家
IT之家
博客园 - Franky
Stack Overflow Blog
Stack Overflow Blog
宝玉的分享
宝玉的分享
Recent Announcements
Recent Announcements
Engineering at Meta
Engineering at Meta
S
SegmentFault 最新的问题
V
Visual Studio Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Last Week in AI
Last Week in AI
H
Help Net Security
V
V2EX
H
Hackread – Cybersecurity News, Data Breaches, AI and More
量子位
博客园 - 叶小钗
J
Java Code Geeks
博客园 - 【当耐特】
月光博客
月光博客
爱范儿
爱范儿
人人都是产品经理
人人都是产品经理
酷 壳 – CoolShell
酷 壳 – CoolShell
小众软件
小众软件

Workflow SDK Documentation

Patterns for Defining Tools Human-in-the-Loop Building Durable AI Agents Queueing User Messages Resumable Streams Sleep, Suspense, and Scheduling Streaming Updates from Tools API Reference Workflow Globals Changelog Resilient run start Cookbook Building a World Deploying Astro Express Fastify Hono Getting Started NestJS Next.js Nitro Nuxt Python SvelteKit Vite corrupted-event-log fetch-in-workflow hook-conflict Errors
workflowEntrypoint
2026-06-12 · via Workflow SDK Documentation

Create the HTTP route handler that executes workflow runs from a workflow bundle.

Creates the HTTP route handler that executes workflow runs. The handler receives queue messages, replays the workflow from its event log, executes steps inline where possible, and suspends when the workflow waits on sleeps or hooks.

Framework adapters (Next.js, Nitro, SvelteKit, etc.) call this for you and mount the result at /.well-known/workflow/v1/flow — you only need it when wiring workflow support into a custom server environment.

import { workflowEntrypoint } from "workflow/runtime";
declare const workflowBundleCode: string; // @setup

const handler = workflowEntrypoint(workflowBundleCode); 

// Mount on your server, e.g. a fetch-style route:
export const POST = (req: Request) => handler(req);

Parameters

ParameterTypeDescription
workflowCodestringThe compiled workflow bundle code containing all workflow functions
options{ namespace?: string }Optional. namespace scopes the queue topics this handler consumes.

Returns

Returns a fetch-style request handler: (req: Request) => Promise<Response>.