@icepanel/sdk 0.1.2 → 0.1.6
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/README.md +1 -1
- package/dist/cjs/BaseClient.d.ts +7 -9
- package/dist/cjs/BaseClient.js +8 -3
- package/dist/cjs/Client.d.ts +2 -2
- package/dist/cjs/Client.js +1 -1
- package/dist/cjs/IcePanelClient.d.ts +7 -8
- package/dist/cjs/IcePanelClient.js +11 -11
- package/dist/cjs/api/requests/requests.d.ts +62 -142
- package/dist/cjs/api/resources/catalog/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/catalog/client/Client.js +1 -1
- package/dist/cjs/api/resources/catalog/resources/technologies/client/Client.d.ts +2 -71
- package/dist/cjs/api/resources/catalog/resources/technologies/client/Client.js +5 -262
- package/dist/cjs/api/resources/catalog/resources/technologies/types/types.d.ts +0 -12
- package/dist/cjs/api/resources/comments/client/Client.d.ts +7 -5
- package/dist/cjs/api/resources/comments/client/Client.js +25 -28
- package/dist/cjs/api/resources/comments/resources/replies/client/Client.d.ts +5 -3
- package/dist/cjs/api/resources/comments/resources/replies/client/Client.js +23 -26
- package/dist/cjs/api/resources/diagrams/client/Client.d.ts +4 -3
- package/dist/cjs/api/resources/diagrams/client/Client.js +31 -32
- package/dist/cjs/api/resources/diagrams/resources/content/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/diagrams/resources/content/client/Client.js +10 -7
- package/dist/cjs/api/resources/diagrams/resources/export/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/diagrams/resources/export/client/Client.js +7 -5
- package/dist/cjs/api/resources/diagrams/resources/groups/client/Client.d.ts +6 -4
- package/dist/cjs/api/resources/diagrams/resources/groups/client/Client.js +27 -29
- package/dist/cjs/api/resources/domains/client/Client.d.ts +5 -3
- package/dist/cjs/api/resources/domains/client/Client.js +26 -28
- package/dist/cjs/api/resources/drafts/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/drafts/client/Client.js +22 -15
- package/dist/cjs/api/resources/flows/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/flows/client/Client.js +28 -19
- package/dist/cjs/api/resources/flows/resources/export/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/flows/resources/export/client/Client.js +10 -7
- package/dist/cjs/api/resources/landscapes/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/landscapes/client/Client.js +19 -13
- package/dist/cjs/api/resources/landscapes/resources/export/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/landscapes/resources/export/client/Client.js +7 -5
- package/dist/cjs/api/resources/landscapes/resources/logs/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/landscapes/resources/logs/client/Client.js +10 -7
- package/dist/cjs/api/resources/landscapes/resources/logs/resources/stats/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/landscapes/resources/logs/resources/stats/client/Client.js +7 -5
- package/dist/cjs/api/resources/model/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/model/client/Client.js +1 -1
- package/dist/cjs/api/resources/model/resources/connections/client/Client.d.ts +28 -5
- package/dist/cjs/api/resources/model/resources/connections/client/Client.js +95 -17
- package/dist/cjs/api/resources/model/resources/connections/resources/export/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/model/resources/connections/resources/export/client/Client.js +6 -4
- package/dist/cjs/api/resources/model/resources/connections/types/types.d.ts +6 -0
- package/dist/cjs/api/resources/model/resources/objects/client/Client.d.ts +6 -4
- package/dist/cjs/api/resources/model/resources/objects/client/Client.js +24 -27
- package/dist/cjs/api/resources/model/resources/objects/resources/export/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/model/resources/objects/resources/export/client/Client.js +9 -6
- package/dist/cjs/api/resources/organizations/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/client/Client.js +16 -11
- package/dist/cjs/api/resources/organizations/resources/landscapes/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/landscapes/client/Client.js +7 -5
- package/dist/cjs/api/resources/organizations/resources/logs/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/logs/client/Client.js +7 -5
- package/dist/cjs/api/resources/organizations/resources/logs/resources/stats/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/logs/resources/stats/client/Client.js +7 -5
- package/dist/cjs/api/resources/organizations/resources/technologies/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/technologies/client/Client.js +16 -11
- package/dist/cjs/api/resources/organizations/resources/users/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/users/client/Client.js +10 -7
- package/dist/cjs/api/resources/organizations/resources/users/resources/invites/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/organizations/resources/users/resources/invites/client/Client.js +10 -7
- package/dist/cjs/api/resources/shareLink/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/shareLink/client/Client.js +13 -9
- package/dist/cjs/api/resources/tags/client/Client.d.ts +8 -6
- package/dist/cjs/api/resources/tags/client/Client.js +26 -29
- package/dist/cjs/api/resources/tags/resources/groups/client/Client.d.ts +7 -5
- package/dist/cjs/api/resources/tags/resources/groups/client/Client.js +25 -28
- package/dist/cjs/api/resources/teams/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/teams/client/Client.js +22 -15
- package/dist/cjs/api/resources/versions/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/versions/client/Client.js +16 -11
- package/dist/cjs/api/resources/versions/resources/reverts/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/versions/resources/reverts/client/Client.js +13 -9
- package/dist/cjs/api/types/types.d.ts +187 -1487
- package/dist/cjs/api/types/types.js +14 -329
- package/dist/cjs/auth/AnyAuthProvider.d.ts +23 -0
- package/dist/cjs/auth/AnyAuthProvider.js +46 -0
- package/dist/cjs/auth/BearerAuthProvider.d.ts +23 -0
- package/dist/cjs/auth/BearerAuthProvider.js +82 -0
- package/dist/cjs/auth/HeaderAuthProvider.d.ts +17 -10
- package/dist/cjs/auth/HeaderAuthProvider.js +22 -9
- package/dist/cjs/auth/index.d.ts +2 -0
- package/dist/cjs/auth/index.js +5 -1
- package/dist/cjs/core/fetcher/EndpointSupplier.d.ts +2 -2
- package/dist/cjs/environments.d.ts +2 -2
- package/dist/cjs/environments.js +1 -1
- package/dist/cjs/helpers/index.d.ts +1 -1
- package/dist/cjs/helpers/index.js +1 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +7 -9
- package/dist/esm/BaseClient.mjs +8 -3
- package/dist/esm/Client.d.mts +2 -2
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/IcePanelClient.d.mts +7 -8
- package/dist/esm/IcePanelClient.mjs +10 -10
- package/dist/esm/api/requests/requests.d.mts +62 -142
- package/dist/esm/api/resources/catalog/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/catalog/client/Client.mjs +2 -2
- package/dist/esm/api/resources/catalog/resources/technologies/client/Client.d.mts +2 -71
- package/dist/esm/api/resources/catalog/resources/technologies/client/Client.mjs +6 -263
- package/dist/esm/api/resources/catalog/resources/technologies/types/types.d.mts +0 -12
- package/dist/esm/api/resources/comments/client/Client.d.mts +7 -5
- package/dist/esm/api/resources/comments/client/Client.mjs +26 -29
- package/dist/esm/api/resources/comments/resources/replies/client/Client.d.mts +5 -3
- package/dist/esm/api/resources/comments/resources/replies/client/Client.mjs +24 -27
- package/dist/esm/api/resources/diagrams/client/Client.d.mts +4 -3
- package/dist/esm/api/resources/diagrams/client/Client.mjs +32 -33
- package/dist/esm/api/resources/diagrams/resources/content/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/diagrams/resources/content/client/Client.mjs +11 -8
- package/dist/esm/api/resources/diagrams/resources/export/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/diagrams/resources/export/client/Client.mjs +8 -6
- package/dist/esm/api/resources/diagrams/resources/groups/client/Client.d.mts +6 -4
- package/dist/esm/api/resources/diagrams/resources/groups/client/Client.mjs +28 -30
- package/dist/esm/api/resources/domains/client/Client.d.mts +5 -3
- package/dist/esm/api/resources/domains/client/Client.mjs +27 -29
- package/dist/esm/api/resources/drafts/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/drafts/client/Client.mjs +23 -16
- package/dist/esm/api/resources/flows/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/flows/client/Client.mjs +29 -20
- package/dist/esm/api/resources/flows/resources/export/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/flows/resources/export/client/Client.mjs +11 -8
- package/dist/esm/api/resources/landscapes/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/landscapes/client/Client.mjs +20 -14
- package/dist/esm/api/resources/landscapes/resources/export/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/landscapes/resources/export/client/Client.mjs +8 -6
- package/dist/esm/api/resources/landscapes/resources/logs/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/landscapes/resources/logs/client/Client.mjs +11 -8
- package/dist/esm/api/resources/landscapes/resources/logs/resources/stats/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/landscapes/resources/logs/resources/stats/client/Client.mjs +8 -6
- package/dist/esm/api/resources/model/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/model/client/Client.mjs +2 -2
- package/dist/esm/api/resources/model/resources/connections/client/Client.d.mts +28 -5
- package/dist/esm/api/resources/model/resources/connections/client/Client.mjs +96 -18
- package/dist/esm/api/resources/model/resources/connections/resources/export/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/model/resources/connections/resources/export/client/Client.mjs +7 -5
- package/dist/esm/api/resources/model/resources/connections/types/types.d.mts +6 -0
- package/dist/esm/api/resources/model/resources/objects/client/Client.d.mts +6 -4
- package/dist/esm/api/resources/model/resources/objects/client/Client.mjs +25 -28
- package/dist/esm/api/resources/model/resources/objects/resources/export/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/model/resources/objects/resources/export/client/Client.mjs +10 -7
- package/dist/esm/api/resources/organizations/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/client/Client.mjs +17 -12
- package/dist/esm/api/resources/organizations/resources/landscapes/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/landscapes/client/Client.mjs +8 -6
- package/dist/esm/api/resources/organizations/resources/logs/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/logs/client/Client.mjs +8 -6
- package/dist/esm/api/resources/organizations/resources/logs/resources/stats/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/logs/resources/stats/client/Client.mjs +8 -6
- package/dist/esm/api/resources/organizations/resources/technologies/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/technologies/client/Client.mjs +17 -12
- package/dist/esm/api/resources/organizations/resources/users/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/users/client/Client.mjs +11 -8
- package/dist/esm/api/resources/organizations/resources/users/resources/invites/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/organizations/resources/users/resources/invites/client/Client.mjs +11 -8
- package/dist/esm/api/resources/shareLink/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/shareLink/client/Client.mjs +14 -10
- package/dist/esm/api/resources/tags/client/Client.d.mts +8 -6
- package/dist/esm/api/resources/tags/client/Client.mjs +27 -30
- package/dist/esm/api/resources/tags/resources/groups/client/Client.d.mts +7 -5
- package/dist/esm/api/resources/tags/resources/groups/client/Client.mjs +26 -29
- package/dist/esm/api/resources/teams/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/teams/client/Client.mjs +23 -16
- package/dist/esm/api/resources/versions/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/versions/client/Client.mjs +17 -12
- package/dist/esm/api/resources/versions/resources/reverts/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/versions/resources/reverts/client/Client.mjs +14 -10
- package/dist/esm/api/types/types.d.mts +187 -1487
- package/dist/esm/api/types/types.mjs +11 -325
- package/dist/esm/auth/AnyAuthProvider.d.mts +23 -0
- package/dist/esm/auth/AnyAuthProvider.mjs +42 -0
- package/dist/esm/auth/BearerAuthProvider.d.mts +23 -0
- package/dist/esm/auth/BearerAuthProvider.mjs +45 -0
- package/dist/esm/auth/HeaderAuthProvider.d.mts +17 -10
- package/dist/esm/auth/HeaderAuthProvider.mjs +22 -9
- package/dist/esm/auth/index.d.mts +2 -0
- package/dist/esm/auth/index.mjs +2 -0
- package/dist/esm/core/fetcher/EndpointSupplier.d.mts +2 -2
- package/dist/esm/environments.d.mts +2 -2
- package/dist/esm/environments.mjs +1 -1
- package/dist/esm/helpers/index.d.mts +1 -1
- package/dist/esm/helpers/index.mjs +1 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +107 -280
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.mjs";
|
|
2
|
-
import { type
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../../../BaseClient.mjs";
|
|
3
3
|
import * as core from "../../../../../../core/index.mjs";
|
|
4
4
|
import * as IcePanel from "../../../../../index.mjs";
|
|
5
5
|
export declare namespace TechnologiesClient {
|
|
@@ -8,59 +8,8 @@ export declare namespace TechnologiesClient {
|
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
export declare class TechnologiesClient {
|
|
11
|
-
protected readonly _options:
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<TechnologiesClient.Options>;
|
|
12
12
|
constructor(options?: TechnologiesClient.Options);
|
|
13
|
-
/**
|
|
14
|
-
* List technologies
|
|
15
|
-
*
|
|
16
|
-
* @param {IcePanel.CatalogTechnologiesListRequest} request
|
|
17
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
|
-
*
|
|
19
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
20
|
-
* @throws {@link IcePanel.ForbiddenError}
|
|
21
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
22
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
23
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
24
|
-
*
|
|
25
|
-
* @example
|
|
26
|
-
* await client.catalog.technologies.list()
|
|
27
|
-
*/
|
|
28
|
-
list(request?: IcePanel.CatalogTechnologiesListRequest, requestOptions?: TechnologiesClient.RequestOptions): core.HttpResponsePromise<IcePanel.catalog.TechnologiesListResponse>;
|
|
29
|
-
private __list;
|
|
30
|
-
/**
|
|
31
|
-
* Generate suggestions for a technologies information
|
|
32
|
-
*
|
|
33
|
-
* @param {IcePanel.CatalogSuggestionInformationGetRequest} request
|
|
34
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
35
|
-
*
|
|
36
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
37
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
38
|
-
*
|
|
39
|
-
* @example
|
|
40
|
-
* await client.catalog.technologies.suggestInformation({
|
|
41
|
-
* url: "url"
|
|
42
|
-
* })
|
|
43
|
-
*/
|
|
44
|
-
suggestInformation(request: IcePanel.CatalogSuggestionInformationGetRequest, requestOptions?: TechnologiesClient.RequestOptions): core.HttpResponsePromise<IcePanel.catalog.TechnologiesSuggestInformationResponse>;
|
|
45
|
-
private __suggestInformation;
|
|
46
|
-
/**
|
|
47
|
-
* Generate suggestions for a technologies branding
|
|
48
|
-
*
|
|
49
|
-
* @param {IcePanel.CatalogSuggestionBrandGetRequest} request
|
|
50
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
|
-
*
|
|
52
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
53
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
54
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
55
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
56
|
-
*
|
|
57
|
-
* @example
|
|
58
|
-
* await client.catalog.technologies.suggestBrand({
|
|
59
|
-
* url: "url"
|
|
60
|
-
* })
|
|
61
|
-
*/
|
|
62
|
-
suggestBrand(request: IcePanel.CatalogSuggestionBrandGetRequest, requestOptions?: TechnologiesClient.RequestOptions): core.HttpResponsePromise<IcePanel.catalog.TechnologiesSuggestBrandResponse>;
|
|
63
|
-
private __suggestBrand;
|
|
64
13
|
/**
|
|
65
14
|
* Create a signed URL prefix with access to all catalog icons
|
|
66
15
|
*
|
|
@@ -95,22 +44,4 @@ export declare class TechnologiesClient {
|
|
|
95
44
|
*/
|
|
96
45
|
get(request: IcePanel.CatalogTechnologyFindRequest, requestOptions?: TechnologiesClient.RequestOptions): core.HttpResponsePromise<IcePanel.catalog.TechnologiesGetResponse>;
|
|
97
46
|
private __get;
|
|
98
|
-
/**
|
|
99
|
-
* Find a technology by the slug
|
|
100
|
-
*
|
|
101
|
-
* @param {IcePanel.CatalogTechnologySlugFindRequest} request
|
|
102
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
103
|
-
*
|
|
104
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
105
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
106
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
107
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
108
|
-
*
|
|
109
|
-
* @example
|
|
110
|
-
* await client.catalog.technologies.getSlug({
|
|
111
|
-
* catalogTechnologySlug: "catalogTechnologySlug"
|
|
112
|
-
* })
|
|
113
|
-
*/
|
|
114
|
-
getSlug(request: IcePanel.CatalogTechnologySlugFindRequest, requestOptions?: TechnologiesClient.RequestOptions): core.HttpResponsePromise<IcePanel.catalog.TechnologiesGetSlugResponse>;
|
|
115
|
-
private __getSlug;
|
|
116
47
|
}
|
|
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
-
import {
|
|
11
|
+
import { normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.mjs";
|
|
12
12
|
import { mergeHeaders } from "../../../../../../core/headers.mjs";
|
|
13
13
|
import * as core from "../../../../../../core/index.mjs";
|
|
14
14
|
import * as environments from "../../../../../../environments.mjs";
|
|
@@ -17,202 +17,7 @@ import * as errors from "../../../../../../errors/index.mjs";
|
|
|
17
17
|
import * as IcePanel from "../../../../../index.mjs";
|
|
18
18
|
export class TechnologiesClient {
|
|
19
19
|
constructor(options = {}) {
|
|
20
|
-
this._options =
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* List technologies
|
|
24
|
-
*
|
|
25
|
-
* @param {IcePanel.CatalogTechnologiesListRequest} request
|
|
26
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
|
-
*
|
|
28
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
29
|
-
* @throws {@link IcePanel.ForbiddenError}
|
|
30
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
31
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
32
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
33
|
-
*
|
|
34
|
-
* @example
|
|
35
|
-
* await client.catalog.technologies.list()
|
|
36
|
-
*/
|
|
37
|
-
list(request = {}, requestOptions) {
|
|
38
|
-
return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions));
|
|
39
|
-
}
|
|
40
|
-
__list() {
|
|
41
|
-
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
42
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
43
|
-
const { filter, admin } = request;
|
|
44
|
-
const _queryParams = {};
|
|
45
|
-
if (filter != null) {
|
|
46
|
-
_queryParams.filter = filter;
|
|
47
|
-
}
|
|
48
|
-
if (admin != null) {
|
|
49
|
-
_queryParams.admin = admin.toString();
|
|
50
|
-
}
|
|
51
|
-
const _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
52
|
-
const _response = yield core.fetcher({
|
|
53
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.V1, "catalog/technologies"),
|
|
54
|
-
method: "GET",
|
|
55
|
-
headers: _headers,
|
|
56
|
-
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
57
|
-
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
58
|
-
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
59
|
-
withCredentials: true,
|
|
60
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
61
|
-
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
62
|
-
logging: this._options.logging,
|
|
63
|
-
});
|
|
64
|
-
if (_response.ok) {
|
|
65
|
-
return {
|
|
66
|
-
data: _response.body,
|
|
67
|
-
rawResponse: _response.rawResponse,
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
if (_response.error.reason === "status-code") {
|
|
71
|
-
switch (_response.error.statusCode) {
|
|
72
|
-
case 401:
|
|
73
|
-
throw new IcePanel.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
74
|
-
case 403:
|
|
75
|
-
throw new IcePanel.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
76
|
-
case 404:
|
|
77
|
-
throw new IcePanel.NotFoundError(_response.error.body, _response.rawResponse);
|
|
78
|
-
case 422:
|
|
79
|
-
throw new IcePanel.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
80
|
-
case 500:
|
|
81
|
-
throw new IcePanel.InternalServerError(_response.error.body, _response.rawResponse);
|
|
82
|
-
default:
|
|
83
|
-
throw new errors.IcePanelError({
|
|
84
|
-
statusCode: _response.error.statusCode,
|
|
85
|
-
body: _response.error.body,
|
|
86
|
-
rawResponse: _response.rawResponse,
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/catalog/technologies");
|
|
91
|
-
});
|
|
92
|
-
}
|
|
93
|
-
/**
|
|
94
|
-
* Generate suggestions for a technologies information
|
|
95
|
-
*
|
|
96
|
-
* @param {IcePanel.CatalogSuggestionInformationGetRequest} request
|
|
97
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
98
|
-
*
|
|
99
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
100
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
101
|
-
*
|
|
102
|
-
* @example
|
|
103
|
-
* await client.catalog.technologies.suggestInformation({
|
|
104
|
-
* url: "url"
|
|
105
|
-
* })
|
|
106
|
-
*/
|
|
107
|
-
suggestInformation(request, requestOptions) {
|
|
108
|
-
return core.HttpResponsePromise.fromPromise(this.__suggestInformation(request, requestOptions));
|
|
109
|
-
}
|
|
110
|
-
__suggestInformation(request, requestOptions) {
|
|
111
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
112
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
113
|
-
const { url } = request;
|
|
114
|
-
const _queryParams = {};
|
|
115
|
-
_queryParams.url = url;
|
|
116
|
-
const _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
117
|
-
const _response = yield core.fetcher({
|
|
118
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.V1, "catalog/suggestion/information"),
|
|
119
|
-
method: "GET",
|
|
120
|
-
headers: _headers,
|
|
121
|
-
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
122
|
-
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
123
|
-
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
124
|
-
withCredentials: true,
|
|
125
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
126
|
-
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
127
|
-
logging: this._options.logging,
|
|
128
|
-
});
|
|
129
|
-
if (_response.ok) {
|
|
130
|
-
return {
|
|
131
|
-
data: _response.body,
|
|
132
|
-
rawResponse: _response.rawResponse,
|
|
133
|
-
};
|
|
134
|
-
}
|
|
135
|
-
if (_response.error.reason === "status-code") {
|
|
136
|
-
switch (_response.error.statusCode) {
|
|
137
|
-
case 401:
|
|
138
|
-
throw new IcePanel.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
139
|
-
case 500:
|
|
140
|
-
throw new IcePanel.InternalServerError(_response.error.body, _response.rawResponse);
|
|
141
|
-
default:
|
|
142
|
-
throw new errors.IcePanelError({
|
|
143
|
-
statusCode: _response.error.statusCode,
|
|
144
|
-
body: _response.error.body,
|
|
145
|
-
rawResponse: _response.rawResponse,
|
|
146
|
-
});
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/catalog/suggestion/information");
|
|
150
|
-
});
|
|
151
|
-
}
|
|
152
|
-
/**
|
|
153
|
-
* Generate suggestions for a technologies branding
|
|
154
|
-
*
|
|
155
|
-
* @param {IcePanel.CatalogSuggestionBrandGetRequest} request
|
|
156
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
157
|
-
*
|
|
158
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
159
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
160
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
161
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
162
|
-
*
|
|
163
|
-
* @example
|
|
164
|
-
* await client.catalog.technologies.suggestBrand({
|
|
165
|
-
* url: "url"
|
|
166
|
-
* })
|
|
167
|
-
*/
|
|
168
|
-
suggestBrand(request, requestOptions) {
|
|
169
|
-
return core.HttpResponsePromise.fromPromise(this.__suggestBrand(request, requestOptions));
|
|
170
|
-
}
|
|
171
|
-
__suggestBrand(request, requestOptions) {
|
|
172
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
173
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
174
|
-
const { url } = request;
|
|
175
|
-
const _queryParams = {};
|
|
176
|
-
_queryParams.url = url;
|
|
177
|
-
const _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
178
|
-
const _response = yield core.fetcher({
|
|
179
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.V1, "catalog/suggestion/brand"),
|
|
180
|
-
method: "GET",
|
|
181
|
-
headers: _headers,
|
|
182
|
-
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
183
|
-
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
184
|
-
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
185
|
-
withCredentials: true,
|
|
186
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
187
|
-
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
188
|
-
logging: this._options.logging,
|
|
189
|
-
});
|
|
190
|
-
if (_response.ok) {
|
|
191
|
-
return {
|
|
192
|
-
data: _response.body,
|
|
193
|
-
rawResponse: _response.rawResponse,
|
|
194
|
-
};
|
|
195
|
-
}
|
|
196
|
-
if (_response.error.reason === "status-code") {
|
|
197
|
-
switch (_response.error.statusCode) {
|
|
198
|
-
case 401:
|
|
199
|
-
throw new IcePanel.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
200
|
-
case 404:
|
|
201
|
-
throw new IcePanel.NotFoundError(_response.error.body, _response.rawResponse);
|
|
202
|
-
case 422:
|
|
203
|
-
throw new IcePanel.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
204
|
-
case 500:
|
|
205
|
-
throw new IcePanel.InternalServerError(_response.error.body, _response.rawResponse);
|
|
206
|
-
default:
|
|
207
|
-
throw new errors.IcePanelError({
|
|
208
|
-
statusCode: _response.error.statusCode,
|
|
209
|
-
body: _response.error.body,
|
|
210
|
-
rawResponse: _response.rawResponse,
|
|
211
|
-
});
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/catalog/suggestion/brand");
|
|
215
|
-
});
|
|
20
|
+
this._options = normalizeClientOptionsWithAuth(options);
|
|
216
21
|
}
|
|
217
22
|
/**
|
|
218
23
|
* Create a signed URL prefix with access to all catalog icons
|
|
@@ -234,9 +39,10 @@ export class TechnologiesClient {
|
|
|
234
39
|
__createSignedIconUrl(requestOptions) {
|
|
235
40
|
return __awaiter(this, void 0, void 0, function* () {
|
|
236
41
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
237
|
-
const
|
|
42
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
43
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
238
44
|
const _response = yield core.fetcher({
|
|
239
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
45
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, "catalog/icons/signed-url"),
|
|
240
46
|
method: "POST",
|
|
241
47
|
headers: _headers,
|
|
242
48
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -301,7 +107,7 @@ export class TechnologiesClient {
|
|
|
301
107
|
const { catalogTechnologyId } = request;
|
|
302
108
|
const _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
303
109
|
const _response = yield core.fetcher({
|
|
304
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
110
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `catalog/technologies/${core.url.encodePathParam(catalogTechnologyId)}`),
|
|
305
111
|
method: "GET",
|
|
306
112
|
headers: _headers,
|
|
307
113
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -339,67 +145,4 @@ export class TechnologiesClient {
|
|
|
339
145
|
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/catalog/technologies/{catalogTechnologyId}");
|
|
340
146
|
});
|
|
341
147
|
}
|
|
342
|
-
/**
|
|
343
|
-
* Find a technology by the slug
|
|
344
|
-
*
|
|
345
|
-
* @param {IcePanel.CatalogTechnologySlugFindRequest} request
|
|
346
|
-
* @param {TechnologiesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
347
|
-
*
|
|
348
|
-
* @throws {@link IcePanel.UnauthorizedError}
|
|
349
|
-
* @throws {@link IcePanel.NotFoundError}
|
|
350
|
-
* @throws {@link IcePanel.UnprocessableEntityError}
|
|
351
|
-
* @throws {@link IcePanel.InternalServerError}
|
|
352
|
-
*
|
|
353
|
-
* @example
|
|
354
|
-
* await client.catalog.technologies.getSlug({
|
|
355
|
-
* catalogTechnologySlug: "catalogTechnologySlug"
|
|
356
|
-
* })
|
|
357
|
-
*/
|
|
358
|
-
getSlug(request, requestOptions) {
|
|
359
|
-
return core.HttpResponsePromise.fromPromise(this.__getSlug(request, requestOptions));
|
|
360
|
-
}
|
|
361
|
-
__getSlug(request, requestOptions) {
|
|
362
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
363
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
364
|
-
const { catalogTechnologySlug } = request;
|
|
365
|
-
const _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
366
|
-
const _response = yield core.fetcher({
|
|
367
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.V1, `catalog/technologies/slugs/${core.url.encodePathParam(catalogTechnologySlug)}`),
|
|
368
|
-
method: "GET",
|
|
369
|
-
headers: _headers,
|
|
370
|
-
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
371
|
-
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
372
|
-
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
373
|
-
withCredentials: true,
|
|
374
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
375
|
-
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
376
|
-
logging: this._options.logging,
|
|
377
|
-
});
|
|
378
|
-
if (_response.ok) {
|
|
379
|
-
return {
|
|
380
|
-
data: _response.body,
|
|
381
|
-
rawResponse: _response.rawResponse,
|
|
382
|
-
};
|
|
383
|
-
}
|
|
384
|
-
if (_response.error.reason === "status-code") {
|
|
385
|
-
switch (_response.error.statusCode) {
|
|
386
|
-
case 401:
|
|
387
|
-
throw new IcePanel.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
388
|
-
case 404:
|
|
389
|
-
throw new IcePanel.NotFoundError(_response.error.body, _response.rawResponse);
|
|
390
|
-
case 422:
|
|
391
|
-
throw new IcePanel.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
392
|
-
case 500:
|
|
393
|
-
throw new IcePanel.InternalServerError(_response.error.body, _response.rawResponse);
|
|
394
|
-
default:
|
|
395
|
-
throw new errors.IcePanelError({
|
|
396
|
-
statusCode: _response.error.statusCode,
|
|
397
|
-
body: _response.error.body,
|
|
398
|
-
rawResponse: _response.rawResponse,
|
|
399
|
-
});
|
|
400
|
-
}
|
|
401
|
-
}
|
|
402
|
-
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/catalog/technologies/slugs/{catalogTechnologySlug}");
|
|
403
|
-
});
|
|
404
|
-
}
|
|
405
148
|
}
|
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
import type * as IcePanel from "../../../../../index.mjs";
|
|
2
|
-
export interface TechnologiesListResponse {
|
|
3
|
-
catalogTechnologies: IcePanel.CatalogTechnology[];
|
|
4
|
-
}
|
|
5
|
-
export interface TechnologiesSuggestInformationResponse {
|
|
6
|
-
catalogSuggestionInformation: IcePanel.CatalogSuggestionInformation;
|
|
7
|
-
}
|
|
8
|
-
export interface TechnologiesSuggestBrandResponse {
|
|
9
|
-
catalogSuggestionBrand: IcePanel.CatalogSuggestionBrand;
|
|
10
|
-
}
|
|
11
2
|
export interface TechnologiesCreateSignedIconUrlResponse {
|
|
12
3
|
/** Signed URL prefix for all catalog icons, you must append the exact icons path, extension supports .svg/.png/.webp/.jpeg, supports size/rounded as query strings, expires in 12 hours */
|
|
13
4
|
signedUrl: string;
|
|
@@ -15,6 +6,3 @@ export interface TechnologiesCreateSignedIconUrlResponse {
|
|
|
15
6
|
export interface TechnologiesGetResponse {
|
|
16
7
|
catalogTechnology: IcePanel.CatalogTechnology;
|
|
17
8
|
}
|
|
18
|
-
export interface TechnologiesGetSlugResponse {
|
|
19
|
-
catalogTechnology: IcePanel.CatalogTechnology;
|
|
20
|
-
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.mjs";
|
|
2
|
-
import { type
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.mjs";
|
|
3
3
|
import * as core from "../../../../core/index.mjs";
|
|
4
4
|
import * as IcePanel from "../../../index.mjs";
|
|
5
5
|
import { RepliesClient } from "../resources/replies/client/Client.mjs";
|
|
@@ -9,7 +9,7 @@ export declare namespace CommentsClient {
|
|
|
9
9
|
}
|
|
10
10
|
}
|
|
11
11
|
export declare class CommentsClient {
|
|
12
|
-
protected readonly _options:
|
|
12
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<CommentsClient.Options>;
|
|
13
13
|
protected _replies: RepliesClient | undefined;
|
|
14
14
|
constructor(options?: CommentsClient.Options);
|
|
15
15
|
get replies(): RepliesClient;
|
|
@@ -88,9 +88,11 @@ export declare class CommentsClient {
|
|
|
88
88
|
* versionId: "versionId",
|
|
89
89
|
* commentId: "commentId",
|
|
90
90
|
* body: {
|
|
91
|
-
*
|
|
92
|
-
*
|
|
93
|
-
*
|
|
91
|
+
* body: {
|
|
92
|
+
* content: "content",
|
|
93
|
+
* status: "open",
|
|
94
|
+
* type: "question"
|
|
95
|
+
* }
|
|
94
96
|
* }
|
|
95
97
|
* })
|
|
96
98
|
*/
|
|
@@ -8,18 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
-
|
|
12
|
-
var t = {};
|
|
13
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
14
|
-
t[p] = s[p];
|
|
15
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
16
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
17
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
18
|
-
t[p[i]] = s[p[i]];
|
|
19
|
-
}
|
|
20
|
-
return t;
|
|
21
|
-
};
|
|
22
|
-
import { normalizeClientOptions } from "../../../../BaseClient.mjs";
|
|
11
|
+
import { normalizeClientOptionsWithAuth } from "../../../../BaseClient.mjs";
|
|
23
12
|
import { mergeHeaders } from "../../../../core/headers.mjs";
|
|
24
13
|
import * as core from "../../../../core/index.mjs";
|
|
25
14
|
import * as environments from "../../../../environments.mjs";
|
|
@@ -29,7 +18,7 @@ import * as IcePanel from "../../../index.mjs";
|
|
|
29
18
|
import { RepliesClient } from "../resources/replies/client/Client.mjs";
|
|
30
19
|
export class CommentsClient {
|
|
31
20
|
constructor(options = {}) {
|
|
32
|
-
this._options =
|
|
21
|
+
this._options = normalizeClientOptionsWithAuth(options);
|
|
33
22
|
}
|
|
34
23
|
get replies() {
|
|
35
24
|
var _a;
|
|
@@ -66,9 +55,10 @@ export class CommentsClient {
|
|
|
66
55
|
_queryParams.status = status;
|
|
67
56
|
}
|
|
68
57
|
}
|
|
69
|
-
const
|
|
58
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
59
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
70
60
|
const _response = yield core.fetcher({
|
|
71
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
61
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments`),
|
|
72
62
|
method: "GET",
|
|
73
63
|
headers: _headers,
|
|
74
64
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
@@ -132,9 +122,10 @@ export class CommentsClient {
|
|
|
132
122
|
return __awaiter(this, void 0, void 0, function* () {
|
|
133
123
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
134
124
|
const { landscapeId, versionId, body: _body } = request;
|
|
135
|
-
const
|
|
125
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
126
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
136
127
|
const _response = yield core.fetcher({
|
|
137
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
128
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments`),
|
|
138
129
|
method: "POST",
|
|
139
130
|
headers: _headers,
|
|
140
131
|
contentType: "application/json",
|
|
@@ -195,9 +186,10 @@ export class CommentsClient {
|
|
|
195
186
|
return __awaiter(this, void 0, void 0, function* () {
|
|
196
187
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
197
188
|
const { landscapeId, versionId, commentId } = request;
|
|
198
|
-
const
|
|
189
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
190
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
199
191
|
const _response = yield core.fetcher({
|
|
200
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
192
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments/${core.url.encodePathParam(commentId)}`),
|
|
201
193
|
method: "GET",
|
|
202
194
|
headers: _headers,
|
|
203
195
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -248,9 +240,11 @@ export class CommentsClient {
|
|
|
248
240
|
* versionId: "versionId",
|
|
249
241
|
* commentId: "commentId",
|
|
250
242
|
* body: {
|
|
251
|
-
*
|
|
252
|
-
*
|
|
253
|
-
*
|
|
243
|
+
* body: {
|
|
244
|
+
* content: "content",
|
|
245
|
+
* status: "open",
|
|
246
|
+
* type: "question"
|
|
247
|
+
* }
|
|
254
248
|
* }
|
|
255
249
|
* })
|
|
256
250
|
*/
|
|
@@ -260,10 +254,11 @@ export class CommentsClient {
|
|
|
260
254
|
__upsert(request, requestOptions) {
|
|
261
255
|
return __awaiter(this, void 0, void 0, function* () {
|
|
262
256
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
263
|
-
const { landscapeId, versionId, commentId
|
|
264
|
-
const
|
|
257
|
+
const { landscapeId, versionId, commentId, body: _body } = request;
|
|
258
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
259
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
265
260
|
const _response = yield core.fetcher({
|
|
266
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
261
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments/${core.url.encodePathParam(commentId)}`),
|
|
267
262
|
method: "PUT",
|
|
268
263
|
headers: _headers,
|
|
269
264
|
contentType: "application/json",
|
|
@@ -327,9 +322,10 @@ export class CommentsClient {
|
|
|
327
322
|
return __awaiter(this, void 0, void 0, function* () {
|
|
328
323
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
329
324
|
const { landscapeId, versionId, commentId } = request;
|
|
330
|
-
const
|
|
325
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
326
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
331
327
|
const _response = yield core.fetcher({
|
|
332
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
328
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments/${core.url.encodePathParam(commentId)}`),
|
|
333
329
|
method: "DELETE",
|
|
334
330
|
headers: _headers,
|
|
335
331
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -391,9 +387,10 @@ export class CommentsClient {
|
|
|
391
387
|
return __awaiter(this, void 0, void 0, function* () {
|
|
392
388
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
393
389
|
const { landscapeId, versionId, commentId, body: _body } = request;
|
|
394
|
-
const
|
|
390
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
391
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
395
392
|
const _response = yield core.fetcher({
|
|
396
|
-
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.
|
|
393
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.IcePanelEnvironment.ApiV1, `landscapes/${core.url.encodePathParam(landscapeId)}/versions/${core.url.encodePathParam(versionId)}/comments/${core.url.encodePathParam(commentId)}`),
|
|
397
394
|
method: "PATCH",
|
|
398
395
|
headers: _headers,
|
|
399
396
|
contentType: "application/json",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.mjs";
|
|
2
|
-
import { type
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../../../BaseClient.mjs";
|
|
3
3
|
import * as core from "../../../../../../core/index.mjs";
|
|
4
4
|
import * as IcePanel from "../../../../../index.mjs";
|
|
5
5
|
export declare namespace RepliesClient {
|
|
@@ -8,7 +8,7 @@ export declare namespace RepliesClient {
|
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
export declare class RepliesClient {
|
|
11
|
-
protected readonly _options:
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<RepliesClient.Options>;
|
|
12
12
|
constructor(options?: RepliesClient.Options);
|
|
13
13
|
/**
|
|
14
14
|
* List comment replies
|
|
@@ -90,7 +90,9 @@ export declare class RepliesClient {
|
|
|
90
90
|
* versionId: "versionId",
|
|
91
91
|
* commentId: "commentId",
|
|
92
92
|
* commentReplyId: "commentReplyId",
|
|
93
|
-
*
|
|
93
|
+
* body: {
|
|
94
|
+
* content: "content"
|
|
95
|
+
* }
|
|
94
96
|
* })
|
|
95
97
|
*/
|
|
96
98
|
upsert(request: IcePanel.CommentReplyUpsertRequest, requestOptions?: RepliesClient.RequestOptions): core.HttpResponsePromise<IcePanel.comments.RepliesUpsertResponse>;
|