Files
dss/.dss/schema/tokens.schema.json
Digital Production Factory 93e1b452fb Phase 5: Add immutable file headers to all protected files
Added protection headers to 9 critical files:

JSON Files (x-immutable-notice field):
- .dss/schema/api.schema.json
- .dss/schema/tokens.schema.json
- .dss/schema/components.schema.json
- .dss/schema/workflows.schema.json
- .dss/schema/guardrails.schema.json
- dss-claude-plugin/.mcp.json

YAML File (comment header):
- .dss-boundaries.yaml

Markdown File (HTML comment):
- API_SPECIFICATION_IMMUTABLE.md

Python File (docstring header):
- dss-mvp1/dss/validators/schema.py

Each header includes:
- Protection notice
- Reason for immutability
- Last modified date
- Bypass instructions (DSS_IMMUTABLE_BYPASS=1)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-09 19:34:32 -03:00

91 lines
2.5 KiB
JSON

{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://dss.overbits.luz.uy/schemas/tokens.schema.json",
"title": "Design Tokens Schema",
"description": "Schema for design tokens in DSS format",
"version": "2.0.0",
"x-immutable-notice": {
"protected": true,
"reason": "Design token format specification - ensures consistency across projects",
"lastModified": "2025-12-09",
"bypassMethod": "Use 'DSS_IMMUTABLE_BYPASS=1 git commit' or commit message '[IMMUTABLE-UPDATE] reason'"
},
"type": "object",
"properties": {
"tokens": {
"type": "object",
"description": "Design token collection",
"additionalProperties": {
"oneOf": [
{"$ref": "#/definitions/tokenValue"},
{"$ref": "#/definitions/tokenGroup"}
]
}
},
"metadata": {
"type": "object",
"properties": {
"source": {
"type": "string",
"enum": ["figma", "css", "scss", "tailwind", "json", "manual"],
"description": "Token source type"
},
"version": {
"type": "string",
"description": "Token collection version"
},
"lastUpdated": {
"type": "string",
"format": "date-time"
},
"projectId": {
"type": "string",
"description": "Associated project identifier"
}
}
}
},
"definitions": {
"tokenValue": {
"type": "object",
"required": ["value", "type"],
"properties": {
"value": {
"description": "Token value (color, size, etc.)"
},
"type": {
"type": "string",
"enum": ["color", "dimension", "fontFamily", "fontWeight", "duration", "cubicBezier", "number", "string"],
"description": "Token type"
},
"description": {
"type": "string",
"description": "Human-readable description"
},
"alias": {
"type": "string",
"description": "Reference to another token"
},
"source": {
"type": "object",
"properties": {
"file": {"type": "string"},
"line": {"type": "integer"},
"figmaId": {"type": "string"}
}
}
}
},
"tokenGroup": {
"type": "object",
"description": "Nested token group",
"additionalProperties": {
"oneOf": [
{"$ref": "#/definitions/tokenValue"},
{"$ref": "#/definitions/tokenGroup"}
]
}
}
}
}