From the course: Unboxing AI: Build a Remote MCP Server from Zero to Deployed with OAuth
Unlock this course with a free trial
Join today to access over 24,900 courses taught by industry experts.
Testing a new MCP elicitation - OAuth Tutorial
From the course: Unboxing AI: Build a Remote MCP Server from Zero to Deployed with OAuth
Testing a new MCP elicitation
- Okay, so what does that look like? I'll create a new chat, and say, "Start the calculator." It spins up the MCP server, and then it says, "Let's do some math. Please provide the numbers and operation you would like to perform." Remember, that's the message up here, "Let's do some math. Please provide the numbers." So in ctx.elicit, the message is what shows up in the client as the message to the user. Click Respond. It now says First Number, and one of three because in this case, we have three inputs. We have first, second, and operation. So we'll say the first number is 98, the second number is three, and the operation, I'll say asterisk here to say multiply. That information is passed back in, Python does its thing, and out I get a response. 98 x 3 is 294, which I'm going to assume is correct. This is how it works. And what you see is it's really straightforward. You set up a tool, you then call in context, you then set up context, elicit, then declare a message, define what types…
Contents
-
-
-
-
- (Locked) Elicitation and sampling: The bleeding edge of MCP1m 35s
- (Locked) Understanding MCP elicitation3m 15s
- (Locked) Why and when elicitation is useful2m 26s
- (Locked) Demo: MCP elicitation in VS Code3m 58s
- (Locked) Why elecitiation matters1m 18s
- (Locked) MCP elicitation in code3m 38s
- (Locked) Testing a new MCP elicitation4m 15s
- (Locked) MCP sampling: The server uses AI tools4m 53s
- (Locked) Demo: MCP sampling in VS Code3m 5s
- (Locked) Innovating with elicitation and sampling1m 37s
- (Locked)
-
-
-