WebMCP Flight Booking Simulator
Registers callable tools on document.modelContext for browser extensions, Chrome Prompt API, or Gemini.
document.modelContext active
← Back to article
Skyline Flights
Target Web Application
Available flights
Declarative Form Tool
toolautosubmit
<form toolname="check_flight_status">
Ask the Browser Agent
Built-in Agent
How the agent connects: WebMCP (
document.modelContext) exposes tool schemas on the page. An agent (this bar, Chrome's Model Context Tool Inspector extension, or Chrome's LanguageModel Prompt API) reads getTools() and calls executeTool().
Where do AI API details come from in WebMCP?
WebMCP itself does not store LLM API keys on the website. The browser agent connects in one of 3 ways:
- 1. Built-in Simulator (Default): Parses natural language prompts locally without an API key.
- 2. Chrome WebMCP Inspector Extension: Reads
document.modelContextdirectly and uses the Gemini API key configured in the extension. - 3. Live Gemini API (Optional below): Paste a Gemini API key to call
gemini-2.5-flashdirectly withgetTools()schemas.
document.modelContext.getTools()
executeTool(search_flights, input)
ModelContext Events & Output