OpenClaw on LINE
The Messaging API plugin, the webhook contract, pairing, quotas, and what LINE cannot do
LINE connects to OpenClaw through the LINE Messaging API: the plugin runs as a webhook receiver on the Gateway and authenticates with your channel access token and channel secret. It is an official plugin installed separately, and the docs’ status line is exact about the surface: direct messages, group chats, media, locations, Flex messages, template messages and quick replies are supported; reactions and threads are not. Here is the setup, the webhook contract that makes delivery durable, access control, what LINE does to a message, the quota rule, and the troubleshooting list.
Setup
- Install the plugin, then in the LINE Developers Console create or pick a Provider, add a Messaging API channel, copy the channel access token and channel secret, and enable the webhook.
- The webhook URL is the Gateway’s LINE webhook path over HTTPS, which is required; a custom path is a config key. The Gateway answers LINE’s signed verification request, an empty events list.
- Signature verification is an HMAC over the raw body, so OpenClaw applies a strict 64 KB pre-auth body limit and a read timeout, and it processes events from the verified raw bytes, ignoring anything middleware rewrote.
- Signed inbound events enter the durable ingress queue before the 200; if durable persistence fails the request returns a 500 rather than acknowledge an event that could be lost, and delivery is at least once across the queue-to-agent boundary, with message events deduplicated by LINE message ID.
Missing quota is unknown, not unlimited.
The delivery contract
The durable 200 carries an acceptance header so a reverse proxy can tell it from a generic one. Events are serialised per conversation lane, group, room or user, with a cap of eight concurrent deliveries across lanes. A failed delivery retries with exponential backoff from one second and dead-letters after the eighth attempt, LINE opting out of the generic 24-hour floor so a poison event cannot block its lane for a day; unparseable payloads, deliveries that already committed side effects, and authentication failures dead-letter immediately. A five-minute stall watchdog covers only the window between claim and adoption, so a long agent turn is never interrupted, a crash-recovery sweep reclaims claims whose Gateway process is gone, and a duplicate suppression window keeps completed and failed records for thirty days or the most recent 4,096 per account. The 500 only helps if LINE re-sends, which needs webhook redelivery enabled in the console and is best effort even then.
Access, messages, quotas
- Direct messages default to pairing: unknown senders get a code and are ignored until approved. Policies are pairing, allowlist, open or disabled for DMs and allowlist, open or disabled for groups, with per-group overrides, and quoting one of the bot’s own messages counts as addressing it. IDs are case-sensitive: U, C or R followed by 32 hex characters.
- Text is chunked at 5,000 characters, Markdown is stripped with code blocks and tables converted into Flex cards, streaming is buffered, the loading animation runs only in one-to-one chats, media downloads are capped at ten megabytes by default, and several images picked in one action arrive as one turn. Native quote replies are off by default and limited to messages whose quote token the running Gateway still holds, the most recent 500 per account.
- Block streaming is off by default, and the docs say why: each block is a separate message, and LINE counts messages against the channel’s monthly quota. Pushes refused with a 429 are read with the probe, whose quota carries used and limit; ordinary reply-token messages do not consume the monthly allowance, pushes do.
OpenClaw pairing explains the approval flow the DM default uses, and OpenClaw on Telegram is the channel the docs call the fastest to connect if LINE is not your market.
Rich messages and troubleshooting
Buttons blocks render as Flex controls and select blocks as quick replies, at most thirteen per message, and a direct-chat question with two to four options becomes tappable controls that answer it. Card images must be HTTPS and fit LINE’s 30 KB bubble and 50 KB carousel limits; outbound videos need a preview image, and media URLs must be public HTTPS of at most 2,000 characters, with private targets rejected. When nothing arrives, the probe reports whether the webhook is registered and switched on, which OpenClaw cannot set for you; when messages are silently skipped, the dead-letter list shows the reason, and an event whose side effects already committed must never be resubmitted, because that repeats the visible reply.
On Diali
LINE is not among the channels Diali connects today: the ones we run are WhatsApp, Telegram, Discord, Slack, Mattermost, Matrix, SMS and voice, and a self-run instance is where this plugin lives for now. Connect your first channel in five minutes shows our connect flow, Hosted OpenClaw on Diali is the assistant and Diali security describes the boundary.
- A webhook receiver with a durable queue in front of the agent.
- Pairing by default, and IDs are case-sensitive.
- Every block is a message, and messages are the quota.
Stop reading about it, build one
Set up an agent, pick a channel, and have it working inside the app you already keep open.
