mezon-js 2.8.98 → 2.9.1
Sign up to get free protection for your applications and to get access to all the features.
- package/api.gen.ts +9 -4
- package/client.ts +1 -0
- package/dist/api.gen.d.ts +6 -2
- package/dist/client.d.ts +1 -0
- package/dist/mezon-js.cjs.js +1 -2
- package/dist/mezon-js.esm.mjs +1 -2
- package/package.json +1 -1
package/api.gen.ts
CHANGED
@@ -188,6 +188,8 @@ export interface MezonUpdateRoleBody {
|
|
188
188
|
description?: string;
|
189
189
|
//
|
190
190
|
display_online?: number;
|
191
|
+
//
|
192
|
+
max_permission_id: string;
|
191
193
|
//The permissions to remove.
|
192
194
|
remove_permission_ids?: Array<string>;
|
193
195
|
//The users to remove.
|
@@ -819,6 +821,8 @@ export interface ApiCreateRoleRequest {
|
|
819
821
|
//
|
820
822
|
display_online?: number;
|
821
823
|
//
|
824
|
+
max_permission_id: string;
|
825
|
+
//
|
822
826
|
role_icon?: string;
|
823
827
|
//
|
824
828
|
title?: string;
|
@@ -1260,6 +1264,8 @@ export interface ApiPermissionUpdate {
|
|
1260
1264
|
//
|
1261
1265
|
permission_id?: string;
|
1262
1266
|
//
|
1267
|
+
slug?: string;
|
1268
|
+
//
|
1263
1269
|
type?: number;
|
1264
1270
|
}
|
1265
1271
|
|
@@ -1625,7 +1631,9 @@ export interface ApiUpdateCategoryOrderRequest {
|
|
1625
1631
|
/** */
|
1626
1632
|
export interface ApiUpdateRoleChannelRequest {
|
1627
1633
|
//
|
1628
|
-
channel_id
|
1634
|
+
channel_id: string;
|
1635
|
+
//
|
1636
|
+
max_permission_id: string;
|
1629
1637
|
//The permissions to add.
|
1630
1638
|
permission_update?: Array<ApiPermissionUpdate>;
|
1631
1639
|
//The ID of the role to update.
|
@@ -5960,7 +5968,6 @@ export class MezonApi {
|
|
5960
5968
|
roleId:string,
|
5961
5969
|
channelId?:string,
|
5962
5970
|
clanId?:string,
|
5963
|
-
maxPermissionsLevel?:string,
|
5964
5971
|
options: any = {}): Promise<any> {
|
5965
5972
|
|
5966
5973
|
if (roleId === null || roleId === undefined) {
|
@@ -5971,8 +5978,6 @@ export class MezonApi {
|
|
5971
5978
|
const queryParams = new Map<string, any>();
|
5972
5979
|
queryParams.set("channel_id", channelId);
|
5973
5980
|
queryParams.set("clan_id", clanId);
|
5974
|
-
queryParams.set("max_permissions_level", maxPermissionsLevel);
|
5975
|
-
|
5976
5981
|
let bodyJson : string = "";
|
5977
5982
|
|
5978
5983
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
package/client.ts
CHANGED
package/dist/api.gen.d.ts
CHANGED
@@ -107,6 +107,7 @@ export interface MezonUpdateRoleBody {
|
|
107
107
|
color?: string;
|
108
108
|
description?: string;
|
109
109
|
display_online?: number;
|
110
|
+
max_permission_id: string;
|
110
111
|
remove_permission_ids?: Array<string>;
|
111
112
|
remove_user_ids?: Array<string>;
|
112
113
|
role_icon?: string;
|
@@ -467,6 +468,7 @@ export interface ApiCreateRoleRequest {
|
|
467
468
|
color?: string;
|
468
469
|
description?: string;
|
469
470
|
display_online?: number;
|
471
|
+
max_permission_id: string;
|
470
472
|
role_icon?: string;
|
471
473
|
title?: string;
|
472
474
|
}
|
@@ -729,6 +731,7 @@ export interface ApiPermissionList {
|
|
729
731
|
/** */
|
730
732
|
export interface ApiPermissionUpdate {
|
731
733
|
permission_id?: string;
|
734
|
+
slug?: string;
|
732
735
|
type?: number;
|
733
736
|
}
|
734
737
|
/** */
|
@@ -942,7 +945,8 @@ export interface ApiUpdateCategoryOrderRequest {
|
|
942
945
|
}
|
943
946
|
/** */
|
944
947
|
export interface ApiUpdateRoleChannelRequest {
|
945
|
-
channel_id
|
948
|
+
channel_id: string;
|
949
|
+
max_permission_id: string;
|
946
950
|
permission_update?: Array<ApiPermissionUpdate>;
|
947
951
|
role_id?: string;
|
948
952
|
}
|
@@ -1271,7 +1275,7 @@ export declare class MezonApi {
|
|
1271
1275
|
/** Update a role when Delete a role by ID. */
|
1272
1276
|
updateRoleDelete(bearerToken: string, roleId: string, body: MezonUpdateRoleDeleteBody, options?: any): Promise<any>;
|
1273
1277
|
/** Delete a role by ID. */
|
1274
|
-
deleteRole(bearerToken: string, roleId: string, channelId?: string, clanId?: string,
|
1278
|
+
deleteRole(bearerToken: string, roleId: string, channelId?: string, clanId?: string, options?: any): Promise<any>;
|
1275
1279
|
/** Update fields in a given role. */
|
1276
1280
|
updateRole(bearerToken: string, roleId: string, body: MezonUpdateRoleBody, options?: any): Promise<any>;
|
1277
1281
|
/** List role permissions */
|
package/dist/client.d.ts
CHANGED
package/dist/mezon-js.cjs.js
CHANGED
@@ -3941,7 +3941,7 @@ var MezonApi = class {
|
|
3941
3941
|
]);
|
3942
3942
|
}
|
3943
3943
|
/** Delete a role by ID. */
|
3944
|
-
deleteRole(bearerToken, roleId, channelId, clanId,
|
3944
|
+
deleteRole(bearerToken, roleId, channelId, clanId, options = {}) {
|
3945
3945
|
if (roleId === null || roleId === void 0) {
|
3946
3946
|
throw new Error("'roleId' is a required parameter but is null or undefined.");
|
3947
3947
|
}
|
@@ -3949,7 +3949,6 @@ var MezonApi = class {
|
|
3949
3949
|
const queryParams = /* @__PURE__ */ new Map();
|
3950
3950
|
queryParams.set("channel_id", channelId);
|
3951
3951
|
queryParams.set("clan_id", clanId);
|
3952
|
-
queryParams.set("max_permissions_level", maxPermissionsLevel);
|
3953
3952
|
let bodyJson = "";
|
3954
3953
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
3955
3954
|
const fetchOptions = buildFetchOptions("DELETE", options, bodyJson);
|
package/dist/mezon-js.esm.mjs
CHANGED
@@ -3912,7 +3912,7 @@ var MezonApi = class {
|
|
3912
3912
|
]);
|
3913
3913
|
}
|
3914
3914
|
/** Delete a role by ID. */
|
3915
|
-
deleteRole(bearerToken, roleId, channelId, clanId,
|
3915
|
+
deleteRole(bearerToken, roleId, channelId, clanId, options = {}) {
|
3916
3916
|
if (roleId === null || roleId === void 0) {
|
3917
3917
|
throw new Error("'roleId' is a required parameter but is null or undefined.");
|
3918
3918
|
}
|
@@ -3920,7 +3920,6 @@ var MezonApi = class {
|
|
3920
3920
|
const queryParams = /* @__PURE__ */ new Map();
|
3921
3921
|
queryParams.set("channel_id", channelId);
|
3922
3922
|
queryParams.set("clan_id", clanId);
|
3923
|
-
queryParams.set("max_permissions_level", maxPermissionsLevel);
|
3924
3923
|
let bodyJson = "";
|
3925
3924
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
3926
3925
|
const fetchOptions = buildFetchOptions("DELETE", options, bodyJson);
|