Skip to content

Export remaining Context response contracts and verified examples - #1075

Merged
sidneyswift merged 3 commits into
mainfrom
codex/context-action-contracts
Oct 21, 2026
Merged

sidneyswift merged 3 commits into
mainfrom
codex/context-action-contracts

Conversation

@sidneyswift

@sidneyswift sidneyswift commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Most Context actions had a generated input schema but only a broad object/prose success response. Export a named response reference and actual 200/202 status for all 30 supported actions, retaining the completed evidence and catalog-planning contracts. Add source-derived input/output examples for the other 26 actions, including ingestion, planning/execution, identity review, release cases and briefs.

This changes contract definitions, producer output, tests and generated fixtures only. Runtime handlers, validation, flags, database calls, grants and collection/spending paths are unchanged. Flexible persisted JSON remains flexible. Request contracts exclude the withheld claim token, evidence URLs can be null as the SQL permits, unavailable snapshots withhold payloads, and verification responses acknowledge queued work rather than completion. Existing public aliases/raw plan IDs are untouched.

Validation: 585 tests passed across 94 files; 8 explicit local/live tests skipped. New examples call actual HTTP/MCP processors with synthetic auth/storage and mocked dispatch, validate their own response models/statuses and compare every frozen published example. Native fetch is fenced off. Missing required fields, withheld-payload/capability errors, authentication denial, disabled verification and historical scalar/array JSON are covered. A wrong read_execution response mapping failed at that action's test and was restored. Full lint and the actual Marketing companion producer's --check pass. Direct whole-project TypeScript has the same 211 errors as the accepted baseline in the reused local dependencies, with no new errors; clean CI remains required.

Source definitions come from API return paths/validators/types and the existing database projections (source pin 5f21d18a668a28b6906ea5aa0821dba8d8ad9906), not an assumption that migrations are applied. Independent review caught an overly narrow nullable URL declaration; it is corrected and exercised by a null-URL example. Final exact-head review is pending. No application/customer/provider/database call, paid job, production flag change or hosted acceptance is claimed.

Tracks only the remaining original Mono #329 response/example criteria. Docs owns the Marketing/retained Docs companions and source pins. Both API fixture copies are included here. Coordinator retains final guarded merge and release ordering; #361/client/provider authority and CLI publication remain separate.


Summary by cubic

Exports named success response models and actual HTTP status codes for all 30 Context actions, with source-verified example inputs and outputs for the 26 actions that previously had no concrete response contract.

  • Adds response schemas and status codes per action in lib/context/contracts/ and wires them into the published catalog fixture.
  • Adds tests that run each example through the real HTTP and MCP processors with synthetic auth/storage and mocked dispatch, validating status, schema, and the frozen fixture.
  • Runtime handlers, validation, flags, database calls, grants, and collection/spending paths are unchanged; persisted JSON stays flexible, request records exclude claim_token, unavailable snapshots return null payloads, and verification responses acknowledge queued work only.
  • Constrains public plan modules and brief documents to reachable source outputs, and covers regression checks for missing fields, withheld-payload errors, auth denial, disabled verification flags, and historical flexible JSON.

Written for commit f23c411. Summary will update on new commits.

View guided diff

@vercel

vercel Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
api Ready Ready Preview Oct 21, 2026 3:09pm UTC

Request Review

@coderabbitai

coderabbitai Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Repository: recoupable/api/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a37c29fd-9d53-42a0-b5a0-376b5bbc2384
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

This branch was successfully deployed

1 active deployment
Preview — e3d9a920 Deployed Oct 21, 2026 by vercel[bot]
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