{"library":"messaging-api-line","title":"messaging-api-line","description":"A Node.js client library for the LINE Messaging API, version 1.1.0. Maintained as part of the Yoctol messaging-apis monorepo, it provides a comprehensive, TypeScript-first wrapper for LINE's REST endpoints including reply, push, multicast, broadcast, and rich menu APIs. The library uses axios for HTTP and wraps errors for better debugging. Key differentiators: full TypeScript types, camelCase key support (v1.0.0+), factory methods for message creation, and support for Flex and Imagemap messages. Release cadence is sporadic with the last release in October 2021.","language":"javascript","status":"active","last_verified":"Sat Apr 25","install":{"commands":["npm install messaging-api-line"],"cli":null},"imports":["import { LineClient } from 'messaging-api-line'","import { Line } from 'messaging-api-line'","import { LineClientConfig } from 'messaging-api-line'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import { LineClient } from 'messaging-api-line';\n\nconst client = new LineClient({\n  accessToken: process.env.LINE_ACCESS_TOKEN ?? '',\n  channelSecret: process.env.LINE_CHANNEL_SECRET ?? '',\n});\n\n// Reply to a webhook event\nawait client.reply(REPLY_TOKEN, [\n  {\n    type: 'text',\n    text: 'Hello from messaging-api-line!',\n  },\n]);\n\n// Push a message to a user\nawait client.push(USER_ID, [\n  {\n    type: 'text',\n    text: 'This is a push message.',\n  },\n]);\n\n// Broadcast to all friends\nawait client.broadcast([\n  {\n    type: 'text',\n    text: 'Broadcast message',\n  },\n]);\n\n// Get bot info\nconst botInfo = await client.getBotInfo();\nconsole.log(botInfo);","lang":"typescript","description":"Initializes LineClient with credentials, then demonstrates reply, push, broadcast, and getBotInfo APIs.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}