Let your AI agent run AI Ambassador
One scoped key and one npm package. Your agent sets up assistants, grounds them on your website, drafts broadcasts, answers guests and runs event check-in, with spending limits it cannot talk its way past.
claude mcp add ai-ambassador \
--env MSG2AI_AGENT_KEY=msgk_live_… \
-- npx -y -p @msg2ai/ai-ambassador-toolkit ambassador-mcp- Tools
- 67Toolsgrouped by job
- Surfaces
- 2SurfacesMCP · CLI
- Packages
- 5Packagesone build
- Runtime deps
- 0Runtime depsNode 18+
How it works
The toolkit is a thin client. Your agent talks to it, it talks to the msg2ai agent gateway, and the gateway acts on your organization's assistants with exactly the scopes your key holds.
Your AI agent
Claude, Cursor, or any MCP client. A shell script or CI job works too.
The toolkit
ambassador-mcp for agents, ambassador for the command line. Same tools, same key.
msg2ai agent gateway
api.msg2ai.xyz/api/agent checks the key, its scopes and its daily budget on every call.
Your assistants
The same assistants your team manages in the dashboard, talking to guests on WhatsApp and SMS.
MCP server
ambassador-mcpRegister it once and your agent sees the AI Ambassador tools as native tools. It advertises only the tools your key may call, and a failed call comes back as a readable error instead of ending the conversation.
Command line
ambassadorEvery tool is a subcommand with the same name. Pass fields as flags or one JSON object, get JSON back, and script it. Handy for onboarding a property, a nightly job, or checking what a key can do.
From key to first call in three steps
You need Node 18 or newer and an Admin of your organization in the msg2ai dashboard.
Mint an agent key
An organization Admin mints the key in the msg2ai dashboard and picks its scopes. It starts with msgk_live_ and is shown once, so store it in a secret manager.
Give it to the toolkit
One environment variable configures both the MCP server and the CLI.
export MSG2AI_AGENT_KEY=msgk_live_…
# optional, this is the default:
export MSG2AI_BASE_URL=https://api.msg2ai.xyzMake the first call
Ask the gateway what this key may do. No install needed; npx fetches the package.
npx -y -p @msg2ai/ai-ambassador-toolkit ambassador toolsConnect the MCP server
Add it to your client's MCP configuration, or register it from the Claude Code command line.
MCP client configuration
For Claude Desktop, Cursor and other clients that read an mcpServers block.
{
"mcpServers": {
"ai-ambassador": {
"command": "npx",
"args": ["-p", "@msg2ai/ai-ambassador-toolkit", "ambassador-mcp"],
"env": { "MSG2AI_AGENT_KEY": "msgk_live_…" }
}
}
}Claude Code
One command. Swap in a vertical package to name the server after your business.
claude mcp add ai-ambassador \
--env MSG2AI_AGENT_KEY=msgk_live_… \
-- npx -y -p @msg2ai/ai-ambassador-toolkit ambassador-mcpclaude mcp add hotel-ambassador \
--env MSG2AI_AGENT_KEY=msgk_live_… \
-- npx -y -p @msg2ai/hotel-ambassador hotel-ambassador-mcpOnly the tools your key can use
At startup the server reads /capabilities and advertises nothing else. Listing tools that would fail with 403 only teaches a model to retry things it can never do.
Errors the model can act on
A failed call returns an isError result with the reason, not a protocol error, so the agent can adjust and the conversation carries on.
Use the CLI
Every tool is a subcommand. Fields go in as --flags or as one JSON object with --input, and results come back as JSON.
npm install -g @msg2ai/ai-ambassador-toolkit
ambassador tools # what this key may call
ambassador list_assistants
ambassador get_assistant --serviceId svc_123
ambassador upload_knowledge --serviceId svc_123 --text "Checkout is 11am"
ambassador openapi > openapi.json # no key needednpm install -g @msg2ai/event-ambassador
event-ambassador get_checkin_stats --serviceId svc_456
event-ambassador list_checkin_arrivals --serviceId svc_456
event-ambassador list_meeting_slots --serviceId svc_456npm install -g @msg2ai/hotel-ambassador
# Create a hotel concierge (no number is attached yet)
hotel-ambassador create_assistant --input '{
"assistantName": "Harbor House Concierge",
"assistantData": {
"caseType": "CONCIERGE_ASSISTANT",
"propertyType": "HOTEL"
}
}'
# Ground it on one page of the hotel's site…
hotel-ambassador upload_knowledge_website \
--serviceId svc_123 --url https://www.example-hotel.com/faq
# …or a bounded crawl (numbers go in --input)
hotel-ambassador upload_knowledge_website --input '{
"serviceId": "svc_123", "url": "https://www.example-hotel.com",
"mode": "crawl", "limit": 25, "maxDepth": 2
}'- Flags are strings. Put numbers, arrays and nested objects in --input, as in the crawl example.
- Key and gateway per call. --key and --base-url override the environment variables.
- Scriptable exit codes. 0 on success, 1 when the gateway refuses the call, 2 for a server or network error.
- The contract is public. ambassador openapi prints the OpenAPI document for every tool, with no key required.
One build, named for your business
Every package below is the same toolkit at the same version. Pick the one that reads right in your agent's tool list; the tools and the key are identical.
AI Ambassador
@msg2ai/ai-ambassador-toolkit$ ambassador$ ambassador-mcpThe base package. Works for every vertical.
Hotels
@msg2ai/hotel-ambassador$ hotel-ambassador$ hotel-ambassador-mcpassistantData: CONCIERGE_ASSISTANT / HOTEL
Vacation rentals
@msg2ai/vacation-rental-ambassador$ vacation-rental-ambassador$ vacation-rental-ambassador-mcpassistantData: CONCIERGE_ASSISTANT / VACATION_HOME
Events
@msg2ai/event-ambassador$ event-ambassador$ event-ambassador-mcpassistantData: MEETING_EVENT_ASSISTANT
Travel agencies
@msg2ai/trip-ambassador$ trip-ambassador$ trip-ambassador-mcpassistantData: CONCIERGE_ASSISTANT / TRAVEL_AGENCY
When your agent creates an assistant, set assistantData.caseType (and propertyType where shown) to the values for your vertical.
What an agent can do with it
Real jobs, chained from the tools below. Each one lists the scopes it needs, so you can mint a key that does that job and nothing else.
Stand up a hotel concierge
Create the assistant, ground it on the hotel's own website, and save the welcome and check-out templates, ready for an operator to attach a number.
Run event day
Pull Humanitix registrations in, mint a check-in code for every attendee, then watch arrivals and meeting requests through the day.
Triage the guest inbox
Scan open conversations, read the ones that need a person, and answer in the same thread, inside the key's daily budget.
Draft a campaign for review
Build an audience group from tagged contacts and draft the broadcast. Without broadcasts:send, a human presses send in the dashboard.
67 tools, grouped by job
The MCP server exposes these names and the CLI uses them as subcommands. Each tool needs one scope, and your key only sees the tools its scopes allow.
Assistants
4 toolsList, read, create and rename assistants. A new assistant never gets a phone number automatically.
list_assistantsget_assistantcreate_assistantupdate_assistant
Knowledge
3 toolsGround an assistant with a text document, a single web page, or a bounded crawl of a site.
upload_knowledgeupload_knowledge_websitedelete_knowledge
Content templates
2 toolsRead and save an assistant's message templates in one write. Saving does not submit them for approval.
list_templatessave_templates
Contacts, tags & audience groups
11 toolsSearch and manage guests and attendees, tag them, and group them into audiences for broadcasts and reminders.
list_contactscreate_contactupdate_contactdelete_contactadd_contact_tagsremove_contact_taglist_audience_groupscreate_audience_groupupdate_audience_groupadd_audience_group_membersdelete_audience_group
Contact consent
3 toolsRead and set a guest's consent flags: email, LinkedIn, WhatsApp, phone and meetings.
list_contact_preferencesget_contact_preferencesupdate_contact_preferences
Broadcasts
8 toolsDrafting and sending are separate tools behind separate scopes. A key can write drafts all day and never send one.
create_broadcastupdate_broadcastdelete_broadcastlist_broadcastsget_broadcastsend_broadcastpause_broadcastcancel_broadcast
Reminders
7 toolsSchedule messages to an audience, then switch them on or off. The scheduler does the sending later.
list_remindersget_remindercreate_reminderupdate_reminderenable_reminderdisable_reminderdelete_reminder
Guest conversations
3 toolsTriage the inbox and answer in an existing thread. The recipient always comes from the conversation.
list_conversationsget_conversationreply_to_conversation
Numbers
3 toolsSee the numbers your organization already owns and move them between its assistants.
list_numbersattach_numberdetach_number
Meetings
6 toolsManage meeting requests between attendees and check which bookable slots are still open.
list_meetingsget_meetingcreate_meetingupdate_meetingdelete_meetinglist_meeting_slots
Event check-in
5 toolsMint check-in codes, look up one attendee, and watch arrivals come in. There is no bulk export of codes.
generate_checkin_codesregenerate_attendee_checkin_codeget_attendee_checkinget_checkin_statslist_checkin_arrivals
Event registration (Humanitix)
5 toolsConnect a Humanitix event to an assistant so its registrations are imported, and see why a sync failed.
list_event_registration_connectionscreate_event_registration_connectionupdate_event_registration_connectiondelete_event_registration_connectionlist_event_registration_sync_events
Survey results
5 toolsRead-only: aggregate results, masked individual responses, and a CSV export. Authoring surveys lives in WhatsApp Surveys.
list_surveysget_survey_resultsget_survey_statisticslist_survey_responsesexport_survey_responses
Discovery & usage
2 toolsAsk what this key may do, and how many messages the organization has sent.
capabilitiesget_usage
One key, one organization
An agent key is a narrow credential for one job, not a login.
- Minted by an Admin. Only an Admin of your organization can create a key, in the msg2ai dashboard.
- Shown once. The msgk_live_ secret is displayed a single time and cannot be recovered. Lost it? Mint a new one.
- Scopes fixed at mint. Each key carries the scopes chosen when it was created. Give a reporting agent read scopes only.
- Stays in its tenant. A key acts as exactly one organization. It cannot reach another tenant and is not a platform credential.
Scope vocabulary
assistants:read / :writeRead or create and update assistantsknowledge:writeAdd and remove knowledge documentstemplates:read / :writeRead or save content templatesaudiences:read / :writeContacts, tags, audience groups, consent flagsbroadcasts:writeDraft, edit and delete broadcasts — never sendbroadcasts:sendSend, pause and cancel broadcasts (spends money)reminders:read / :writeRead or schedule, enable and disable remindersconversations:readRead guest conversationsconversations:writeReply in a conversation (spends money)numbers:attachMove owned numbers between assistantsmeetings:read / :writeMeeting requests and slotscheckin:read / :writeCheck-in stats, arrivals and codesintegrations:read / :writeHumanitix registration connectionssurveys:readList the organization's surveysresults:read / :exportSurvey results, masked responses and CSVusage:readMessage counts for the organization
Safe to automate
An agent works fast and never gets tired, so the limits live in the gateway, not in the prompt. Here is what it will refuse.
Spend is checked before anything queues
send_broadcast and reply_to_conversation spend money. Recipients are counted and charged against the key's daily budget first; a send over the per-call ceiling or the daily budget is refused outright, never partly delivered.
Drafting and sending are separate
create_broadcast only ever makes a DRAFT. Sending needs broadcasts:send, a different scope, so you can hand an agent the pen without the button.
No phone number by accident
Creating an assistant does not attach a number. The number pool is operator-owned; until a number is attached, template submission refuses with AGENT_NUMBER_REQUIRED.
Refused, not silently dropped
Instructions, guardrails, privacy settings, provider credentials and billing flags are rejected with an explanation. Your agent learns why instead of thinking it worked.
Guest data stays masked
Phone numbers are masked in list results. Contact emails, notes and enrichment are never returned, and conversation lists carry no message text.
Only the tools a key can use
The MCP server reads /capabilities at startup and advertises only the tools the key may call, so a model is never shown a tool that would fail with 403.
Failures the model can read
A tool failure comes back as an isError result, not a protocol error. The model sees the reason and adapts; the conversation keeps going.
Reminders send later
A reminder is scheduled, not sent by the key. The scheduler sends it later, outside the key's daily send budget, so treat reminders:write as a sending scope.
Authoring surveys or WhatsApp campaigns?
Survey results are read-only here. To create and send surveys, or to build WhatsApp campaign templates, from an agent, use the companion toolkit for WhatsApp Campaigns & Surveys: @wa-campaigns/agent-toolkit (wa and wa-mcp). It has its own tools and its own keys.
Frequently Asked Questions
About the AI Ambassador MCP server and CLI
It is a Model Context Protocol server, ambassador-mcp, that lets an AI agent manage your AI Ambassador assistants: knowledge, templates, contacts, broadcasts, reminders, conversations, meetings and event check-in. It ships in the npm package @msg2ai/ai-ambassador-toolkit alongside the ambassador command-line tool.
Building an agent for your property or event?
Tell us what you want it to do. We'll help you set up the assistant, attach a number and pick the scopes for its key.
Looking for the guest experience instead? See AI Ambassador for hotels, vacation rentals and events.