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

推荐订阅源

V
Visual Studio Blog
Y
Y Combinator Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Hugging Face - Blog
Hugging Face - Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
The Cloudflare Blog
L
LangChain Blog
美团技术团队
N
Netflix TechBlog - Medium
量子位
酷 壳 – CoolShell
酷 壳 – CoolShell
B
Blog
博客园 - 司徒正美
爱范儿
爱范儿
D
DataBreaches.Net
月光博客
月光博客
U
Unit 42
B
Blog RSS Feed
Engineering at Meta
Engineering at Meta
Apple Machine Learning Research
Apple Machine Learning Research
Jina AI
Jina AI
MongoDB | Blog
MongoDB | Blog
腾讯CDC

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
hydrateResourceIO
2026-06-12 · via Workflow SDK Documentation

Hydrate the serialized data fields of a run, step, hook, or event for display.

Hydrates (deserializes) the data fields of a resource returned by the World SDK — a workflow run, step, hook, or event. Workflow data is serialized using the devalue format, so this is required before displaying step input/output in a UI.

The function dispatches on the resource shape: steps get input/output hydrated, hooks get metadata, events get eventData, and runs get input/output.

import { getWorld } from "workflow/runtime";
import { hydrateResourceIO, observabilityRevivers } from "workflow/observability"; 
declare const runId: string; // @setup
declare const stepId: string; // @setup

const world = await getWorld();
const step = await world.steps.get(runId, stepId);
const hydrated = hydrateResourceIO(step, observabilityRevivers); 
console.log(hydrated.input, hydrated.output);

Parameters

ParameterTypeDescription
resourceWorkflowRun | Step | Hook | EventThe resource with serialized data fields
reviversReviversReviver functions for deserialization. Use observabilityRevivers for standard use.

Returns

The same resource with its data fields hydrated into plain JavaScript values.

Encrypted data fields pass through as raw Uint8Array values rather than being decrypted — see Encrypted Data.

Display a Run's Steps with Hydrated I/O

import { getWorld } from "workflow/runtime";
import { hydrateResourceIO, observabilityRevivers } from "workflow/observability"; 
declare const runId: string; // @setup

const world = await getWorld();
const steps = await world.steps.list({ runId, resolveData: "all" });

for (const step of steps.data) {
  const hydrated = hydrateResourceIO(step, observabilityRevivers); 
  console.log(step.stepName, hydrated.input, hydrated.output);
}