mezon-js 2.8.83 → 2.8.84
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 +10 -5
- package/client.ts +3 -2
- package/dist/api.gen.d.ts +1 -1
- package/dist/client.d.ts +1 -1
- package/dist/mezon-js.cjs.js +9 -6
- package/dist/mezon-js.esm.mjs +9 -6
- package/package.json +1 -1
package/api.gen.ts
CHANGED
|
@@ -4127,14 +4127,19 @@ export class MezonApi {
|
|
|
4127
4127
|
|
|
4128
4128
|
/** */
|
|
4129
4129
|
deleteCategoryDesc(bearerToken: string,
|
|
4130
|
-
|
|
4130
|
+
categoryId:string,
|
|
4131
|
+
clanId:string,
|
|
4131
4132
|
options: any = {}): Promise<any> {
|
|
4132
4133
|
|
|
4133
|
-
if (
|
|
4134
|
-
throw new Error("'
|
|
4134
|
+
if (categoryId === null || categoryId === undefined) {
|
|
4135
|
+
throw new Error("'categoryId' is a required parameter but is null or undefined.");
|
|
4135
4136
|
}
|
|
4136
|
-
|
|
4137
|
-
|
|
4137
|
+
if (clanId === null || clanId === undefined) {
|
|
4138
|
+
throw new Error("'clanId' is a required parameter but is null or undefined.");
|
|
4139
|
+
}
|
|
4140
|
+
const urlPath = "/v2/deletecategory/category_id/{categoryId}/clan_id/{clanId}"
|
|
4141
|
+
.replace("{categoryId}", encodeURIComponent(String(categoryId)))
|
|
4142
|
+
.replace("{clanId}", encodeURIComponent(String(clanId)));
|
|
4138
4143
|
const queryParams = new Map<string, any>();
|
|
4139
4144
|
|
|
4140
4145
|
let bodyJson : string = "";
|
package/client.ts
CHANGED
|
@@ -1055,7 +1055,8 @@ export class Client {
|
|
|
1055
1055
|
/** Delete a category by ID. */
|
|
1056
1056
|
async deleteCategoryDesc(
|
|
1057
1057
|
session: Session,
|
|
1058
|
-
|
|
1058
|
+
categoryId: string,
|
|
1059
|
+
clanId: string,
|
|
1059
1060
|
): Promise<boolean> {
|
|
1060
1061
|
if (
|
|
1061
1062
|
this.autoRefreshSession &&
|
|
@@ -1066,7 +1067,7 @@ export class Client {
|
|
|
1066
1067
|
}
|
|
1067
1068
|
|
|
1068
1069
|
return this.apiClient
|
|
1069
|
-
.deleteCategoryDesc(session.token,
|
|
1070
|
+
.deleteCategoryDesc(session.token, categoryId, clanId)
|
|
1070
1071
|
.then((response: any) => {
|
|
1071
1072
|
return response !== undefined;
|
|
1072
1073
|
});
|
package/dist/api.gen.d.ts
CHANGED
|
@@ -1121,7 +1121,7 @@ export declare class MezonApi {
|
|
|
1121
1121
|
/** */
|
|
1122
1122
|
createCategoryDesc(bearerToken: string, body: ApiCreateCategoryDescRequest, options?: any): Promise<ApiCategoryDesc>;
|
|
1123
1123
|
/** */
|
|
1124
|
-
deleteCategoryDesc(bearerToken: string,
|
|
1124
|
+
deleteCategoryDesc(bearerToken: string, categoryId: string, clanId: string, options?: any): Promise<any>;
|
|
1125
1125
|
/** */
|
|
1126
1126
|
deleteCategoryOrder(bearerToken: string, clanId: string, options?: any): Promise<any>;
|
|
1127
1127
|
/** regist fcm device token */
|
package/dist/client.d.ts
CHANGED
|
@@ -375,7 +375,7 @@ export declare class Client {
|
|
|
375
375
|
/** Delete a clan desc by ID. */
|
|
376
376
|
deleteClanDesc(session: Session, clanDescId: string): Promise<boolean>;
|
|
377
377
|
/** Delete a category by ID. */
|
|
378
|
-
deleteCategoryDesc(session: Session,
|
|
378
|
+
deleteCategoryDesc(session: Session, categoryId: string, clanId: string): Promise<boolean>;
|
|
379
379
|
/** Delete one or more notifications */
|
|
380
380
|
deleteNotifications(session: Session, ids?: Array<string>): Promise<boolean>;
|
|
381
381
|
/** Delete a role by ID. */
|
package/dist/mezon-js.cjs.js
CHANGED
|
@@ -2571,11 +2571,14 @@ var MezonApi = class {
|
|
|
2571
2571
|
]);
|
|
2572
2572
|
}
|
|
2573
2573
|
/** */
|
|
2574
|
-
deleteCategoryDesc(bearerToken,
|
|
2575
|
-
if (
|
|
2576
|
-
throw new Error("'
|
|
2574
|
+
deleteCategoryDesc(bearerToken, categoryId, clanId, options = {}) {
|
|
2575
|
+
if (categoryId === null || categoryId === void 0) {
|
|
2576
|
+
throw new Error("'categoryId' is a required parameter but is null or undefined.");
|
|
2577
2577
|
}
|
|
2578
|
-
|
|
2578
|
+
if (clanId === null || clanId === void 0) {
|
|
2579
|
+
throw new Error("'clanId' is a required parameter but is null or undefined.");
|
|
2580
|
+
}
|
|
2581
|
+
const urlPath = "/v2/deletecategory/category_id/{categoryId}/clan_id/{clanId}".replace("{categoryId}", encodeURIComponent(String(categoryId))).replace("{clanId}", encodeURIComponent(String(clanId)));
|
|
2579
2582
|
const queryParams = /* @__PURE__ */ new Map();
|
|
2580
2583
|
let bodyJson = "";
|
|
2581
2584
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
|
@@ -5799,12 +5802,12 @@ var Client = class {
|
|
|
5799
5802
|
});
|
|
5800
5803
|
}
|
|
5801
5804
|
/** Delete a category by ID. */
|
|
5802
|
-
deleteCategoryDesc(session,
|
|
5805
|
+
deleteCategoryDesc(session, categoryId, clanId) {
|
|
5803
5806
|
return __async(this, null, function* () {
|
|
5804
5807
|
if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
|
|
5805
5808
|
yield this.sessionRefresh(session);
|
|
5806
5809
|
}
|
|
5807
|
-
return this.apiClient.deleteCategoryDesc(session.token,
|
|
5810
|
+
return this.apiClient.deleteCategoryDesc(session.token, categoryId, clanId).then((response) => {
|
|
5808
5811
|
return response !== void 0;
|
|
5809
5812
|
});
|
|
5810
5813
|
});
|
package/dist/mezon-js.esm.mjs
CHANGED
|
@@ -2542,11 +2542,14 @@ var MezonApi = class {
|
|
|
2542
2542
|
]);
|
|
2543
2543
|
}
|
|
2544
2544
|
/** */
|
|
2545
|
-
deleteCategoryDesc(bearerToken,
|
|
2546
|
-
if (
|
|
2547
|
-
throw new Error("'
|
|
2545
|
+
deleteCategoryDesc(bearerToken, categoryId, clanId, options = {}) {
|
|
2546
|
+
if (categoryId === null || categoryId === void 0) {
|
|
2547
|
+
throw new Error("'categoryId' is a required parameter but is null or undefined.");
|
|
2548
2548
|
}
|
|
2549
|
-
|
|
2549
|
+
if (clanId === null || clanId === void 0) {
|
|
2550
|
+
throw new Error("'clanId' is a required parameter but is null or undefined.");
|
|
2551
|
+
}
|
|
2552
|
+
const urlPath = "/v2/deletecategory/category_id/{categoryId}/clan_id/{clanId}".replace("{categoryId}", encodeURIComponent(String(categoryId))).replace("{clanId}", encodeURIComponent(String(clanId)));
|
|
2550
2553
|
const queryParams = /* @__PURE__ */ new Map();
|
|
2551
2554
|
let bodyJson = "";
|
|
2552
2555
|
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
|
@@ -5770,12 +5773,12 @@ var Client = class {
|
|
|
5770
5773
|
});
|
|
5771
5774
|
}
|
|
5772
5775
|
/** Delete a category by ID. */
|
|
5773
|
-
deleteCategoryDesc(session,
|
|
5776
|
+
deleteCategoryDesc(session, categoryId, clanId) {
|
|
5774
5777
|
return __async(this, null, function* () {
|
|
5775
5778
|
if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
|
|
5776
5779
|
yield this.sessionRefresh(session);
|
|
5777
5780
|
}
|
|
5778
|
-
return this.apiClient.deleteCategoryDesc(session.token,
|
|
5781
|
+
return this.apiClient.deleteCategoryDesc(session.token, categoryId, clanId).then((response) => {
|
|
5779
5782
|
return response !== void 0;
|
|
5780
5783
|
});
|
|
5781
5784
|
});
|