Files
gh-raw-labs-claude-code-mar…/skills/mxcp-expert/assets/schemas/drift-report-schema-1.json
2025-11-30 08:49:50 +08:00

145 lines
4.5 KiB
JSON

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "MXCP Drift Report",
"type": "object",
"required": ["version", "generated_at", "baseline_snapshot_path", "current_snapshot_generated_at", "baseline_snapshot_generated_at", "has_drift", "summary", "table_changes", "resource_changes"],
"properties": {
"version": {
"type": "integer",
"description": "Version of the drift report format. Must be 1.",
"enum": [1],
"default": 1
},
"generated_at": {
"type": "string",
"format": "date-time",
"description": "ISO 8601 timestamp when the report was generated"
},
"baseline_snapshot_path": {
"type": "string",
"description": "Path to the baseline snapshot file"
},
"current_snapshot_generated_at": {
"type": "string",
"format": "date-time",
"description": "Timestamp when the current snapshot was generated"
},
"baseline_snapshot_generated_at": {
"type": "string",
"format": "date-time",
"description": "Timestamp when the baseline snapshot was generated"
},
"has_drift": {
"type": "boolean",
"description": "Whether any drift was detected"
},
"summary": {
"type": "object",
"description": "Summary counts of changes by type",
"properties": {
"tables_added": { "type": "integer" },
"tables_removed": { "type": "integer" },
"tables_modified": { "type": "integer" },
"resources_added": { "type": "integer" },
"resources_removed": { "type": "integer" },
"resources_modified": { "type": "integer" }
},
"additionalProperties": false
},
"table_changes": {
"type": "array",
"description": "List of table changes detected",
"items": {
"type": "object",
"required": ["name", "change_type"],
"properties": {
"name": {
"type": "string",
"description": "Name of the table"
},
"change_type": {
"type": "string",
"enum": ["added", "removed", "modified"],
"description": "Type of change"
},
"columns_added": {
"type": "array",
"description": "Columns that were added",
"items": {
"type": "object",
"required": ["name", "type"],
"properties": {
"name": { "type": "string" },
"type": { "type": "string" }
}
}
},
"columns_removed": {
"type": "array",
"description": "Columns that were removed",
"items": {
"type": "object",
"required": ["name", "type"],
"properties": {
"name": { "type": "string" },
"type": { "type": "string" }
}
}
},
"columns_modified": {
"type": "array",
"description": "Columns that were modified",
"items": {
"type": "object",
"properties": {
"name": { "type": "string" },
"old_type": { "type": "string" },
"new_type": { "type": "string" }
}
}
}
}
}
},
"resource_changes": {
"type": "array",
"description": "List of resource changes detected",
"items": {
"type": "object",
"required": ["path", "change_type"],
"properties": {
"path": {
"type": "string",
"description": "Path to the resource file"
},
"endpoint": {
"type": "string",
"description": "Endpoint identifier (e.g., 'tool/name')"
},
"change_type": {
"type": "string",
"enum": ["added", "removed", "modified"],
"description": "Type of change"
},
"validation_changed": {
"type": "boolean",
"description": "Whether validation results changed"
},
"test_results_changed": {
"type": "boolean",
"description": "Whether test results changed"
},
"definition_changed": {
"type": "boolean",
"description": "Whether endpoint definition changed"
},
"details": {
"type": "object",
"description": "Specific details about what changed",
"additionalProperties": true
}
}
}
}
}
}