# Capability Spec Delta: idempotency (spec-conformance) **Package**: `@suaveplan/idempotency` **Status**: PROPOSED This delta annotates each existing requirement in `openspec/specs/idempotency/spec.md` with a `**Verified by:**` line and rewrites the heading style from `REQ-IDMP-NNN — name` to `IDMP-NN — name` so the conformance parser ingests them. No requirement semantics change. ## MODIFIED Requirements (See `openspec/specs/idempotency/spec.md` for the full requirement bodies; this delta only records the verification mapping.) | Requirement | Verified by | |---|---| | IDMP-01 — Structured error hierarchy | `src/errors/idempotency-error.test.ts` AND `src/error-codes.test.ts` AND `src/errors/idempotency-error.spec-conformance.test.ts` | | IDMP-02 — Zod schemas for all public config types | `src/schemas/idempotency.schemas.spec-conformance.test.ts` | | IDMP-03 — Injectable clock and RNG | `src/guard/idempotency-guard.test.ts` AND `src/distributed/distributed-guard.test.ts` AND `src/metrics/idempotency-metrics.test.ts` AND `src/key/key-generator.test.ts` AND `src/guard/idempotency-guard.spec-conformance.test.ts` | | IDMP-04 — AbortSignal support throughout | `src/guard/idempotency-guard.test.ts` AND `src/distributed/distributed-guard.test.ts` AND `src/guard/idempotency-guard.spec-conformance.test.ts` | | IDMP-05 — OTel instrumentation via `@opentelemetry/api` | `src/metrics/idempotency-metrics.test.ts` AND `src/metrics/idempotency-metrics.spec-conformance.test.ts` | | IDMP-06 — Property-based tests with fast-check | `tests/property.test.ts` | | IDMP-07 — Benchmarks with mitata | `src/__benchmarks__/idempotency.bench.ts` AND `tests/benchmarks-present.spec-conformance.test.ts` | | IDMP-08 — Store adapter extensibility | `src/store/memory-store.test.ts` AND `src/store/database-store.test.ts` AND `src/store/redis-store.test.ts` AND `src/distributed/distributed-guard.test.ts` AND `tests/structural-adapters.spec-conformance.test.ts` | | IDMP-09 — Real services for integration tests; no mock stores in unit tests | `tests/no-disallowed.test.ts` AND `src/store/memory-store.test.ts` | | IDMP-10 — 100% test coverage | `vitest.config.ts` (Istanbul thresholds 100/100/100/100) plus the `bunx turbo test:coverage --filter=@suaveplan/idempotency` gate | ## Newly added tests in this change - `src/errors/idempotency-error.spec-conformance.test.ts` — pins error-hierarchy and namespace invariants. - `src/schemas/idempotency.schemas.spec-conformance.test.ts` — pins every required Zod schema export and a representative round-trip. - `src/guard/idempotency-guard.spec-conformance.test.ts` — pins clock-driven TTL semantics and AbortSignal mid-flight. - `src/metrics/idempotency-metrics.spec-conformance.test.ts` — pins OTel no-op behaviour and the five required instrument labels. - `tests/structural-adapters.spec-conformance.test.ts` — pins that plain-object store and lock-provider implementations are accepted. - `tests/benchmarks-present.spec-conformance.test.ts` — pins the canonical benchmark suite location and coverage of all four hot paths.