// readme

ucp-schema

CLI and library for Universal Commerce Protocol (UCP) schemas.

UCP defines an open extensibility protocol on top of JSON Schema. Agents negotiate capabilities at runtime via self-describing payloads, extensions compose dynamically via allOf, and ucp_request/ucp_response annotations control field visibility per direction and operation. This tool implements UCP’s composition and resolution pipeline: compose capability schemas, resolve annotations into standard JSON Schema, and validate payloads.

How It Works

The CLI exposes a progressive pipeline. Each command runs it up to its named step:

  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚      compose      β”‚ ──▢ β”‚      resolve      β”‚ ──▢ β”‚     validate      β”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
   merge capability          apply annotations           check payload
   schemas into one          for direction + op           against schema

Like gcc -E (preprocess only) vs gcc (full build), each command runs the pipeline to a different depth: compose stops after merging capability schemas, resolve applies…