import { Configuration } from "../../configuration"; import { EventFired } from "../../HandleEvent"; import { AutomationContextAware, HandlerContext } from "../../HandlerContext"; import { HandlerResult } from "../../HandlerResult"; import { AutomationEventListener } from "../../server/AutomationEventListener"; import { AutomationServer } from "../../server/AutomationServer"; import { GraphClient } from "../../spi/graph/GraphClient"; import { MessageClient, SlackMessageClient } from "../../spi/message/MessageClient"; import { CommandInvocation } from "../invoker/Payload"; import { CommandIncoming, EventIncoming, RequestProcessor } from "./RequestProcessor"; export declare abstract class AbstractRequestProcessor implements RequestProcessor { protected automations: AutomationServer; protected configuration: Configuration; protected listeners: AutomationEventListener[]; constructor(automations: AutomationServer, configuration: Configuration, listeners?: AutomationEventListener[]); processCommand(command: CommandIncoming, callback?: (result: Promise) => void): void; processEvent(event: EventIncoming, callback?: (results: Promise) => void): void; sendCommandStatus(success: boolean, code: number, request: CommandIncoming, ctx: HandlerContext & AutomationContextAware): Promise; sendEventStatus(success: boolean, request: EventFired, event: EventIncoming, ctx: HandlerContext & AutomationContextAware): Promise; protected invokeCommand(ci: CommandInvocation, ctx: HandlerContext & AutomationContextAware, command: CommandIncoming, callback: (result: Promise) => void): void; protected invokeEvent(ef: EventFired, ctx: HandlerContext & AutomationContextAware, event: EventIncoming, callback: (results: Promise) => void): void; protected createAndWrapMessageClient(event: EventIncoming | CommandIncoming, context: HandlerContext & AutomationContextAware): MessageClient & SlackMessageClient; protected setupNamespace(request: any, automations: AutomationServer, invocationId?: string, ts?: number): { correlationId: any; workspaceId: any; workspaceName: any; operation: any; name: string; version: string; invocationId: string; ts: number; }; protected clearNamespace(): void; protected abstract sendStatusMessage(payload: any, ctx: HandlerContext & AutomationContextAware): Promise; protected abstract createGraphClient(event: EventIncoming | CommandIncoming, context: HandlerContext & AutomationContextAware): GraphClient; protected abstract createMessageClient(event: EventIncoming | CommandIncoming, context: AutomationContextAware): MessageClient; private handleCommandError; private handleEventError; } export declare function defaultResult(context: AutomationContextAware): HandlerResult; export declare function defaultErrorResult(context: AutomationContextAware): HandlerResult; export declare function replacer(key: string, value: any): any; export declare function possibleAxiosObjectReplacer(key: string, value: any): any;