/**
 * Returns an array of two arrays, one will all resolved promises, and one with all rejected promises
 */
export declare const robustPromiseAll: <T, E = Error>(promises: Promise<T>[]) => Promise<[T[], E[]]>;
export declare const groupResolvePromises: <T, E = Error>(promiseList: Promise<T>[], evaluationFn: (res: T) => boolean, maxLosses: number, minWins: number) => Promise<{
    success: boolean;
    wins: T[];
    losses: T[];
    errors: E[];
}>;
/**
 * Wraps an async function call with a max timeout.
 * @param fn - The async function to call.
 * @param timeoutMs - The maximum time in milliseconds to wait for the function to complete.
 * @returns A promise that resolves with the function's return value, or "timeout" if the timeout expires first.
 */
export declare function withTimeout<T>(fn: () => Promise<T>, timeoutMs: number): Promise<T | 'timeout'>;
export declare const fireAndForget: (fn: () => Promise<unknown>, onError?: (error: Error) => void) => void;
