Skip to content

spec: publication-layer cleanup — semantic_base model, audit path, reset auth - #41

Merged
amavashev merged 2 commits into
mainfrom
spec/publication-cleanup-v0.1.26.1
Apr 13, 2026
Merged

amavashev merged 2 commits into
mainfrom
spec/publication-cleanup-v0.1.26.1

Conversation

@amavashev

Copy link
Copy Markdown
Contributor

Summary

Publication and consistency cleanup across the Cycles spec family. Addresses two passes of external review (publication layer drift, malformed YAML, version-model ambiguity, stale merge-recipe references, audit-path typo, reset-endpoint auth noise). Reviewer's final verdict: implementation-ready.

No wire-contract changes. One documentation tightening on reset.tenant_id matches behavior already mandated by the AdminKeyAuth-only security: block.

Changes by file

cycles-spec-index.yaml

  • Fix two YAML scanner errors in wrapped list items (action-kinds reset bullet; admin_merged enforcement bullet — both contained colons in the wrap, breaking parsing).
  • Introduce version (editorial revision) vs semantic_base (frozen wire identity) versioning model with a top-of-file convention block.
  • governance_base: version: 0.1.25.14 (matches info.version), semantic_base: 0.1.25.9 added.
  • action_kinds path count: 3 → 4 (counter reset endpoint was missing).

cycles-governance-admin-v0.1.25.yaml

  • Replace stale cycles-openapi-full-merged.yaml / full_merged recipe references with merged/cycles-openapi-admin-merged.yaml / admin_merged.
  • Audit-path typo in v0.1.25.14 changelog: /v1/admin/audit-log → /v1/admin/audit/logs (the declared path was already correct).
  • AdminKeyAuth security scheme description: stop enumerating allowlisted paths in prose (had drifted as dual-auth surface expanded); point readers at per-operation security: blocks as the source of truth.
  • Summary/description rewrite: "document revision 0.1.25.14; semantic base frozen at 0.1.25.9".

cycles-action-kinds-v0.1.26.yaml

  • POST /v1/admin/action-quota-counters/reset: remove ApiKeyAuth / reserved action_quotas:write permission branch from description (operation security: block was already AdminKeyAuth-only and no such permission exists in v0.1.26). State plainly: AdminKeyAuth-only in v0.1.26, with v0.1.27 future note.
  • ActionQuotaCounterResetRequest.tenant_id: tighten description from "Ignored when using ApiKeyAuth" to "REQUIRED" with explicit 400 INVALID_REQUEST + missing_required_field: tenant_id behavior. Documentation tightening only.
  • Top-level description: "Three endpoints" → "Four endpoints" (registry list, registry get, counter list, counter reset).
  • Add v0.1.26 changelog "DOCUMENTATION TIGHTENING (no wire change)" entry covering both reset prose fixes.

cycles-governance-extensions-v0.1.26.yaml

  • Update base-spec references from (v0.1.25.9) to (semantic_base 0.1.25.9) in summary, EXTENSION CONTRACT, and BASE SPEC blocks to match the new versioning model.

Implementation impact

Edit Server/admin re-verification needed?
YAML parser fixes, paths_added count, semantic_base field, recipe redirect, audit-path changelog typo, AdminKeyAuth description, version-label wording, "Three → Four endpoints" No — publication layer or description prose only
Reset endpoint ApiKeyAuth branch removal No — operation security: block was already AdminKeyAuth-only
Reset endpoint tenant_id documentation tightening Yes — verify server returns 400 INVALID_REQUEST with missing_required_field: tenant_id rather than a generic 400 or auth error

Test plan

  • All 6 spec YAML files parse cleanly with yaml.safe_load (utf-8)
  • No remaining cycles-openapi-full-merged references
  • No remaining /v1/admin/audit-log references (without /logs)
  • External reviewer pass confirms major issues fixed and family is implementation-ready
  • Server repo: confirm reset endpoint returns the now-mandated 400 shape on missing tenant_id
  • Admin tooling repo: confirm no client today omits tenant_id on reset relying on the old "Ignored when using ApiKeyAuth" prose

Follow-ups (not in this PR)

  • CI gate that parses cycles-spec-index.yaml, resolves every recipe to an existing output path, and asserts paths_added counts match the merged artifacts. Would prevent recurrence of items 1, 2, and 6 from the original review pass permanently. Will open as a separate PR per planning agreement.

