Template library
Start from code that runs.
Only templates marked ✓ Tested have passed an end-to-end run. “Coming soon” cards are the roadmap, not finished work.
Approval + resume & tool error formatting
Pause tool calls for human approval, checkpoint the run to a string, approve/reject, and resume. Plus the new run-wide tool_error_formatter that scrubs secrets from crashed tools.
Human-in-the-loop approval graph
A propose → approval → execute StateGraph that pauses with interrupt(), saves the pause in a checkpointer under a thread_id, and resumes with Command(resume=...) down the approve or reject path.
Idempotent approval: no double charges on resume
When a run resumes after interrupt(), LangGraph re-runs the paused node from the top. This template shows the double-charge bug and the fix: approval-only node, separate execute node, and an idempotency key derived from thread_id.
Idempotent approved side effects
The Agents SDK runs an approved tool once per resume, but side effects still repeat on a duplicate resume of the same RunState or a whole-run retry after a crash. Shows both failures (2 charges) and the fix (1 charge).
Multiple interrupts in one node
One node calls interrupt() three times and is answered one resume at a time (matched by position), plus two parallel nodes that interrupt in the same step and are resumed together with a dict keyed by Interrupt.id.
Minimal web UI to approve paused runs
A stdlib-only web page (plain HTML forms, no JavaScript) that lists paused LangGraph runs and approves or rejects them with Command(resume=...), with 409/400/404 handling.
Tool approval with generateText
generateText with the v7 toolApproval option: refunds over $100 pause as tool-approval-request, a human approves or denies, and the run resumes. Covers $50 auto-approved, $500 approved and $500 denied.
Research crew with sourced output
Planned: a role-based crew (researcher, writer, reviewer) that returns a cited brief. Not built or tested yet.
Tool confirmation step
An ADK agent whose transfer_money tool asks a human to confirm only large amounts (require_confirmation as a callable), then runs or rejects the original call in the same session.
Durable, typed task runner
Planned: typed agent outputs with a task that survives restarts. Not built or tested yet.
MCP server starter
Planned: a minimal Model Context Protocol server exposing two tools, with a local test client. Not built or tested yet.
Scheduled agent on the edge
Planned: a stateful agent that schedules its own follow-up tasks. Not built or tested yet.