All paths in the protocol should be absolute
-
Create the params and output structs in
agent-client-protocol-schema/src/{v1,v2}/{agent,client}.rsunder the corresponding section, with the fields the RFD or request defines. Follow the schema rules below for each field. -
If the protocol method name is
noun/verb, useverb_nounfor the user facing methods and structs.Example 1 (
noun/noun): Protocol method:terminal/outputTrait method name:terminal_outputRequest/Response structs:TerminalOutputRequest/TerminalOutputResponseMethod names struct:terminal_output: &'static strExample 2 (
noun/verb): Protocol method:terminal/newTrait method name:new_terminalRequest/Response structs:NewTerminalRequest/NewTerminalResponseMethod names struct:terminal_new: &'static str -
Add constants for the method names
-
Add variants to {Agent|Client}{Request|Response} enums
-
Add the method to the SideDocs functions in
schema-generator/src/main.rs -
Run
npm run generateand fix any issues that appear -
Run
npm run check -
Update the example agents and clients in tests and examples in both libraries
- For any nullable field, explicitly define whether it is required or optional and whether
nullis equivalent to an omitted key before running schema generation. - Use
DefaultOnError/VecSkipErroronly when the fallback means less (no metadata, an unsupported capability, a missing display item). If the receiver acts on the value (runs, reads, connects, or applies something), keep it strict so a request fails with-32602instead of silently doing something else; useDefaultOnNullon such lists sonullstill means empty. - A malformed value for a known discriminator must not fall through to an untagged fallback variant.
- Update the mintlify docs and guides in the
docsdirectory - Make the same change in both the stable page and its
draft/copy, unless the change is draft-only - Run
npm run checkto make sure the json and zod schemas gets generated properly
These apply to the docs/protocol pages and to Rust doc comments, which become the descriptions in the generated schema.
- Say what the protocol does: name the method, field, or behavior. Skip sentences that only describe benefits ("enables rich interactions", "provides a flexible way", "seamless integration").
- Don't tack on
-ingclauses ("…, allowing Clients to…", "…, providing visibility into…"). Write "Clients use it to…" or start a new sentence. - Name concrete methods and capabilities instead of abstract nouns. Write "Agents that advertise
capabilities.session" or "auth/loginandauth/logout", not "the session method surface" or "the authentication surface". - Use periods instead of semicolons or em dashes to join clauses. Use straight quotes.
- Prefer plain words: "use", not "leverage" or "utilize"; "to", not "in order to".
- Use sentence case for headings. Keep Agent, Client, and acronyms capitalized.
- v1 is stable: rewording must not add, remove, or change a requirement. Keep every MUST/SHOULD/MAY and its scope as it was, and don't state behavior the v1 spec doesn't already define. Draft v2 pages can change freely.
Never write readme files related to the conversation unless explicitly asked to.
This repository uses Conventional Commits for automated releases via release-plz. All commit messages should follow this format:
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
- feat: A new feature (triggers minor version bump)
- fix: A bug fix (triggers patch version bump)
- docs: Documentation only changes
- style: Code style changes (formatting, missing semicolons, etc.)
- refactor: Code changes that neither fix bugs nor add features
- perf: Performance improvements
- test: Adding or updating tests
- chore: Maintenance tasks, dependency updates, etc.
- ci: CI/CD configuration changes
- build: Build system or external dependency changes
feat(schema): add support for dynamic proxy chains
fix(unstable): resolve deadlock in message routing
docs(rfd): update README with installation instructions
chore: bump tokio to 1.40
Common scopes for this repository:
schema- Anything that touches the actual generated schemaunstable- Any changes that would only touch unstable featuresunstable-v2- Any changes that would only touch v2rust- Any changes that only touch Rust code and how Rust handles the data with no changes to the schemarfd- Any changes that only touch RFD documentation