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

@pusher/chatkit-server

Package Overview
Dependencies
Maintainers
9
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pusher/chatkit-server - npm Package Compare versions

Comparing version 2.1.1 to 2.2.0

36

CHANGELOG.md

@@ -8,4 +8,10 @@ # Changelog

## [Unreleased](https://github.com/pusher/chatkit-server-node/compare/2.1.1...HEAD)
## [Unreleased](https://github.com/pusher/chatkit-server-node/compare/2.2.0...HEAD)
## [2.2.0](https://github.com/pusher/chatkit-server-node/compare/2.1.1...2.2.0)
### Additions
- Support for fetching a message by its message ID, via `fetchMultipartMessage`.
## [2.1.1](https://github.com/pusher/chatkit-server-node/compare/2.1.0...2.1.1)

@@ -40,3 +46,3 @@

- The `deleteMessage` method now *requires* a room ID parameter, `roomID`, and
- The `deleteMessage` method now _requires_ a room ID parameter, `roomID`, and
the `id` parameter has been renamed to `messageId` to avoid ambiguity.

@@ -164,5 +170,5 @@

* `status` is the suggested HTTP response status code,
* `headers` are the suggested response headers,
* `body` holds the token payload.
- `status` is the suggested HTTP response status code,
- `headers` are the suggested response headers,
- `body` holds the token payload.

@@ -188,5 +194,5 @@ If there's an error with the authentication process then the return value will be the same but with a different `body`. For example:

* Swift SDK - (**breaking change**) you must be using version `>= 0.8.0` of [chatkit-swift](https://github.com/pusher/chatkit-swift).
* Android SDK - you won't be affected regardless of which version you are running.
* JS SDK - you won't be affected regardless of which version you are running.
- Swift SDK - (**breaking change**) you must be using version `>= 0.8.0` of [chatkit-swift](https://github.com/pusher/chatkit-swift).
- Android SDK - you won't be affected regardless of which version you are running.
- JS SDK - you won't be affected regardless of which version you are running.

@@ -216,3 +222,3 @@ ## [0.11.2](https://github.com/pusher/chatkit-server-node/compare/0.11.1...0.11.2) - 2018-04-17

```js
chatkit.authenticate('my-user-id', { grant_type: 'client_credentials' });
chatkit.authenticate("my-user-id", { grant_type: "client_credentials" })
```

@@ -224,5 +230,5 @@

chatkit.authenticate({
userId: 'my-user-id',
authPayload: { grant_type: 'client_credentials' }
});
userId: "my-user-id",
authPayload: { grant_type: "client_credentials" },
})
```

@@ -233,3 +239,3 @@

```js
chatkit.createRoom('ham', 'New room');
chatkit.createRoom("ham", "New room")
```

@@ -241,4 +247,4 @@

chatkit.createRoom({
creatorId: 'ham',
name: 'New room'
creatorId: "ham",
name: "New room",
})

@@ -245,0 +251,0 @@ ```

{
"name": "@pusher/chatkit-server",
"description": "Pusher Chatkit server SDK",
"version": "2.1.1",
"version": "2.2.0",
"main": "target/src/index.js",

@@ -6,0 +6,0 @@ "license": "MIT",

{
"name": "@pusher/chatkit-server",
"description": "Pusher Chatkit server SDK",
"version": "2.1.1",
"version": "2.2.0",
"main": "target/src/index.js",

@@ -6,0 +6,0 @@ "license": "MIT",

@@ -132,2 +132,6 @@ /// <reference types="node" />

}
export interface FetchMultipartMessageOptions {
roomId: string;
messageId: string;
}
export declare type GetRoomMessagesOptions = FetchMultipartMessagesOptions;

@@ -228,2 +232,3 @@ export interface FetchMultipartMessagesOptions {

deleteMessage(options: DeleteMessageOptions): Promise<void>;
fetchMultipartMessage(options: FetchMultipartMessageOptions): Promise<any>;
getRoomMessages(options: GetRoomMessagesOptions): Promise<any>;

@@ -230,0 +235,0 @@ fetchMultipartMessages(options: FetchMultipartMessagesOptions): Promise<any>;

@@ -268,2 +268,11 @@ "use strict";

}
fetchMultipartMessage(options) {
return this.serverInstance
.request({
method: "GET",
path: `/rooms/${encodeURIComponent(options.roomId)}/messages/${encodeURIComponent(options.messageId)}`,
jwt: this.getServerToken(),
})
.then(res => JSON.parse(res.body));
}
getRoomMessages(options) {

@@ -270,0 +279,0 @@ return this.fetchMessages(Object.assign({}, options, { serverInstance: this.serverInstanceV2 }));

Sorry, the diff of this file is not supported yet

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