Skip to main content
Glama

Send a broadcast

send_broadcast
Destructive

Send a broadcast

Sends one approved template from one of the agent's WhatsApp numbers to many numbers, right away, as the dashboard's Broadcasts page does. The answer is 201 with the broadcast, sending; Mojeeb sends in the background, and each message's delivery comes back on listBroadcastRecipients. Each recipient lands in their conversation with the agent (one is started if they have none), so a reply reaches the AI.

A broadcast fills only the template's body variables: parameters for everyone, and a recipient's own parameters over them. Its header keeps the sample it was approved with, and no button gets a value, so a template with a header variable or a button that needs a value per send is 422 template_not_broadcastable (send those one by one with sendWhatsAppTemplate), and so is one with a location header, which Mojeeb can't send yet. A template the number doesn't have is 422 template_not_found with available_templates, or template_not_found_for_language with available_languages. Only an approved template can be broadcast (422 template_not_approved). A number listed twice gets one message; recipient_count says how many will be sent. Mojeeb refuses a broadcast with more recipients than the number's WhatsApp daily messaging limit allows (422 invalid_request).

It checks the template with Meta, so it shares the WhatsApp template endpoints' budget of 10 requests a minute per key. Plans with broadcasts only.

The MCP server sends this call with an idempotency key of its own, so a retry after a timeout never sends it twice.

Input Schema

NameRequiredDescriptionDefault
nameYesWhat the team sees in the dashboard's broadcast list. Can't contain angle brackets.
agent_idYesThe agent the resource belongs to. Another company's agent, or the nil UUID, is `404 agent_not_found`; an agent outside the key's agent list is `403 agent_not_authorized`.
templateYesThe template, as `listWhatsAppTemplates` names it: an approved one whose header has no variable and whose buttons need no value.
parametersNoThe body's values for everyone, keyed as the template's `body.parameters` (`"1"` or `"first_name"`).
recipientsYesThe numbers it goes to, within the 1 MB body; a number listed twice gets one message.
connection_idYesThe WhatsApp number it goes from: one of the agent's connections (`listConnections`).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (destructiveHint true, openWorldHint true), the description discloses the 201/sending response contract, background delivery surfaced via listBroadcastRecipients, per-recipient conversation creation, the 10-requests-per-minute shared template budget, plan gating, de-duplication of repeated numbers, daily-limit refusal, and the MCP-level idempotency key for timeout retries. These are exactly the operational traits an agent needs before issuing an irreversible bulk send.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The core action and scope are front-loaded in the first sentence, and subsequent paragraphs are organized around invocation, template constraints, and errors. It is dense and long, but each cluster of sentences carries distinct operational information; a minor trim of stacked 422 cases would sharpen it further.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter mutation with nested objects, no output schema, and destructive semantics, the description covers invocation, response shape, delivery tracking, template eligibility, limits, and error codes. Nothing an agent needs in order to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, and the description meaningfully adds to it: it explains that `parameters` fills everyone's body variables while a recipient's own `parameters` override them, that the header keeps its approved sample, and that no button receives a value. That semantic layering of the two parameter fields is not evident from the schema alone.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a concrete verb and resource: 'Sends one approved template from one of the agent's WhatsApp numbers to many numbers, right away.' It explicitly contrasts with the sibling sendWhatsAppTemplate ('send those one by one') and names the follow-up tool listBroadcastRecipients, so an agent can distinguish it from other send tools without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit when-to-use and when-not-to-use rules: use sendWhatsAppTemplate for templates with header variables or per-send buttons; only approved templates can be broadcast; plans with broadcasts only. Failure modes (422 template_not_broadcastable, template_not_found, template_not_approved, invalid_request) each come with a routing condition.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources