Schema Versioning
How XcodeBuildMCP versions, publishes, and maintains structured output JSON Schemas served from xcodebuildmcp.com.
XcodeBuildMCP publishes structured output schemas at stable website URLs. External consumers can validate CLI JSON output and MCP structuredContent against those schemas, so schema changes need the same care as any public contract.
Goals
- Keep schema contracts stable and predictable for external consumers.
- Make published schema URLs real, durable, and safe to reference.
- Serve schemas directly from
https://xcodebuildmcp.com/schemas/.... - Avoid ambiguous compatibility rules.
Canonical schema identity
Each structured payload has two stable identifiers:
{
"schema": "xcodebuildmcp.output.build-result",
"schemaVersion": "1"
}The matching published schema URL is:
https://xcodebuildmcp.com/schemas/structured-output/xcodebuildmcp.output.build-result/1.schema.jsonThe in-payload schema and schemaVersion values must always match the published schema document that validates that payload.
Version format
schemaVersion uses integer strings only:
"1""2""3"
Do not use semver-style schema versions such as "1.1" or "2.0". The version number is a contract version, not a release number.
Versioning rules
Published versions are immutable
Once a schema version is published, do not make breaking changes to that file.
Breaking changes include:
- Removing a property.
- Making an optional property required.
- Narrowing allowed values or enums.
- Changing object shape incompatibly.
- Changing field meaning in a way that could break clients.
If any of those changes are needed, publish a new version instead:
schemas/structured-output/xcodebuildmcp.output.build-result/2.schema.jsonThen emit:
"schemaVersion": "2"Old versions remain available
Previously published schema files must continue to be hosted. Do not remove old schema versions from the website once consumers may rely on them.
Additive changes
Additive optional fields can be compatible, but use caution. If a new field is truly optional and old clients can safely ignore it, it may remain within the same schema version. If there is any doubt about compatibility or meaning, bump the schema version.
Bias toward a new version when the contract meaning changes.
Directory layout
Source schemas in the main repository live under:
schemas/structured-output/Published schemas on the website live under:
public/schemas/structured-output/A source file such as:
schemas/structured-output/xcodebuildmcp.output.build-result/1.schema.jsonis published to:
public/schemas/structured-output/xcodebuildmcp.output.build-result/1.schema.jsonThe website then serves it at:
https://xcodebuildmcp.com/schemas/structured-output/xcodebuildmcp.output.build-result/1.schema.jsonPublishing workflow
Schema publishing is handled from the main repository by a GitHub Actions workflow.
Trigger conditions:
- Push to
mainwhen files underschemas/**change. - Manual
workflow_dispatch.
Publishing steps:
- Check out
getsentry/XcodeBuildMCP. - Clone
getsentry/xcodebuildmcp.comover SSH. - Sync
schemas/structured-output/intopublic/schemas/structured-output/in the website repository. - Commit the website change if the published files changed.
- Push to the website repository
mainbranch. - Let Vercel deploy the website normally.
This keeps schema authoring in the main project repository while using the website repository as the deployment surface.
Required secret
The publishing workflow requires this repository secret:
XCODEBUILDMCP_WEBSITE_DEPLOY_KEYThis secret must contain an SSH private key with write access to:
git@github.com:getsentry/xcodebuildmcp.com.gitThe corresponding public key should be installed as a deploy key on the website repository with write access.
Deploy key setup
-
Generate a dedicated SSH key pair for schema publishing.
shellssh-keygen -t ed25519 -C "schema-publisher" -f ./xcodebuildmcp-website-deploy-key -
In
getsentry/xcodebuildmcp.com, add the public key as a deploy key with write access. -
In
getsentry/XcodeBuildMCP, add the private key as an actions secret namedXCODEBUILDMCP_WEBSITE_DEPLOY_KEY. -
Trigger the
Publish Schemasworkflow manually once to verify SSH access and sync. -
Confirm that the website repository receives the commit and Vercel deploys it.
-
Confirm a final URL resolves, for example:
texthttps://xcodebuildmcp.com/schemas/structured-output/xcodebuildmcp.output.build-result/1.schema.json
Use a dedicated deploy key for this workflow only. Do not reuse a personal SSH key.
Consumer guidance
Consumers should branch on both schema and schemaVersion:
switch (`${payload.schema}@${payload.schemaVersion}`) {
case "xcodebuildmcp.output.build-result@1":
// validate using v1 schema
break
case "xcodebuildmcp.output.build-result@2":
// validate using v2 schema
break
default:
throw new Error("Unsupported schema version")
}These JSON Schemas describe payload shapes. They are not an OpenAPI description by themselves. If an HTTP API is introduced later, OpenAPI should reference the schema files as component schemas instead of trying to infer endpoints from them.
Maintenance checklist
When updating schemas:
- Decide whether the change is compatible or breaking.
- If breaking, add a new versioned schema file instead of changing the old one.
- Update fixture payloads to emit the correct
schemaVersion. - Run
npm run test:schema-fixtures. - Merge to
main. - Confirm the publish workflow updated the website repo.
- Confirm the final schema URL resolves on the website.
Related
- Tool Authoring, where schemas fit into a tool change
- Output Formats, how structured output appears in MCP and CLI responses
- Testing, schema fixture validation