From 07838e2d55e28f592c2d9a1274c36086137a31e7 Mon Sep 17 00:00:00 2001 From: Euchi Yuta Date: Mon, 2 Jun 2025 17:31:58 +0900 Subject: [PATCH 1/2] Update TypeScript documentation to reflect messagingApi usage --- docs/guide/typescript.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/guide/typescript.md b/docs/guide/typescript.md index 10ea7156d..06272f67b 100644 --- a/docs/guide/typescript.md +++ b/docs/guide/typescript.md @@ -58,7 +58,7 @@ there you go. ``` typescript import { // main APIs - Client, + messagingApi, middleware, // exceptions @@ -69,6 +69,9 @@ import { TemplateMessage, WebhookEvent, } from "@line/bot-sdk"; + +// For example, you can use MessagingApiClient like this: +const { MessagingApiClient } = messagingApi; ``` Message object and webhook event types can be also imported from `@line/bot-sdk`, From 8ae99e8d38e48e4876804d4269aa1cce2062c634 Mon Sep 17 00:00:00 2001 From: Euchi Yuta Date: Mon, 2 Jun 2025 18:36:14 +0900 Subject: [PATCH 2/2] Update TypeScript documentation to include webhook API --- docs/guide/typescript.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/guide/typescript.md b/docs/guide/typescript.md index 06272f67b..a201cb1aa 100644 --- a/docs/guide/typescript.md +++ b/docs/guide/typescript.md @@ -60,14 +60,13 @@ import { // main APIs messagingApi, middleware, + + // webhook + webhook, // exceptions JSONParseError, SignatureValidationFailed, - - // types - TemplateMessage, - WebhookEvent, } from "@line/bot-sdk"; // For example, you can use MessagingApiClient like this: @@ -75,5 +74,5 @@ const { MessagingApiClient } = messagingApi; ``` Message object and webhook event types can be also imported from `@line/bot-sdk`, -e.g. `TemplateMessage` or `Event`. For declarations of the types, please +e.g. `messagingApi.TemplateMessage` or `webhook.Event`. For declarations of the types, please refer to [lib/](https://github.com/line/line-bot-sdk-nodejs/blob/master/lib/).