import { Exchange } from 'amqp-ts'; import { ExchangeOptions, MessageOptions, ProducerConfig } from '../types'; /** * The main Producer object, primarily used for publishing messages to * exchanges. Note that a connection is created before the publish event * and then closed after the event resolves. */ declare class RabbitProducer { private config; private connection; constructor(config: ProducerConfig); connect(): void; declareExchange(exchange: string, exchangeOptions: ExchangeOptions): Exchange; publish(content: T, routingKey: string, options: MessageOptions): Promise; } export default RabbitProducer;