Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/amqplib

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/amqplib - npm Package Compare versions

Comparing version 0.10.1 to 0.10.2

91

amqplib/callback_api.d.ts

@@ -1,4 +0,4 @@

import events = require('events');
import { Replies, Options, Message, ServerProperties } from './properties';
export * from './properties';
import events = require("events");
import { Message, Options, Replies, ServerProperties } from "./properties";
export * from "./properties";

@@ -19,18 +19,59 @@ export interface Connection extends events.EventEmitter {

assertQueue(queue?: string, options?: Options.AssertQueue, callback?: (err: any, ok: Replies.AssertQueue) => void): void;
assertQueue(
queue?: string,
options?: Options.AssertQueue,
callback?: (err: any, ok: Replies.AssertQueue) => void,
): void;
checkQueue(queue: string, callback?: (err: any, ok: Replies.AssertQueue) => void): void;
deleteQueue(queue: string, options?: Options.DeleteQueue, callback?: (err: any, ok: Replies.DeleteQueue) => void): void;
deleteQueue(
queue: string,
options?: Options.DeleteQueue,
callback?: (err: any, ok: Replies.DeleteQueue) => void,
): void;
purgeQueue(queue: string, callback?: (err: any, ok: Replies.PurgeQueue) => void): void;
bindQueue(queue: string, source: string, pattern: string, args?: any, callback?: (err: any, ok: Replies.Empty) => void): void;
unbindQueue(queue: string, source: string, pattern: string, args?: any, callback?: (err: any, ok: Replies.Empty) => void): void;
bindQueue(
queue: string,
source: string,
pattern: string,
args?: any,
callback?: (err: any, ok: Replies.Empty) => void,
): void;
unbindQueue(
queue: string,
source: string,
pattern: string,
args?: any,
callback?: (err: any, ok: Replies.Empty) => void,
): void;
assertExchange(exchange: string, type: string, options?: Options.AssertExchange, callback?: (err: any, ok: Replies.AssertExchange) => void): void;
assertExchange(
exchange: string,
type: string,
options?: Options.AssertExchange,
callback?: (err: any, ok: Replies.AssertExchange) => void,
): void;
checkExchange(exchange: string, callback?: (err: any, ok: Replies.Empty) => void): void;
deleteExchange(exchange: string, options?: Options.DeleteExchange, callback?: (err: any, ok: Replies.Empty) => void): void;
deleteExchange(
exchange: string,
options?: Options.DeleteExchange,
callback?: (err: any, ok: Replies.Empty) => void,
): void;
bindExchange(destination: string, source: string, pattern: string, args?: any, callback?: (err: any, ok: Replies.Empty) => void): void;
unbindExchange(destination: string, source: string, pattern: string, args?: any, callback?: (err: any, ok: Replies.Empty) => void): void;
bindExchange(
destination: string,
source: string,
pattern: string,
args?: any,
callback?: (err: any, ok: Replies.Empty) => void,
): void;
unbindExchange(
destination: string,
source: string,
pattern: string,
args?: any,
callback?: (err: any, ok: Replies.Empty) => void,
): void;

@@ -40,3 +81,8 @@ publish(exchange: string, routingKey: string, content: Buffer, options?: Options.Publish): boolean;

consume(queue: string, onMessage: (msg: Message | null) => void, options?: Options.Consume, callback?: (err: any, ok: Replies.Consume) => void): void;
consume(
queue: string,
onMessage: (msg: Message | null) => void,
options?: Options.Consume,
callback?: (err: any, ok: Replies.Consume) => void,
): void;

@@ -58,4 +104,15 @@ cancel(consumerTag: string, callback?: (err: any, ok: Replies.Empty) => void): void;

export interface ConfirmChannel extends Channel {
publish(exchange: string, routingKey: string, content: Buffer, options?: Options.Publish, callback?: (err: any, ok: Replies.Empty) => void): boolean;
sendToQueue(queue: string, content: Buffer, options?: Options.Publish, callback?: (err: any, ok: Replies.Empty) => void): boolean;
publish(
exchange: string,
routingKey: string,
content: Buffer,
options?: Options.Publish,
callback?: (err: any, ok: Replies.Empty) => void,
): boolean;
sendToQueue(
queue: string,
content: Buffer,
options?: Options.Publish,
callback?: (err: any, ok: Replies.Empty) => void,
): boolean;

@@ -86,2 +143,6 @@ waitForConfirms(callback?: (err: any) => void): void;

export function connect(url: string | Options.Connect, callback: (err: any, connection: Connection) => void): void;
export function connect(url: string | Options.Connect, socketOptions: any, callback: (err: any, connection: Connection) => void): void;
export function connect(
url: string | Options.Connect,
socketOptions: any,
callback: (err: any, connection: Connection) => void,
): void;

33

amqplib/index.d.ts

@@ -14,5 +14,5 @@ // Type definitions for amqplib 0.10

import * as events from 'events';
import { Replies, Options, Message, GetMessage, ConsumeMessage, ServerProperties } from './properties';
export * from './properties';
import * as events from "events";
import { ConsumeMessage, GetMessage, Message, Options, Replies, ServerProperties } from "./properties";
export * from "./properties";

@@ -42,3 +42,7 @@ export interface Connection extends events.EventEmitter {

assertExchange(exchange: string, type: 'direct' | 'topic' | 'headers' | 'fanout' | 'match' | string, options?: Options.AssertExchange): Promise<Replies.AssertExchange>;
assertExchange(
exchange: string,
type: "direct" | "topic" | "headers" | "fanout" | "match" | string,
options?: Options.AssertExchange,
): Promise<Replies.AssertExchange>;
checkExchange(exchange: string): Promise<Replies.Empty>;

@@ -54,3 +58,7 @@

consume(queue: string, onMessage: (msg: ConsumeMessage | null) => void, options?: Options.Consume): Promise<Replies.Consume>;
consume(
queue: string,
onMessage: (msg: ConsumeMessage | null) => void,
options?: Options.Consume,
): Promise<Replies.Consume>;

@@ -72,4 +80,15 @@ cancel(consumerTag: string): Promise<Replies.Empty>;

export interface ConfirmChannel extends Channel {
publish(exchange: string, routingKey: string, content: Buffer, options?: Options.Publish, callback?: (err: any, ok: Replies.Empty) => void): boolean;
sendToQueue(queue: string, content: Buffer, options?: Options.Publish, callback?: (err: any, ok: Replies.Empty) => void): boolean;
publish(
exchange: string,
routingKey: string,
content: Buffer,
options?: Options.Publish,
callback?: (err: any, ok: Replies.Empty) => void,
): boolean;
sendToQueue(
queue: string,
content: Buffer,
options?: Options.Publish,
callback?: (err: any, ok: Replies.Empty) => void,
): boolean;

@@ -76,0 +95,0 @@ waitForConfirms(): Promise<void>;

{
"name": "@types/amqplib",
"version": "0.10.1",
"version": "0.10.2",
"description": "TypeScript definitions for amqplib",

@@ -50,4 +50,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/amqplib",

},
"typesPublisherContentHash": "64242b0f780db5977f7f101045ba047b4acfca16d72e3440c334fb54f65ecb0d",
"typeScriptVersion": "4.2"
"typesPublisherContentHash": "ecd990b340f31d3a1334ceed7c0388373fd7cc4d26ced0c34d72d9f8d82f2036",
"typeScriptVersion": "4.5"
}

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Mon, 19 Dec 2022 11:02:10 GMT
* Last updated: Fri, 22 Sep 2023 18:11:03 GMT
* Dependencies: [@types/node](https://npmjs.com/package/@types/node)

@@ -14,0 +14,0 @@ * Global values: none

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc