UNPKG

@broid/kit

Version:

Bot framework supported all messaging plateforms and middlewares.

31 lines (24 loc) 820 B
import { IActivityStream } from '@broid/schemas'; import { Observable } from 'rxjs/Rx'; export type callbackType = (message: any, error?: any) => any; export type middlewareIncomingType = (bot: any, message: any, acc?: any) => Promise<any> | Observable<any>; export type middlewareOutgoingType = (bot: any, content: string, message: IActivityStream, acc?: any) => Promise<any> | Observable<any>; export interface IHTTPOptions { host: string; port: number; } export interface IListenerArgs { callback?: callbackType ; msgTypes?: string | void; } export interface IMetaMediaSend { name?: string; content?: string; } export interface IOptions { logLevel?: string; http?: IHTTPOptions; }