Skip to content

feature request - support an export entrypoint for messagingApi #1021

Closed

Description

@sacrosanctic

It would be nice if I could import like this

import { MessagingApiClient } from '@line/bot-sdk/messagingApi';

Currently, these are the import options

// ES modules or TypeScript
import { messagingApi } from '@line/bot-sdk';
const { MessagingApiClient } = messagingApi;
// OR
import * as line from '@line/bot-sdk';
const { MessagingApiClient } = line.messagingApi;

// CommonJS
const MessagingApiClient = require('@line/bot-sdk').messagingApi.MessagingApiClient;

Activity

  1. added and removed on Nov 5, 2024
  2. assigned and unassigned on Nov 19, 2024
  3. Yang-33 commented on Apr 3, 2026

    @Yang-33
    Contributor

    #1561 will provide unified client so let's close this issue after the change is published. now we don't have to care which client provides what API in many cases.

  4. Yang-33 commented on Apr 3, 2026

    @Yang-33
    Contributor

    https://github.com/line/line-bot-sdk-nodejs/releases/tag/v11.0.0 provides unified client like

    const { LineBotClient, channelAccessToken } = require('@line/bot-sdk');
    # the client contains all methods for MessagingApiClient, MessagingApiBlobClient, InsightClient, ....
    const client = LineBotClient.fromChannelAccessToken({ channelAccessToken: '...' });

    though it doesn't resolve this issue perfectly. how about this? If you still request this, you can reopen this issue freely. Thank you for requesting, and sorry for delay about this 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions