For reading and verification only. You may not copy, use, modify or redistribute this code. Full notice on the main page.
contracts/schemas/paywall.schema.json
| 1 | { |
| 2 | "$schema": "https://json-schema.org/draft/2020-12/schema", |
| 3 | "$id": "https://all-mcp.fyi/contracts/v2/paywall.schema.json", |
| 4 | "title": "The plans card inside a paywall statement: the shape the paywall module parse_paywall accepts (the device keeps its own field-by-field parser, which is stricter: distinct plan ids, byte limits, control characters).", |
| 5 | "type": "object", |
| 6 | "required": ["version", "status", "plan", "trial_ended_at", "upgrade_url", "plans", "note_es", "note_en", "text_es", "text_en"], |
| 7 | "additionalProperties": false, |
| 8 | "properties": { |
| 9 | "version": {"const": 1}, |
| 10 | "status": {"const": "trial_ended"}, |
| 11 | "plan": {"const": "trial"}, |
| 12 | "trial_ended_at": {"$ref": "common.schema.json#/$defs/epoch_ms"}, |
| 13 | "locale": {"type": "string", "enum": ["es", "en"]}, |
| 14 | "upgrade_url": {"type": "string", "pattern": "^https://all-mcp\\.fyi/upgrade/(?:\\?lang=(?:es|en))?#[A-Za-z0-9._&=-]{8,400}$"}, |
| 15 | "plans": { |
| 16 | "type": "array", "minItems": 3, "maxItems": 3, |
| 17 | "items": { |
| 18 | "type": "object", |
| 19 | "required": ["id", "label", "amount", "cadence", "updates", "computers"], |
| 20 | "additionalProperties": false, |
| 21 | "properties": { |
| 22 | "id": {"type": "string", "enum": ["monthly", "no_updates", "with_updates"]}, |
| 23 | "label": {"type": "string", "minLength": 1, "maxLength": 64}, |
| 24 | "amount": {"type": "string", "pattern": "^\\$[0-9]+\\.[0-9][0-9]$"}, |
| 25 | "cadence": {"type": "string", "enum": ["monthly", "one_time"]}, |
| 26 | "updates": {"type": "boolean"}, |
| 27 | "computers": {"type": "integer", "minimum": 1, "maximum": 25} |
| 28 | } |
| 29 | } |
| 30 | }, |
| 31 | "reactivation": {"type": "string", "minLength": 1, "maxLength": 200}, |
| 32 | "is_error": {"type": "boolean"}, |
| 33 | "note_es": {"type": "string", "minLength": 1, "maxLength": 2048}, |
| 34 | "note_en": {"type": "string", "minLength": 1, "maxLength": 2048}, |
| 35 | "text_es": {"type": "string", "minLength": 1, "maxLength": 2048}, |
| 36 | "text_en": {"type": "string", "minLength": 1, "maxLength": 2048} |
| 37 | } |
| 38 | } |