Tagline

A clinic page that gives your own agent real tools and never lets it book for you.

Inspiration

Someone in our family needs time to talk. Not to think, to talk. The web punishes that more every year. Cancelled appointments go up at 8:00 and are gone by 8:01. Course seats, visa slots, concert tickets, same story. If you use a switch, a head pointer, or voice control, you lose that race every time, and nobody who built the race was thinking about you.

The odd thing is that this same person already has an assistant that understands them fine. It just cannot do anything on a clinic website except look at the buttons and guess.

So we built the page we wished existed. Not an app you install and not the clinic's chatbot. A normal public booking page that, when you turn up with your own agent, tells that agent exactly what it may do for you and draws a line it cannot cross.

What it does

Cedarfield is a made-up clinic that releases cancelled appointments in waves, a few at a time. You open the booking page inside whatever agent you use. We recorded ours with Codex. Through WebMCP the page hands your agent the board, finds times, holds a slot for three minutes, lets it go, waits for whatever you say to the page, and asks you one question with two or three choices.

You talk to the page however you can. Type. Speak. Press a phrase. Hold up a hand shape, and the camera reads it as a switch. If you cannot type your name, a scanning keyboard opens and you pick letters with a thumbs up, the way switch users have typed for decades. Your agent takes each request, searches, and holds a time, and when it needs a decision, it asks you on the page instead of in its own window. You answer with a button, a word, or a thumbs up.

This is the part we care about most. When the page loads, there is no booking tool. None. Your agent can hold a slot, and it can ask, but it cannot book. A booking tool only comes into existence when you do something an agent cannot do: press a button yourself, hold an open palm to the camera, or say a word that is shown on your screen and nowhere else. Then the tool lives for ten minutes, works once, and disappears. You can watch it appear as a gold chip on the page and watch it die when you take permission back. Cancelling and moving are never handed over at all.

If an agent tries to press the confirm button with a script, the press is refused and the count is shown on screen. Every call your agent makes is written on the page in plain English, and a small cursor travels to whatever it touched, so you can see your assistant working instead of taking its word for it.

Cedarfield is fictional. The other patients you see taking slots are simulated, and the page says so in its footer. No real appointment is ever made, and your details never leave your browser.

How we built it

Next.js 15 on Vercel. The page registers tools with document.modelContext. The twelve tools that exist at load time are registered by an inline script in the HTML before any JavaScript bundle runs. We learned the hard way that an agent snapshots the tool list the instant a page opens, and would otherwise see nothing. The app takes over running those tools once it has hydrated. Three more sets of tools are born and die with the state of the page.

The board is shared between every visitor and lives in Supabase. Row-level security and security definer procedures enforce the rules. One hold per person. Hold before you book. You can only cancel your own. A clever client cannot take someone else's slot. Hand shapes come from MediaPipe, served from our own domain. Speech is the browser's own recognizer. The scanning keyboard is a hundred-line state machine with tests.

Every number you see on the page is measured by the code that displays it. One interaction from you. Three appointments left. Held for 2:41. We did not want a single decorative number.

Challenges we ran into

The first-call problem above cost us a whole audit round. Three fresh loads, three failures, all because React had not hydrated yet.

Yes is a trap. It is the one word an agent can say too. So a spoken yes only counts when the page itself asked a visible question. The microphone is ignored while the page is talking. The page's voice client cannot run at the same time. For a noisy room, there is a word on screen you can say instead.

We wanted to call the hand shapes sign language, and we cannot. Five shapes, not a language, and the page says exactly that. It stung. Claiming ASL with a gesture model would have been a lie to the people we built this for.

Agents are slow. Ten to forty seconds per tool call in a chat client. Our forty-five-second hold kept expiring while the agent was still telling the user about it. Holds are three minutes now and the timer on screen is real.

Accomplishments that we're proud of

We got an agent to book an appointment for someone who never touched the page. That was the whole point, and it took twenty builds in one night to get there, because every time a real hand tried it, something real broke. The thumbs up never fired because our confidence bar was set for a lab and not a laptop camera. The palm met a closed lens because two cameras were fighting over one webcam. The agent never asked a question because nothing in our tool answers told it to. We found each of those with a person's hand in front of the screen, fixed the cause, and put it in front of the same hand again.

The part we are most proud of is the line the agent cannot cross. There is no booking tool on this page until a person makes one exist, with a press, a palm, or a word only they can see. The tool then lives ten minutes, works once, and dies. We tried to break it ourselves with scripted clicks and a second agent auditing the live page cold, and it held every time.

And it works for the person we built it for. Someone who cannot move their hands can open this page, type their name with two hand shapes, ask for a time with one finger, answer their agent's question with a thumbs up, grant permission with an open palm, and get a booking with a reference number and a calendar file. No touch. No voice. Nobody else in the room.

What we learned

Getting an agent to call tools is a weekend. Getting a page to decide what an agent may do for this person, right now, and to change its mind the moment the person does, is the actual work.

We learned that the tool list is part of the page, not something you add after it loads. Agents snapshot the page the instant it opens. If your tools arrive a second later, the agent has already decided you have none.

We learned that yes is a trap. It is the one word an agent can say too. A page that books on yes cannot tell its visitor from its assistant. So the page only listens for yes when it asks the question itself, ignores the microphone while it is speaking, and shows a word on screen for the room where that is not enough.

We learned that a camera is a shared resource with one owner, that a hold has to outlive an agent's thinking time, and that agents follow the sentence you put at the end of a tool result far more faithfully than anything you put in a prompt.

We learned to say no to our own idea. Five hand shapes are not sign language, and we took the words off the page.

And we learned why WebMCP is different from an API. An API cannot see the visitor's palm. A scraper cannot see a tool that does not exist yet. A page that can make consent into a tool and unmake it is a page a person can trust with their own agent.

What's next

Three things, in this order.

One. The pattern leaves the clinic. Everything that matters here is one idea: a page tells a visitor's own agent what it may do right now, and consent is a tool the person creates and the agent cannot. We are packaging that as a drop-in for any site, a few lines that register a born tool behind a trusted press, and we will propose the pattern to the WebMCP working group as a first-class annotation, so a booking tool that must not exist until a human acts can say so in the spec instead of in our code.

Two. Real sign language, done properly. Five shapes are switches, not a language, and the page says so today. Next we train a recognizer for the fifty signs a clinic visit actually needs, on video from Deaf signers who are paid and named as co-designers, and we ship it only when they say it reads them. Not a demo of ASL. A vocabulary that works.

Three. The people. A recorded session with a real switch user and a real AAC user, with their permission, and we change whatever they hate. Then the pages where people lose races they should never have had to run. Visa slots. Course registration. Ticket drops. Housing lists. We built one. The web needs all of them.

Built with

Next.js 15, TypeScript, WebMCP, Supabase, MediaPipe, Web Speech API, OpenAI Realtime API, Vercel

Live

https://cedarfield-clinic.vercel.app/clinic/book

Share this project:

Updates

Submission history