Voice AI

How to Send a Bot to Your Meeting by Text Message with Telnyx

You double-book yourself. The standup starts in two minutes, and you are on a train.

This example solves that with one text message. You send a meeting link to a Telnyx number, a bot joins the meeting in your place, tells everyone you are out, takes notes, and texts you a TL;DR when the meeting ends.

It is built with Telnyx Messaging and Telnyx Meeting Bot in about 200 lines of Node.js. Messaging receives your text and sends the replies. Meeting Bot joins the call, records the transcript, and generates the summary. Both use the same API key.

The canonical code example is:

https://github.com/team-telnyx/telnyx-code-examples/tree/main/join-meeting-by-sms-nodejs

The live walkthrough is:

https://youtu.be/cQMwlgGuU5E

What This Meeting Bot Example Builds

The example is an Express server with one webhook route. The full flow is:

~~~ you text a meeting link -> Telnyx Messaging webhook -> signature check and owner check -> create meeting session -> bot joins and announces itself in chat -> status texts: waiting room, then in the meeting -> meeting ends -> summary artifact -> TL;DR text ~~~

It supports Google Meet, Zoom, Microsoft Teams, and Webex links. A regular expression pulls the first matching URL out of your text, so you can write the message naturally:

~~~ I can't join this meeting: https://meet.google.com/abc-defg-hij. Join as my bot, and send me a TL;DR when it ends. ~~~

Step 1: Receive The Text And Verify It

Telnyx posts every inbound SMS to your webhook. A public URL can be called by anyone, so the handler verifies the Ed25519 signature before it trusts the body.

Verification needs the raw request bytes, so the route uses express.raw instead of a JSON parser:

