diff --git a/types/index.d.ts b/types/index.d.ts index 24058b6d..ed22355c 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -145,6 +145,20 @@ export class ProducerStream extends Writable { _writev (chunks: Chunk[], cb: (error: any, data: any) => any): void; } +export class Admin extends EventEmitter { + constructor (kafkaClient: KafkaClient); + + listTopics (cb?: () => void): void; + + listGroups (cb?: () => void): void; + + describeGroups (consumerGroups: ConsumerGroup[], cb?: () => void): void; + + createTopics (topics: string[], cb?: () => void): void; + + describeConfigs(payload: { resources: Resource[], includeSynonyms?: boolean }, cb?: () => void): void; +} + // # Interfaces export interface Message { @@ -348,3 +362,14 @@ export interface MetadataResponse extends Array