From 2ac18770cc4b821dba19bbf501ea7680a219e801 Mon Sep 17 00:00:00 2001 From: Yuta Kasai Date: Sat, 5 Apr 2025 22:33:25 +0900 Subject: [PATCH 1/2] NO-ISSUE template --- .../line-bot-sdk-nodejs-generator/api-single.pebble | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/generator/src/main/resources/line-bot-sdk-nodejs-generator/api-single.pebble b/generator/src/main/resources/line-bot-sdk-nodejs-generator/api-single.pebble index 67e094572..d7b9cd0e2 100644 --- a/generator/src/main/resources/line-bot-sdk-nodejs-generator/api-single.pebble +++ b/generator/src/main/resources/line-bot-sdk-nodejs-generator/api-single.pebble @@ -41,18 +41,6 @@ export class {{operations.classname}} { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...await response.json(), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = - response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME); - } - return resBody; - } - {% for op in operations.operation -%} /** * {{op.notes}} From 502d3bdba8e1f996e5870670850a2d7e9e216f27 Mon Sep 17 00:00:00 2001 From: Yuta Kasai Date: Sat, 5 Apr 2025 22:33:28 +0900 Subject: [PATCH 2/2] NO-ISSUE gen --- .../api/channelAccessTokenClient.ts | 13 ------------- lib/insight/api/insightClient.ts | 13 ------------- lib/liff/api/liffClient.ts | 13 ------------- lib/manage-audience/api/manageAudienceBlobClient.ts | 13 ------------- lib/manage-audience/api/manageAudienceClient.ts | 13 ------------- lib/messaging-api/api/messagingApiBlobClient.ts | 13 ------------- lib/messaging-api/api/messagingApiClient.ts | 13 ------------- lib/module-attach/api/lineModuleAttachClient.ts | 13 ------------- lib/module/api/lineModuleClient.ts | 13 ------------- lib/shop/api/shopClient.ts | 13 ------------- 10 files changed, 130 deletions(-) diff --git a/lib/channel-access-token/api/channelAccessTokenClient.ts b/lib/channel-access-token/api/channelAccessTokenClient.ts index 327b5b088..d9f566b94 100644 --- a/lib/channel-access-token/api/channelAccessTokenClient.ts +++ b/lib/channel-access-token/api/channelAccessTokenClient.ts @@ -46,19 +46,6 @@ export class ChannelAccessTokenClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Gets all valid channel access token key IDs. * @param clientAssertionType `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` diff --git a/lib/insight/api/insightClient.ts b/lib/insight/api/insightClient.ts index 8c4724430..47479d6f3 100644 --- a/lib/insight/api/insightClient.ts +++ b/lib/insight/api/insightClient.ts @@ -48,19 +48,6 @@ export class InsightClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Retrieves the demographic attributes for a LINE Official Account\'s friends.You can only retrieve information about friends for LINE Official Accounts created by users in Japan (JP), Thailand (TH), Taiwan (TW) and Indonesia (ID). * diff --git a/lib/liff/api/liffClient.ts b/lib/liff/api/liffClient.ts index 8ae051232..99fb95993 100644 --- a/lib/liff/api/liffClient.ts +++ b/lib/liff/api/liffClient.ts @@ -47,19 +47,6 @@ export class LiffClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Adding the LIFF app to a channel * @summary Create LIFF app diff --git a/lib/manage-audience/api/manageAudienceBlobClient.ts b/lib/manage-audience/api/manageAudienceBlobClient.ts index e6b6a4ba9..69df1fc2a 100644 --- a/lib/manage-audience/api/manageAudienceBlobClient.ts +++ b/lib/manage-audience/api/manageAudienceBlobClient.ts @@ -44,19 +44,6 @@ export class ManageAudienceBlobClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Add user IDs or Identifiers for Advertisers (IFAs) to an audience for uploading user IDs (by file). * @param file A text file with one user ID or IFA entered per line. Specify text/plain as Content-Type. Max file number: 1 Max number: 1,500,000 diff --git a/lib/manage-audience/api/manageAudienceClient.ts b/lib/manage-audience/api/manageAudienceClient.ts index e0c559f20..3c162d259 100644 --- a/lib/manage-audience/api/manageAudienceClient.ts +++ b/lib/manage-audience/api/manageAudienceClient.ts @@ -60,19 +60,6 @@ export class ManageAudienceClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Activate audience * @param audienceGroupId The audience ID. diff --git a/lib/messaging-api/api/messagingApiBlobClient.ts b/lib/messaging-api/api/messagingApiBlobClient.ts index fac382620..d9964864e 100644 --- a/lib/messaging-api/api/messagingApiBlobClient.ts +++ b/lib/messaging-api/api/messagingApiBlobClient.ts @@ -44,19 +44,6 @@ export class MessagingApiBlobClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Download image, video, and audio data sent from users. * @param messageId Message ID of video or audio diff --git a/lib/messaging-api/api/messagingApiClient.ts b/lib/messaging-api/api/messagingApiClient.ts index ec1236452..2138542e3 100644 --- a/lib/messaging-api/api/messagingApiClient.ts +++ b/lib/messaging-api/api/messagingApiClient.ts @@ -90,19 +90,6 @@ export class MessagingApiClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Sends a message to multiple users at any time. * @param broadcastRequest diff --git a/lib/module-attach/api/lineModuleAttachClient.ts b/lib/module-attach/api/lineModuleAttachClient.ts index 4c969f7d5..59a2c4947 100644 --- a/lib/module-attach/api/lineModuleAttachClient.ts +++ b/lib/module-attach/api/lineModuleAttachClient.ts @@ -44,19 +44,6 @@ export class LineModuleAttachClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Attach by operation of the module channel provider * @param grantType authorization_code diff --git a/lib/module/api/lineModuleClient.ts b/lib/module/api/lineModuleClient.ts index 4ec0bb288..6e5d707d3 100644 --- a/lib/module/api/lineModuleClient.ts +++ b/lib/module/api/lineModuleClient.ts @@ -46,19 +46,6 @@ export class LineModuleClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * If the Standby Channel wants to take the initiative (Chat Control), it calls the Acquire Control API. The channel that was previously an Active Channel will automatically switch to a Standby Channel. * @param chatId The `userId`, `roomId`, or `groupId` diff --git a/lib/shop/api/shopClient.ts b/lib/shop/api/shopClient.ts index 8e69a61ba..5f3b01fe1 100644 --- a/lib/shop/api/shopClient.ts +++ b/lib/shop/api/shopClient.ts @@ -44,19 +44,6 @@ export class ShopClient { }); } - private async parseHTTPResponse(response: Response) { - const { LINE_REQUEST_ID_HTTP_HEADER_NAME } = Types; - let resBody: Record = { - ...(await response.json()), - }; - if (response.headers.get(LINE_REQUEST_ID_HTTP_HEADER_NAME)) { - resBody[LINE_REQUEST_ID_HTTP_HEADER_NAME] = response.headers.get( - LINE_REQUEST_ID_HTTP_HEADER_NAME, - ); - } - return resBody; - } - /** * Sends a mission sticker. * @param missionStickerRequest