Test a LINE channel's connection.
POST/api/v1/chat-channels/{chat_channel_id}/testchat_channels:write
Checks the stored credentials and that the access token belongs to the channel's LINE account, then points LINE's webhook at the Portal and reports its status (webhook_status), without sending a message. A channel that is not connected is answered 200 with is_connected false and the reason. Needs Test Chat Channels.
| Scope | chat_channels:write (sensitive) |
| Asynchronous | No |
| MCP tool | test_chat_channel |
| Portal permissions | test_chat_channels |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
chat_channel_id | path | string | Required | |
Docwize-Version | header | string (date) | Optional | |
Idempotency-Key | header | string | Optional | max 255 |
Responses
| Status | Description | Body |
|---|---|---|
200 | Success. | application/json ChatConnectionTest or object |
400 | invalid_version | application/problem+json Problem |
401 | token_expired, unauthenticated | application/problem+json Problem |
403 | forbidden, insufficient_scope, token_owner_inactive | application/problem+json Problem |
404 | not_found | application/problem+json Problem |
405 | method_not_allowed | application/problem+json Problem |
406 | not_acceptable | application/problem+json Problem |
409 | idempotency_in_progress | application/problem+json Problem |
421 | wrong_region | application/problem+json Problem |
422 | idempotency_key_reused, validation_failed | application/problem+json Problem |
500 | internal_error | application/problem+json Problem |
503 | tenant_unavailable, unavailable | application/problem+json Problem |
504 | timeout | application/problem+json Problem |
Errors
The problem codes this operation can answer with. Each code links to its page.
Schemas
ChatConnectionTest
| Field | Type | Required | Description |
|---|---|---|---|
display_name | string or null | Required | The bot account's name on LINE. |
failure | string or null | Required | Why it is not connected: missing_channel_secret, missing_access_token or the reason LINE gave; null when connected. |
is_connected | boolean | Required | True when the stored credentials work and belong to the channel's LINE account. |
provider_user_id | string or null | Required | LINE's own id of the channel's bot account. |
webhook_detail | string or null | Required | |
webhook_status | string or null | Required | active (events reach the Portal), use_webhook_off (the LINE Console switch is off), unreachable (LINE could not deliver; webhook_detail has its reason), other_endpoint (the channel already sends elsewhere and was left alone; webhook_detail has that URL) or unavailable (could not be checked: set it by hand). Open. |
webhook_url | string or null | Required | The webhook the Portal pointed the channel at. |