ALL

Solo para leer y verificar. No puedes copiar, usar, modificar ni redistribuir este código. Aviso completo en la página principal.

contracts/schemas/statement-claims.schema.json

SHA-256: 51aebdb33bfd73c7cacd5e5d417dfc9b60c4150067e280b63763c5fb450d3dc6
32 líneas · 2070 bytes · Ver en GitHub

1{
2 "$schema": "https://json-schema.org/draft/2020-12/schema",
3 "$id": "https://all-mcp.fyi/contracts/v2/statement-claims.schema.json",
4 "title": "Claims of the control plane's signed access statement (typ device-access, aud all-device-access), as pushed by the node in STATEMENT and as returned next to authorize. Same keys and typ as 1.1 (ver stays 1: a 1.1 device ignores the added claims); seq is what makes an old statement unable to lift a pause or a paywall. Lifetime: mode active up to policy.authorization.access_ttl_paid_s (a verifier cannot tell a trial from a paid statement; the control plane issues access_ttl_trial_s for a trial and never past its end), mode paywall up to access_ttl_paywall_s. paused and resumed are never both present. paused.since and resumed.at are the license page's click moments in milliseconds (the 1.1 authorize shape). Unknown extra claims are ignored (a token is not a closed shape), the listed ones are not optional unless the schema says so.",
5 "type": "object",
6 "required": ["typ", "ver", "iss", "aud", "sub", "iat", "exp", "jti", "mode", "seq"],
7 "properties": {
8 "typ": {"const": "device-access"},
9 "ver": {"const": 1},
10 "iss": {"const": "https://api.all-mcp.fyi"},
11 "aud": {"const": "all-device-access"},
12 "sub": {"$ref": "common.schema.json#/$defs/device_id"},
13 "iat": {"$ref": "common.schema.json#/$defs/epoch_s"},
14 "exp": {"$ref": "common.schema.json#/$defs/epoch_s"},
15 "jti": {"$ref": "common.schema.json#/$defs/jti"},
16 "mode": {"type": "string", "enum": ["active", "paywall"]},
17 "seq": {"type": "integer", "minimum": 1, "maximum": 9007199254740991},
18 "paywall": {"$ref": "paywall.schema.json"},
19 "paused": {
20 "type": "object",
21 "required": ["since"],
22 "additionalProperties": false,
23 "properties": {"since": {"$ref": "common.schema.json#/$defs/epoch_ms"}}
24 },
25 "resumed": {
26 "type": "object",
27 "required": ["at"],
28 "additionalProperties": false,
29 "properties": {"at": {"$ref": "common.schema.json#/$defs/epoch_ms"}}
30 }
31 }
32}