UNPKG

tami

Version:

Typescript client for asterisk's AMI

19 lines (18 loc) 642 B
/// <reference types="node" /> import { EventEmitter } from 'events'; import AuthOptions from './interfaces/AuthOptions'; import { Connection } from './Connection'; export declare class Ami extends EventEmitter { readonly user: string; readonly secret: string; readonly conn: Connection; private keepAliveTimeoutRef; private functions; constructor(authOpts: AuthOptions, host: string, port?: number); connect(): Promise<Connection>; action(action: Record<string, string>): Promise<Record<string, string>>; private keepAlive; private sendAuth; private handleData; private addResponseListener; }