import { Duration } from '@arturwojnar/hermes';
import { JSONValue, Options, PostgresType } from 'postgres';
import { AsyncOrSync } from 'ts-essentials';
import { UseAsyncOutboxPolicy } from '../policies/useBasicAsyncStoragePolicy.js';
import { HermesMessageEnvelope, NowFunction } from './types.js';
type ConsumerCreationParams<Message extends JSONValue> = {
    getOptions: () => Options<Record<string, PostgresType>>;
    publish: (message: HermesMessageEnvelope<Message> | HermesMessageEnvelope<Message>[]) => AsyncOrSync<void> | never;
    consumerName: string;
    partitionKey?: string;
    waitAfterFailedPublish?: Duration;
    shouldDisposeOnSigterm?: boolean;
    saveTimestamps?: boolean;
    serialization?: boolean;
    onFailedPublish?: ErrorCallback;
    onDbError?: ErrorCallback;
    now?: NowFunction;
    asyncOutbox?: UseAsyncOutboxPolicy<Message>;
};
export type { ConsumerCreationParams };
