RESOURCES · GUIDES

Think in journeys.

Tutorials show the commands. Guides explain the decisions behind them: what belongs in the model, which values should be captured, when to branch, and what a healthy regression suite looks like.

ConceptsPatternsAuthRegression
guide index
01 the behavioral model
02 auth as a chain
03 state between steps
04 failures worth asserting
05 a suite you can trust
Five ideas behind a reliable workflow

GUIDES

Five ideas that carry most of the work.

01Model

The behavioral model

Why the route, middleware, and source location belong in one shared artifact.

02Auth

Auth as a chain

A token is produced somewhere and consumed elsewhere. Model both ends.

03State

State between steps

Capture only what later steps need, and name it for the workflow.

04Edges

Failures worth asserting

Negative paths prove the API says no for the right reason.

05Suite

A suite you can trust

Small, isolated, deterministic journeys beat a large flaky suite.

06Runs

Evidence over output

A pass is a result. A trace is an explanation.

PATTERNS

Match the pattern to the problem.

These are the recurring shapes in real workflows.

PatternUse whenMechanism
Token handoffA route requires a session or bearer tokenCapture from the login response and inject as a header
Create then readLater steps depend on a generated idCapture the id and use it in the next path
Expected rejectionThe behavior includes a 4xx responseSet the expected status and assert the error code
Conditional branchThe next step depends on a role or flagEvaluate workflow memory after the step
Retry with delayA dependency is eventually consistentAdd a bounded retry to the step
Regression baselineA journey must keep workingCommit the workflow and run it in CI

PRINCIPLES

How to keep a model honest.

The model is only valuable if it matches the code and the tests stay small enough to review.

Rescan instead of guessing

When the router or middleware changes, rescan. A model that has drifted from the source is worse than no model, because it produces confident tests for the wrong contract.

Capture with intent

Do not capture every field in a response. Capture the token, id, or flag that a later step actually needs, and give it a name that reads in the workflow.

Prefer explicit over clever

  • A visible expected status beats an implied success rule
  • A condition on a captured role beats a hidden script
  • A small workflow beats a long one with unclear ownership
  • A reproducible failure beats a retry that hides it

GO DEEPER

Concepts into practice.

GUIDE FAQ

Frequently asked questions

Do I need to read these in order?

No. Start with the model or auth guide, depending on what is blocking you.

Are these tied to the CLI version?

The concepts are stable. Command details live in the docs and may evolve.

Can I contribute a pattern?

Yes. Share the shape and the problem it solves; see the community page.

Read the idea. Run the pattern.

The docs take each guide from concept to a workflow you can execute.

Open the docs