~~~js app.post("/webhooks/sms", express.raw({ type: "/" }), async (req, res) => { let event; try { event = await client.webhooks.unwrap(req.body.toString(), { headers: req.headers }); } catch (error) { return res.status(401).json({ error: "invalid signature" }); }

res.status(200).json({ received: true }); // acknowledge fast // ...handle the event }); ~~~

The handler acknowledges with 200 before doing any work. Creating a meeting session takes longer than Telnyx is willing to wait, and a slow response triggers a retry.

Step 2: Only Listen To The Owner

If anyone who finds your number could send a bot into any meeting, the number becomes an abuse vector. The handler compares the sender with OWNER_PHONE_NUMBER and ignores everyone else:

~~~js if (from !== OWNER_PHONE_NUMBER) { console.log("[skip] message is not from the owner number"); return; } ~~~

This is a deliberately small authorization model. It fits a personal assistant. A team deployment would map several numbers to users and decide which meetings each user may send a bot into.

Step 3: Send The Bot In

One call creates the meeting session:

~~~js const response = await client.meetingSessions.create({ meeting_url: meetingUrl, bot_name: BOT_NAME, chat_on_enter: CHAT_ON_ENTER, summarize_on_end: true, idempotency_key: join-meeting-by-sms:${messageId}, }); ~~~

Three fields carry most of the behavior:

  • chat_on_enter posts a message in the meeting chat the moment the bot becomes active, so nobody is surprised by an unfamiliar participant. Chat is not available on every meeting platform, and the API rejects the field where it is unsupported.
  • summarize_on_end tells Telnyx to generate a summary artifact when the session ends.
  • idempotency_key makes the create call safe to retry.

Why The Idempotency Key Matters

Telnyx retries a webhook that does not get a fast success response. Without protection, a retried text could create a second bot in the same meeting.

The key is built from the inbound message ID. If the same message is delivered twice, Telnyx replays the existing session instead of creating another one.

The server also checks for an in-progress session on the same meeting URL before creating one. If you text the same link twice, you get "Your bot is already in that meeting" instead of a duplicate.

Step 4: Keep You Posted

The bot is not instant. It may sit in a waiting room until a host admits it. The server polls the session every five seconds and texts you once per status change:

~~~ joining -> "On it. Your bot is joining now." waiting_for_admission -> "Your bot is at the waiting room. A host needs to admit it." active -> "Your bot is in the meeting and taking notes." admission_denied -> "The host did not admit your bot, so no notes were taken." failed -> "Your bot could not join the meeting." ~~~

Polling keeps the sample runnable on localhost with a single webhook URL. If you want to avoid polling, create the session with a webhook_url and handle its lifecycle callbacks instead.

Step 5: Text The TL;DR

When the session reaches ended, the server fetches the artifacts and looks for the one with type summary:

~~~js const artifacts = await client.meetingSessions.artifacts.list(sessionId); const summary = artifacts.data.find((a) => a.type === "summary"); if (summary?.status === "completed" && summary.content?.text) { return summary.content.text.trim(); } ~~~

Summary generation is asynchronous, so the server waits for the artifact to complete, up to 90 seconds. If it fails or times out, you get a plain fallback message rather than silence.

Optional: Let The Bot Talk

Set ASSISTANT_ID to attach a Telnyx AI Assistant. The bot can then speak and answer questions in the meeting. Use chat_on_enter to announce an assistant-backed bot, because speak_on_enter is not spoken when an assistant is attached.

You can also set CAMERA_IMAGE_URL to a public JPEG that the bot shows as its camera tile.

Run The Example

~~~bash git clone https://github.com/team-telnyx/telnyx-code-examples.git cd telnyx-code-examples/join-meeting-by-sms-nodejs cp .env.example .env npm install npm start ~~~

Fill in .env with your API key, public key, Telnyx number, and your own mobile number. Expose the server with a tunnel and set the Messaging Profile's inbound webhook to https://<tunnel>/webhooks/sms. Then text your Telnyx number a meeting link from the owner number.

This places a real bot in a real meeting and sends real SMS, so try it first with a meeting you control.

Production Considerations

The sample is a focused pattern, not a finished product. A production version should:

  • Persist watched session IDs in a database and resume watching on boot. They are held in memory, so a restart stops the status texts
  • Disclose the bot clearly in every meeting. People should know a bot is taking notes
  • Register the sending number for US SMS with 10DLC or toll-free verification
  • Decide who may send a bot where, instead of a single owner number
  • Handle meeting platforms that do not support chat
  • Define a retention policy for transcripts and summaries

First comment

Demo video: https://youtu.be/cQMwlgGuU5E

Code: https://github.com/team-telnyx/telnyx-code-examples/tree/main/join-meeting-by-sms-nodejs

Frequently Asked Questions

How do I send a bot to a meeting from an API call?

Create a meeting session with the meeting URL. Telnyx joins the call as a bot, and the session moves through joining, waiting_for_admission, active, and ended.

Which meeting platforms does the example accept?

The URL pattern matches Google Meet, Zoom, Microsoft Teams, and Webex links.

How does the TL;DR get generated?

Creating the session with summarize_on_end: true makes Telnyx generate a summary artifact from the transcript when the meeting ends. The server reads it and texts it to you.

What stops a retry from adding a second bot?

The inbound message ID is the session idempotency key, and the server also checks for an in-progress session on the same meeting URL.

Who can send the bot into a meeting?

Only OWNER_PHONE_NUMBER. Texts from any other number are ignored, and webhooks without a valid Telnyx signature are rejected with 401.

Can the bot speak in the meeting?

Yes, when you attach a Telnyx AI Assistant with ASSISTANT_ID.

Resources

  • Code example: https://github.com/team-telnyx/telnyx-code-examples/tree/main/join-meeting-by-sms-nodejs
  • Demo video: https://youtu.be/cQMwlgGuU5E
  • Telnyx SMS API: https://telnyx.com/products/sms-api
  • Receive a message guide: https://developers.telnyx.com/docs/messaging/messages/receive-message
  • Node.js SDK: https://developers.telnyx.com/development/sdk/node

Ready to build with low-latency voice AI?

Join developers building the future of real-time conversations