https://sitegpt.ai/mcp. To connect an app, see Connect an AI assistant with MCP. The local server (sitegpt mcp) has other tools. See Local server tools.
Connection
Scopes
- The app can ask for any scope in the scope table. If the app asks for no scopes, SiteGPT asks for the Standard access level: every scope except creating or changing tokens (
tokens:write), changing billing (billing:write), and reading or changing integrations (integrations:read,integrations:write). - The connection gets only the scopes that your dashboard role allows on the chatbots that you select on the approval page.
- Read only on the approval page keeps only the requested scopes that end in
:read. See Connect with read-only access. - With an API token as the bearer, the token’s own scopes and chatbot access apply.
- An access token is valid for 1 hour. The app gets a new one with its refresh token, which is valid for 90 days.
403 TOKEN_SCOPE_NOT_ALLOWED, and details.requiredScopes lists the missing scopes. A scope alone is not enough: your role must also allow the action on that chatbot.
Tool summary
Access type puts each tool in one class:- Read: the tool gets data. It does not change data, account state, or permissions.
- Write: the tool creates, changes, or deletes data, or changes settings.
- Sensitive write: the tool sends a message to another person, or it can delete data that cannot be restored.
reply_to_conversationsends a message to a real website visitor and can take over the conversation.execute_writecan delete data that cannot be restored, invite members by email, reply to visitors, and send email drafts to customers.
readOnlyHint, destructiveHint, idempotentHint, openWorldHint).
ChatGPT and Codex do not get
get_onboarding_status, and the remote server refuses onboarding API calls from them with NOT_AVAILABLE_IN_THIS_ASSISTANT. They also cannot read /api/v2/openapi.json with execute_read. That call returns 403 USE_SEARCH_TOOL. Use search instead. In a HIPAA workspace, the tools that return conversations, leads, or escalations are blocked.
Code tools
search, execute_read, and execute_write take one input, code: a JavaScript async arrow function as a string. The code runs on SiteGPT’s side and can call API v2 only. The result is the return value of the function, as text in result.
- The scopes, inputs, outputs, and errors of each operation are in the API reference.
- An API error does not end the tool call. It comes back inside
resultas{"ok": false, "error": {"code": "...", "message": "..."}}. execute_writecannot create or change GitHub sources, because they carry an access token. Connect GitHub in the dashboard. See Connect GitHub.- The code stops after 20 seconds.
Chatbot and conversation tools
preview_chatbot
Shows a live preview of a chatbot widget.
Returns:
chatbotId, widgetUrl, and title. Apps that support MCP app views show the preview.
Side effects: None. A preview does not count in analytics.
Errors: A value that is not a chatbot ID returns an error. The tool does not check that the chatbot exists.
send_chat_message
Sends a message to a chatbot as a visitor and returns the answer.
Returns:
chatbotId, threadId, answer, and messageType. If the chatbot is in Human mode, answer is null, because the chatbot does not reply. If the message gets your away message outside working hours, the text result includes the away message.
Side effects:
- Creates a real conversation, or adds a message to one.
- An AI answer counts toward your message quota. See Plans and limits.
- The AI can escalate the conversation to your team.
403 ACCOUNT_INACTIVE (the chatbot owner has no active plan), 404 CONVERSATION_NOT_FOUND, 409 CONVERSATION_CLOSED (the conversation is resolved), 429 MESSAGE_LIMIT_REACHED (the conversation reached its message limit, so leave out threadId to start a new conversation), 400 VALIDATION_FAILED.
list_conversations
Lists the conversations of a chatbot.
Returns:
conversations and nextCursor. Each conversation has threadId, title, mode, escalated, resolved, important, startedAt, updatedAt, totalMessages, unreadMessages, visitor (name, email), pageUrl, lastMessage, lastQuestion, lastAnswer, and lastFrom (visitor, bot, or agent). If the last message is your away message, lastFrom is visitor, because the visitor still waits for your team. Message text is cut to 200 characters.
Side effects: None.
Errors: 400 VALIDATION_FAILED for a filter that is not valid.
get_conversation
Reads the transcript of one conversation.
Returns:
threadId, title, mode, escalated, resolved, important, startedAt, visitor, pageUrl, lastFrom, dashboardUrl (the conversation in the dashboard), and messages. Each message has messageId, question, answer, messageType, systemMessageType, and createdAt. The tool returns the last 200 messages, with each text cut to 2,000 characters. It does not return lead form answers. If the last message is your away message, lastFrom is visitor, because the visitor still waits for your team.
Side effects: None.
Errors: 404 CONVERSATION_NOT_FOUND.
reply_to_conversation
Sends a reply to the visitor as a person on your team.
Returns:
threadId, reply (messageId, text, createdAt), tookOver, and delivery (channel, delivered, reason).
Side effects:
- The visitor sees the reply in the chat widget, on WhatsApp or Messenger for a conversation there, or by email for an email conversation. See Email.
- If your team does not handle the conversation yet, the reply takes it over first: the AI stops answering, and the visitor sees that a human agent joined.
tookOveris thentrue. See Reply to visitors and take over. - Except in a WhatsApp, Messenger, or email conversation, SiteGPT can email the reply to the visitor, the same as a reply from Chat History. See When SiteGPT emails your reply to the visitor.
- Each call sends another message.
delivery.delivered is false and delivery.reason tells why. For example, over_quota means that the WhatsApp add-on does not cover this number, and disconnected means that the number is no longer connected. See If a number is not covered. For an email conversation, delivery.channel is email. If the email cannot go out, delivery.reason is hipaa_blocked, unentitled (the AI Email Support add-on does not cover the inbox), no_inbox (the inbox was removed), or send_failed (the inbox is still being set up, or the email could not be sent). The reply stays in the conversation. For a Messenger conversation, delivery.channel is messenger. If Messenger does not deliver the reply, delivery.reason is outside_window (Meta’s time limit passed, see Messenger), disconnected (the Facebook Page is no longer connected), hipaa_blocked, or send_failed. The reply stays in the conversation.
Errors: 409 CONVERSATION_CLOSED (the conversation is resolved), 409 REPLY_IN_CHANNEL (the conversation is on Slack, Crisp, or another channel with its own agent inbox, so reply there), 404 CONVERSATION_NOT_FOUND, 503 REPLY_NOT_SENT, 400 VALIDATION_FAILED.
list_escalations
Lists escalated conversations that are still open and wait for your team.
Returns:
escalations and nextCursor. Each escalation has the same fields as a conversation in list_conversations.
Side effects: None.
list_leads
Lists the leads of a chatbot.
Returns:
leads and nextCursor. Each lead has id, name, email, phone, important, archived, and createdAt.
Side effects: None.
Errors: 400 VALIDATION_FAILED.
get_chatbot_analytics
Reads the analytics of a chatbot.
Returns:
conversations: message count and the share of positive and negative feedback.training: the training state and the counts of trained, pending, and failed documents.knowledge: the counts of pages, documents, links, and files.quota: messages, pages, and chatbots used and allowed, and the current usage window.history: the last 12 months.engagement: totals for the last 30 days, with a comparison to the 30 days before. It isnullwhen your plan does not include analytics.
Appearance and settings tools
get_chatbot_appearance
Reads how the chat widget looks.
Returns:
appearance (title, tooltip, welcomeMessage, placeholderText, brandColor, brandTextColor, iconBackgroundColor, linkColor, iconPosition, iconShape, enableDarkMode) and the first 8 conversation starters (id, title).
Side effects: None.
update_chatbot_appearance
Changes how the chat widget looks. Give at least one field to change.
Returns:
chatbotId and the saved appearance.
Side effects: The widget on your website changes at once.
Errors: 400 VALIDATION_FAILED.
read_sitegpt_settings
Reads four settings: lead email notifications, human handoff, how new conversations start, and hide sources in answers. It takes no input. It reads up to 10 chatbots: the first 10 in your chatbot list, which are the chatbots that you were added to most recently. To change a setting of another chatbot, use the dashboard orexecute_write.
Returns: schema, values, and layout. Each setting is named <field>__<chatbotId>, where <field> is leadEmails, humanSupport, chatMode, or hideSources. chatMode is WORKING_HOURS while the chatbot follows its working hours, and VISITOR_CHOICE while Let the Visitor Choose is selected. Visitors get the question only while humanSupport is true. Otherwise it is the fixed chat mode, AI or AGENT. A setting that your role cannot read is left out.
Side effects: None.
update_sitegpt_settings
Changes the settings thatread_sitegpt_settings returns.
SiteGPT checks every value before it saves any change. Each change goes through the same checks as the dashboard.
Returns:
values, read again after the save.
Side effects: The changes are live at once. For example, chatMode set to AGENT sends every new conversation to your team, and the AI does not answer first. Setting chatMode to AI or AGENT turns working hours and visitor choice off. SiteGPT keeps the schedule and the visitor choice text. WORKING_HOURS turns the saved schedule on again and turns visitor choice off. It does not change the fixed chat mode that Zendesk and Zoho SalesIQ use. To create or change the schedule, use the dashboard or API v2. VISITOR_CHOICE turns visitor choice on with the saved question and button labels, or with the default text if none are saved, and turns working hours off. Visitors get the question only while humanSupport is true. Otherwise new conversations start with the AI. A saved schedule stays and then decides what a visitor who asks for a person gets. See Connect visitors to your team during your hours. To change the question or the labels, use the dashboard or API v2.
Errors: An unknown setting name or a value that is not valid fails before anything is saved. WORKING_HOURS for a chatbot without saved working hours also fails before anything is saved, with “This chatbot has no working hours yet. Set them on the Chat Modes page of the SiteGPT dashboard first.” If SiteGPT refuses a change partway, the error tells how many changes it saved before it stopped.
Content tools
list_knowledge_sources
Lists the connected sources of a chatbot and the training state of its documents.
Returns:
sources: each withid,name,connector,status(PENDING,ACTIVE,FAILED, orREVOKED),statusReason,hasCredentials, andcreatedAt.documents: document counts by status and by source. The document statuses areBACKLOG,QUEUED,PROCESSING,SUCCESS,FAILED,CANCELLED, andBLOCKED_BY_QUOTA.
upload_knowledge_file or a new source. Documents move from QUEUED and PROCESSING to SUCCESS or FAILED.
create_knowledge_source
Connects a new source from another app.
Returns:
source, authorizationUrl, and nextStep.
Side effects: Creates the source with the status PENDING.
Status: The source stays PENDING until you open authorizationUrl and sign in to the other app in your browser.
Errors: 400 CONNECTOR_REQUIRED, 400 CONFLUENCE_DOMAIN_REQUIRED, 403 HIPAA_CONNECTORS_DISABLED (a HIPAA workspace), 503 HIPAA_CHECK_UNAVAILABLE.
authorize_knowledge_source
Gets a new authorization link for a source.
Returns: The same fields as
create_knowledge_source.
Side effects: Sets a new authorization link for the source.
Errors: The same as create_knowledge_source.
upload_knowledge_file
Uploads one file as content.
Returns:
fileName, documentsCount, and ingestJobRunIds.
Side effects:
- The file is added to the chatbot’s content and uses pages of your plan.
- After training, the chatbot uses the file in its answers.
list_knowledge_sources.
Errors: 429 CHATBOT_PAGES_LIMIT_REACHED (no pages left), 413 FILE_TOO_LARGE, 400 FILE_BASE64_NOT_VALID, 503 HIPAA_UPLOADS_BLOCKED, 400 HIPAA_TXT_ONLY, 502 KNOWLEDGE_INGEST_FAILED.
Home view tools
open_sitegpt and open_sitegpt_inbox
Open the SiteGPT home view, with a chatbot switcher and the tabs Inbox, Escalations, Leads, Analytics, and Knowledge.open_sitegpt_inbox is named Support Inbox and opens the view as a panel inside a conversation, in apps that support panels. In those apps, the conversation or lead that you open becomes context for that chat. Both tools take no input.
Returns: chatbots (id, title) and truncated. The switcher lists up to 1,000 chatbots. truncated is true when you have more. A connection limited to some chatbots lists only those.
Side effects: None by itself. In the views, the reply form calls reply_to_conversation, and the Knowledge tab can connect an app (Connect, Connect again) and upload a file (Upload and train) with create_knowledge_source, authorize_knowledge_source, and upload_knowledge_file. These calls have the side effects of those tools.
Onboarding tool
get_onboarding_status
Shows the setup status of a temporary chatbot from agent-first onboarding.
Returns:
status, isExpired, chatbotId, claimStatus, checklist (each item with key, label, state, and detail), claimUrl, and onboardingUrl.
Side effects: None.
Errors: It needs the temporary onboarding token. A connection that signed in to an account gets 403 ONBOARDING_TOKEN_REQUIRED. 404 ONBOARDING_WORKSPACE_NOT_FOUND means the workspace does not exist.
Errors
- The chatbot, conversation, appearance, content, and home view tools report an error as text in the form
<step> failed: <message> (<CODE>). The code is the API v2 error code. The code tools return API errors insideresult. See Code tools. - These errors can come from every tool that reads or changes a chatbot:
For all API v2 error codes, see API conventions.
Limits
- There is no per-request rate limit.
429means that a plan quota is used up, or withMESSAGE_LIMIT_REACHED, that a conversation reached its message limit. An onboarding start throughexecute_writecan also return429 RATE_LIMITED, when too many onboarding workspaces were started. Its message says how many minutes to wait. Do not retry it in a loop. See Rate limits and quotas. - A request to the MCP server can be up to 4 MB.
- The list tools return up to 100 items for each page. Use
nextCursorto get the next page. - The size limits of each input are in the tool sections above. Plan limits are on Plans and limits.