Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add resonatehq/resonate-skills --skill resonate-basic-durable-world-usage-typescriptgit clone --depth 1 https://github.com/resonatehq/resonate-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/resonatehq/resonate-skills/resonate-basic-durable-world-usage-typescript)<a href="https://agentmods.dev/skills/resonatehq/resonate-skills/resonate-basic-durable-world-usage-typescript"><img src="https://agentmods.dev/badge/skills/resonatehq/resonate-skills/resonate-basic-durable-world-usage-typescript/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/resonatehq/resonate-skills/resonate-basic-durable-world-usage-typescript"><img src="https://agentmods.dev/badge/skills/resonatehq/resonate-skills/resonate-basic-durable-world-usage-typescript.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00083 | $0.04840 |
| Opus 5 | $0.00042 | $0.02420 |
| Sonnet 5 | $0.00017 | $0.00968 |
| Haiku 4.5 | $0.00008 | $0.00484 |
Grade A, and why
resonate-basic-durable-world-usage-typescript scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 726 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Resonate Basic Durable World Usage
SDK version: This skill reflects
@resonatehq/sdkv0.11.4 (current on npm).Two execution engines (v0.11.0+): The SDK now ships two engines. This skill documents the generator engine (imported from
@resonatehq/sdk), which usesfunction*/yield*and is the basis of all existing Resonate examples. An async/await engine (imported from@resonatehq/sdk/async) was added in v0.11.0 and is documented inresonate-async-await-engine-typescript.
Overview
The Durable World is inside generator functions where you write durable, recoverable execution logic using the Context object. Every operation checkpoints progress, enabling automatic recovery after failures.
Key distinction: Durable World code uses ctx (Context). Ephemeral World code uses resonate (Client).
Mental Model
Generator Function (function*)
↓
yield* ctx.run() ← Checkpoint
↓
yield* ctx.sleep() ← Checkpoint + Suspend
↓
yield* ctx.rpc() ← Checkpoint + Cross Process
↓
return result ← Final Checkpoint
Every yield* is a durable checkpoint.
If the process crashes, the execution replays from the last checkpoint using stored results.
Core Syntax Rules
1. Use function* (Generator Functions)
// ✅ CORRECT - Generator function
function* myWorkflow(ctx: Context, arg: string) {
// Durable code here
}
// ❌ WRONG - Async function
async function myWorkflow(ctx: Context, arg: string) {
// Not durable!
}
// ❌ WRONG - Async generator
async function* myWorkflow(ctx: Context, arg: string) {
// Invalid syntax for Resonate
}
2. Always yield* Context Calls
function* myWorkflow(ctx: Context) {
// ✅ CORRECT
const result = yield* ctx.run(someFunc, "arg");
// ❌ WRONG - Missing yield*
const result = ctx.run(someFunc, "arg");
// ❌ WRONG - Using await
const result = await ctx.run(someFunc, "arg");
}
3. First Parameter is Always Context
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 10d ago First seen · 726 lines · 83 tokens per session scan A cbb3097747d6
resonate-basic-durable-world-usage-typescript is a skill published in the GitHub repository resonatehq/resonate-skills (6 stars, last pushed 18d ago), licensed Apache-2.0. It adds 83 tokens to every session and 4,840 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
workflow
Creates durable, resumable workflows using Vercel's Workflow SDK. Use when building workflows that need to survive restarts, pause for external events, retry on failure, or coordinate multi-step operations over time. Triggers on mentions of "workflow", "durable functions", "resumable", "workflow sdk", "queue"…
migrating-workflow-v4-to-v5
Upgrades an app from Workflow SDK 4.x to 5.0. Use when bumping the workflow / @workflow/ dependencies to v5, or when hitting removed v4 APIs — runStep, stepEntrypoint, workflow/internal/private, @workflow/core/private, writeToStream / closeStream / readFromStream on a World, world.steps.get without a runId…
migrating-to-workflow-sdk
Migrates Temporal, Inngest, Trigger.dev, and AWS Step Functions workflows to the Workflow SDK. Use when porting Activities, Workers, Signals, step.run(), step.waitForEvent(), Trigger.dev tasks / wait.forToken / triggerAndWait, ASL JSON state machines, Task/Choice/Wait/Parallel states, task tokens, or child workflows.
deepep-to-cam-converter
A code migration skill for replacing DeepEP communication operations with CAM operations when moving mixture-of-experts code from CUDA/NCCL to Ascend NPUs.
e2a-doctor
Use when an existing e2a MCP connection, inbox, custom domain, protection policy, webhook, or message delivery is failing or unclear. Diagnoses read-only through MCP first, ranks evidence-backed causes, and offers individually confirmed repairs; uses the CLI doctor only when CLI or self-hosted diagnostics are…
e2a-integrate
Use when adding e2a email capabilities to an application or codebase: outbound sending, inbound signed webhooks, REST polling, or SDK integration. Inspects the existing language and framework, uses official TypeScript/Python SDKs or idiomatic REST/OpenAPI, adds tests, and keeps credentials server-side.