Skip to main content
With the flag, recorded traffic from the linked agent upstream becomes the sandbox’s final resolution tier. A request the spec cannot answer, and the traffic overlay has not admitted, is answered from the closest recording instead of a 404. It is never on silently.

Matching is hierarchical

One clever hash would miss on real payment traffic where every request carries different amounts and references, so matching degrades in three steps:
  1. exact: method, path, and the normalized request body hash.
  2. shape: method, path template, and the set of body fields, values ignored.
  3. sequence: the next unserved recording for that method and template.
Before hashing, a curated list of request fields and headers that churn by nature (idempotency keys, trace ids, signatures, timestamps) is stripped.

Every response says where it came from

Each degradation explains which fields missed, so a shape-tier answer is never mistaken for an exact one.

What it needs

An agent upstream with the same name, or one linked with --upstream, and recordings under <data_dir>/recordings/<upstream>.ndjson. When the flag is on but no recordings are loaded yet, pikopod up says so and unmatched requests answer 404 until traffic is recorded. Recordings are the redacted ones. Identifiers are tokens and unclassified strings were dropped, so a replayed body is the sanitized body. See Redaction.