LINE Messaging API errors, explained one by one
Last verified against LINE Developers - Messaging API reference (error responses)
LINE does not use numeric error codes the way Meta or Telegram do. A failed Messaging API call gives you exactly two things: an HTTP status code and a JSON body whose message property carries a documented English string such as Invalid reply token or You have reached your monthly limit. When the problem is inside your request body, the response adds a details array, and each element pins the fault to a location: details[].property names the JSON field or query parameter (for example messages[0].text), and details[].message says what is wrong with it (May not be empty). The reference states the array is omitted entirely when it would be empty, so never assume it exists. Every response also carries an X-Line-Request-Id header, which is the identifier to quote if you contact LINE support.
To read LINE errors correctly you also need the platform's core sending model. Replying to a webhook event with its single-use replyToken is free and does not touch your monthly quota; pushing a message on your own initiative (push, multicast, narrowcast, broadcast) consumes the quota attached to your LINE Official Account's subscription plan. That split explains the errors that surprise people most: Invalid reply token appears when the one-minute, one-use token contract is broken, and You have reached your monthly limit. appears when paid-side sending runs out, even though replies keep working. The pages below cover every error message and status LINE documents for the Messaging API, with the literal strings, example bodies, and concrete fixes. Statuses and message strings are quoted from the official reference; where LINE templates in variable text, the varying part is marked.
How to read a LINE error
HTTP/1.1 400 Bad Request
x-line-request-id: 5b59509c-c57b-11e9-aa8c-2a2ae2dbcce4
{
"message": "The request body has 2 error(s)",
"details": [
{
"message": "May not be empty",
"property": "messages[0].text"
},
{
"message": "Must be one of the following values: [text, image, video, audio, location, sticker, template, imagemap]",
"property": "messages[1].type"
}
]
}All 23 codes
Jump to: 400 / 409 / 413: request body, tokens and payload (9) · 401 and channel access token errors (3) · 403 / monthly quota: plan and permission limits (2) · 404 / 410: recipients, profiles and content (5) · 429: rate limits and concurrency (2) · Webhook configuration errors (1) · 500: LINE-side failures (1)
400 / 409 / 413: request body, tokens and payload
| Code | Title |
|---|---|
400 | Invalid reply token Invalid reply token |
400 | The request body has X error(s) The request body has X error(s) <detail varies> |
400 | The property, XXX, in the request body is invalid The property, XXX, in the request body is invalid (line: XXX, column: XXX) <detail varies> |
400 | The request body could not be parsed as JSON The request body could not be parsed as JSON (line: XXX, column: XXX) <detail varies> |
400 | The content type, XXX, is not supported The content type, XXX, is not supported <detail varies> |
409 | The retry key is already accepted The retry key is already accepted |
413 | Payload Too Large (request over 2MB) Request exceeds the max size of 2MB. Make the request smaller than 2MB and try again. |
415 | Unsupported Media Type <detail varies> |
400 | Invalid audience group id Invalid audience group id: {audience ID} <detail varies> |
401 and channel access token errors
| Code | Title |
|---|---|
400 | The access token expired invalid_request / The access token expired |
400 | invalid_client (invalid client_id / client_secret) invalid_client / invalid client_id <detail varies> |
401 | Authentication failed Authentication failed due to the following reason: XXX <detail varies> |
403 / monthly quota: plan and permission limits
| Code | Title |
|---|---|
403 | Access to this API is not available for your account Access to this API is not available for your account |
429 | You have reached your monthly limit. You have reached your monthly limit. |
404 / 410: recipients, profiles and content
| Code | Title |
|---|---|
400 | Failed to send messages Failed to send messages |
403 | Not enough recipients (narrowcast) Not enough recipients <detail varies> |
404 | Not found (profile: user blocked or not a friend) Not found |
404 | not found (content by message ID) not found |
410 | The content is gone The content is gone |
429: rate limits and concurrency
| Code | Title |
|---|---|
429 | Too Many Requests (rate limit) The API rate limit has been exceeded. Try again later. |
429 | Too Many Requests (concurrent audience operations) <detail varies> |
Webhook configuration errors
| Code | Title |
|---|---|
400 | Invalid webhook endpoint URL Invalid webhook endpoint URL |
500: LINE-side failures
| Code | Title |
|---|---|
500 | Internal Server Error <detail varies> |
LINE guides and tools
Other platforms
Frequently asked questions
Does the LINE Messaging API use numeric error codes?
No. LINE returns a plain HTTP status code (400, 401, 403, 404, 409, 410, 413, 415, 429, 500) plus a JSON body with a documented message string such as "Invalid reply token" or "Failed to send messages". Validation problems additionally include a details array where details[].property names the offending JSON field and details[].message describes the fault. There is no separate platform-specific code number to look up.
Why do I get "Invalid reply token" from the reply endpoint?
The reference gives two reasons: the reply token was already used, or it expired. Reply tokens can only be used once and must be used within one minute of receiving the webhook; use beyond one minute isn't guaranteed to work. Sending two reply calls for one event, replaying stored tokens, or replying after slow processing all trigger it. Switch to a push message when you miss the window.
Are reply messages free on the LINE Messaging API?
Yes. The pricing documentation lists reply messages under "sending methods that are not counted as message count", while push, multicast, narrowcast, and broadcast messages are counted against the monthly quota of your LINE Official Account's subscription plan. Messages are counted per recipient, and sends to users who blocked you or to non-existent user IDs are not counted.
What does HTTP 429 mean on the LINE Messaging API?
Four documented causes: you exceeded the per-endpoint rate limit, you exceeded the limit on concurrent audience operations, you used up your plan's free messages, or you hit your configured cap of additional paid messages. The body distinguishes them: "The API rate limit has been exceeded. Try again later." is throughput, while "You have reached your monthly limit." is quota. The fixes are opposite - back off versus upgrade your plan.
What is the rate limit for sending push messages on LINE?
The reference sets 2,000 requests per second per channel for the push and reply endpoints (the general "other API endpoints" tier). Multicast is 200 requests per second, broadcast and narrowcast are 60 requests per hour, and issuing short-lived channel access tokens is 370 requests per second. Limits are enforced per channel with a token bucket algorithm, not a fixed reset window.
Why does getting a LINE user profile return 404 Not Found?
The status codes table lists four reasons: the user ID doesn't exist, the user hasn't consented to profile access, the user never added your LINE Official Account as a friend, or the user blocked it after adding it. A block therefore surfaces as 404 with body {"message":"Not found"} - there is no explicit "blocked" error, so treat profile 404s on previously working IDs as a likely block.
How does X-Line-Retry-Key idempotency work on LINE?
You generate a UUID yourself and send it in the X-Line-Retry-Key header of a push, multicast, narrowcast, or broadcast request. If LINE already accepted a request with that key, the retry returns 409 Conflict with "The retry key is already accepted" and an x-line-accepted-request-id header instead of sending duplicates. LINE manages keys for 24 hours; after that, the same key is treated as a brand-new request.
How long is a LINE reply token valid?
The documented rule is one minute from receiving the webhook, and "use beyond one minute isn't guaranteed to work." Tokens in redelivered webhooks can also be used within one minute of the redelivery, unless the original token was already used or 20 minutes have passed since the event occurred. LINE explicitly warns the time limit is subject to change, so reply as soon as possible.
What does "Access to this API is not available for your account" mean?
The error messages table says it "appears when calling an API that you do not have permission to use." Several capabilities are gated: narrowcast attribute targeting requires a target reach of at least 100 friends, and Identifiers for Advertisers (IFA) audiences require a completed corporate application. It is an account or plan entitlement problem, not a bug - the same request works on an account that has the capability.
Does LINE retry webhooks my server failed to receive?
Only if you enable webhook redelivery in the LINE Developers Console (it is off by default). LINE then re-sends webhooks your server didn't answer with a 2xx status, for an undisclosed number of attempts at undisclosed intervals. Redelivered events keep the same webhookEventId and reply token but set deliveryContext.isRedelivery to true, so deduplicate by event ID and expect out-of-order arrival.
Run your LINE bot without babysitting error codes
Conferbot manages the connection, tokens, webhooks and retries, and shows failures as readable status.