typescript-sdk/examples/resources
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-07-06 21:03:15 +01:00
..
client.ts docs(servers): document resources/subscribe serving; exercise subscriptions in the resources example (#2413) 2026-07-02 14:18:25 +01:00
package.json Use protected HTTP wiring in examples and guides (#2445) 2026-07-06 21:03:15 +01:00
README.md docs(servers): document resources/subscribe serving; exercise subscriptions in the resources example (#2413) 2026-07-02 14:18:25 +01:00
server.ts Use protected HTTP wiring in examples and guides (#2445) 2026-07-06 21:03:15 +01:00

resources

Direct resources (a fixed URI string), templated resources (ResourceTemplate('greeting://{name}')), and per-resource subscriptions. The client lists both kinds, reads the direct config and a templated greeting, then subscribes to counter://value — subscriptions/listen on 2026-07-28, resources/subscribe on 2025 — calls the increment tool, and asserts the notifications/resources/updated it produces. Per-request legacy HTTP has no delivery channel, so that leg skips the delivery assertion.

pnpm tsx examples/resources/client.ts