The C# reference publishes authorityRoutes with certificate: null for loopback routes, and its own verifier treats null as "no certificate" in local development. The TypeScript JSON schema only allowed the object, so the browser client rejected every catalog the getting-started provider served: "certificate: must be object", Odin could not resolve the Verse, and the real browser/C# checkpoint has failed sincef622ee1(2026-08-18), behind the sample failure that hid it. TypeScript consumers already guard route.certificate; the schema now accepts null. The package-closure smoke also still spelled the browser identity with providerId; it is authorityRuntimeId sincec194bd4. npm test --workspace packages/cultnet-ts -> 54 pass npm run test:pack:ts -> passed Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
72 lines
3.6 KiB
JSON
72 lines
3.6 KiB
JSON
{
|
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
"$id": "https://github.com/GameCult/cultnet-ts/contracts/cultmesh.verse-catalog-response.schema.json",
|
|
"title": "CultMesh Verse Catalog Response",
|
|
"type": "object",
|
|
"required": ["schemaVersion", "messageId", "verses"],
|
|
"additionalProperties": false,
|
|
"$defs": {
|
|
"compatibility": {
|
|
"type": "object",
|
|
"required": ["transportVersion", "rulesHash", "compatibleVerseIds", "requiredPluginIds", "optionalPluginIds"],
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"transportVersion": { "type": "string", "minLength": 1 },
|
|
"rulesHash": { "type": "string", "minLength": 1 },
|
|
"compatibleVerseIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
|
|
"requiredPluginIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
|
|
"optionalPluginIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }
|
|
}
|
|
},
|
|
"authorityRoute": {
|
|
"type": "object",
|
|
"required": ["authorityRuntimeId", "endpoint", "protocolIds", "priority", "generation"],
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"authorityRuntimeId": { "type": "string", "minLength": 1 },
|
|
"endpoint": { "type": "string", "minLength": 1 },
|
|
"protocolIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
|
|
"priority": { "type": "integer", "minimum": 0 },
|
|
"generation": { "type": "string", "minLength": 1 },
|
|
"certificate": {
|
|
"anyOf": [{ "$ref": "#/$defs/routeCertificate" }, { "type": "null" }]
|
|
}
|
|
}
|
|
},
|
|
"routeCertificate": {
|
|
"type": "object",
|
|
"required": ["providerKeyId", "providerPublicKeyX", "providerPublicKeyY", "odinKeyId", "issuedAtUnixMilliseconds", "expiresAtUnixMilliseconds", "signature"],
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"providerKeyId": { "type": "string", "minLength": 1 },
|
|
"providerPublicKeyX": { "type": "string", "minLength": 1 },
|
|
"providerPublicKeyY": { "type": "string", "minLength": 1 },
|
|
"odinKeyId": { "type": "string", "minLength": 1 },
|
|
"issuedAtUnixMilliseconds": { "type": "integer", "minimum": 0 },
|
|
"expiresAtUnixMilliseconds": { "type": "integer", "minimum": 1 },
|
|
"signature": { "type": "string", "minLength": 1 }
|
|
}
|
|
},
|
|
"verse": {
|
|
"type": "object",
|
|
"required": ["verseId", "displayName", "authorityModel", "compatibility", "discoveryEndpoints", "authorityRuntimeIds"],
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"verseId": { "type": "string", "minLength": 1 },
|
|
"displayName": { "type": "string", "minLength": 1 },
|
|
"authorityModel": { "type": "string", "minLength": 1 },
|
|
"compatibility": { "$ref": "#/$defs/compatibility" },
|
|
"discoveryEndpoints": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
|
|
"authorityRuntimeIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
|
|
"authorityRoutes": { "type": "array", "items": { "$ref": "#/$defs/authorityRoute" } },
|
|
"parentVerseId": { "type": "string", "minLength": 1 },
|
|
"description": { "type": "string" }
|
|
}
|
|
}
|
|
},
|
|
"properties": {
|
|
"schemaVersion": { "const": "cultmesh.verse_catalog_response.v0" },
|
|
"messageId": { "type": "string", "minLength": 1 },
|
|
"verses": { "type": "array", "items": { "$ref": "#/$defs/verse" } }
|
|
}
|
|
}
|