For developers and AI apps
MCP server reference
Address, sign-in, tools, limits and errors of the Clinixa clinic API's MCP server.
Available
The Clinixa clinic API answers AI apps through one MCP server. Each connection belongs to one clinic and sees only what that clinic shows the public.
Address and transport
- Address:
https://api.clinixaeg.com/mcp,POSTonly. - Streamable HTTP without sessions: one JSON-RPC message per request and a JSON answer, with no session ID and no server-sent events.
- Protocol versions:
2025-11-25,2025-06-18and2025-03-26. - Call it from an AI app or a server. A request with an
Originheader, as a web browser sends, is refused with 403.
Sign-in
Every call carries Authorization: Bearer and a credential. There are two kinds:
- AI apps: an OAuth access token. The clinic's Owner approves the app on Clinixa's consent page.
- A clinic's own website or bot: a website key that starts with
cxk_live_, which the clinic's Owner creates in Clinixa. See the website API.
A call with no credential is answered 401, and its WWW-Authenticate header gives the address of the protected resource metadata, so an MCP client can find the rest.
OAuth details
- Protected resource metadata:
https://api.clinixaeg.com/.well-known/oauth-protected-resource/mcp - Authorization server metadata:
https://api.clinixaeg.com/.well-known/oauth-authorization-server - Authorization server endpoints on the same host:
/oauth/authorize,/oauth/token,/oauth/registerand/oauth/revoke. - OAuth 2.1 authorization code with PKCE (
S256) for public clients, with no client secret. Every answer to the app carriesiss. - An app names itself with a client ID metadata document, an https address used as its
client_id, or, while the server allows it, registers itself (RFC 7591). Its redirect address must be one it declared. - Resource (RFC 8707):
https://api.clinixaeg.com/mcp - Scopes:
clinic:catalogandclinic:availability.offline_accessis accepted; a refresh token is always issued. - Access tokens work for 60 minutes by default. A refresh token changes on every use, so present each one only once: showing a used one again ends the connection.
Tools
tools/list shows only the tools the connection may use. Call get_clinic_info first in each conversation.
get_clinic_info: the clinic, the branches this connection may use with their opening hours for the next 14 days, the online booking rules, and the tools it may use.list_services: the services the public can book at a branch, with their duration, whether a doctor must be chosen, and the price when the clinic shows prices online.list_doctors: the doctors who can be booked online for a service at a branch.find_free_times: start times for one to ten services done back to back, over 1 to 14 days. Nothing is held.
clinic:catalog gives the first three tools and clinic:availability gives find_free_times. Every tool takes language, en or ar. IDs must come from an earlier answer in the same conversation. Times show in 12-hour form with Western digits.
Rules for assistants
- Offer only the services, doctors and times the tools return, and show each time exactly as its
displaytext. - A free time is not held or booked. Tell the visitor to contact the clinic to book it.
- Never ask for medical details.
Coming later: requests
Two more tools, request_booking and send_enquiry, under the scope clinic:requests, will let an app send reception a booking request for a free time, a question or a call-back request. They are not available yet, and tools/list does not show them.
Limits
- Calls a minute per connection, set by the clinic's Owner within the platform's limit.
- Past it, the answer is
rate_limitedwithretryAfterSeconds. When the API is busy it answers 503 withRetry-After.
Errors
A refused tool call names a code:
invalid_request: an argument is missing or wrong. The answer lists the fields to fix.not_found: no such branch, service or doctor for this connection.rate_limitedandtemporarily_unavailable: wait and try again.
While the clinic's Owner has paused an AI app's connection, every call is answered HTTP 403 with the code paused.