slack-web-api-client
Version:
Streamlined Slack Web API client for TypeScript
25 lines • 703 B
TypeScript
import type { SlackAPIClientLogLevel } from "../../logging/index";
export interface RetryHandlerState {
currentAttempt: number;
logLevel: SlackAPIClientLogLevel;
}
export type RetryHandlerArgs = RetryHandlerResponseArgs | RetryHandlerErrorArgs;
export interface RetryHandlerResponseArgs {
state: RetryHandlerState;
request: Request;
response: Response;
error?: Error;
}
export interface RetryHandlerErrorArgs {
state: RetryHandlerState;
request: Request;
response?: Response;
error: Error;
}
/**
* Retry handler interface
*/
export interface RetryHandler {
shouldRetry(args: RetryHandlerArgs): Promise<boolean>;
}
//# sourceMappingURL=retry-handler.d.ts.map