# LINE Official Account Scraper (`parsebird/line-official-account-scraper`) Actor

Scrape LINE Official Account profiles from page.line.me: name, LINE ID, friend count, badge, phone, address, opening hours, websites, social links, coupons and related accounts. Export as JSON, CSV, or Excel.

- **URL**: https://apify.com/parsebird/line-official-account-scraper.md
- **Developed by:** [ParseBird](https://apify.com/parsebird) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.49 / 1,000 line accounts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### LINE Official Account Scraper

LINE Official Account Scraper extracts public profile data from [LINE Official Account](https://page.line.me/914aycak) pages on page.line.me: name, LINE ID, premium ID, friend count, badge, phone, address with map coordinates, opening hours, websites, social links, coupons, and the related accounts LINE recommends.

<table><tr>
<td style="border-left:4px solid #06C755;padding:12px 16px;font-weight:600">
Paste page.line.me links, add-friend links, lin.ee short links, or plain @IDs, and get one analysis-ready row per LINE Official Account with up to 48 fields, from friend count and badge to weekly opening hours, payment methods, coupons, and showcase items.
</td>
</tr></table>

##### Copy to your AI assistant

Copy this block into ChatGPT, Claude, Cursor, or any LLM to start using this actor.

```text
Apify Actor parsebird/line-official-account-scraper scrapes public LINE Official Account profiles from page.line.me. Call it with the apify-client package: client.actor("parsebird/line-official-account-scraper").call(run_input={"mode": "account_details", "accountUrls": ["https://page.line.me/914aycak", "@076mimrd"]}). Inputs: mode (string: "account_details" = one full profile row per link, default; "related_accounts" = one row per account LINE recommends on that profile), accountUrls (array of strings, required: page.line.me links, line.me/R/ti/p/@id add-friend links, lin.ee short links, basic IDs like @914aycak, or premium IDs like @linefriends_hk_mo), maxResults (int, min 1, default 100: related accounts kept per link; LINE shows up to about 21). Output for account_details: result_type, input, status ("success" or "failed"), account_page_id, line_id, premium_line_id, url, add_friend_url, qr_code_url, name, description, country_code, managing_country_code, badge_type, provider_name, image_url, background_image_url, friend_count, phone, address, postal_code, province, city, street_address, latitude, longitude, nearest_stations, website_urls, websites, social_links, business_hours_note, business_hours (day, status, hours), price_range, price_currency, payment_methods, seats, facilities, smoking_policy, services, about, announcements, coupons, showcase_items, faq, reward_cards, has_reservation, profile_sections, error_code, error_message, scraped_at. Output for related_accounts: source_line_id, source_name, rank, line_id, url, add_friend_url, qr_code_url, name, badge_type, image_url, friend_count. Failed rows (error_code INVALID_INPUT, NOT_FOUND, PROFILE_NOT_PUBLIC, NO_RELATED_ACCOUNTS, REQUEST_FAILED) are free. API docs: https://apify.com/parsebird/line-official-account-scraper/api. Get a token: https://console.apify.com/settings/integrations
```

### What is LINE Official Account Scraper?

**LINE Official Account Scraper** is a data extraction tool for **LINE Official Accounts** (LINE公式アカウント, LINE OA), the business accounts that brands, shops, restaurants, and salons run inside the [LINE](https://line.me) messenger. Every account with a public profile has a web page on **page.line.me**. The Actor reads those pages and returns clean JSON instead of the screen you see in the LINE app.

It works as a **LINE Official Account API alternative**: you don't need a LINE login, a LINE Business ID, or Messaging API access to collect public profile data such as **friend counts, contact details, and opening hours**.

The easiest way to try it: open the **Input** tab, keep the two sample links, and click **Start**. You get two full LINE profiles in a few seconds.

### What can LINE Official Account Scraper do?

- 👤 **Scrape LINE Official Account details**: name, status message, basic LINE ID, premium ID, badge type (certified or premium), country, operating company, profile and cover images, and friend count.
- 📍 **Get business contact data**: phone number, full address split into postal code, prefecture or province, city and street, latitude and longitude, nearest stations, websites, and social media links (Instagram, X, YouTube, TikTok, Facebook).
- 🕒 **Collect opening hours and shop info**: day-by-day opening hours, the business-hours note, price range, accepted payment methods (cards, PayPay, d払い, and more), seats, facilities, smoking policy, and takeout or delivery.
- 🎟️ **Read profile content**: coupons with validity dates, showcase items with prices and links, announcements, FAQ, the "about" text, and reward card goals.
- 🔗 **Find related LINE accounts**: switch to **Related accounts** mode to list the accounts LINE recommends on each profile, with rank, name, badge, and friend count. Use it to discover competitors and similar businesses.
- 🧩 **Use any link format**: page.line.me links, `line.me/R/ti/p/@id` add-friend links, `lin.ee` short links, or plain `@IDs`. Premium IDs and basic IDs of the same account are merged so you don't pay twice.

On the Apify platform you also get [scheduled runs](https://docs.apify.com/platform/schedules) to track friend counts over time, a full [REST API](https://docs.apify.com/api/v2), [integrations](https://apify.com/integrations) with Make, Zapier, n8n, Google Sheets, and webhooks, and export to JSON, CSV, Excel, XML, or HTML.

### What data can you extract from LINE Official Accounts?

| Field | Description |
|-------|-------------|
| `name` / `description` | Account name and the status message under it |
| `line_id` / `premium_line_id` | Basic LINE ID (`@914aycak`) and premium ID (`@linefriends_hk_mo`) if the account bought one |
| `account_page_id` | LINE's internal account page ID |
| `friend_count` | Number of LINE users who added the account as a friend |
| `badge_type` | `CERTIFIED` (blue badge, verified account) or `PREMIUM` (green badge, premium account) |
| `country_code` / `provider_name` | Account country and the company that operates it, when shown |
| `image_url` / `background_image_url` | Profile picture and cover image |
| `phone` / `address` / `latitude` / `longitude` | Published phone number, full address, and map location |
| `postal_code` / `province` / `city` / `street_address` / `nearest_stations` | Address parts and nearby train stations |
| `website_urls` / `social_links` | Websites and social media profiles |
| `business_hours` / `business_hours_note` | Opening hours for each weekday and the free-text hours note |
| `price_range` / `payment_methods` / `facilities` / `seats` | Budget, payment options, facilities such as parking or Wi-Fi, and seat count |
| `coupons` / `showcase_items` / `announcements` / `faq` / `about` | Content blocks the account shows on its profile |
| `add_friend_url` / `qr_code_url` | Ready-to-use add-friend link and QR code image |

Every row has the same keys. Values the account doesn't publish are `null` or an empty list. Lists such as coupons and opening hours stay inside their account row instead of creating extra rows.

### How to scrape LINE Official Account profiles

1. Open [LINE Official Account Scraper](https://apify.com/parsebird/line-official-account-scraper) and click **Try for free**.
2. Choose **What to collect**: **Account details** for full profiles, or **Related accounts** for the accounts LINE recommends.
3. Paste your **Account links**, one per line. You can copy a link from the LINE app with **Share**, or use the `@ID` shown under the account name.
4. For related accounts, set **Maximum results per link**.
5. Click **Start** and wait a few seconds.
6. Download the results from the **Output** tab as JSON, CSV, Excel, XML, or HTML, or fetch them through the API.

### Input parameters

| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| `mode` | string | No | `account_details` | `account_details` returns one full profile per link. `related_accounts` returns the accounts LINE recommends on each profile. |
| `accountUrls` | array of strings | **Yes** | — | page.line.me links, add-friend links, lin.ee short links, `@basic` IDs, or `@premium` IDs |
| `maxResults` | integer | No | 100 | Related accounts kept per link (minimum 1). Account details mode always returns one row per link. |

Account details for two shops:

```json
{
    "mode": "account_details",
    "accountUrls": [
        "https://page.line.me/914aycak",
        "@076mimrd"
    ]
}
```

Top 10 related accounts for a profile:

```json
{
    "mode": "related_accounts",
    "maxResults": 10,
    "accountUrls": [
        "https://lin.ee/ZlXu8S6"
    ]
}
```

### Output example

Account details for a hair salon in Osaka (real output; the coupon and showcase lists are shortened to one item each):

```json
{
    "result_type": "account_details",
    "input": "https://page.line.me/076mimrd",
    "status": "success",
    "account_page_id": "1331040139817929",
    "line_id": "@076mimrd",
    "premium_line_id": null,
    "url": "https://page.line.me/076mimrd",
    "add_friend_url": "https://line.me/R/ti/p/@076mimrd",
    "qr_code_url": "https://qr-official.line.me/gs/M_076mimrd_GW.png",
    "name": "Steel",
    "description": "大阪狭山　金剛　美容室　キッズ",
    "country_code": "JP",
    "managing_country_code": "JP",
    "badge_type": "CERTIFIED",
    "provider_name": null,
    "image_url": "https://profile.line-scdn.net/0hTHdGkchQC2dZPhif9rR0MGV7BQouEA0vIQ8RB3prBwdwCBwzZAhGBSk6UQV1ChwzYlkUBH5uBQRy",
    "background_image_url": null,
    "friend_count": 1169,
    "phone": "0723658010",
    "address": "5890011 大阪府大阪狭山市半田2-224-61",
    "postal_code": "5890011",
    "province": "大阪府",
    "city": "大阪狭山市",
    "street_address": "半田2-224-61",
    "latitude": 34.4938905,
    "longitude": 135.5576026,
    "nearest_stations": ["金剛駅"],
    "website_urls": ["http://steel-hc.com/"],
    "websites": [
        {"title": "WebSite", "url": "http://steel-hc.com/"},
        {"title": "Book", "url": "http://steel-hc.com/"}
    ],
    "social_links": [
        {"type": "INSTAGRAM", "url": "https://www.instagram.com/stee1_?igsh=cmI3M21hNHo3ajU1&utm_source=qr"}
    ],
    "business_hours_note": "毎週月曜・火曜定休日",
    "business_hours": [
        {"day": "MONDAY", "status": "open", "hours": ["00:00-00:00"]},
        {"day": "TUESDAY", "status": "open", "hours": ["00:00-00:00"]},
        {"day": "WEDNESDAY", "status": "open", "hours": ["10:00-18:00"]},
        {"day": "THURSDAY", "status": "open", "hours": ["10:00-18:00"]},
        {"day": "FRIDAY", "status": "open", "hours": ["10:00-18:00"]},
        {"day": "SATURDAY", "status": "open", "hours": ["09:00-18:00"]},
        {"day": "SUNDAY", "status": "open", "hours": ["09:00-18:00"]}
    ],
    "price_range": [{"type": "GENERAL", "price": "~ ￥1,000"}],
    "price_currency": "JPY",
    "price_note": null,
    "payment_methods": ["CASH", "VISA", "MASTER_CARD", "JCB", "AMERICAN_EXPRESS"],
    "payment_note": null,
    "seats": 8,
    "facilities": ["PARKINGLOT", "CONSENT", "WIFI"],
    "smoking_policy": null,
    "facilities_note": null,
    "services": [],
    "services_note": null,
    "about": [],
    "announcements": [],
    "coupons": [
        {
            "id": "01KZWN3AR387BDYRYW7GAQMH3D",
            "title": "9月お誕生日クーポン",
            "coupon_type": "FREE",
            "multi_use": false,
            "image_url": "https://oa-coupon.line-scdn.net/0hfrm4f8VgOV1QTSYJKLlGCgoTNz8jOT9VMzUkZTEMOTJjLyUKKVQpXz4lLAY_LxheJEMqbjwyBQY2HBhKKlQuUHQsDhEhKBsKJXstXDYfZCQ4AQh3bEN1aTM2Ozd1ASg",
            "starts_at": "2026-08-31T15:00:00Z",
            "ends_at": "2026-10-31T14:59:00Z",
            "time_zone": "(UTC+09:00) Asia/Tokyo, Seoul"
        }
    ],
    "showcase_items": [
        {
            "section": "店内",
            "title": "親子専用フロア",
            "description": "スティルでは親子専用のフロアがあり、一般のお客様と防音ガラスで仕切られている為、他のお客様に気兼ねなくご利用いただけます。\nキッズスペースではYouTube・Netflix・Disney+が見れたりおもちゃがあるので小さいお子様も退屈せずに遊べ、ママは子供の様子を見ながら安心してオシャレを楽しんでいただけます!!",
            "price": null,
            "link_url": null,
            "image_url": "https://oa-profile-media.line-scdn.net/0hBFf-RVEuHWlbVAObM4FiPg4LExhoNkRtPDNXZCUrGQsALQBsEVEVZBcsHws9ZBptElIOWgtUGSIpAFJDAWtRcyUnQgoAZAVAEmgUcww_AjgTFA"
        }
    ],
    "faq": [],
    "reward_cards": [],
    "has_reservation": false,
    "profile_sections": ["notice", "coupon", "showcase", "basicInfo"],
    "error_code": null,
    "error_message": null,
    "scraped_at": "2026-10-30T11:06:27Z"
}
```

Related accounts mode returns one row per recommended account:

```json
{
    "result_type": "related_accounts",
    "input": "076mimrd",
    "status": "success",
    "source_line_id": "@076mimrd",
    "source_name": "Steel",
    "rank": 1,
    "line_id": "@926dwxwn",
    "url": "https://page.line.me/926dwxwn",
    "add_friend_url": "https://line.me/R/ti/p/@926dwxwn",
    "qr_code_url": "https://qr-official.line.me/gs/M_926dwxwn_GW.png",
    "name": "Dear",
    "badge_type": "CERTIFIED",
    "image_url": "https://profile.line-scdn.net/0hXRJqJR8GB313CBtf1Jd4KktNCRAAJgE1D2oaHQdbXE5Tb0AvSW5KHgZbWktYbEcjT29LEgFfXx0N",
    "friend_count": 1274,
    "error_code": null,
    "error_message": null,
    "scraped_at": "2026-10-30T11:06:28Z"
}
```

Links that can't be scraped give one row with `status: "failed"`, an `error_code`, and an `error_message`. These rows are free:

| error_code | Meaning |
|------------|---------|
| `INVALID_INPUT` | The text is not a LINE Official Account link or ID (for example a personal `line.me/ti/p/~` link) |
| `NOT_FOUND` | No LINE Official Account exists with this ID |
| `PROFILE_NOT_PUBLIC` | The account exists but has no public page.line.me profile. The row still has `line_id`, `friend_count`, `add_friend_url`, and `qr_code_url` |
| `NO_RELATED_ACCOUNTS` | Related accounts mode only: LINE shows no recommendations on this profile |
| `REQUEST_FAILED` | LINE did not answer after several retries |

### Use cases

- **Competitor research**: compare friend counts, coupons, and showcase items of rival shops, salons, or restaurants on LINE.
- **Friend count tracking**: schedule a daily run to follow the growth of your own and competing LINE Official Accounts.
- **Lead generation**: collect phone numbers, addresses, websites, and social links of local businesses that use LINE, especially in Japan and Thailand.
- **Market mapping**: start from one account and use related accounts mode to find similar businesses that LINE groups together.
- **Data enrichment**: turn a list of LINE IDs from your CRM or a website crawl into full company profiles with location and opening hours.
- **Influencer and brand monitoring**: check badge type, premium ID, and the operating company behind a LINE account.

### How it works

1. The Actor turns every input into a LINE search ID. `lin.ee` short links are followed to the account they open.
2. It loads the account's public page.line.me profile and reads the profile data embedded in the page. No browser and no LINE login are used.
3. For accounts without a public profile page, it asks LINE's public friend counter for the friend count and saves a `PROFILE_NOT_PUBLIC` row.
4. In related accounts mode it reads the "Recommended accounts" list from the same page, in the order LINE shows it.
5. Each account is saved as one dataset row. Up to 5 links are processed at the same time, with automatic retries.

### How much does it cost to scrape LINE Official Accounts?

LINE Official Account Scraper uses pay-per-event pricing. You pay per account row saved to the dataset. Compute and proxy costs are included in the event price, so they are not billed separately.

| Event | Price per event | Price per 1,000 |
|-------|----------------|-----------------|
| account-scraped (Free plan) | $0.00299 | **$2.99** |
| account-scraped (Bronze plan) | $0.00249 | **$2.49** |
| account-scraped (Silver plan) | $0.00199 | **$1.99** |
| account-scraped (Gold plan) | $0.00149 | **$1.49** |

One event is one successful row: a full profile in account details mode, or one recommended account in related accounts mode. Failed rows are not charged. A small platform **Actor start** fee also applies per run. For example, 1,000 LINE profiles cost $2.99 on the Free plan, and the 21 related accounts of one profile cost about $0.06. Apify's free plan includes monthly platform credit you can use for this Actor.

### Python and JavaScript API examples

Python ([apify-client](https://docs.apify.com/api/client/python)):

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("parsebird/line-official-account-scraper").call(run_input={
    "mode": "account_details",
    "accountUrls": ["https://page.line.me/914aycak", "@076mimrd"],
})
for account in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(account["name"], "|", account["line_id"], "|", account["friend_count"], "|", account["phone"])
```

JavaScript ([apify-client](https://docs.apify.com/api/client/js)):

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: '<YOUR_APIFY_TOKEN>' });
const run = await client.actor('parsebird/line-official-account-scraper').call({
    mode: 'related_accounts',
    maxResults: 10,
    accountUrls: ['https://page.line.me/076mimrd'],
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((a) => console.log(a.rank, a.name, a.line_id, a.friend_count));
```

Find all endpoints on the [API tab](https://apify.com/parsebird/line-official-account-scraper/api).

### FAQ

**Do I need a LINE account or the LINE Messaging API?**
No. The Actor reads the profile pages that page.line.me shows to anyone on the web. You don't need a LINE login, a LINE Business ID, or a channel access token.

**Where do I find an account's LINE ID or link?**
In the LINE app, open the account's profile and tap **Share** to copy its link, or read the ID that starts with `@` under the name. Many businesses also put a `lin.ee` link or an add-friend button on their website. All of these work as input.

**Why does an account return PROFILE_NOT_PUBLIC?**
Some LINE Official Accounts, often large brands, have no public web profile. page.line.me then only shows an add-friend QR code. In a test of 300 Japanese accounts, 32 were like this. The Actor still returns the friend count, add-friend link, and QR code image for them, and the row is free.

**Why are phone, address, or opening hours empty for some accounts?**
Each business decides what to publish on its LINE profile. In a sample of 268 public Japanese accounts, 57% listed a website, 45% an address, 41% social links, 36% opening hours, and 31% a phone number. Missing values are `null` or an empty list.

**Why does an opening-hours entry show 00:00-00:00?**
The Actor returns the hours exactly as the account entered them. Some businesses leave a day at 00:00-00:00 and explain their schedule in `business_hours_note` instead, so check both fields.

**How many related accounts can I get?**
LINE shows up to 21 recommended accounts on a profile, and the list stayed the same between loads in our tests. Every Japanese account in our 60-account sample had recommendations. The Hong Kong and Thai accounts we tested had none, so they return `NO_RELATED_ACCOUNTS`. To go further, run account details or related accounts mode again on the IDs you found.

**Is the friend count exact?**
`friend_count` is the number LINE itself reports for the account at the time of the run. Schedule runs to see how it changes over time.

**What if I enter the premium ID and the basic ID of the same account?**
The Actor notices both point to the same account and saves it once, so you are charged once.

**Which countries are supported?**
Any country where LINE Official Accounts have page.line.me profiles. We tested accounts from Japan, Thailand, and Hong Kong. Addresses and other text are returned as the account entered them, often in the local language.

**Can I schedule the scraper and connect it to other tools?**
Yes. Use [Apify schedules](https://docs.apify.com/platform/schedules) to run it daily or weekly, and send the results to Google Sheets, Slack, Make, Zapier, n8n, or your own system through [integrations](https://apify.com/integrations), webhooks, or the [API](https://docs.apify.com/api/v2).

**Something does not work or a field is missing.**
Open an issue on the **Issues** tab with your input and run ID, and we will look into it.

### Is it legal to scrape LINE Official Accounts?

The Actor collects only business profile data that LINE Official Accounts publish openly on page.line.me for anyone to see. It does not log in, read chats, or access personal LINE accounts. Some small businesses, such as sole traders, may list a personal phone number or address, which can be personal data under the GDPR, Japan's APPI, or Thailand's PDPA. Make sure you have a lawful basis for storing and using it, and don't use it for spam. For more background, read Apify's article [Is web scraping legal?](https://blog.apify.com/is-web-scraping-legal/) and consult a lawyer if you are unsure about your use case.

### Other scrapers from ParseBird

| Actor | What it scrapes |
|-------|-----------------|
| [WeChat Official Accounts Scraper](https://apify.com/parsebird/wechat-official-accounts-scraper) | WeChat Official Account (公众号) data |
| [Sogou WeChat Article Search Scraper](https://apify.com/parsebird/sogou-wechat-search-scraper) | WeChat articles found through Sogou search |
| [NAVER Map Scraper](https://apify.com/parsebird/naver-map-scraper) | Korean business listings from NAVER Map |
| [Instagram Profile Scraper](https://apify.com/parsebird/instagram-profile-scraper) | Instagram profiles with email, phone, and social links |
| [Facebook Page Details Scraper](https://apify.com/parsebird/facebook-page-details-scraper) | Facebook Page contact and About details |
| [Threads Scraper](https://apify.com/parsebird/threads-scraper) | Threads profiles, posts, and search |
| [Telegram Media Downloader](https://apify.com/parsebird/telegram-media-downloader) | Photos and videos from public Telegram channels |

# Changelog

This Actor's version history is a separate document: https://apify.com/parsebird/line-official-account-scraper/changelog.md

# Actor input Schema

## `mode` (type: `string`):

Pick <b>Account details</b> to get one full profile row per link. Pick <b>Related accounts</b> to get the accounts LINE recommends on each profile ("Recommended accounts"), one row per account.

## `accountUrls` (type: `array`):

Add one LINE Official Account per line: a profile link (https://page.line.me/914aycak), an add-friend link (https://line.me/R/ti/p/@914aycak), a lin.ee short link, or just the LINE ID (@914aycak). Premium IDs such as @linefriends_hk_mo work too.

## `maxResults` (type: `integer`):

In <b>Related accounts</b> mode, keep up to this many recommended accounts per link (LINE usually shows about 20). <b>Account details</b> mode always returns one row per link.

## Actor input object example

```json
{
  "mode": "account_details",
  "accountUrls": [
    "https://page.line.me/914aycak",
    "https://page.line.me/076mimrd"
  ],
  "maxResults": 20
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "mode": "account_details",
    "accountUrls": [
        "https://page.line.me/914aycak",
        "https://page.line.me/076mimrd"
    ],
    "maxResults": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("parsebird/line-official-account-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "mode": "account_details",
    "accountUrls": [
        "https://page.line.me/914aycak",
        "https://page.line.me/076mimrd",
    ],
    "maxResults": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("parsebird/line-official-account-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "mode": "account_details",
  "accountUrls": [
    "https://page.line.me/914aycak",
    "https://page.line.me/076mimrd"
  ],
  "maxResults": 20
}' |
apify call parsebird/line-official-account-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parsebird/line-official-account-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/cVWrgTKPK9htLuSKi/builds/kg3B4S0Z5wqpeHTpa/openapi.json
