mezon-js 2.9.45 → 2.9.46
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 +42 -47
- package/dist/api.gen.d.ts +2 -2
- package/dist/mezon-js.cjs.js +31 -36
- package/dist/mezon-js.esm.mjs +31 -36
- package/package.json +1 -1
package/api.gen.ts
CHANGED
@@ -4010,6 +4010,48 @@ export class MezonApi {
|
|
4010
4010
|
]);
|
4011
4011
|
}
|
4012
4012
|
|
4013
|
+
/** */
|
4014
|
+
getChannelCanvasList(bearerToken: string,
|
4015
|
+
channelId:string,
|
4016
|
+
clanId?:string,
|
4017
|
+
limit?:number,
|
4018
|
+
page?:number,
|
4019
|
+
options: any = {}): Promise<ApiChannelCanvasListResponse> {
|
4020
|
+
|
4021
|
+
if (channelId === null || channelId === undefined) {
|
4022
|
+
throw new Error("'channelId' is a required parameter but is null or undefined.");
|
4023
|
+
}
|
4024
|
+
const urlPath = "/v2/channel-canvases/{channelId}"
|
4025
|
+
.replace("{channelId}", encodeURIComponent(String(channelId)));
|
4026
|
+
const queryParams = new Map<string, any>();
|
4027
|
+
queryParams.set("clan_id", clanId);
|
4028
|
+
queryParams.set("limit", limit);
|
4029
|
+
queryParams.set("page", page);
|
4030
|
+
|
4031
|
+
let bodyJson : string = "";
|
4032
|
+
|
4033
|
+
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
4034
|
+
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
4035
|
+
if (bearerToken) {
|
4036
|
+
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
4037
|
+
}
|
4038
|
+
|
4039
|
+
return Promise.race([
|
4040
|
+
fetch(fullUrl, fetchOptions).then((response) => {
|
4041
|
+
if (response.status == 204) {
|
4042
|
+
return response;
|
4043
|
+
} else if (response.status >= 200 && response.status < 300) {
|
4044
|
+
return response.json();
|
4045
|
+
} else {
|
4046
|
+
throw response;
|
4047
|
+
}
|
4048
|
+
}),
|
4049
|
+
new Promise((_, reject) =>
|
4050
|
+
setTimeout(reject, this.timeoutMs, "Request timed out.")
|
4051
|
+
),
|
4052
|
+
]);
|
4053
|
+
}
|
4054
|
+
|
4013
4055
|
/** */
|
4014
4056
|
addChannelFavorite(bearerToken: string,
|
4015
4057
|
body:ApiAddFavoriteChannelRequest,
|
@@ -8852,53 +8894,6 @@ export class MezonApi {
|
|
8852
8894
|
]);
|
8853
8895
|
}
|
8854
8896
|
|
8855
|
-
/** */
|
8856
|
-
getChannelCanvasList(
|
8857
|
-
bearerToken: string,
|
8858
|
-
channelId: string,
|
8859
|
-
clanId?: string,
|
8860
|
-
limit?: number,
|
8861
|
-
page?: number,
|
8862
|
-
options: any = {}
|
8863
|
-
): Promise<ApiChannelCanvasListResponse> {
|
8864
|
-
if (channelId === null || channelId === undefined) {
|
8865
|
-
throw new Error(
|
8866
|
-
"'channelId' is a required parameter but is null or undefined."
|
8867
|
-
);
|
8868
|
-
}
|
8869
|
-
const urlPath = "/v2/channel_canvases/{channelId}".replace(
|
8870
|
-
"{channelId}",
|
8871
|
-
encodeURIComponent(String(channelId))
|
8872
|
-
);
|
8873
|
-
const queryParams = new Map<string, any>();
|
8874
|
-
queryParams.set("clan_id", clanId);
|
8875
|
-
queryParams.set("limit", limit);
|
8876
|
-
queryParams.set("page", page);
|
8877
|
-
|
8878
|
-
let bodyJson: string = "";
|
8879
|
-
|
8880
|
-
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
8881
|
-
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
8882
|
-
if (bearerToken) {
|
8883
|
-
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
8884
|
-
}
|
8885
|
-
|
8886
|
-
return Promise.race([
|
8887
|
-
fetch(fullUrl, fetchOptions).then((response) => {
|
8888
|
-
if (response.status == 204) {
|
8889
|
-
return response;
|
8890
|
-
} else if (response.status >= 200 && response.status < 300) {
|
8891
|
-
return response.json();
|
8892
|
-
} else {
|
8893
|
-
throw response;
|
8894
|
-
}
|
8895
|
-
}),
|
8896
|
-
new Promise((_, reject) =>
|
8897
|
-
setTimeout(reject, this.timeoutMs, "Request timed out.")
|
8898
|
-
),
|
8899
|
-
]);
|
8900
|
-
}
|
8901
|
-
|
8902
8897
|
/** */
|
8903
8898
|
deleteChannelCanvas(
|
8904
8899
|
bearerToken: string,
|
package/dist/api.gen.d.ts
CHANGED
@@ -1401,6 +1401,8 @@ export declare class MezonApi {
|
|
1401
1401
|
/** List channel apps. */
|
1402
1402
|
listChannelApps(bearerToken: string, clanId?: string, options?: any): Promise<ApiListChannelAppsResponse>;
|
1403
1403
|
/** */
|
1404
|
+
getChannelCanvasList(bearerToken: string, channelId: string, clanId?: string, limit?: number, page?: number, options?: any): Promise<ApiChannelCanvasListResponse>;
|
1405
|
+
/** */
|
1404
1406
|
addChannelFavorite(bearerToken: string, body: ApiAddFavoriteChannelRequest, options?: any): Promise<any>;
|
1405
1407
|
/** */
|
1406
1408
|
removeChannelFavorite(bearerToken: string, channelId: string, options?: any): Promise<any>;
|
@@ -1642,7 +1644,5 @@ export declare class MezonApi {
|
|
1642
1644
|
/** */
|
1643
1645
|
getChannelCanvasDetail(bearerToken: string, id: string, clanId?: string, channelId?: string, options?: any): Promise<ApiChannelCanvasDetailResponse>;
|
1644
1646
|
/** */
|
1645
|
-
getChannelCanvasList(bearerToken: string, channelId: string, clanId?: string, limit?: number, page?: number, options?: any): Promise<ApiChannelCanvasListResponse>;
|
1646
|
-
/** */
|
1647
1647
|
deleteChannelCanvas(bearerToken: string, canvasId: string, clanId?: string, channelId?: string, options?: any): Promise<any>;
|
1648
1648
|
}
|
package/dist/mezon-js.cjs.js
CHANGED
@@ -2063,6 +2063,37 @@ var MezonApi = class {
|
|
2063
2063
|
]);
|
2064
2064
|
}
|
2065
2065
|
/** */
|
2066
|
+
getChannelCanvasList(bearerToken, channelId, clanId, limit, page, options = {}) {
|
2067
|
+
if (channelId === null || channelId === void 0) {
|
2068
|
+
throw new Error("'channelId' is a required parameter but is null or undefined.");
|
2069
|
+
}
|
2070
|
+
const urlPath = "/v2/channel-canvases/{channelId}".replace("{channelId}", encodeURIComponent(String(channelId)));
|
2071
|
+
const queryParams = /* @__PURE__ */ new Map();
|
2072
|
+
queryParams.set("clan_id", clanId);
|
2073
|
+
queryParams.set("limit", limit);
|
2074
|
+
queryParams.set("page", page);
|
2075
|
+
let bodyJson = "";
|
2076
|
+
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
2077
|
+
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
2078
|
+
if (bearerToken) {
|
2079
|
+
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
2080
|
+
}
|
2081
|
+
return Promise.race([
|
2082
|
+
fetch(fullUrl, fetchOptions).then((response) => {
|
2083
|
+
if (response.status == 204) {
|
2084
|
+
return response;
|
2085
|
+
} else if (response.status >= 200 && response.status < 300) {
|
2086
|
+
return response.json();
|
2087
|
+
} else {
|
2088
|
+
throw response;
|
2089
|
+
}
|
2090
|
+
}),
|
2091
|
+
new Promise(
|
2092
|
+
(_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
|
2093
|
+
)
|
2094
|
+
]);
|
2095
|
+
}
|
2096
|
+
/** */
|
2066
2097
|
addChannelFavorite(bearerToken, body, options = {}) {
|
2067
2098
|
if (body === null || body === void 0) {
|
2068
2099
|
throw new Error("'body' is a required parameter but is null or undefined.");
|
@@ -5846,42 +5877,6 @@ var MezonApi = class {
|
|
5846
5877
|
]);
|
5847
5878
|
}
|
5848
5879
|
/** */
|
5849
|
-
getChannelCanvasList(bearerToken, channelId, clanId, limit, page, options = {}) {
|
5850
|
-
if (channelId === null || channelId === void 0) {
|
5851
|
-
throw new Error(
|
5852
|
-
"'channelId' is a required parameter but is null or undefined."
|
5853
|
-
);
|
5854
|
-
}
|
5855
|
-
const urlPath = "/v2/channel_canvases/{channelId}".replace(
|
5856
|
-
"{channelId}",
|
5857
|
-
encodeURIComponent(String(channelId))
|
5858
|
-
);
|
5859
|
-
const queryParams = /* @__PURE__ */ new Map();
|
5860
|
-
queryParams.set("clan_id", clanId);
|
5861
|
-
queryParams.set("limit", limit);
|
5862
|
-
queryParams.set("page", page);
|
5863
|
-
let bodyJson = "";
|
5864
|
-
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
5865
|
-
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
5866
|
-
if (bearerToken) {
|
5867
|
-
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
5868
|
-
}
|
5869
|
-
return Promise.race([
|
5870
|
-
fetch(fullUrl, fetchOptions).then((response) => {
|
5871
|
-
if (response.status == 204) {
|
5872
|
-
return response;
|
5873
|
-
} else if (response.status >= 200 && response.status < 300) {
|
5874
|
-
return response.json();
|
5875
|
-
} else {
|
5876
|
-
throw response;
|
5877
|
-
}
|
5878
|
-
}),
|
5879
|
-
new Promise(
|
5880
|
-
(_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
|
5881
|
-
)
|
5882
|
-
]);
|
5883
|
-
}
|
5884
|
-
/** */
|
5885
5880
|
deleteChannelCanvas(bearerToken, canvasId, clanId, channelId, options = {}) {
|
5886
5881
|
if (canvasId === null || canvasId === void 0) {
|
5887
5882
|
throw new Error(
|
package/dist/mezon-js.esm.mjs
CHANGED
@@ -2034,6 +2034,37 @@ var MezonApi = class {
|
|
2034
2034
|
]);
|
2035
2035
|
}
|
2036
2036
|
/** */
|
2037
|
+
getChannelCanvasList(bearerToken, channelId, clanId, limit, page, options = {}) {
|
2038
|
+
if (channelId === null || channelId === void 0) {
|
2039
|
+
throw new Error("'channelId' is a required parameter but is null or undefined.");
|
2040
|
+
}
|
2041
|
+
const urlPath = "/v2/channel-canvases/{channelId}".replace("{channelId}", encodeURIComponent(String(channelId)));
|
2042
|
+
const queryParams = /* @__PURE__ */ new Map();
|
2043
|
+
queryParams.set("clan_id", clanId);
|
2044
|
+
queryParams.set("limit", limit);
|
2045
|
+
queryParams.set("page", page);
|
2046
|
+
let bodyJson = "";
|
2047
|
+
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
2048
|
+
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
2049
|
+
if (bearerToken) {
|
2050
|
+
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
2051
|
+
}
|
2052
|
+
return Promise.race([
|
2053
|
+
fetch(fullUrl, fetchOptions).then((response) => {
|
2054
|
+
if (response.status == 204) {
|
2055
|
+
return response;
|
2056
|
+
} else if (response.status >= 200 && response.status < 300) {
|
2057
|
+
return response.json();
|
2058
|
+
} else {
|
2059
|
+
throw response;
|
2060
|
+
}
|
2061
|
+
}),
|
2062
|
+
new Promise(
|
2063
|
+
(_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
|
2064
|
+
)
|
2065
|
+
]);
|
2066
|
+
}
|
2067
|
+
/** */
|
2037
2068
|
addChannelFavorite(bearerToken, body, options = {}) {
|
2038
2069
|
if (body === null || body === void 0) {
|
2039
2070
|
throw new Error("'body' is a required parameter but is null or undefined.");
|
@@ -5817,42 +5848,6 @@ var MezonApi = class {
|
|
5817
5848
|
]);
|
5818
5849
|
}
|
5819
5850
|
/** */
|
5820
|
-
getChannelCanvasList(bearerToken, channelId, clanId, limit, page, options = {}) {
|
5821
|
-
if (channelId === null || channelId === void 0) {
|
5822
|
-
throw new Error(
|
5823
|
-
"'channelId' is a required parameter but is null or undefined."
|
5824
|
-
);
|
5825
|
-
}
|
5826
|
-
const urlPath = "/v2/channel_canvases/{channelId}".replace(
|
5827
|
-
"{channelId}",
|
5828
|
-
encodeURIComponent(String(channelId))
|
5829
|
-
);
|
5830
|
-
const queryParams = /* @__PURE__ */ new Map();
|
5831
|
-
queryParams.set("clan_id", clanId);
|
5832
|
-
queryParams.set("limit", limit);
|
5833
|
-
queryParams.set("page", page);
|
5834
|
-
let bodyJson = "";
|
5835
|
-
const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
|
5836
|
-
const fetchOptions = buildFetchOptions("GET", options, bodyJson);
|
5837
|
-
if (bearerToken) {
|
5838
|
-
fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
|
5839
|
-
}
|
5840
|
-
return Promise.race([
|
5841
|
-
fetch(fullUrl, fetchOptions).then((response) => {
|
5842
|
-
if (response.status == 204) {
|
5843
|
-
return response;
|
5844
|
-
} else if (response.status >= 200 && response.status < 300) {
|
5845
|
-
return response.json();
|
5846
|
-
} else {
|
5847
|
-
throw response;
|
5848
|
-
}
|
5849
|
-
}),
|
5850
|
-
new Promise(
|
5851
|
-
(_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
|
5852
|
-
)
|
5853
|
-
]);
|
5854
|
-
}
|
5855
|
-
/** */
|
5856
5851
|
deleteChannelCanvas(bearerToken, canvasId, clanId, channelId, options = {}) {
|
5857
5852
|
if (canvasId === null || canvasId === void 0) {
|
5858
5853
|
throw new Error(
|