CourseModel Context Protocol: The Complete Course · Module 4: Resources, Prompts, and User Interaction · part 29 of 77
Part 29 · Module 4: Resources, Prompts, and User Interaction

Lesson 2: Live updates, prompts and slash commands

22 min read·
Module 4 · Lesson 2 · About 45 minutes · Needs: Lesson 1 of this module (resources); Module 1 Lessons 2 and 3

The situation

It is Thursday 17 September 2026, week 2. Lesson 1 gave the notes server two resources, notes://index and notes://{note_id}. Nare keeps the index open in a sidebar. On Tuesday she saved her consent form note, and the sidebar showed the old list until she reloaded it. She also types the same request every week: "summarise what my notes say about sleep, and cite the notes".

She wants two things. The sidebar should update by itself, and the weekly request should be one command: /summarise_topic sleep. This lesson adds both: subscriptions that tell a client what changed, and a prompt that the user starts as a slash command.

TWO REQUESTS FROM NARE notes server a note changed change event Nare's sidebar refetches the index Nare types /summarise_topic sleep prompt notes attached model cited summary
This lesson answers two requests: the sidebar hears about changes instead of going stale, and Nare's weekly request becomes one slash command whose answer comes from a model (amber).

The rest of this course is yours to keep

This course is bought on its own, once, and stays readable afterwards, including the parts added to it later.

Or open everything with a plan