> ADVANCED MCP PRESENTATION
SLIDE 06/16

> RESOURCES: READ-ONLY CONTEXT [DYNAMIC DATA]

▶ URI-BASED STRUCTURED CONTENT

Provide structured content on demand - great for large data and real-time updates
{
  "uri": "test://static/resource/42",
  "name": "Static Test Resource",
  "description": "A test resource that updates every 5 seconds",
  "mimeType": "application/json"
}

▶ RESOURCE PATTERNS

📊 LARGE DATA SETS

File contents, search results, database queries

🔄 AUTO-UPDATING

Real-time data feeds, monitoring dashboards

🔗 SUBSCRIPTIONS

Push notifications when resources change

▶ AUTO-UPDATE ARCHITECTURE

┌────────────────────────────────────────────────────────────────┐
│              AUTO-UPDATING RESOURCE SYSTEM                    │
├────────────────────────────────────────────────────────────────┤
│                                                                │
│  ┌─────────────┐    5s Timer    ┌─────────────┐               │
│  │  RESOURCE   │◄──────────────►│   UPDATE    │               │
│  │ test://42   │                │  GENERATOR  │               │
│  └─────────────┘                └─────────────┘               │
│         │                               │                     │
│         ▼                               ▼                     │
│  ┌─────────────┐                ┌─────────────┐               │
│  │ SUBSCRIBERS │                │  NEW DATA   │               │
│  │   NOTIFIED  │◄───────────────┤  TIMESTAMP  │               │
│  └─────────────┘                └─────────────┘               │
│                                                                │
│  Inspector, Claude, and other clients get live updates        │
└────────────────────────────────────────────────────────────────┘

🎮 LIVE DEMO: AUTO-UPDATING RESOURCES

DEMONSTRATION: test://static/resource/42 in Everything Server - auto-updates every 5 seconds
$ mcp-inspector
> Navigate to Resources tab
> Subscribe to test://static/resource/42

[T+00s] {"id": 42, "timestamp": "2025-11-19T10:00:00Z", "value": 1}
[T+05s] {"id": 42, "timestamp": "2025-11-19T10:00:05Z", "value": 2}
[T+10s] {"id": 42, "timestamp": "2025-11-19T10:00:10Z", "value": 3}
[T+15s] {"id": 42, "timestamp": "2025-11-19T10:00:15Z", "value": 4}

[NOTIFICATION] Resource updated - new data available
[SUBSCRIPTION] Real-time updates flowing to all subscribers

Key Observations:

  • Automatic updates - no polling required
  • Subscription model - efficient resource management
  • Version tracking - timestamp-based change detection
  • Multiple consumers - Inspector + Claude both receive updates

▶ COMMON USE CASES

├── File System Contents    │ Directory listings, file metadata
├── Database Query Results  │ Live data feeds, cached queries
├── API Response Caching    │ External service data
├── Search Indexes         │ Document collections, embeddings
└── Monitoring Dashboards   │ System metrics, health checks