…set auth

Publication and consistency fixes across the spec family. No wire-contract
changes (one documentation tightening on reset.tenant_id matches behavior
already mandated by the AdminKeyAuth-only security block).

Index (cycles-spec-index.yaml):
- Fix two YAML scanner errors in wrapped list items that broke parsing
  (action-kinds reset bullet; admin_merged enforcement bullet — both
  contained colons in the wrap).
- Introduce explicit versioning model: `version` (editorial revision) vs
  `semantic_base` (frozen wire identity). Document the convention at the
  top of the file.
- governance_base: version 0.1.25.9 -> 0.1.25.14 (matches info.version),
  semantic_base: 0.1.25.9 added.
- action_kinds path count: 3 -> 4 (counter reset endpoint was missing).

Governance base (cycles-governance-admin-v0.1.25.yaml):
- Replace stale `cycles-openapi-full-merged.yaml` / `full_merged` recipe
  references with `merged/cycles-openapi-admin-merged.yaml` / `admin_merged`.
- Rewrite v0.1.25.14 changelog audit-path typo: /v1/admin/audit-log ->
  /v1/admin/audit/logs (declared path was already correct; only the
  changelog prose was wrong).
- AdminKeyAuth security scheme description: stop enumerating allowlisted
  paths in prose (had drifted as dual-auth surface expanded); point
  readers at per-operation `security:` blocks as the source of truth.
- Reword summary/description to use "document revision 0.1.25.14;
  semantic base frozen at 0.1.25.9".

Action-kinds (cycles-action-kinds-v0.1.26.yaml):
- POST /v1/admin/action-quota-counters/reset: remove ApiKeyAuth /
  reserved-permission branch from description (operation security block
  was already AdminKeyAuth-only, and no `action_quotas:write` permission
  exists in v0.1.26). State plainly that it is AdminKeyAuth-only in
  v0.1.26 with a v0.1.27 future note.
- ActionQuotaCounterResetRequest.tenant_id: tighten description from
  "Ignored when using ApiKeyAuth" to "REQUIRED" with explicit
  400 INVALID_REQUEST + missing_required_field:tenant_id behavior.
  Documentation tightening only — the AdminKeyAuth-only security block
  already mandated this.
- Top-level description: "Three endpoints" -> "Four endpoints"
  (registry list, registry get, counter list, counter reset).
- Add v0.1.26 changelog "DOCUMENTATION TIGHTENING (no wire change)"
  entry covering both reset prose fixes.

Governance extension (cycles-governance-extensions-v0.1.26.yaml):
- Update base-spec references from `(v0.1.25.9)` to
  `(semantic_base 0.1.25.9)` in summary, EXTENSION CONTRACT, and
  BASE SPEC blocks to match the new versioning model.

Validation:
- All 6 spec YAML files parse cleanly with yaml.safe_load (utf-8).
- No remaining occurrences of `cycles-openapi-full-merged` or stale
  `/v1/admin/audit-log` (without `/logs`).

Implementation impact:
- Server/admin compliance check warranted on one item only:
  reset endpoint must return 400 INVALID_REQUEST with
  missing_required_field:tenant_id when tenant_id is omitted, rather
  than a generic 400 or auth error. All other edits are publication
  layer or description prose with zero wire-contract change.
CI drift check (merge-check) failed on the prior commit because the
prose edits to source specs were not accompanied by regenerated
merged/ artifacts. Regenerated via `python scripts/merge_specs.py`.

No source changes in this commit — only the mechanical merge output
for `merged/cycles-openapi-admin-merged.yaml` and
`merged/cycles-openapi-protocol-merged.yaml`.
@amavashev
amavashev merged commit 8d84251 into main Apr 13, 2026
1 check passed
amavashev added a commit that referenced this pull request Apr 14, 2026
README header listed 'Governance base: v0.1.25.8'. After PR #40
(Stage 3 webhooks dual-auth) the governance-admin spec is at
editorial revision v0.1.25.14. The semantic_base is frozen at
0.1.25.9 per the PR #41 versioning model.

Updated to 'v0.1.25.14 (semantic_base 0.1.25.9)' — surfaces both
values so readers see the latest feature revision AND understand
wire-compatibility is tied to the 0.1.25.9 baseline.
@amavashev
amavashev deleted the spec/publication-cleanup-v0.1.26.1 branch June 18, 2026 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant