Getting started with LIFF

Table of contents

To start using LIFF, you must first create a channel on the LINE Developers console.

What's a channel?

A channel is a communication path for using the functions provided by the LINE Platform in the services developed by the provider. To use the LINE Platform, create a channel and associate your service with the channel. Channels must have a name, description, and icon image. When a channel is created, a unique channel ID is issued to identify the channel.

You can use a LIFF app with both LINE Login channels and Messaging API channels.

When using the LIFF server API on a LINE Login channel, you need to issue a channel access token as described in 6. Prepare a channel access token.

Note: Use of LIFF is not supported on channels associated with services other than the LINE Login and Messaging API.

Creating a channel

1. Log in to the console

Log in to the LINE Developers console with the email address and password of your LINE account.

Note: If you do not have a LINE account with a registered email address, download LINE, then go to Settings > Account to register your email address.

Log in to console

LINE Login dialog

2. Register as a developer (only on first login)

Enter your name and email address to create a developer account on the LINE Developers console.

Developer registration screen

3. Create a new provider

Enter a name for the provider. The provider is the entity that offers your app. For example, you can use your own name or the name of your company.

Provider creation screen

4. Create a channel

Enter the required information for your channel. "LINE" or a similar string cannot be included in the channel name.

Channel creation screen

5. Confirm

Confirm that your channel was created.

Console home

6. Prepare a channel access token

On a Messaging API channel

A channel access token is also issued when a channel is created. Check the value in the "Channel access token (long-lived)" field in the "Messaging settings" section in the "Channel settings" page. The validity period of this token is so long that you do not need to consider expiration.

On a LINE Login channel

Issue a channel access token by calling the API. To do so, send an HTTP POST request to the /v2/oauth/accessToken endpoint. The validity period of a channel access token issued by the API is 30 days.

Example request

curl -v -X POST https://api.line.me/v2/oauth/accessToken \
-H "Content-Type:application/x-www-form-urlencoded" \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'client_id={channel ID}' \
--data-urlencode 'client_secret={channel secret}'

A channel access token is returned on success.

Example response

{
  "access_token":"{channel access token}",
  "expires_in":2592000,
  "token_type":"Bearer"
}

For more information, see Issue channel access token in the Messaging API reference documentation.

Next steps

You have now created a channel for your LIFF app. Next, deploy the sample LIFF app or develop your LIFF app.