Skip to main content
Glama
acquo

LINE Bot MCP Server (SSE Support)

by acquo

broadcast_flex_message

Send customizable flex messages to all LINE Official Account users using bubble or carousel layouts for rich content delivery.

Instructions

Broadcast a highly customizable flex message via LINE to all users who have added your LINE Official Account. Supports both bubble (single container) and carousel (multiple swipeable bubbles) layouts. Please be aware that this message will be sent to all users.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
messageYes

Implementation Reference

  • The implementation of the broadcast_flex_message handler, which uses the LINE MessagingApiClient to broadcast the message.
    async ({ message }) => {
      try {
        const response = await this.client.broadcast({
          messages: [message as unknown as messagingApi.Message],
        });
        return createSuccessResponse(response);
      } catch (error) {
        return createErrorResponse(
          `Failed to broadcast message: ${error.message}`,
        );
      }
    },
  • The registration method for the broadcast_flex_message tool using the McpServer.
    register(server: McpServer) {
      server.tool(
        "broadcast_flex_message",
        "Broadcast a highly customizable flex message via LINE to all users who have added your LINE Official Account. " +
          "Supports both bubble (single container) and carousel (multiple swipeable bubbles) layouts. Please be aware that " +
          "this message will be sent to all users.",
        {
          message: flexMessageSchema,
        },
        async ({ message }) => {
          try {
            const response = await this.client.broadcast({
              messages: [message as unknown as messagingApi.Message],
            });
            return createSuccessResponse(response);
          } catch (error) {
            return createErrorResponse(
              `Failed to broadcast message: ${error.message}`,
            );
          }
        },
      );
    }

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.1-local

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations provided, the description carries full burden. It discloses the broadcast nature ('sent to all users') and mentions support for bubble/carousel layouts, but lacks details about permissions, rate limits, confirmation steps, or what happens on failure. The warning about broadcasting is helpful but incomplete for behavioral transparency.

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

Conciseness5/5

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

Two sentences with zero waste. First sentence establishes purpose and capabilities, second provides crucial behavioral warning. Every word earns its place, and the most important information (broadcast nature) is appropriately front-loaded.

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

Completeness3/5

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

For a broadcast tool with no annotations, no output schema, and complex nested parameters, the description is moderately complete. It covers the broadcast scope and basic layout options but misses details about authentication requirements, error handling, response format, and the full complexity of the flex message structure.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate. It mentions bubble/carousel layouts which correspond to the 'type' enum in the nested schema, but doesn't explain the 'altText' parameter or the complex 'contents' structure beyond basic layout types. This leaves significant gaps in parameter understanding.

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 clearly states the specific action ('broadcast'), resource ('flex message'), and platform ('LINE to all users who have added your LINE Official Account'). It distinguishes from siblings like 'broadcast_text_message' by specifying the message type and from 'push_flex_message' by indicating broadcast vs targeted push.

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool: for sending flex messages to all LINE Official Account users. It implicitly distinguishes from sibling tools like 'broadcast_text_message' (text vs flex) and 'push_flex_message' (broadcast vs targeted), though it doesn't explicitly name alternatives or state when not to use it.

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