Appearance
@line/bot-sdk / Exports / webhook
Namespace: webhook
Table of contents
Namespaces
- AccountLinkEvent
- ActionResult
- ActivatedEvent
- BeaconContent
- BeaconEvent
- BotResumedEvent
- BotSuspendedEvent
- ContentProvider
- DeactivatedEvent
- DetachedModuleContent
- Event
- FollowEvent
- JoinEvent
- LeaveEvent
- LinkContent
- MemberJoinedEvent
- MemberLeftEvent
- MessageEvent
- ModuleEvent
- PnpDeliveryCompletionEvent
- PostbackEvent
- StickerMessageContent
- ThingsEvent
- UnfollowEvent
- UnsendEvent
- VideoPlayCompleteEvent
Type Aliases
- AccountLinkEvent
- ActionResult
- ActivatedEvent
- AllMentionee
- AttachedModuleContent
- AudioMessageContent
- BeaconContent
- BeaconEvent
- BotResumedEvent
- BotSuspendedEvent
- CallbackRequest
- ChatControl
- ContentProvider
- DeactivatedEvent
- DeliveryContext
- DetachedModuleContent
- Emoji
- Event
- EventBase
- EventMode
- FileMessageContent
- FollowDetail
- FollowEvent
- GroupSource
- ImageMessageContent
- ImageSet
- JoinEvent
- JoinedMembers
- LeaveEvent
- LeftMembers
- LinkContent
- LinkThingsContent
- LocationMessageContent
- MemberJoinedEvent
- MemberLeftEvent
- Mention
- Mentionee
- MentioneeBase
- MessageContent
- MessageContentBase
- MessageEvent
- ModuleContent
- ModuleContentBase
- ModuleEvent
- PnpDelivery
- PnpDeliveryCompletionEvent
- PostbackContent
- PostbackEvent
- RoomSource
- ScenarioResult
- ScenarioResultThingsContent
- Source
- SourceBase
- StickerMessageContent
- TextMessageContent
- ThingsContent
- ThingsContentBase
- ThingsEvent
- UnfollowEvent
- UnlinkThingsContent
- UnsendDetail
- UnsendEvent
- UserMentionee
- UserSource
- VideoMessageContent
- VideoPlayComplete
- VideoPlayCompleteEvent
Type Aliases
AccountLinkEvent
Ƭ AccountLinkEvent: EventBase
& { link
: LinkContent
; replyToken?
: string
; type
: "accountLink"
}
Defined in
lib/webhook/model/accountLinkEvent.ts:24
lib/webhook/model/accountLinkEvent.ts:35
ActionResult
Ƭ ActionResult: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
data? | string | Base64-encoded binary data |
type | TypeEnum |
Defined in
lib/webhook/model/actionResult.ts:13
lib/webhook/model/actionResult.ts:23
ActivatedEvent
Ƭ ActivatedEvent: EventBase
& { chatControl
: ChatControl
; type
: "activated"
}
Defined in
lib/webhook/model/activatedEvent.ts:24
lib/webhook/model/activatedEvent.ts:31
AllMentionee
Ƭ AllMentionee: MentioneeBase
& { type
: "all"
}
Defined in
lib/webhook/model/allMentionee.ts:20
AttachedModuleContent
Ƭ AttachedModuleContent: ModuleContentBase
& { botId
: string
; scopes
: string
[] ; type
: "attached"
}
Defined in
lib/webhook/model/attachedModuleContent.ts:17
AudioMessageContent
Ƭ AudioMessageContent: MessageContentBase
& { contentProvider
: ContentProvider
; duration?
: number
; type
: "audio"
}
Defined in
lib/webhook/model/audioMessageContent.ts:18
BeaconContent
Ƭ BeaconContent: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
dm? | string | Device message of beacon that was detected. |
hwid | string | Hardware ID of the beacon that was detected |
type | TypeEnum | Type of beacon event. |
Defined in
lib/webhook/model/beaconContent.ts:13
lib/webhook/model/beaconContent.ts:28
BeaconEvent
Ƭ BeaconEvent: EventBase
& { beacon
: BeaconContent
; replyToken
: string
; type
: "beacon"
}
Defined in
lib/webhook/model/beaconEvent.ts:24
lib/webhook/model/beaconEvent.ts:35
BotResumedEvent
Ƭ BotResumedEvent: EventBase
& { type
: "botResumed"
}
Defined in
lib/webhook/model/botResumedEvent.ts:23
lib/webhook/model/botResumedEvent.ts:27
BotSuspendedEvent
Ƭ BotSuspendedEvent: EventBase
& { type
: "botSuspended"
}
Defined in
lib/webhook/model/botSuspendedEvent.ts:23
lib/webhook/model/botSuspendedEvent.ts:27
CallbackRequest
Ƭ CallbackRequest: Object
The request body contains a JSON object with the user ID of a bot that should receive webhook events and an array of webhook event objects.
Type declaration
Name | Type | Description |
---|---|---|
destination | string | User ID of a bot that should receive webhook events. The user ID value is a string that matches the regular expression, U[0-9a-f]{32} . See destination Documentation |
events | Event [] | Array of webhook event objects. The LINE Platform may send an empty array that doesn't include a webhook event object to confirm communication. See events Documentation |
Defined in
lib/webhook/model/callbackRequest.ts:18
ChatControl
Ƭ ChatControl: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type |
---|---|
expireAt | number |
Defined in
lib/webhook/model/chatControl.ts:13
ContentProvider
Ƭ ContentProvider: Object
Provider of the media file.
Type declaration
Name | Type | Description |
---|---|---|
originalContentUrl? | string | URL of the image file. Only included when contentProvider.type is external. |
previewImageUrl? | string | URL of the preview image. Only included when contentProvider.type is external. |
type | TypeEnum | Provider of the image file. |
Defined in
lib/webhook/model/contentProvider.ts:16
lib/webhook/model/contentProvider.ts:31
DeactivatedEvent
Ƭ DeactivatedEvent: EventBase
& { type
: "deactivated"
}
Defined in
lib/webhook/model/deactivatedEvent.ts:23
lib/webhook/model/deactivatedEvent.ts:27
DeliveryContext
Ƭ DeliveryContext: Object
webhook's delivery context information
Type declaration
Name | Type | Description |
---|---|---|
isRedelivery | boolean | Whether the webhook event is a redelivered one or not. |
Defined in
lib/webhook/model/deliveryContext.ts:16
DetachedModuleContent
Ƭ DetachedModuleContent: ModuleContentBase
& { botId
: string
; reason
: ReasonEnum
; type
: "detached"
}
Defined in
lib/webhook/model/detachedModuleContent.ts:17
lib/webhook/model/detachedModuleContent.ts:29
Emoji
Ƭ Emoji: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
emojiId | string | ID for a LINE emoji inside a set. |
index | number | Index position for a character in text, with the first character being at position 0. |
length | number | The length of the LINE emoji string. For LINE emoji (hello), 7 is the length. |
productId | string | Product ID for a LINE emoji set. |
Defined in
Event
Ƭ Event: AccountLinkEvent
| ActivatedEvent
| BeaconEvent
| BotResumedEvent
| BotSuspendedEvent
| DeactivatedEvent
| PnpDeliveryCompletionEvent
| FollowEvent
| JoinEvent
| LeaveEvent
| MemberJoinedEvent
| MemberLeftEvent
| MessageEvent
| ModuleEvent
| PostbackEvent
| ThingsEvent
| UnfollowEvent
| UnsendEvent
| VideoPlayCompleteEvent
Defined in
EventBase
Ƭ EventBase: Object
Webhook event
Type declaration
Name | Type | Description |
---|---|---|
deliveryContext | DeliveryContext | |
mode | EventMode | |
source? | Source | |
timestamp | number | Time of the event in milliseconds. |
type | string | Type of the event |
webhookEventId | string | Webhook Event ID. An ID that uniquely identifies a webhook event. This is a string in ULID format. |
Defined in
EventMode
Ƭ EventMode: "active"
| "standby"
Channel state.
Defined in
lib/webhook/model/eventMode.ts:17
FileMessageContent
Ƭ FileMessageContent: MessageContentBase
& { fileName
: string
; fileSize
: number
; type
: "file"
}
Defined in
lib/webhook/model/fileMessageContent.ts:17
FollowDetail
Ƭ FollowDetail: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
isUnblocked | boolean | Whether a user has added your LINE Official Account as a friend or unblocked. |
Defined in
lib/webhook/model/followDetail.ts:13
FollowEvent
Ƭ FollowEvent: EventBase
& { follow
: FollowDetail
; replyToken
: string
; type
: "follow"
}
Defined in
lib/webhook/model/followEvent.ts:24
lib/webhook/model/followEvent.ts:35
GroupSource
Ƭ GroupSource: SourceBase
& { groupId
: string
; type
: "group"
; userId?
: string
}
Defined in
lib/webhook/model/groupSource.ts:17
ImageMessageContent
Ƭ ImageMessageContent: MessageContentBase
& { contentProvider
: ContentProvider
; imageSet?
: ImageSet
; quoteToken
: string
; type
: "image"
}
Defined in
lib/webhook/model/imageMessageContent.ts:19
ImageSet
Ƭ ImageSet: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
id | string | Image set ID. Only included when multiple images are sent simultaneously. |
index? | number | An index starting from 1, indicating the image number in a set of images sent simultaneously. Only included when multiple images are sent simultaneously. However, it won't be included if the sender is using LINE 11.15 or earlier for Android. |
total? | number | The total number of images sent simultaneously. |
Defined in
lib/webhook/model/imageSet.ts:13
JoinEvent
Ƭ JoinEvent: EventBase
& { replyToken
: string
; type
: "join"
}
Defined in
lib/webhook/model/joinEvent.ts:23
lib/webhook/model/joinEvent.ts:31
JoinedMembers
Ƭ JoinedMembers: Object
Type declaration
Name | Type | Description |
---|---|---|
members | UserSource [] | Users who joined. Array of source user objects. |
Defined in
lib/webhook/model/joinedMembers.ts:15
LeaveEvent
Ƭ LeaveEvent: EventBase
& { type
: "leave"
}
Defined in
lib/webhook/model/leaveEvent.ts:23
lib/webhook/model/leaveEvent.ts:27
LeftMembers
Ƭ LeftMembers: Object
Type declaration
Name | Type | Description |
---|---|---|
members | UserSource [] | Users who left. Array of source user objects. |
Defined in
lib/webhook/model/leftMembers.ts:15
LinkContent
Ƭ LinkContent: Object
Content of the account link event.
Type declaration
Name | Type | Description |
---|---|---|
nonce | string | Specified nonce (number used once) when verifying the user ID. |
result | ResultEnum | One of the following values to indicate whether linking the account was successful or not |
Defined in
lib/webhook/model/linkContent.ts:16
lib/webhook/model/linkContent.ts:27
LinkThingsContent
Ƭ LinkThingsContent: ThingsContentBase
& { deviceId
: string
; type
: "link"
}
Defined in
lib/webhook/model/linkThingsContent.ts:17
LocationMessageContent
Ƭ LocationMessageContent: MessageContentBase
& { address?
: string
; latitude
: number
; longitude
: number
; title?
: string
; type
: "location"
}
Defined in
lib/webhook/model/locationMessageContent.ts:17
MemberJoinedEvent
Ƭ MemberJoinedEvent: EventBase
& { joined
: JoinedMembers
; replyToken
: string
; type
: "memberJoined"
}
Defined in
lib/webhook/model/memberJoinedEvent.ts:24
lib/webhook/model/memberJoinedEvent.ts:35
MemberLeftEvent
Ƭ MemberLeftEvent: EventBase
& { left
: LeftMembers
; type
: "memberLeft"
}
Defined in
lib/webhook/model/memberLeftEvent.ts:24
lib/webhook/model/memberLeftEvent.ts:31
Mention
Ƭ Mention: Object
Type declaration
Name | Type | Description |
---|---|---|
mentionees | Mentionee [] | Array of one or more mention objects. Max: 20 mentions |
Defined in
lib/webhook/model/mention.ts:15
Mentionee
Ƭ Mentionee: AllMentionee
| UserMentionee
Defined in
lib/webhook/model/mentionee.ts:16
MentioneeBase
Ƭ MentioneeBase: Object
Type declaration
Name | Type | Description |
---|---|---|
index | number | Index position of the user mention for a character in text, with the first character being at position 0. See index Documentation |
length | number | The length of the text of the mentioned user. For a mention @example, 8 is the length. See length Documentation |
type | string | Mentioned target. See type Documentation |
Defined in
lib/webhook/model/mentionee.ts:20
MessageContent
Ƭ MessageContent: AudioMessageContent
| FileMessageContent
| ImageMessageContent
| LocationMessageContent
| StickerMessageContent
| TextMessageContent
| VideoMessageContent
Defined in
lib/webhook/model/messageContent.ts:21
MessageContentBase
Ƭ MessageContentBase: Object
Type declaration
Name | Type | Description |
---|---|---|
id | string | Message ID See id Documentation |
type | string | Type See type Documentation |
Defined in
lib/webhook/model/messageContent.ts:30
MessageEvent
Ƭ MessageEvent: EventBase
& { message
: MessageContent
; replyToken?
: string
; type
: "message"
}
Defined in
lib/webhook/model/messageEvent.ts:24
lib/webhook/model/messageEvent.ts:34
ModuleContent
Ƭ ModuleContent: AttachedModuleContent
| DetachedModuleContent
Defined in
lib/webhook/model/moduleContent.ts:16
ModuleContentBase
Ƭ ModuleContentBase: Object
Type declaration
Name | Type | Description |
---|---|---|
type | string | Type |
Defined in
lib/webhook/model/moduleContent.ts:20
ModuleEvent
Ƭ ModuleEvent: EventBase
& { module
: ModuleContent
; type
: "module"
}
Defined in
lib/webhook/model/moduleEvent.ts:24
lib/webhook/model/moduleEvent.ts:31
PnpDelivery
Ƭ PnpDelivery: Object
A delivery object containing a hashed phone number string or a string specified by X-Line-Delivery-Tag
header
Type declaration
Name | Type | Description |
---|---|---|
data | string | A hashed phone number string or a string specified by X-Line-Delivery-Tag header |
Defined in
lib/webhook/model/pnpDelivery.ts:16
PnpDeliveryCompletionEvent
Ƭ PnpDeliveryCompletionEvent: EventBase
& { delivery
: PnpDelivery
; type
: "delivery"
}
Defined in
lib/webhook/model/pnpDeliveryCompletionEvent.ts:24
lib/webhook/model/pnpDeliveryCompletionEvent.ts:31
PostbackContent
Ƭ PostbackContent: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
data | string | Postback data |
params? | { [key: string] : string ; } |
Defined in
lib/webhook/model/postbackContent.ts:13
PostbackEvent
Ƭ PostbackEvent: EventBase
& { postback
: PostbackContent
; replyToken?
: string
; type
: "postback"
}
Defined in
lib/webhook/model/postbackEvent.ts:24
lib/webhook/model/postbackEvent.ts:35
RoomSource
Ƭ RoomSource: SourceBase
& { roomId
: string
; type
: "room"
; userId?
: string
}
Defined in
lib/webhook/model/roomSource.ts:17
ScenarioResult
Ƭ ScenarioResult: Object
Type declaration
Name | Type | Description |
---|---|---|
actionResults? | ActionResult [] | Execution result of individual operations specified in action. Only included when things.result.resultCode is success. See actionResults Documentation |
bleNotificationPayload? | string | Data contained in notification. See bleNotificationPayload Documentation |
endTime | number | Timestamp for when execution of scenario was completed (milliseconds, LINE app time) See endTime Documentation |
errorReason? | string | Error reason. See errorReason Documentation |
resultCode | string | Scenario execution completion status See resultCode Documentation |
revision? | number | Revision number of the scenario set containing the executed scenario See revision Documentation |
scenarioId? | string | Scenario ID executed See scenarioId Documentation |
startTime | number | Timestamp for when execution of scenario action started (milliseconds, LINE app time) See startTime Documentation |
Defined in
lib/webhook/model/scenarioResult.ts:15
ScenarioResultThingsContent
Ƭ ScenarioResultThingsContent: ThingsContentBase
& { deviceId
: string
; result
: ScenarioResult
; type
: "scenarioResult"
}
Defined in
lib/webhook/model/scenarioResultThingsContent.ts:18
Source
Ƭ Source: GroupSource
| RoomSource
| UserSource
Defined in
lib/webhook/model/source.ts:17
SourceBase
Ƭ SourceBase: Object
the source of the event.
Type declaration
Name | Type | Description |
---|---|---|
type? | string | source type See type Documentation |
Defined in
lib/webhook/model/source.ts:25
StickerMessageContent
Ƭ StickerMessageContent: MessageContentBase
& { keywords?
: string
[] ; packageId
: string
; quoteToken
: string
; quotedMessageId?
: string
; stickerId
: string
; stickerResourceType
: StickerResourceTypeEnum
; text?
: string
; type
: "sticker"
}
Defined in
lib/webhook/model/stickerMessageContent.ts:17
lib/webhook/model/stickerMessageContent.ts:62
TextMessageContent
Ƭ TextMessageContent: MessageContentBase
& { emojis?
: Emoji
[] ; mention?
: Mention
; quoteToken
: string
; quotedMessageId?
: string
; text
: string
; type
: "text"
}
Defined in
lib/webhook/model/textMessageContent.ts:19
ThingsContent
Ƭ ThingsContent: LinkThingsContent
| ScenarioResultThingsContent
| UnlinkThingsContent
Defined in
lib/webhook/model/thingsContent.ts:17
ThingsContentBase
Ƭ ThingsContentBase: Object
Type declaration
Name | Type | Description |
---|---|---|
type | string | Type |
Defined in
lib/webhook/model/thingsContent.ts:22
ThingsEvent
Ƭ ThingsEvent: EventBase
& { replyToken
: string
; things
: ThingsContent
; type
: "things"
}
Defined in
lib/webhook/model/thingsEvent.ts:24
lib/webhook/model/thingsEvent.ts:35
UnfollowEvent
Ƭ UnfollowEvent: EventBase
& { type
: "unfollow"
}
Defined in
lib/webhook/model/unfollowEvent.ts:23
lib/webhook/model/unfollowEvent.ts:27
UnlinkThingsContent
Ƭ UnlinkThingsContent: ThingsContentBase
& { deviceId
: string
; type
: "unlink"
}
Defined in
lib/webhook/model/unlinkThingsContent.ts:17
UnsendDetail
Ƭ UnsendDetail: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
messageId | string | The message ID of the unsent message |
Defined in
lib/webhook/model/unsendDetail.ts:13
UnsendEvent
Ƭ UnsendEvent: EventBase
& { type
: "unsend"
; unsend
: UnsendDetail
}
Defined in
lib/webhook/model/unsendEvent.ts:24
lib/webhook/model/unsendEvent.ts:31
UserMentionee
Ƭ UserMentionee: MentioneeBase
& { type
: "user"
; userId?
: string
}
Defined in
lib/webhook/model/userMentionee.ts:20
UserSource
Ƭ UserSource: SourceBase
& { type
: "user"
; userId?
: string
}
Defined in
lib/webhook/model/userSource.ts:17
VideoMessageContent
Ƭ VideoMessageContent: MessageContentBase
& { contentProvider
: ContentProvider
; duration?
: number
; quoteToken
: string
; type
: "video"
}
Defined in
lib/webhook/model/videoMessageContent.ts:18
VideoPlayComplete
Ƭ VideoPlayComplete: Object
Webhook Type Definition Webhook event definition of the LINE Messaging API
The version of the OpenAPI document: 1.0.0
NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). https://openapi-generator.tech Do not edit the class manually.
Type declaration
Name | Type | Description |
---|---|---|
trackingId | string | ID used to identify a video. Returns the same value as the trackingId assigned to the video message. |
Defined in
lib/webhook/model/videoPlayComplete.ts:13
VideoPlayCompleteEvent
Ƭ VideoPlayCompleteEvent: EventBase
& { replyToken
: string
; type
: "videoPlayComplete"
; videoPlayComplete
: VideoPlayComplete
}