@bothive/helpers
Version:
Collection of helper functions mainly used inside bothive-core project
14 lines (13 loc) • 548 B
TypeScript
import { IMissingFields } from "../interfaces/error.interfaces";
declare function checkForMissingRequiredKeys({ payload, keys, message, meta }: IMissingFields): void;
declare function retryHandler<Type>({ callback, limit, timeout, onError, }: {
callback: () => Promise<Type> | Type;
onError?: (error: Error) => void;
limit?: number;
timeout?: number;
}): Promise<Type>;
declare const _default: {
checkForMissingRequiredKeys: typeof checkForMissingRequiredKeys;
retryHandler: typeof retryHandler;
};
export default _default;