task-flow-authoring

Author executable JSON contract flows that verify API behavior against feature plans.

Updated Apr 7, 2026
One-click install
npx skills add https://github.com/hontauadrian/sfx-app-empty-test --skill task-flow-authoring-hontauadrian
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: task-flow-authoring
Source: https://github.com/hontauadrian/sfx-app-empty-test/tree/main/.claude/skills/task-flow-authoring
Command: npx skills add https://github.com/hontauadrian/sfx-app-empty-test --skill task-flow-authoring-hontauadrian

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Feature plans and product journeys describe expected API behavior in prose, but nothing enforces those promises at runtime. This Skill turns a plan into a curated, executable contract flow file (.overstory/runtime-contract.flows/<task-id>.json) that a runtime probe asserts against, catching drift between spec and code before it ships. ## Core Features & Use Cases - Decision-11 coverage authoring: Walks 17 coverage sub-rows (business rules, cross-tenant isolation, async polling, idempotency, bulk endpoints, concurrency, content negotiation) with paste-ready JSON patterns per row. - Bootstrap curation workflow: Converts machine-generated bootstrap:openapi:* draft rows into curated plan-referenced flows, adding the ~70% of coverage (cross-tenant, state machines, side-effects) that code inference cannot produce. - Failure-mode triage: Provides resolution recipes for the five probe diagnostics (FLOW_OWNERSHIP_VIOLATION, FLOW_NEW_ENDPOINT_UNCOVERED, FLOW_MERGE_CONFLICT, FLOW_DUPLICATE_ID, FLOW_FILE_MISSING_OWNS_OR_EXTENDS) and the flow_mismatch/flow_update mail protocol for builder hand-offs. - Use Case: After finishing a feature plan for a multi-tenant orders API, run bootstrap, then use this Skill to author the four-flow cross-tenant set, idempotency replay flows, and async job polling flows so the probe proves the plan's promises. ## Quick Start After completing a feature plan, ask the agent to invoke the task-flow-authoring skill to bootstrap and curate the contract flow file for your task id.

Frequently Asked Questions about task-flow-authoring

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I author a contract flow file for a new API endpoint?▼

Run pnpm flows:bootstrap --task=<task-id> to scaffold a draft from OpenAPI decorators, then walk the Decision-11 checklist to curate each generated row and add plan-level flows like cross-tenant and business-rule coverage. Commit only after replacing bootstrap:openapi:* sources with plan references.

What is the difference between bootstrap-generated and curated flows?▼

Bootstrap generates happy-path, status, and lifecycle skeletons inferable from code, marked with bootstrap:openapi:* sources. Curated flows carry plan references and cover what code cannot infer: cross-tenant rules, state machines, side-effects, and validation boundaries.

Can a builder edit the runtime-contract.flows folder directly?▼

No. The flows-path-boundary hook blocks builder writes with FLOW_OWNERSHIP_VIOLATION. Builders must mail the lead with --type flow_mismatch; only the lead or coordinator can edit flow files, including copies inside builder worktrees.

Why does the probe report FLOW_NEW_ENDPOINT_UNCOVERED on commit?▼

The drift-check hook detected a route in the diff that no flow file declares. The builder mails the lead, who invokes this Skill to add Decision-11 coverage for the new endpoint, then replies with a flow_update so the pre-close gate clears.

What auth schemes are supported for flow actors?▼

Actors must use a scheme from AUTH_SCHEME_REGISTRY: anonymous, bearer-in-body, bearer-in-header, cookie, api-key, or oauth-scoped. Placeholder auth objects are rejected at contract load; unsupported schemes like mTLS or SAML require extending the registry first.

When should I not reduce flow coverage to fix a failing probe?▼

Never. Deleting resources, owns entries, or generated flows to silence a failure is a COVERAGE_REGRESSION_HACK. Fix the assertion or the code instead, or escalate via flow_escalation with rationale if the coverage itself is genuinely wrong.