Options
All
  • Public
  • Public/Protected
  • All
Menu

Support for Whatsapp.

Hierarchy

  • GBService
    • WhatsappDirectLine

Index

Constructors

constructor

  • new WhatsappDirectLine(min: GBMinInstance, botId: any, directLineSecret: any, whatsappServiceKey: any, whatsappServiceNumber: any, whatsappServiceUrl: any): WhatsappDirectLine

Properties

botId

botId: string

directLineClient

directLineClient: any

directLineClientName

directLineClientName: string = "DirectLineClient"

Private directLineSecret

directLineSecret: string

Private locale

locale: string = "pt-BR"

min

min: GBMinInstance

pollInterval

pollInterval: number = 5000

whatsappServiceKey

whatsappServiceKey: string

whatsappServiceNumber

whatsappServiceNumber: string

whatsappServiceUrl

whatsappServiceUrl: string

Static conversationIds

conversationIds: {}

Type declaration

Methods

check

  • check(): Promise<boolean>

inputMessage

  • inputMessage(client: any, conversationId: any, text: any, from: any, fromName: any): any

pollMessages

  • pollMessages(client: any, conversationId: any, from: any, fromName: any): void

printMessage

  • printMessage(activity: any, conversationId: any, from: any, fromName: any): Promise<void>

printMessages

  • printMessages(activities: any, conversationId: any, from: any, fromName: any): Promise<void>

received

  • received(req: any, res: any): Promise<void>

renderHeroCard

  • renderHeroCard(attachment: any): string

resetConversationId

  • resetConversationId(number: any): Promise<void>

sendAudioToDevice

  • sendAudioToDevice(to: any, url: any): Promise<void>

sendFileToDevice

  • sendFileToDevice(to: any, url: any, filename: any, caption: any): Promise<void>

sendTextAsAudioToDevice

  • sendTextAsAudioToDevice(to: any, msg: any): Promise<void>

sendToDevice

  • sendToDevice(to: string, msg: string): Promise<void>

sendToDeviceEx

  • sendToDeviceEx(to: any, text: any, locale: any): Promise<void>

setup

  • setup(setUrl: any): Promise<void>

Static asyncForEach

  • asyncForEach(array: any, callback: any): Promise<void>

Generated using TypeDoc