mezon-js 2.13.36 → 2.13.38

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/api.gen.ts CHANGED
@@ -2440,6 +2440,8 @@ export interface ApiSession {
2440
2440
  refresh_token?: string;
2441
2441
  //Authentication credentials.
2442
2442
  token?: string;
2443
+ // user id
2444
+ user_id?: string;
2443
2445
  // Whether to enable "Remember Me" for extended session duration.
2444
2446
  is_remember?: boolean;
2445
2447
  api_url?: string;
@@ -11381,6 +11383,7 @@ export class MezonApi {
11381
11383
  /** */
11382
11384
  deleteQuickMenuAccess(bearerToken: string,
11383
11385
  id?:string,
11386
+ clanId?: string,
11384
11387
  botId?:string,
11385
11388
  menuName?:string,
11386
11389
  background?:string,
@@ -11390,6 +11393,7 @@ export class MezonApi {
11390
11393
  const urlPath = "/v2/quickmenuaccess";
11391
11394
  const queryParams = new Map<string, any>();
11392
11395
  queryParams.set("id", id);
11396
+ queryParams.set("clan_id", clanId);
11393
11397
  queryParams.set("bot_id", botId);
11394
11398
  queryParams.set("menu_name", menuName);
11395
11399
  queryParams.set("background", background);
package/client.ts CHANGED
@@ -4842,7 +4842,8 @@ export class Client {
4842
4842
 
4843
4843
  async deleteQuickMenuAccess(
4844
4844
  session: Session,
4845
- id: string
4845
+ id: string,
4846
+ clanId: string
4846
4847
  ): Promise<any> {
4847
4848
  if (
4848
4849
  this.autoRefreshSession &&
@@ -4853,7 +4854,7 @@ export class Client {
4853
4854
  }
4854
4855
 
4855
4856
  return this.apiClient
4856
- .deleteQuickMenuAccess(session.token, id)
4857
+ .deleteQuickMenuAccess(session.token, id, clanId)
4857
4858
  .then((response: any) => {
4858
4859
  return response !== undefined;
4859
4860
  });
package/dist/api.gen.d.ts CHANGED
@@ -1396,6 +1396,7 @@ export interface ApiSession {
1396
1396
  created?: boolean;
1397
1397
  refresh_token?: string;
1398
1398
  token?: string;
1399
+ user_id?: string;
1399
1400
  is_remember?: boolean;
1400
1401
  api_url?: string;
1401
1402
  }
@@ -2382,7 +2383,7 @@ export declare class MezonApi {
2382
2383
  /** Discover mezon clan. */
2383
2384
  clanDiscover(basicAuthUsername: string, basicAuthPassword: string, basePath: string, body: ApiClanDiscoverRequest, options?: any): Promise<ApiListClanDiscover>;
2384
2385
  /** */
2385
- deleteQuickMenuAccess(bearerToken: string, id?: string, botId?: string, menuName?: string, background?: string, actionMsg?: string, options?: any): Promise<any>;
2386
+ deleteQuickMenuAccess(bearerToken: string, id?: string, clanId?: string, botId?: string, menuName?: string, background?: string, actionMsg?: string, options?: any): Promise<any>;
2386
2387
  /** */
2387
2388
  listQuickMenuAccess(bearerToken: string, botId?: string, channelId?: string, menuType?: number, options?: any): Promise<ApiQuickMenuAccessList>;
2388
2389
  /** */
package/dist/client.d.ts CHANGED
@@ -525,7 +525,7 @@ export declare class Client {
525
525
  /** list clan discover. */
526
526
  listClanDiscover(basePath: string, request: ApiClanDiscoverRequest): Promise<ApiListClanDiscover>;
527
527
  listQuickMenuAccess(session: Session, botId: string, channelId: string, menuType: number): Promise<ApiQuickMenuAccessList>;
528
- deleteQuickMenuAccess(session: Session, id: string): Promise<any>;
528
+ deleteQuickMenuAccess(session: Session, id: string, clanId: string): Promise<any>;
529
529
  addQuickMenuAccess(session: Session, request: ApiQuickMenuAccessRequest): Promise<any>;
530
530
  updateQuickMenuAccess(session: Session, request: ApiQuickMenuAccessRequest): Promise<any>;
531
531
  unlockItem(session: Session, request: ApiUnlockedItemRequest): Promise<ApiUnlockedItemResponse>;
@@ -6917,10 +6917,11 @@ var MezonApi = class {
6917
6917
  ]);
6918
6918
  }
6919
6919
  /** */
6920
- deleteQuickMenuAccess(bearerToken, id, botId, menuName, background, actionMsg, options = {}) {
6920
+ deleteQuickMenuAccess(bearerToken, id, clanId, botId, menuName, background, actionMsg, options = {}) {
6921
6921
  const urlPath = "/v2/quickmenuaccess";
6922
6922
  const queryParams = /* @__PURE__ */ new Map();
6923
6923
  queryParams.set("id", id);
6924
+ queryParams.set("clan_id", clanId);
6924
6925
  queryParams.set("bot_id", botId);
6925
6926
  queryParams.set("menu_name", menuName);
6926
6927
  queryParams.set("background", background);
@@ -11098,12 +11099,12 @@ var Client = class {
11098
11099
  });
11099
11100
  });
11100
11101
  }
11101
- deleteQuickMenuAccess(session, id) {
11102
+ deleteQuickMenuAccess(session, id, clanId) {
11102
11103
  return __async(this, null, function* () {
11103
11104
  if (this.autoRefreshSession && session.refresh_token && session.isexpired(Date.now() / 1e3)) {
11104
11105
  yield this.sessionRefresh(session);
11105
11106
  }
11106
- return this.apiClient.deleteQuickMenuAccess(session.token, id).then((response) => {
11107
+ return this.apiClient.deleteQuickMenuAccess(session.token, id, clanId).then((response) => {
11107
11108
  return response !== void 0;
11108
11109
  });
11109
11110
  });
@@ -6883,10 +6883,11 @@ var MezonApi = class {
6883
6883
  ]);
6884
6884
  }
6885
6885
  /** */
6886
- deleteQuickMenuAccess(bearerToken, id, botId, menuName, background, actionMsg, options = {}) {
6886
+ deleteQuickMenuAccess(bearerToken, id, clanId, botId, menuName, background, actionMsg, options = {}) {
6887
6887
  const urlPath = "/v2/quickmenuaccess";
6888
6888
  const queryParams = /* @__PURE__ */ new Map();
6889
6889
  queryParams.set("id", id);
6890
+ queryParams.set("clan_id", clanId);
6890
6891
  queryParams.set("bot_id", botId);
6891
6892
  queryParams.set("menu_name", menuName);
6892
6893
  queryParams.set("background", background);
@@ -11064,12 +11065,12 @@ var Client = class {
11064
11065
  });
11065
11066
  });
11066
11067
  }
11067
- deleteQuickMenuAccess(session, id) {
11068
+ deleteQuickMenuAccess(session, id, clanId) {
11068
11069
  return __async(this, null, function* () {
11069
11070
  if (this.autoRefreshSession && session.refresh_token && session.isexpired(Date.now() / 1e3)) {
11070
11071
  yield this.sessionRefresh(session);
11071
11072
  }
11072
- return this.apiClient.deleteQuickMenuAccess(session.token, id).then((response) => {
11073
+ return this.apiClient.deleteQuickMenuAccess(session.token, id, clanId).then((response) => {
11073
11074
  return response !== void 0;
11074
11075
  });
11075
11076
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mezon-js",
3
- "version": "2.13.36",
3
+ "version": "2.13.38",
4
4
  "scripts": {
5
5
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
6
6
  },