Line API

Social / OAuth Advanced HTTPS
Varies by plan (check documentation)

Overview

The LINE API lets you integrate LINE Login, messaging, and social sharing into your apps and websites for users in Japan, Thailand, Taiwan, and other markets where LINE is the dominant messaging platform. It uses OAuth 2.0 for authentication and supports both web login and in-app messaging via the Messaging API. Register your app at developers.line.biz to get your channel credentials.

💡

Beginner Tip

LINE has two separate products: LINE Login for authenticating users and the Messaging API for chatbots. Start with LINE Login if you want social sign-in; use the Messaging API if you want to send messages to users via a LINE Official Account.

Available Data

stock price and symbol
open/close/high/low values
trading volume
market cap
historical price data

Example Response

JSON Response
{
  "status": "success",
  "data": {
    "result": "Data from Line",
    "description": "Line Login, Share on Line, Social Plugins and more",
    "timestamp": "2025-01-15T10:00:00Z"
  }
}

Field Reference

userId The unique LINE user ID for the authenticated user
displayName The LINE display name of the user
pictureUrl URL of the user LINE profile picture
statusMessage The custom status message set by the user on LINE
language The LINE app language setting of the user such as ja, th, or en

Implementation Example

const url = "https://developers.line.biz/";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "Authorization": "Bearer YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

401: The access token expired LINE access tokens have a 30-day expiry
Use the refresh token to get a new access token via POST to https://api.line.me/oauth2/v2.1/token with grant_type=refresh_token
403: Insufficient permission The OAuth scope granted does not include the requested resource
Check that you requested the needed scopes such as profile and openid in your LINE Login configuration at developers.line.biz
Channel access token vs user access token confusion Using a channel access token where a user token is required or vice versa
Channel access tokens are for Messaging API bot operations; user access tokens from LINE Login are for accessing user profile data

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 10/20
🔒 Security 15/15
🛠 Developer XP 3/20
✓ Reliability 10/15

Partially tested on Apr 5, 2026

Technical Specifications

Auth OAuth
HTTPS REQUIRED
CORS UNKNOWN
Category Social
Difficulty Advanced
Verified: 2026-04-04

Similar APIs

View All →