diff --git a/types/amqp/amqp-tests.ts b/types/amqp/amqp-tests.ts index 7940f44ed4..dfe38f2676 100644 --- a/types/amqp/amqp-tests.ts +++ b/types/amqp/amqp-tests.ts @@ -3,6 +3,7 @@ import * as amqp from 'amqp'; async function connect() { const promise = new Promise((resolve, reject) => { const client = amqp.createConnection({ + clientProperties: { applicationName: 'typing' }, url: 'amqp://admin:password@localhost:5672' }); diff --git a/types/amqp/index.d.ts b/types/amqp/index.d.ts index 374a03322b..ca39ce4404 100644 --- a/types/amqp/index.d.ts +++ b/types/amqp/index.d.ts @@ -1,6 +1,7 @@ // Type definitions for amqp 0.2 // Project: https://github.com/postwait/node-amqp // Definitions by: Carl Winkler +// Mark Line // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped /// @@ -125,6 +126,19 @@ export interface ConnectionOptions { /** Default: 1000 */ reconnectBackoffTime?: number; + + clientProperties?: { + applicationName?: string; + capabilities?: { + consumer_cancel_notify?: boolean + } + /** Default: 'node-' + process.version */ + platform?: string; + /** Default: node-amqp */ + product?: string; + /** Default: 'nodeAMQPVersion' */ + version?: string; + }; } export interface QueueOptions {