auth0 5.2.0 → 5.3.0
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/LICENSE +1 -1
- package/dist/cjs/management/Client.d.ts +3 -0
- package/dist/cjs/management/Client.js +59 -54
- package/dist/cjs/management/api/errors/PreconditionFailedError.d.ts +5 -0
- package/dist/cjs/management/api/errors/PreconditionFailedError.js +54 -0
- package/dist/cjs/management/api/errors/index.d.ts +1 -0
- package/dist/cjs/management/api/errors/index.js +1 -0
- package/dist/cjs/management/api/requests/requests.d.ts +185 -10
- package/dist/cjs/management/api/resources/actions/client/Client.d.ts +3 -0
- package/dist/cjs/management/api/resources/actions/client/Client.js +9 -4
- package/dist/cjs/management/api/resources/actions/resources/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/actions/resources/index.js +2 -1
- package/dist/cjs/management/api/resources/actions/resources/modules/client/Client.d.ts +149 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/client/Client.js +569 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/client/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/client/index.js +2 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/index.d.ts +2 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/index.js +18 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/index.js +37 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/client/Client.d.ts +66 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/client/Client.js +252 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/client/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/client/index.js +2 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/actions/resources/modules/resources/versions/index.js +17 -0
- package/dist/cjs/management/api/resources/clientGrants/client/Client.d.ts +17 -0
- package/dist/cjs/management/api/resources/clientGrants/client/Client.js +61 -0
- package/dist/cjs/management/api/resources/connections/client/Client.d.ts +7 -3
- package/dist/cjs/management/api/resources/connections/client/Client.js +9 -5
- package/dist/cjs/management/api/resources/connections/resources/directoryProvisioning/client/Client.d.ts +18 -0
- package/dist/cjs/management/api/resources/connections/resources/directoryProvisioning/client/Client.js +80 -0
- package/dist/cjs/management/api/resources/deviceCredentials/client/Client.d.ts +1 -0
- package/dist/cjs/management/api/resources/deviceCredentials/client/Client.js +2 -1
- package/dist/cjs/management/api/resources/eventStreams/client/Client.d.ts +1 -2
- package/dist/cjs/management/api/resources/eventStreams/client/Client.js +59 -50
- package/dist/cjs/management/api/resources/flows/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/flows/index.js +1 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/index.js +1 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/types/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/types/index.js +17 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/types/types.d.ts +4 -0
- package/dist/cjs/management/api/resources/flows/resources/executions/types/types.js +7 -0
- package/dist/cjs/management/api/resources/flows/resources/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/flows/resources/index.js +4 -0
- package/dist/cjs/management/api/resources/flows/types/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/flows/types/index.js +17 -0
- package/dist/cjs/management/api/resources/flows/types/types.d.ts +4 -0
- package/dist/cjs/management/api/resources/flows/types/types.js +7 -0
- package/dist/cjs/management/api/resources/groups/client/Client.d.ts +56 -0
- package/dist/cjs/management/api/resources/groups/client/Client.js +224 -0
- package/dist/cjs/management/api/resources/groups/client/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/groups/client/index.js +2 -0
- package/dist/cjs/management/api/resources/groups/index.d.ts +2 -0
- package/dist/cjs/management/api/resources/groups/index.js +18 -0
- package/dist/cjs/management/api/resources/groups/resources/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/groups/resources/index.js +37 -0
- package/dist/cjs/management/api/resources/groups/resources/members/client/Client.d.ts +34 -0
- package/dist/cjs/management/api/resources/groups/resources/members/client/Client.js +148 -0
- package/dist/cjs/management/api/resources/groups/resources/members/client/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/groups/resources/members/client/index.js +2 -0
- package/dist/cjs/management/api/resources/groups/resources/members/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/groups/resources/members/index.js +17 -0
- package/dist/cjs/management/api/resources/index.d.ts +2 -0
- package/dist/cjs/management/api/resources/index.js +3 -1
- package/dist/cjs/management/api/resources/organizations/resources/discoveryDomains/client/Client.d.ts +20 -1
- package/dist/cjs/management/api/resources/organizations/resources/discoveryDomains/client/Client.js +66 -1
- package/dist/cjs/management/api/resources/prompts/resources/rendering/client/Client.d.ts +1 -1
- package/dist/cjs/management/api/resources/refreshTokens/client/Client.d.ts +18 -0
- package/dist/cjs/management/api/resources/refreshTokens/client/Client.js +67 -0
- package/dist/cjs/management/api/resources/roles/client/Client.d.ts +1 -0
- package/dist/cjs/management/api/resources/roles/client/Client.js +3 -0
- package/dist/cjs/management/api/resources/tokenExchangeProfiles/client/Client.d.ts +2 -1
- package/dist/cjs/management/api/resources/tokenExchangeProfiles/client/Client.js +3 -2
- package/dist/cjs/management/api/resources/users/client/Client.d.ts +3 -0
- package/dist/cjs/management/api/resources/users/client/Client.js +23 -18
- package/dist/cjs/management/api/resources/users/resources/groups/client/Client.d.ts +34 -0
- package/dist/cjs/management/api/resources/users/resources/groups/client/Client.js +148 -0
- package/dist/cjs/management/api/resources/users/resources/groups/client/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/users/resources/groups/client/index.js +2 -0
- package/dist/cjs/management/api/resources/users/resources/groups/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/users/resources/groups/index.js +17 -0
- package/dist/cjs/management/api/resources/users/resources/index.d.ts +1 -0
- package/dist/cjs/management/api/resources/users/resources/index.js +2 -1
- package/dist/cjs/management/api/types/types.d.ts +4374 -959
- package/dist/cjs/management/api/types/types.js +1715 -11
- package/dist/cjs/management/version.d.ts +1 -1
- package/dist/cjs/management/version.js +1 -1
- package/dist/esm/management/Client.d.mts +3 -0
- package/dist/esm/management/Client.mjs +5 -0
- package/dist/esm/management/api/errors/PreconditionFailedError.d.mts +5 -0
- package/dist/esm/management/api/errors/PreconditionFailedError.mjs +17 -0
- package/dist/esm/management/api/errors/index.d.mts +1 -0
- package/dist/esm/management/api/errors/index.mjs +1 -0
- package/dist/esm/management/api/requests/requests.d.mts +185 -10
- package/dist/esm/management/api/resources/actions/client/Client.d.mts +3 -0
- package/dist/esm/management/api/resources/actions/client/Client.mjs +5 -0
- package/dist/esm/management/api/resources/actions/resources/index.d.mts +1 -0
- package/dist/esm/management/api/resources/actions/resources/index.mjs +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/client/Client.d.mts +149 -0
- package/dist/esm/management/api/resources/actions/resources/modules/client/Client.mjs +532 -0
- package/dist/esm/management/api/resources/actions/resources/modules/client/index.d.mts +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/client/index.mjs +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/index.d.mts +2 -0
- package/dist/esm/management/api/resources/actions/resources/modules/index.mjs +2 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/index.d.mts +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/index.mjs +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/client/Client.d.mts +66 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/client/Client.mjs +215 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/client/index.d.mts +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/client/index.mjs +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/index.d.mts +1 -0
- package/dist/esm/management/api/resources/actions/resources/modules/resources/versions/index.mjs +1 -0
- package/dist/esm/management/api/resources/clientGrants/client/Client.d.mts +17 -0
- package/dist/esm/management/api/resources/clientGrants/client/Client.mjs +61 -0
- package/dist/esm/management/api/resources/connections/client/Client.d.mts +7 -3
- package/dist/esm/management/api/resources/connections/client/Client.mjs +9 -5
- package/dist/esm/management/api/resources/connections/resources/directoryProvisioning/client/Client.d.mts +18 -0
- package/dist/esm/management/api/resources/connections/resources/directoryProvisioning/client/Client.mjs +80 -0
- package/dist/esm/management/api/resources/deviceCredentials/client/Client.d.mts +1 -0
- package/dist/esm/management/api/resources/deviceCredentials/client/Client.mjs +2 -1
- package/dist/esm/management/api/resources/eventStreams/client/Client.d.mts +1 -2
- package/dist/esm/management/api/resources/eventStreams/client/Client.mjs +59 -50
- package/dist/esm/management/api/resources/flows/index.d.mts +1 -0
- package/dist/esm/management/api/resources/flows/index.mjs +1 -0
- package/dist/esm/management/api/resources/flows/resources/executions/index.d.mts +1 -0
- package/dist/esm/management/api/resources/flows/resources/executions/index.mjs +1 -0
- package/dist/esm/management/api/resources/flows/resources/executions/types/index.d.mts +1 -0
- package/dist/esm/management/api/resources/flows/resources/executions/types/index.mjs +1 -0
- package/dist/esm/management/api/resources/flows/resources/executions/types/types.d.mts +4 -0
- package/dist/esm/management/api/resources/flows/resources/executions/types/types.mjs +4 -0
- package/dist/esm/management/api/resources/flows/resources/index.d.mts +1 -0
- package/dist/esm/management/api/resources/flows/resources/index.mjs +1 -0
- package/dist/esm/management/api/resources/flows/types/index.d.mts +1 -0
- package/dist/esm/management/api/resources/flows/types/index.mjs +1 -0
- package/dist/esm/management/api/resources/flows/types/types.d.mts +4 -0
- package/dist/esm/management/api/resources/flows/types/types.mjs +4 -0
- package/dist/esm/management/api/resources/groups/client/Client.d.mts +56 -0
- package/dist/esm/management/api/resources/groups/client/Client.mjs +187 -0
- package/dist/esm/management/api/resources/groups/client/index.d.mts +1 -0
- package/dist/esm/management/api/resources/groups/client/index.mjs +1 -0
- package/dist/esm/management/api/resources/groups/index.d.mts +2 -0
- package/dist/esm/management/api/resources/groups/index.mjs +2 -0
- package/dist/esm/management/api/resources/groups/resources/index.d.mts +1 -0
- package/dist/esm/management/api/resources/groups/resources/index.mjs +1 -0
- package/dist/esm/management/api/resources/groups/resources/members/client/Client.d.mts +34 -0
- package/dist/esm/management/api/resources/groups/resources/members/client/Client.mjs +111 -0
- package/dist/esm/management/api/resources/groups/resources/members/client/index.d.mts +1 -0
- package/dist/esm/management/api/resources/groups/resources/members/client/index.mjs +1 -0
- package/dist/esm/management/api/resources/groups/resources/members/index.d.mts +1 -0
- package/dist/esm/management/api/resources/groups/resources/members/index.mjs +1 -0
- package/dist/esm/management/api/resources/index.d.mts +2 -0
- package/dist/esm/management/api/resources/index.mjs +2 -0
- package/dist/esm/management/api/resources/organizations/resources/discoveryDomains/client/Client.d.mts +20 -1
- package/dist/esm/management/api/resources/organizations/resources/discoveryDomains/client/Client.mjs +66 -1
- package/dist/esm/management/api/resources/prompts/resources/rendering/client/Client.d.mts +1 -1
- package/dist/esm/management/api/resources/refreshTokens/client/Client.d.mts +18 -0
- package/dist/esm/management/api/resources/refreshTokens/client/Client.mjs +67 -0
- package/dist/esm/management/api/resources/roles/client/Client.d.mts +1 -0
- package/dist/esm/management/api/resources/roles/client/Client.mjs +3 -0
- package/dist/esm/management/api/resources/tokenExchangeProfiles/client/Client.d.mts +2 -1
- package/dist/esm/management/api/resources/tokenExchangeProfiles/client/Client.mjs +3 -2
- package/dist/esm/management/api/resources/users/client/Client.d.mts +3 -0
- package/dist/esm/management/api/resources/users/client/Client.mjs +5 -0
- package/dist/esm/management/api/resources/users/resources/groups/client/Client.d.mts +34 -0
- package/dist/esm/management/api/resources/users/resources/groups/client/Client.mjs +111 -0
- package/dist/esm/management/api/resources/users/resources/groups/client/index.d.mts +1 -0
- package/dist/esm/management/api/resources/users/resources/groups/client/index.mjs +1 -0
- package/dist/esm/management/api/resources/users/resources/groups/index.d.mts +1 -0
- package/dist/esm/management/api/resources/users/resources/groups/index.mjs +1 -0
- package/dist/esm/management/api/resources/users/resources/index.d.mts +1 -0
- package/dist/esm/management/api/resources/users/resources/index.mjs +1 -0
- package/dist/esm/management/api/types/types.d.mts +4374 -959
- package/dist/esm/management/api/types/types.mjs +1705 -7
- package/dist/esm/management/version.d.mts +1 -1
- package/dist/esm/management/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +1547 -186
|
@@ -178,6 +178,7 @@ class DeviceCredentialsClient {
|
|
|
178
178
|
* @example
|
|
179
179
|
* await client.deviceCredentials.createPublicKey({
|
|
180
180
|
* device_name: "device_name",
|
|
181
|
+
* type: "public_key",
|
|
181
182
|
* value: "value",
|
|
182
183
|
* device_id: "device_id"
|
|
183
184
|
* })
|
|
@@ -197,7 +198,7 @@ class DeviceCredentialsClient {
|
|
|
197
198
|
contentType: "application/json",
|
|
198
199
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
199
200
|
requestType: "json",
|
|
200
|
-
body:
|
|
201
|
+
body: request,
|
|
201
202
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
202
203
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
203
204
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -31,8 +31,7 @@ export declare class EventStreamsClient {
|
|
|
31
31
|
* take: 1
|
|
32
32
|
* })
|
|
33
33
|
*/
|
|
34
|
-
list(request?: Management.ListEventStreamsRequestParameters, requestOptions?: EventStreamsClient.RequestOptions): core.
|
|
35
|
-
private __list;
|
|
34
|
+
list(request?: Management.ListEventStreamsRequestParameters, requestOptions?: EventStreamsClient.RequestOptions): Promise<core.Page<Management.EventStreamResponseContent, Management.ListEventStreamsResponseContent>>;
|
|
36
35
|
/**
|
|
37
36
|
* @param {Management.EventStreamsCreateRequest} request
|
|
38
37
|
* @param {EventStreamsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -80,58 +80,67 @@ class EventStreamsClient {
|
|
|
80
80
|
* take: 1
|
|
81
81
|
* })
|
|
82
82
|
*/
|
|
83
|
-
list(
|
|
84
|
-
return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions));
|
|
85
|
-
}
|
|
86
|
-
__list() {
|
|
83
|
+
list() {
|
|
87
84
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
if (take !== undefined) {
|
|
95
|
-
_queryParams["take"] = (_a = take === null || take === void 0 ? void 0 : take.toString()) !== null && _a !== void 0 ? _a : null;
|
|
96
|
-
}
|
|
97
|
-
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
98
|
-
let _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_b = this._options) === null || _b === void 0 ? void 0 : _b.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
99
|
-
const _response = yield ((_c = this._options.fetcher) !== null && _c !== void 0 ? _c : core.fetcher)({
|
|
100
|
-
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ManagementEnvironment.Default, "event-streams"),
|
|
101
|
-
method: "GET",
|
|
102
|
-
headers: _headers,
|
|
103
|
-
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
104
|
-
timeoutMs: ((_h = (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.timeoutInSeconds) !== null && _h !== void 0 ? _h : 60) * 1000,
|
|
105
|
-
maxRetries: (_j = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _j !== void 0 ? _j : (_k = this._options) === null || _k === void 0 ? void 0 : _k.maxRetries,
|
|
106
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
107
|
-
fetchFn: (_l = this._options) === null || _l === void 0 ? void 0 : _l.fetch,
|
|
108
|
-
logging: this._options.logging,
|
|
109
|
-
});
|
|
110
|
-
if (_response.ok) {
|
|
111
|
-
return {
|
|
112
|
-
data: _response.body,
|
|
113
|
-
rawResponse: _response.rawResponse,
|
|
114
|
-
};
|
|
115
|
-
}
|
|
116
|
-
if (_response.error.reason === "status-code") {
|
|
117
|
-
switch (_response.error.statusCode) {
|
|
118
|
-
case 400:
|
|
119
|
-
throw new Management.BadRequestError(_response.error.body, _response.rawResponse);
|
|
120
|
-
case 401:
|
|
121
|
-
throw new Management.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
122
|
-
case 403:
|
|
123
|
-
throw new Management.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
124
|
-
case 429:
|
|
125
|
-
throw new Management.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
126
|
-
default:
|
|
127
|
-
throw new errors.ManagementError({
|
|
128
|
-
statusCode: _response.error.statusCode,
|
|
129
|
-
body: _response.error.body,
|
|
130
|
-
rawResponse: _response.rawResponse,
|
|
131
|
-
});
|
|
85
|
+
const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
|
|
86
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
87
|
+
const { from: from_, take = 50 } = request;
|
|
88
|
+
const _queryParams = {};
|
|
89
|
+
if (from_ !== undefined) {
|
|
90
|
+
_queryParams["from"] = from_;
|
|
132
91
|
}
|
|
133
|
-
|
|
134
|
-
|
|
92
|
+
if (take !== undefined) {
|
|
93
|
+
_queryParams["take"] = (_a = take === null || take === void 0 ? void 0 : take.toString()) !== null && _a !== void 0 ? _a : null;
|
|
94
|
+
}
|
|
95
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
96
|
+
let _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_b = this._options) === null || _b === void 0 ? void 0 : _b.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
97
|
+
const _response = yield ((_c = this._options.fetcher) !== null && _c !== void 0 ? _c : core.fetcher)({
|
|
98
|
+
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ManagementEnvironment.Default, "event-streams"),
|
|
99
|
+
method: "GET",
|
|
100
|
+
headers: _headers,
|
|
101
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
102
|
+
timeoutMs: ((_h = (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.timeoutInSeconds) !== null && _h !== void 0 ? _h : 60) * 1000,
|
|
103
|
+
maxRetries: (_j = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _j !== void 0 ? _j : (_k = this._options) === null || _k === void 0 ? void 0 : _k.maxRetries,
|
|
104
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
105
|
+
fetchFn: (_l = this._options) === null || _l === void 0 ? void 0 : _l.fetch,
|
|
106
|
+
logging: this._options.logging,
|
|
107
|
+
});
|
|
108
|
+
if (_response.ok) {
|
|
109
|
+
return {
|
|
110
|
+
data: _response.body,
|
|
111
|
+
rawResponse: _response.rawResponse,
|
|
112
|
+
};
|
|
113
|
+
}
|
|
114
|
+
if (_response.error.reason === "status-code") {
|
|
115
|
+
switch (_response.error.statusCode) {
|
|
116
|
+
case 400:
|
|
117
|
+
throw new Management.BadRequestError(_response.error.body, _response.rawResponse);
|
|
118
|
+
case 401:
|
|
119
|
+
throw new Management.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
120
|
+
case 403:
|
|
121
|
+
throw new Management.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
122
|
+
case 429:
|
|
123
|
+
throw new Management.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
124
|
+
default:
|
|
125
|
+
throw new errors.ManagementError({
|
|
126
|
+
statusCode: _response.error.statusCode,
|
|
127
|
+
body: _response.error.body,
|
|
128
|
+
rawResponse: _response.rawResponse,
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/event-streams");
|
|
133
|
+
}));
|
|
134
|
+
const dataWithRawResponse = yield list(request).withRawResponse();
|
|
135
|
+
return new core.Page({
|
|
136
|
+
response: dataWithRawResponse.data,
|
|
137
|
+
rawResponse: dataWithRawResponse.rawResponse,
|
|
138
|
+
hasNextPage: (response) => (response === null || response === void 0 ? void 0 : response.next) != null && !(typeof (response === null || response === void 0 ? void 0 : response.next) === "string" && (response === null || response === void 0 ? void 0 : response.next) === ""),
|
|
139
|
+
getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.eventStreams) !== null && _a !== void 0 ? _a : []; },
|
|
140
|
+
loadPage: (response) => {
|
|
141
|
+
return list(core.setObjectProperty(request, "from", response === null || response === void 0 ? void 0 : response.next));
|
|
142
|
+
},
|
|
143
|
+
});
|
|
135
144
|
});
|
|
136
145
|
}
|
|
137
146
|
/**
|
|
@@ -16,3 +16,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./client/index.js"), exports);
|
|
18
18
|
__exportStar(require("./resources/index.js"), exports);
|
|
19
|
+
__exportStar(require("./types/index.js"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./types.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./types.js"), exports);
|
|
@@ -32,7 +32,11 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
32
32
|
return result;
|
|
33
33
|
};
|
|
34
34
|
})();
|
|
35
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
36
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
|
+
};
|
|
35
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
39
|
exports.vault = exports.executions = void 0;
|
|
37
40
|
exports.executions = __importStar(require("./executions/index.js"));
|
|
41
|
+
__exportStar(require("./executions/types/index.js"), exports);
|
|
38
42
|
exports.vault = __importStar(require("./vault/index.js"));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./types.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./types.js"), exports);
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../core/index.js";
|
|
4
|
+
import * as Management from "../../../index.js";
|
|
5
|
+
import { MembersClient } from "../resources/members/client/Client.js";
|
|
6
|
+
export declare namespace GroupsClient {
|
|
7
|
+
type Options = BaseClientOptions;
|
|
8
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
export declare class GroupsClient {
|
|
12
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<GroupsClient.Options>;
|
|
13
|
+
protected _members: MembersClient | undefined;
|
|
14
|
+
constructor(options: GroupsClient.Options);
|
|
15
|
+
get members(): MembersClient;
|
|
16
|
+
/**
|
|
17
|
+
* List all groups in your tenant.
|
|
18
|
+
*
|
|
19
|
+
* @param {Management.ListGroupsRequestParameters} request
|
|
20
|
+
* @param {GroupsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
21
|
+
*
|
|
22
|
+
* @throws {@link Management.BadRequestError}
|
|
23
|
+
* @throws {@link Management.UnauthorizedError}
|
|
24
|
+
* @throws {@link Management.ForbiddenError}
|
|
25
|
+
* @throws {@link Management.TooManyRequestsError}
|
|
26
|
+
*
|
|
27
|
+
* @example
|
|
28
|
+
* await client.groups.list({
|
|
29
|
+
* connection_id: "connection_id",
|
|
30
|
+
* name: "name",
|
|
31
|
+
* external_id: "external_id",
|
|
32
|
+
* fields: "fields",
|
|
33
|
+
* include_fields: true,
|
|
34
|
+
* from: "from",
|
|
35
|
+
* take: 1
|
|
36
|
+
* })
|
|
37
|
+
*/
|
|
38
|
+
list(request?: Management.ListGroupsRequestParameters, requestOptions?: GroupsClient.RequestOptions): Promise<core.Page<Management.Group, Management.ListGroupsPaginatedResponseContent>>;
|
|
39
|
+
/**
|
|
40
|
+
* Retrieve a group by its ID.
|
|
41
|
+
*
|
|
42
|
+
* @param {string} id - Unique identifier for the group (service-generated).
|
|
43
|
+
* @param {GroupsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
44
|
+
*
|
|
45
|
+
* @throws {@link Management.BadRequestError}
|
|
46
|
+
* @throws {@link Management.UnauthorizedError}
|
|
47
|
+
* @throws {@link Management.ForbiddenError}
|
|
48
|
+
* @throws {@link Management.NotFoundError}
|
|
49
|
+
* @throws {@link Management.TooManyRequestsError}
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
* await client.groups.get("id")
|
|
53
|
+
*/
|
|
54
|
+
get(id: string, requestOptions?: GroupsClient.RequestOptions): core.HttpResponsePromise<Management.GetGroupResponseContent>;
|
|
55
|
+
private __get;
|
|
56
|
+
}
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.GroupsClient = void 0;
|
|
47
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
48
|
+
const core = __importStar(require("../../../../core/index.js"));
|
|
49
|
+
const headers_js_1 = require("../../../../core/headers.js");
|
|
50
|
+
const environments = __importStar(require("../../../../environments.js"));
|
|
51
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
52
|
+
const errors = __importStar(require("../../../../errors/index.js"));
|
|
53
|
+
const Management = __importStar(require("../../../index.js"));
|
|
54
|
+
const Client_js_1 = require("../resources/members/client/Client.js");
|
|
55
|
+
class GroupsClient {
|
|
56
|
+
constructor(options) {
|
|
57
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
58
|
+
}
|
|
59
|
+
get members() {
|
|
60
|
+
var _a;
|
|
61
|
+
return ((_a = this._members) !== null && _a !== void 0 ? _a : (this._members = new Client_js_1.MembersClient(this._options)));
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* List all groups in your tenant.
|
|
65
|
+
*
|
|
66
|
+
* @param {Management.ListGroupsRequestParameters} request
|
|
67
|
+
* @param {GroupsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
|
+
*
|
|
69
|
+
* @throws {@link Management.BadRequestError}
|
|
70
|
+
* @throws {@link Management.UnauthorizedError}
|
|
71
|
+
* @throws {@link Management.ForbiddenError}
|
|
72
|
+
* @throws {@link Management.TooManyRequestsError}
|
|
73
|
+
*
|
|
74
|
+
* @example
|
|
75
|
+
* await client.groups.list({
|
|
76
|
+
* connection_id: "connection_id",
|
|
77
|
+
* name: "name",
|
|
78
|
+
* external_id: "external_id",
|
|
79
|
+
* fields: "fields",
|
|
80
|
+
* include_fields: true,
|
|
81
|
+
* from: "from",
|
|
82
|
+
* take: 1
|
|
83
|
+
* })
|
|
84
|
+
*/
|
|
85
|
+
list() {
|
|
86
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
87
|
+
const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
|
|
88
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
89
|
+
const { connection_id: connectionId, name, external_id: externalId, fields, include_fields: includeFields, from: from_, take = 50, } = request;
|
|
90
|
+
const _queryParams = {};
|
|
91
|
+
if (connectionId !== undefined) {
|
|
92
|
+
_queryParams["connection_id"] = connectionId;
|
|
93
|
+
}
|
|
94
|
+
if (name !== undefined) {
|
|
95
|
+
_queryParams["name"] = name;
|
|
96
|
+
}
|
|
97
|
+
if (externalId !== undefined) {
|
|
98
|
+
_queryParams["external_id"] = externalId;
|
|
99
|
+
}
|
|
100
|
+
if (fields !== undefined) {
|
|
101
|
+
_queryParams["fields"] = fields;
|
|
102
|
+
}
|
|
103
|
+
if (includeFields !== undefined) {
|
|
104
|
+
_queryParams["include_fields"] = (_a = includeFields === null || includeFields === void 0 ? void 0 : includeFields.toString()) !== null && _a !== void 0 ? _a : null;
|
|
105
|
+
}
|
|
106
|
+
if (from_ !== undefined) {
|
|
107
|
+
_queryParams["from"] = from_;
|
|
108
|
+
}
|
|
109
|
+
if (take !== undefined) {
|
|
110
|
+
_queryParams["take"] = (_b = take === null || take === void 0 ? void 0 : take.toString()) !== null && _b !== void 0 ? _b : null;
|
|
111
|
+
}
|
|
112
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
113
|
+
let _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
114
|
+
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
115
|
+
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ManagementEnvironment.Default, "groups"),
|
|
116
|
+
method: "GET",
|
|
117
|
+
headers: _headers,
|
|
118
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
119
|
+
timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
|
|
120
|
+
maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
|
|
121
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
122
|
+
fetchFn: (_m = this._options) === null || _m === void 0 ? void 0 : _m.fetch,
|
|
123
|
+
logging: this._options.logging,
|
|
124
|
+
});
|
|
125
|
+
if (_response.ok) {
|
|
126
|
+
return {
|
|
127
|
+
data: _response.body,
|
|
128
|
+
rawResponse: _response.rawResponse,
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
if (_response.error.reason === "status-code") {
|
|
132
|
+
switch (_response.error.statusCode) {
|
|
133
|
+
case 400:
|
|
134
|
+
throw new Management.BadRequestError(_response.error.body, _response.rawResponse);
|
|
135
|
+
case 401:
|
|
136
|
+
throw new Management.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
137
|
+
case 403:
|
|
138
|
+
throw new Management.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
139
|
+
case 429:
|
|
140
|
+
throw new Management.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
141
|
+
default:
|
|
142
|
+
throw new errors.ManagementError({
|
|
143
|
+
statusCode: _response.error.statusCode,
|
|
144
|
+
body: _response.error.body,
|
|
145
|
+
rawResponse: _response.rawResponse,
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/groups");
|
|
150
|
+
}));
|
|
151
|
+
const dataWithRawResponse = yield list(request).withRawResponse();
|
|
152
|
+
return new core.Page({
|
|
153
|
+
response: dataWithRawResponse.data,
|
|
154
|
+
rawResponse: dataWithRawResponse.rawResponse,
|
|
155
|
+
hasNextPage: (response) => (response === null || response === void 0 ? void 0 : response.next) != null && !(typeof (response === null || response === void 0 ? void 0 : response.next) === "string" && (response === null || response === void 0 ? void 0 : response.next) === ""),
|
|
156
|
+
getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.groups) !== null && _a !== void 0 ? _a : []; },
|
|
157
|
+
loadPage: (response) => {
|
|
158
|
+
return list(core.setObjectProperty(request, "from", response === null || response === void 0 ? void 0 : response.next));
|
|
159
|
+
},
|
|
160
|
+
});
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* Retrieve a group by its ID.
|
|
165
|
+
*
|
|
166
|
+
* @param {string} id - Unique identifier for the group (service-generated).
|
|
167
|
+
* @param {GroupsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
168
|
+
*
|
|
169
|
+
* @throws {@link Management.BadRequestError}
|
|
170
|
+
* @throws {@link Management.UnauthorizedError}
|
|
171
|
+
* @throws {@link Management.ForbiddenError}
|
|
172
|
+
* @throws {@link Management.NotFoundError}
|
|
173
|
+
* @throws {@link Management.TooManyRequestsError}
|
|
174
|
+
*
|
|
175
|
+
* @example
|
|
176
|
+
* await client.groups.get("id")
|
|
177
|
+
*/
|
|
178
|
+
get(id, requestOptions) {
|
|
179
|
+
return core.HttpResponsePromise.fromPromise(this.__get(id, requestOptions));
|
|
180
|
+
}
|
|
181
|
+
__get(id, requestOptions) {
|
|
182
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
183
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
184
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
185
|
+
let _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
186
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
187
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ManagementEnvironment.Default, `groups/${core.url.encodePathParam(id)}`),
|
|
188
|
+
method: "GET",
|
|
189
|
+
headers: _headers,
|
|
190
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
191
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
192
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
193
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
194
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
195
|
+
logging: this._options.logging,
|
|
196
|
+
});
|
|
197
|
+
if (_response.ok) {
|
|
198
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
199
|
+
}
|
|
200
|
+
if (_response.error.reason === "status-code") {
|
|
201
|
+
switch (_response.error.statusCode) {
|
|
202
|
+
case 400:
|
|
203
|
+
throw new Management.BadRequestError(_response.error.body, _response.rawResponse);
|
|
204
|
+
case 401:
|
|
205
|
+
throw new Management.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
206
|
+
case 403:
|
|
207
|
+
throw new Management.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
208
|
+
case 404:
|
|
209
|
+
throw new Management.NotFoundError(_response.error.body, _response.rawResponse);
|
|
210
|
+
case 429:
|
|
211
|
+
throw new Management.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
212
|
+
default:
|
|
213
|
+
throw new errors.ManagementError({
|
|
214
|
+
statusCode: _response.error.statusCode,
|
|
215
|
+
body: _response.error.body,
|
|
216
|
+
rawResponse: _response.rawResponse,
|
|
217
|
+
});
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/groups/{id}");
|
|
221
|
+
});
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
exports.GroupsClient = GroupsClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|
|
18
|
+
__exportStar(require("./resources/index.js"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * as members from "./members/index.js";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.members = void 0;
|
|
37
|
+
exports.members = __importStar(require("./members/index.js"));
|