- LINE setup: Create the Official Account, enable the Messaging API, and collect the Channel Secret, Channel Access Token, and Destination ID.
- Artemis channel configuration using those three values, then copy the generated webhook URL.
- Webhook configuration in LINE: Register the webhook URL, verify it, and switch delivery on.
- Two consoles, two halves of the job: LINE splits the work between LINE Official Account Manager and the LINE Developers Console. Sign in to both with the same account, because the Developers Console asks first-time users to register a developer profile with a name and email, and an account that skips that step can’t see the channel it just created.
- Official Account Manager creates the channel, not the Developers Console: LINE removed the ability to create Messaging API channels directly in the Developers Console in September 2024. Enabling the Messaging API on the Official Account creates the channel.
- Provider selection is permanent: You can’t change or remove the provider afterwards, and a person receives a different user ID under each provider, so moving an account later would break every stored user reference.
- The Destination ID is not shown in either console: It comes from an API call. Three identifiers that are shown look plausible and none of them route. See How Artemis routes LINE events.
Prerequisites
- A LINE Business ID, registered with an existing personal LINE account or with an email address. See LINE setup.
- The admin role on the Official Account and on the Messaging API channel. Several steps hide their controls from lower roles rather than reporting a permission error.
- The admin role on the provider you intend to use, if you plan to select an existing one. A provider only appears in the selection list when your account holds that role on it.
- Artemis project access with permission to open Deployments -> Channels, and a deployed agent in the environment you intend to bind.
How Artemis routes LINE events
LINE sends every event for a channel to one URL, so Artemis identifies the connection from the payload rather than the path. Each webhook body carries adestination field holding the bot’s user ID, and Artemis resolves the connection from that value before it verifies the signature.
Three LINE identifiers look plausible in the Destination ID field and none of them route. The Channel ID on the Basic settings tab is numeric. The Bot basic ID on the Messaging API tab starts with
@. Your user ID, also on the Basic settings tab, is your own personal LINE account, not the bot’s. The correct value comes from an API call, covered in LINE setup.
LINE setup
Complete all of this in LINE before you open Artemis. Start at the beginning even if someone has already created an Official Account, because enabling the Messaging API is what creates the channel you’ll configure.1
Register a LINE Business ID
LINE accounts for business sit behind a Business ID, which you can register with an existing personal LINE account or with an email address.
- Go to account.line.biz and register a Business ID, if your organization doesn’t already have one.
- Use an account your team can keep. This identity carries the admin role for everything that follows.
2
Create the Official Account
- Complete LINE’s Official Account entry form with your business details. Submitting it creates the account.
- Open LINE Official Account Manager and confirm the new account appears in your list before you continue.
3
Enable the Messaging API
- In Official Account Manager, select the account.
- Go to Settings -> Messaging API and enable the Messaging API. This is what creates the channel that Artemis connects to.
4
Choose the provider carefully
LINE asks you to pick a provider, which is the organization that owns the channel. Two constraints make this a decision rather than a formality.You can’t change or remove the provider afterwards. And a person receives a different user ID under each provider, so moving an account later would break every stored user reference. An existing provider only appears in the list when your account holds the admin role on it, so a provider that seems to be missing is usually a permissions problem rather than an absent one.Pick the provider that owns your related channels, and avoid putting unrelated services under one provider for convenience.
5
Turn off LINE's automatic replies
A new channel arrives with greeting messages and auto-reply messages enabled, which means a person gets one LINE-managed response and one agent response to the same message.Reach the settings from either console:
- In Official Account Manager, open Settings -> Response settings.
- Or in the Developers Console, open the channel’s Messaging API tab, where Greeting messages and Auto-reply messages each carry an Edit link that opens Official Account Manager at the right place.
6
Copy the Channel Secret from Basic settings
All three credential values live in the Developers Console, spread across two tabs of the same channel.
- Sign in at developers.line.biz/console.
- Select your provider, then select the Messaging API channel.
- Open the Basic settings tab and copy Channel secret. You need the admin role on the channel to see it.
7
Issue a Channel Access Token from the Messaging API tab
Open the Messaging API tab. LINE offers four token types, and this screen issues only one of them.
The long-lived token is the one with an Issue control on this tab. The other three come from API calls rather than the console, so choosing them means building issuance into your own tooling.LINE recommends the v2.1 token, and that recommendation costs you a rotation schedule. Pick the long-lived token if you’d rather not build that, and accept that a single indefinite credential carries more risk. Whichever you choose, copy the value straight into your secret manager.
8
Get the Destination ID from Get bot info
The console never shows this value, so you call for it.
-
Use LINE’s Get bot info endpoint with the channel access token you just issued.
-
Copy the
userIdfrom the response.
U and matches the destination field LINE puts in every webhook for this channel. Run this from a secure terminal rather than a shared one, since the command carries your token.9
Note the QR code for later
While you’re on the Messaging API tab, find the QR code or add-friend link. You’ll need it to test, and it’s easier to grab now than to come back for.
Artemis channel configuration
Create the connection before you verify the webhook in LINE. LINE’s verification request has to resolve to an active connection and authenticate with that connection’s Channel Secret, so an unsaved connection fails verification.- Open Artemis and select the project.
- Go to Deployments -> Channels -> LINE -> + New. The New LINE Connection dialog opens.
-
Configure the following fields:
- Select Create.
- Open the connection and copy the Webhook URL from the Overview tab. You need it for the next section.
Webhook configuration in LINE
LINE separates saving the URL from switching delivery on, so a verified webhook can still deliver nothing. Complete all three parts, in the Developers Console on the channel’s Messaging API tab.1
Paste the webhook URL
- Find Webhook settings.
- Select Edit under Webhook URL.
- Paste the Artemis endpoint exactly as shown and select Update.
2
Select Verify and require Success
Select Verify. LINE posts an event-free payload to the endpoint, and Artemis responds once it has resolved the connection and verified the signature. LINE reports Success when this works.Treat anything else as a stop. A timeout, a non-200 response, a TLS error, and a signature failure each point somewhere different, and continuing past one means debugging later with live users watching.
3
Enable Use webhook
Turn on Use webhook.This is the step people miss. Saving a verified URL without this toggle leaves the channel looking correctly configured while message events never reach Artemis.
4
Decide about webhook redelivery
Enable redelivery only when your operations policy requires retries after a non-2xx response.LINE can deliver the same webhook more than once when redelivery is on, and it can change event order during redelivery. Your agent logic has to tolerate both, so rely on event IDs rather than arrival order before you turn this on.
5
Restrict API access by IP, if you chose a long-lived token
The channel’s Security tab accepts a list of IP addresses, individually or in CIDR notation, that may call the LINE Platform with a long-lived token.This narrows the blast radius of an indefinite credential considerably, so it’s worth doing whenever you pick that token type. LINE covers the setting under restrict who can call the API. It doesn’t apply to the other three.
Validation checklist
Verify the connection
Artemis has no synthetic test for this channel, so a real conversation is the only end-to-end proof.- Add the Official Account as a friend by scanning the QR code or using the add-friend link on the Messaging API tab. Test from an ordinary LINE account rather than an identity that exists only as a console administrator, because the two behave differently.
- Send a short message you can search for later, and confirm the agent replies in the same chat.
- Count the replies. Two responses to one message means greeting messages or auto-reply messages are still enabled, not that the agent ran twice.
- Send each input type your agent supports, and confirm its authored behavior for each. Receiving a media event isn’t the same as handling it, so test the authored path rather than only the delivery.
- Test groups only if you need them. Enable Allow bot to join group chats in Official Account Manager, invite the bot, then message or mention it. Confirm sessions stay scoped to the LINE source, so a group conversation and a one-to-one conversation with the same person don’t merge.
Secure the connection
Both LINE credentials are secrets, and they do opposite jobs. The Channel Secret authenticates what comes in; the Channel Access Token authorizes what goes out. Artemis computes HMAC-SHA256 over the unchanged raw request body and compares it with theX-Line-Signature header. Any proxy or middleware in front of Artemis has to leave the signed body untouched, because a single changed byte fails verification as surely as a wrong secret does.
Rotation invalidates immediately on both credentials. Reissuing a Channel Secret kills the old secret, and reissuing a long-lived access token kills the previous token unless you use the 24-hour extension. Coordinate the Artemis update with the provider-side change rather than doing them hours apart, and revoke any token you suspect someone has copied, because a compromised token can broadcast to every friend of the Official Account.
Keep both values out of browser code, screenshots, tickets, and source control, and update Artemis the moment LINE reissues or revokes either one.
Use distinct providers or channels for development and production, or at minimum distinct credentials and connections. Pointing two environments at one webhook mixes test traffic into real conversation history.
Manage the channel connection
Opening a connection shows four tabs. The delete control sits beside the connection name.- Overview
- Credentials
- Configuration
- Deployment
Connection Summary reports the connection’s state and identity.
Setup Instructions shows the Webhook URL to register in the Developers Console and the Destination ID this connection matches events to, each with a copy control. Check the Destination ID here first when messages arrive and no session appears.
Troubleshoot connection issues
LINE reference
Use these LINE pages and consoles when you need detail beyond what this article covers.
Related articles: