Skip to content

@line/bot-sdk / Exports / insight / InsightClient

Class: InsightClient

insight.InsightClient

Table of contents

Constructors

Methods

Constructors

constructor

new InsightClient(config): InsightClient

Parameters

NameType
confighttpClientConfig

Returns

InsightClient

Defined in

lib/insight/api/insightClient.ts:41

Methods

getFriendsDemographics

getFriendsDemographics(): Promise<GetFriendsDemographicsResponse>

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).

Returns

Promise<GetFriendsDemographicsResponse>

See

Documentation

Defined in

lib/insight/api/insightClient.ts:69


getFriendsDemographicsWithHttpInfo

getFriendsDemographicsWithHttpInfo(): Promise<ApiResponseType<GetFriendsDemographicsResponse>>

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). . This method includes HttpInfo object to return additional information.

Returns

Promise<ApiResponseType<GetFriendsDemographicsResponse>>

See

Documentation

Defined in

lib/insight/api/insightClient.ts:79


getMessageEvent

getMessageEvent(requestId): Promise<GetMessageEventResponse>

Returns statistics about how users interact with narrowcast messages or broadcast messages sent from your LINE Official Account.

Parameters

NameTypeDescription
requestIdstringRequest ID of a narrowcast message or broadcast message. Each Messaging API request has a request ID.

Returns

Promise<GetMessageEventResponse>

Summary

Get user interaction statistics

See

Get user interaction statistics Documentation

Defined in

lib/insight/api/insightClient.ts:92


getMessageEventWithHttpInfo

getMessageEventWithHttpInfo(requestId): Promise<ApiResponseType<GetMessageEventResponse>>

Returns statistics about how users interact with narrowcast messages or broadcast messages sent from your LINE Official Account. . This method includes HttpInfo object to return additional information.

Parameters

NameTypeDescription
requestIdstringRequest ID of a narrowcast message or broadcast message. Each Messaging API request has a request ID.

Returns

Promise<ApiResponseType<GetMessageEventResponse>>

Summary

Get user interaction statistics

See

Get user interaction statistics Documentation

Defined in

lib/insight/api/insightClient.ts:106


getNumberOfFollowers

getNumberOfFollowers(date?): Promise<GetNumberOfFollowersResponse>

Returns the number of users who have added the LINE Official Account on or before a specified date.

Parameters

NameTypeDescription
date?stringDate for which to retrieve the number of followers. Format: yyyyMMdd (e.g. 20191231) Timezone: UTC+9

Returns

Promise<GetNumberOfFollowersResponse>

Summary

Get number of followers

See

Get number of followers Documentation

Defined in

lib/insight/api/insightClient.ts:131


getNumberOfFollowersWithHttpInfo

getNumberOfFollowersWithHttpInfo(date?): Promise<ApiResponseType<GetNumberOfFollowersResponse>>

Returns the number of users who have added the LINE Official Account on or before a specified date. . This method includes HttpInfo object to return additional information.

Parameters

NameTypeDescription
date?stringDate for which to retrieve the number of followers. Format: yyyyMMdd (e.g. 20191231) Timezone: UTC+9

Returns

Promise<ApiResponseType<GetNumberOfFollowersResponse>>

Summary

Get number of followers

See

Get number of followers Documentation

Defined in

lib/insight/api/insightClient.ts:145


getNumberOfMessageDeliveries

getNumberOfMessageDeliveries(date): Promise<GetNumberOfMessageDeliveriesResponse>

Returns the number of messages sent from LINE Official Account on a specified day.

Parameters

NameTypeDescription
datestringDate for which to retrieve number of sent messages. - Format: yyyyMMdd (e.g. 20191231) - Timezone: UTC+9

Returns

Promise<GetNumberOfMessageDeliveriesResponse>

Summary

Get number of message deliveries

See

Get number of message deliveries Documentation

Defined in

lib/insight/api/insightClient.ts:170


getNumberOfMessageDeliveriesWithHttpInfo

getNumberOfMessageDeliveriesWithHttpInfo(date): Promise<ApiResponseType<GetNumberOfMessageDeliveriesResponse>>

Returns the number of messages sent from LINE Official Account on a specified day. . This method includes HttpInfo object to return additional information.

Parameters

NameTypeDescription
datestringDate for which to retrieve number of sent messages. - Format: yyyyMMdd (e.g. 20191231) - Timezone: UTC+9

Returns

Promise<ApiResponseType<GetNumberOfMessageDeliveriesResponse>>

Summary

Get number of message deliveries

See

Get number of message deliveries Documentation

Defined in

lib/insight/api/insightClient.ts:184


getStatisticsPerUnit

getStatisticsPerUnit(customAggregationUnit, from, to): Promise<GetStatisticsPerUnitResponse>

You can check the per-unit statistics of how users interact with push messages and multicast messages sent from your LINE Official Account.

Parameters

NameTypeDescription
customAggregationUnitstringName of aggregation unit specified when sending the message. Case-sensitive. For example, Promotion_a and Promotion_A are regarded as different unit names.
fromstringStart date of aggregation period. Format: yyyyMMdd (e.g. 20210301) Time zone: UTC+9
tostringEnd date of aggregation period. The end date can be specified for up to 30 days later. For example, if the start date is 20210301, the latest end date is 20210331. Format: yyyyMMdd (e.g. 20210301) Time zone: UTC+9

Returns

Promise<GetStatisticsPerUnitResponse>

See

Documentation

Defined in

lib/insight/api/insightClient.ts:210


getStatisticsPerUnitWithHttpInfo

getStatisticsPerUnitWithHttpInfo(customAggregationUnit, from, to): Promise<ApiResponseType<GetStatisticsPerUnitResponse>>

You can check the per-unit statistics of how users interact with push messages and multicast messages sent from your LINE Official Account. . This method includes HttpInfo object to return additional information.

Parameters

NameTypeDescription
customAggregationUnitstringName of aggregation unit specified when sending the message. Case-sensitive. For example, Promotion_a and Promotion_A are regarded as different unit names.
fromstringStart date of aggregation period. Format: yyyyMMdd (e.g. 20210301) Time zone: UTC+9
tostringEnd date of aggregation period. The end date can be specified for up to 30 days later. For example, if the start date is 20210301, the latest end date is 20210331. Format: yyyyMMdd (e.g. 20210301) Time zone: UTC+9

Returns

Promise<ApiResponseType<GetStatisticsPerUnitResponse>>

See

Documentation

Defined in

lib/insight/api/insightClient.ts:233