Skip to content
{mcpdesc}

Use a concrete URI that expands the template

A Resource Template example records the concrete requested URI, which must be an RFC 6570 expansion of the containing template. Check the template and URI together, including examples reached through components. Matching a URI does not require network retrieval.

A Resource Template example uri is a valid RFC 6570 expansion of the template.

Rule ID: mcpdesc.resource-template.example.expansion
Owner: mcpdesc
Surface: Resource Template example · Path: uri
Kind: mcpdesc-semantic
Requirement level: must
Protocol versions: independent of the MCP protocol version
Status: internal · Enforcement: internal

Source: expected-valid/named-resource-examples.json · Selected: /resourceTemplates/0

{
"protocolVersions": [
"2026-07-28"
],
"uriTemplate": "chess://games/{game_id}",
"name": "game_detail",
"mimeType": "application/json",
"examples": {
"sample-game": {
"uri": "chess://games/example-1234",
"result": {
"resultType": "complete",
"ttlMs": 300000,
"cacheScope": "public",
"contents": [
{
"uri": "chess://games/example-1234",
"mimeType": "application/json",
"text": "{\"id\":\"example-1234\",\"result\":\"1-0\"}"
}
]
}
}
}
}

Source: expected-invalid/resource-example-result-semantics.json · Selected: /resourceTemplates/0/examples/not-an-expansion

{
"uri": "chess://players/example-1234",
"result": {
"contents": [
{
"uri": "chess://players/example-1234",
"text": "wrong route"
}
]
}
}

Source: expected-invalid/component-contextual-examples.json · Selected: /components/resourceTemplateExamples/bad-uri

{
"uri": "data://other/1",
"result": {
"resultType": "complete",
"ttlMs": 1,
"cacheScope": "private",
"contents": [
{
"uri": "data://other/1",
"text": "wrong"
}
]
}
}

resource.yaml at immutable tag v0.9.0-rc.3.