mezon-js 2.9.17 → 2.9.18
Sign up to get free protection for your applications and to get access to all the features.
- package/api.gen.ts +6 -0
- package/client.ts +4 -2
- package/dist/api.gen.d.ts +2 -1
- package/dist/client.d.ts +1 -1
- package/dist/mezon-js.cjs.js +5 -3
- package/dist/mezon-js.esm.mjs +5 -3
- package/package.json +1 -1
package/api.gen.ts
CHANGED
@@ -1496,6 +1496,8 @@ export interface ApiPinMessageRequest {
|
|
1496
1496
|
//
|
1497
1497
|
channel_id?: string;
|
1498
1498
|
//
|
1499
|
+
clan_id?: string;
|
1500
|
+
//
|
1499
1501
|
message_id?: string;
|
1500
1502
|
}
|
1501
1503
|
|
@@ -6277,12 +6279,16 @@ export class MezonApi {
|
|
6277
6279
|
|
6278
6280
|
/** */
|
6279
6281
|
getPinMessagesList(bearerToken: string,
|
6282
|
+
messageId?:string,
|
6280
6283
|
channelId?:string,
|
6284
|
+
clanId?:string,
|
6281
6285
|
options: any = {}): Promise<ApiPinMessagesList> {
|
6282
6286
|
|
6283
6287
|
const urlPath = "/v2/pinmessage/get";
|
6284
6288
|
const queryParams = new Map<string, any>();
|
6289
|
+
queryParams.set("message_id", messageId);
|
6285
6290
|
queryParams.set("channel_id", channelId);
|
6291
|
+
queryParams.set("clan_id", clanId);
|
6286
6292
|
|
6287
6293
|
let bodyJson : string = "";
|
6288
6294
|
|
package/client.ts
CHANGED
@@ -2994,7 +2994,9 @@ export class Client {
|
|
2994
2994
|
|
2995
2995
|
async pinMessagesList(
|
2996
2996
|
session: Session,
|
2997
|
-
|
2997
|
+
messageId: string,
|
2998
|
+
channelId: string,
|
2999
|
+
clanId: string,
|
2998
3000
|
): Promise<ApiPinMessagesList> {
|
2999
3001
|
if (
|
3000
3002
|
this.autoRefreshSession &&
|
@@ -3005,7 +3007,7 @@ export class Client {
|
|
3005
3007
|
}
|
3006
3008
|
|
3007
3009
|
return this.apiClient
|
3008
|
-
.getPinMessagesList(session.token, channelId)
|
3010
|
+
.getPinMessagesList(session.token, messageId, channelId, clanId)
|
3009
3011
|
.then((response: ApiPinMessagesList) => {
|
3010
3012
|
return Promise.resolve(response);
|
3011
3013
|
});
|
package/dist/api.gen.d.ts
CHANGED
@@ -866,6 +866,7 @@ export interface ApiPinMessage {
|
|
866
866
|
/** */
|
867
867
|
export interface ApiPinMessageRequest {
|
868
868
|
channel_id?: string;
|
869
|
+
clan_id?: string;
|
869
870
|
message_id?: string;
|
870
871
|
}
|
871
872
|
/** */
|
@@ -1420,7 +1421,7 @@ export declare class MezonApi {
|
|
1420
1421
|
/** */
|
1421
1422
|
deletePinMessage(bearerToken: string, messageId?: string, options?: any): Promise<any>;
|
1422
1423
|
/** */
|
1423
|
-
getPinMessagesList(bearerToken: string, channelId?: string, options?: any): Promise<ApiPinMessagesList>;
|
1424
|
+
getPinMessagesList(bearerToken: string, messageId?: string, channelId?: string, clanId?: string, options?: any): Promise<ApiPinMessagesList>;
|
1424
1425
|
/** set notification user channel. */
|
1425
1426
|
createPinMessage(bearerToken: string, body: ApiPinMessageRequest, options?: any): Promise<any>;
|
1426
1427
|
/** */
|
package/dist/client.d.ts
CHANGED
@@ -525,7 +525,7 @@ export declare class Client {
|
|
525
525
|
searchMessage(session: Session, request: ApiSearchMessageRequest): Promise<ApiSearchMessageResponse>;
|
526
526
|
/** */
|
527
527
|
createPinMessage(session: Session, request: ApiPinMessageRequest): Promise<boolean>;
|
528
|
-
pinMessagesList(session: Session, channelId: string): Promise<ApiPinMessagesList>;
|
528
|
+
pinMessagesList(session: Session, messageId: string, channelId: string, clanId: string): Promise<ApiPinMessagesList>;
|
529
529
|
deletePinMessage(session: Session, message_id: string): Promise<boolean>;
|
530
530
|
/** create clan emoji */
|
531
531
|
createClanEmoji(session: Session, request: ApiClanEmojiCreateRequest): Promise<boolean>;
|
package/dist/mezon-js.cjs.js
CHANGED
@@ -3997,10 +3997,12 @@ var MezonApi = class {
|
|
3997
3997
|
]);
|
3998
3998
|
}
|
3999
3999
|
/** */
|
4000
|
-
getPinMessagesList(bearerToken, channelId, options = {}) {
|
4000
|
+
getPinMessagesList(bearerToken, messageId, channelId, clanId, options = {}) {
|
4001
4001
|
const urlPath = "/v2/pinmessage/get";
|
4002
4002
|
const queryParams = /* @__PURE__ */ new Map();
|
4003
|
+
queryParams.set("message_id", messageId);
|
4003
4004
|
queryParams.set("channel_id", channelId);
|
4005
|
+
queryParams.set("clan_id", clanId);
|
4004
4006
|
let bodyJson = "";
|
4005
4007
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
4006
4008
|
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
@@ -7552,12 +7554,12 @@ var Client = class {
|
|
7552
7554
|
});
|
7553
7555
|
});
|
7554
7556
|
}
|
7555
|
-
pinMessagesList(session, channelId) {
|
7557
|
+
pinMessagesList(session, messageId, channelId, clanId) {
|
7556
7558
|
return __async(this, null, function* () {
|
7557
7559
|
if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
|
7558
7560
|
yield this.sessionRefresh(session);
|
7559
7561
|
}
|
7560
|
-
return this.apiClient.getPinMessagesList(session.token, channelId).then((response) => {
|
7562
|
+
return this.apiClient.getPinMessagesList(session.token, messageId, channelId, clanId).then((response) => {
|
7561
7563
|
return Promise.resolve(response);
|
7562
7564
|
});
|
7563
7565
|
});
|
package/dist/mezon-js.esm.mjs
CHANGED
@@ -3968,10 +3968,12 @@ var MezonApi = class {
|
|
3968
3968
|
]);
|
3969
3969
|
}
|
3970
3970
|
/** */
|
3971
|
-
getPinMessagesList(bearerToken, channelId, options = {}) {
|
3971
|
+
getPinMessagesList(bearerToken, messageId, channelId, clanId, options = {}) {
|
3972
3972
|
const urlPath = "/v2/pinmessage/get";
|
3973
3973
|
const queryParams = /* @__PURE__ */ new Map();
|
3974
|
+
queryParams.set("message_id", messageId);
|
3974
3975
|
queryParams.set("channel_id", channelId);
|
3976
|
+
queryParams.set("clan_id", clanId);
|
3975
3977
|
let bodyJson = "";
|
3976
3978
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
3977
3979
|
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
@@ -7523,12 +7525,12 @@ var Client = class {
|
|
7523
7525
|
});
|
7524
7526
|
});
|
7525
7527
|
}
|
7526
|
-
pinMessagesList(session, channelId) {
|
7528
|
+
pinMessagesList(session, messageId, channelId, clanId) {
|
7527
7529
|
return __async(this, null, function* () {
|
7528
7530
|
if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
|
7529
7531
|
yield this.sessionRefresh(session);
|
7530
7532
|
}
|
7531
|
-
return this.apiClient.getPinMessagesList(session.token, channelId).then((response) => {
|
7533
|
+
return this.apiClient.getPinMessagesList(session.token, messageId, channelId, clanId).then((response) => {
|
7532
7534
|
return Promise.resolve(response);
|
7533
7535
|
});
|
7534
7536
|
});
|