@redhat-cloud-services/notifications-client 0.0.40 → 1.0.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/README.md +8 -8
- package/dist/EventResourceV1GetEvents/index.d.ts +111 -0
- package/dist/EventResourceV1GetEvents/index.js +143 -0
- package/dist/NotificationResourceV1AppendBehaviorGroupToEventType/index.d.ts +26 -0
- package/dist/NotificationResourceV1AppendBehaviorGroupToEventType/index.js +93 -0
- package/dist/NotificationResourceV1CreateBehaviorGroup/index.d.ts +21 -0
- package/dist/NotificationResourceV1CreateBehaviorGroup/index.js +93 -0
- package/dist/NotificationResourceV1DeleteBehaviorGroup/index.d.ts +20 -0
- package/dist/NotificationResourceV1DeleteBehaviorGroup/index.js +92 -0
- package/dist/NotificationResourceV1DeleteBehaviorGroupFromEventType/index.d.ts +26 -0
- package/dist/NotificationResourceV1DeleteBehaviorGroupFromEventType/index.js +93 -0
- package/dist/NotificationResourceV1FindBehaviorGroupsByBundleId/index.d.ts +20 -0
- package/dist/NotificationResourceV1FindBehaviorGroupsByBundleId/index.js +92 -0
- package/dist/NotificationResourceV1GetApplicationByNameAndBundleName/index.d.ts +26 -0
- package/dist/NotificationResourceV1GetApplicationByNameAndBundleName/index.js +93 -0
- package/dist/NotificationResourceV1GetApplicationsFacets/index.d.ts +20 -0
- package/dist/NotificationResourceV1GetApplicationsFacets/index.js +94 -0
- package/dist/NotificationResourceV1GetBehaviorGroupsAffectedByRemovalOfEndpoint/index.d.ts +20 -0
- package/dist/NotificationResourceV1GetBehaviorGroupsAffectedByRemovalOfEndpoint/index.js +92 -0
- package/dist/NotificationResourceV1GetBundleByName/index.d.ts +20 -0
- package/dist/NotificationResourceV1GetBundleByName/index.js +92 -0
- package/dist/NotificationResourceV1GetBundleFacets/index.d.ts +20 -0
- package/dist/NotificationResourceV1GetBundleFacets/index.js +94 -0
- package/dist/NotificationResourceV1GetEventTypes/index.d.ts +62 -0
- package/dist/NotificationResourceV1GetEventTypes/index.js +115 -0
- package/dist/NotificationResourceV1GetEventTypesAffectedByRemovalOfBehaviorGroup/index.d.ts +20 -0
- package/dist/NotificationResourceV1GetEventTypesAffectedByRemovalOfBehaviorGroup/index.js +92 -0
- package/dist/NotificationResourceV1GetEventTypesByNameAndBundleAndApplicationName/index.d.ts +32 -0
- package/dist/NotificationResourceV1GetEventTypesByNameAndBundleAndApplicationName/index.js +94 -0
- package/dist/NotificationResourceV1GetLinkedBehaviorGroups/index.d.ts +50 -0
- package/dist/NotificationResourceV1GetLinkedBehaviorGroups/index.js +116 -0
- package/dist/NotificationResourceV1UpdateBehaviorGroup/index.d.ts +27 -0
- package/dist/NotificationResourceV1UpdateBehaviorGroup/index.js +94 -0
- package/dist/NotificationResourceV1UpdateBehaviorGroupActions/index.d.ts +26 -0
- package/dist/NotificationResourceV1UpdateBehaviorGroupActions/index.js +94 -0
- package/dist/NotificationResourceV1UpdateEventTypeBehaviors/index.d.ts +26 -0
- package/dist/NotificationResourceV1UpdateEventTypeBehaviors/index.js +94 -0
- package/dist/OrgConfigResourceV1GetDailyDigestTimePreference/index.d.ts +13 -0
- package/dist/OrgConfigResourceV1GetDailyDigestTimePreference/index.js +90 -0
- package/dist/OrgConfigResourceV1SaveDailyDigestTimePreference/index.d.ts +20 -0
- package/dist/OrgConfigResourceV1SaveDailyDigestTimePreference/index.js +93 -0
- package/dist/UserConfigResourceV1GetPreferences/index.d.ts +25 -0
- package/dist/UserConfigResourceV1GetPreferences/index.js +92 -0
- package/dist/UserConfigResourceV1GetSettingsSchema/index.d.ts +19 -0
- package/dist/UserConfigResourceV1GetSettingsSchema/index.js +93 -0
- package/dist/UserConfigResourceV1SaveSettings/index.d.ts +20 -0
- package/dist/UserConfigResourceV1SaveSettings/index.js +92 -0
- package/dist/api.d.ts +2536 -759
- package/dist/api.js +2833 -778
- package/dist/base.d.ts +54 -0
- package/dist/base.js +80 -0
- package/dist/common.d.ts +65 -0
- package/dist/common.js +252 -0
- package/dist/configuration.d.ts +24 -15
- package/dist/configuration.js +19 -12
- package/dist/index.d.ts +27 -13
- package/dist/index.js +89 -17
- package/dist/types/index.d.ts +1657 -0
- package/dist/types/index.js +90 -0
- package/dist/utils/base.d.ts +84 -0
- package/dist/utils/base.js +251 -0
- package/dist/utils/common.d.ts +54 -0
- package/dist/utils/common.js +241 -0
- package/dist/utils/configuration.d.ts +72 -0
- package/dist/utils/configuration.js +33 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.js +19 -0
- package/doc/.nojekyll +1 -0
- package/doc/README.md +11 -420
- package/doc/classes/BaseAPI.md +125 -0
- package/doc/classes/Configuration.md +194 -0
- package/doc/classes/RequiredError.md +179 -0
- package/doc/enums/EmailSubscriptionType.md +21 -0
- package/doc/enums/EndpointStatus.md +76 -0
- package/doc/enums/EndpointType.md +65 -0
- package/doc/enums/Environment.md +54 -0
- package/doc/enums/EventLogEntryActionStatus.md +65 -0
- package/doc/enums/HttpType.md +43 -0
- package/doc/enums/NotificationStatus.md +65 -0
- package/doc/enums/Status.md +32 -0
- package/doc/interfaces/AddAccessRequest.md +44 -0
- package/doc/interfaces/AddApplicationRequest.md +74 -0
- package/doc/interfaces/AggregationEmailTemplate.md +164 -0
- package/doc/interfaces/ApiConfig.md +30 -0
- package/doc/interfaces/Application.md +104 -0
- package/doc/interfaces/Application1.md +44 -0
- package/doc/interfaces/ApplicationSettingsValue.md +33 -0
- package/doc/interfaces/ApplicationSettingsValue1.md +48 -0
- package/doc/interfaces/BasicAuthentication.md +44 -0
- package/doc/interfaces/BehaviorGroup.md +149 -0
- package/doc/interfaces/BehaviorGroupAction.md +59 -0
- package/doc/interfaces/BehaviorGroupActionId.md +44 -0
- package/doc/interfaces/Bundle.md +89 -0
- package/doc/interfaces/BundleSettingsValue.md +33 -0
- package/doc/interfaces/BundleSettingsValue1.md +33 -0
- package/doc/interfaces/CamelProperties.md +93 -0
- package/doc/interfaces/ConfigurationParameters.md +89 -0
- package/doc/interfaces/CreateBehaviorGroupRequest.md +104 -0
- package/doc/interfaces/CreateBehaviorGroupResponse.md +104 -0
- package/doc/interfaces/CurrentStatus.md +59 -0
- package/doc/interfaces/DuplicateNameMigrationReport.md +44 -0
- package/doc/interfaces/Endpoint.md +179 -0
- package/doc/interfaces/EndpointPage.md +63 -0
- package/doc/interfaces/EndpointTestRequest.md +29 -0
- package/doc/interfaces/EventLogEntry.md +119 -0
- package/doc/interfaces/EventLogEntryAction.md +125 -0
- package/doc/interfaces/EventType.md +119 -0
- package/doc/interfaces/EventTypeBehavior.md +59 -0
- package/doc/interfaces/EventTypeBehaviorId.md +44 -0
- package/doc/interfaces/EventTypeSettingsValue.md +48 -0
- package/doc/interfaces/Facet.md +74 -0
- package/doc/interfaces/InstantEmailTemplate.md +149 -0
- package/doc/interfaces/InternalApplicationUserPermission.md +59 -0
- package/doc/interfaces/InternalRoleAccess.md +59 -0
- package/doc/interfaces/InternalUserPermissions.md +59 -0
- package/doc/interfaces/MessageValidationResponse.md +33 -0
- package/doc/interfaces/Meta.md +29 -0
- package/doc/interfaces/NotificationHistory.md +155 -0
- package/doc/interfaces/PageBehaviorGroup.md +63 -0
- package/doc/interfaces/PageEventLogEntry.md +63 -0
- package/doc/interfaces/PageEventType.md +63 -0
- package/doc/interfaces/PageNotificationHistory.md +63 -0
- package/doc/interfaces/RenderEmailTemplateRequest.md +44 -0
- package/doc/interfaces/RequestArgs.md +58 -0
- package/doc/interfaces/RequestDefaultBehaviorGroupPropertyList.md +44 -0
- package/doc/interfaces/RequestSystemSubscriptionProperties.md +44 -0
- package/doc/interfaces/ServerInfo.md +29 -0
- package/doc/interfaces/SettingsValues.md +33 -0
- package/doc/interfaces/SettingsValuesByEventType.md +33 -0
- package/doc/interfaces/SystemSubscriptionProperties.md +59 -0
- package/doc/interfaces/Template.md +104 -0
- package/doc/interfaces/TriggerDailyDigestRequest.md +89 -0
- package/doc/interfaces/UpdateBehaviorGroupRequest.md +74 -0
- package/doc/interfaces/UserConfigPreferences.md +44 -0
- package/doc/interfaces/WebhookProperties.md +89 -0
- package/doc/modules.md +1080 -0
- package/git_push.sh +57 -0
- package/openapitools.json +7 -0
- package/package.json +26 -31
- package/postProcess.sh +3 -11
- package/tsconfig-cjs.json +19 -0
- package/tsconfig-esm.json +21 -0
- package/tsconfig.json +18 -0
- package/doc/classes/appregistrationapi.md +0 -123
- package/doc/classes/appsapi.md +0 -149
- package/doc/classes/baseapi.md +0 -86
- package/doc/classes/configuration.md +0 -140
- package/doc/classes/endpointsapi.md +0 -255
- package/doc/classes/filtersapi.md +0 -124
- package/doc/classes/requirederror.md +0 -109
- package/doc/enums/app.typeenum.md +0 -28
- package/doc/enums/endpoint.typeenum.md +0 -28
- package/doc/enums/endpointattributes.lastdeliverystatusenum.md +0 -38
- package/doc/enums/eventtype.typeenum.md +0 -28
- package/doc/enums/inlineresponse2004data.typeenum.md +0 -28
- package/doc/enums/level.typeenum.md +0 -28
- package/doc/interfaces/appattributes.md +0 -54
- package/doc/interfaces/apprelationships.md +0 -36
- package/doc/interfaces/appsregisterapplication.md +0 -50
- package/doc/interfaces/appsregistereventtypes.md +0 -64
- package/doc/interfaces/appsregistereventtypeslevels.md +0 -50
- package/doc/interfaces/configurationparameters.md +0 -84
- package/doc/interfaces/endpointsendpoint.md +0 -78
- package/doc/interfaces/endpointsendpointfilter.md +0 -64
- package/doc/interfaces/endpointsidendpoint.md +0 -78
- package/doc/interfaces/endpointsidendpointfilter.md +0 -78
- package/doc/interfaces/errors.md +0 -36
- package/doc/interfaces/errorserrors.md +0 -120
- package/doc/interfaces/errorssource.md +0 -50
- package/doc/interfaces/eventtypeattributes.md +0 -54
- package/doc/interfaces/eventtyperelationships.md +0 -36
- package/doc/interfaces/inlineobject.md +0 -50
- package/doc/interfaces/inlineobject1.md +0 -36
- package/doc/interfaces/inlineobject2.md +0 -36
- package/doc/interfaces/inlineresponse200.md +0 -50
- package/doc/interfaces/inlineresponse2001.md +0 -36
- package/doc/interfaces/inlineresponse2002.md +0 -50
- package/doc/interfaces/inlineresponse2003.md +0 -64
- package/doc/interfaces/inlineresponse2004.md +0 -36
- package/doc/interfaces/inlineresponse2004dataattributes.md +0 -36
- package/doc/interfaces/inlineresponse2004datarelationships.md +0 -78
- package/doc/interfaces/inlineresponse201.md +0 -36
- package/doc/interfaces/levelattributes.md +0 -38
- package/doc/interfaces/links.md +0 -86
- package/doc/interfaces/metadata.md +0 -70
- package/doc/interfaces/relationship.md +0 -50
- package/doc/interfaces/relationships.md +0 -36
- package/doc/interfaces/requestargs.md +0 -42
- package/doc/modules/app.md +0 -82
- package/doc/modules/endpoint.md +0 -68
- package/doc/modules/endpointattributes.md +0 -118
- package/doc/modules/eventtype.md +0 -82
- package/doc/modules/inlineresponse2004data.md +0 -78
- package/doc/modules/level.md +0 -68
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
var __assign = (this && this.__assign) || function () {
|
|
5
|
+
__assign = Object.assign || function(t) {
|
|
6
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
7
|
+
s = arguments[i];
|
|
8
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
9
|
+
t[p] = s[p];
|
|
10
|
+
}
|
|
11
|
+
return t;
|
|
12
|
+
};
|
|
13
|
+
return __assign.apply(this, arguments);
|
|
14
|
+
};
|
|
15
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
18
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
19
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
20
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
21
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
25
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
26
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
27
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
28
|
+
function step(op) {
|
|
29
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
30
|
+
while (_) try {
|
|
31
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
32
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
33
|
+
switch (op[0]) {
|
|
34
|
+
case 0: case 1: t = op; break;
|
|
35
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
36
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
37
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
38
|
+
default:
|
|
39
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
40
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
41
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
42
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
43
|
+
if (t[2]) _.ops.pop();
|
|
44
|
+
_.trys.pop(); continue;
|
|
45
|
+
}
|
|
46
|
+
op = body.call(thisArg, _);
|
|
47
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
48
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
52
|
+
exports.createRequestFunction = exports.toPathString = exports.serializeDataIfNeeded = exports.setSearchParams = exports.setOAuthToObject = exports.setBearerAuthToObject = exports.setBasicAuthToObject = exports.setApiKeyToObject = exports.assertParamExists = exports.DUMMY_BASE_URL = void 0;
|
|
53
|
+
var base_1 = require("./base");
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @export
|
|
57
|
+
*/
|
|
58
|
+
exports.DUMMY_BASE_URL = 'https://example.com';
|
|
59
|
+
/**
|
|
60
|
+
*
|
|
61
|
+
* @throws {RequiredError}
|
|
62
|
+
* @export
|
|
63
|
+
*/
|
|
64
|
+
var assertParamExists = function (functionName, paramName, paramValue) {
|
|
65
|
+
if (paramValue === null || paramValue === undefined) {
|
|
66
|
+
throw new base_1.RequiredError(paramName, "Required parameter ".concat(paramName, " was null or undefined when calling ").concat(functionName, "."));
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
exports.assertParamExists = assertParamExists;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @export
|
|
73
|
+
*/
|
|
74
|
+
var setApiKeyToObject = function (object, keyParamName, configuration) {
|
|
75
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
76
|
+
var localVarApiKeyValue, _a;
|
|
77
|
+
return __generator(this, function (_b) {
|
|
78
|
+
switch (_b.label) {
|
|
79
|
+
case 0:
|
|
80
|
+
if (!(configuration && configuration.apiKey)) return [3 /*break*/, 5];
|
|
81
|
+
if (!(typeof configuration.apiKey === 'function')) return [3 /*break*/, 2];
|
|
82
|
+
return [4 /*yield*/, configuration.apiKey(keyParamName)];
|
|
83
|
+
case 1:
|
|
84
|
+
_a = _b.sent();
|
|
85
|
+
return [3 /*break*/, 4];
|
|
86
|
+
case 2: return [4 /*yield*/, configuration.apiKey];
|
|
87
|
+
case 3:
|
|
88
|
+
_a = _b.sent();
|
|
89
|
+
_b.label = 4;
|
|
90
|
+
case 4:
|
|
91
|
+
localVarApiKeyValue = _a;
|
|
92
|
+
object[keyParamName] = localVarApiKeyValue;
|
|
93
|
+
_b.label = 5;
|
|
94
|
+
case 5: return [2 /*return*/];
|
|
95
|
+
}
|
|
96
|
+
});
|
|
97
|
+
});
|
|
98
|
+
};
|
|
99
|
+
exports.setApiKeyToObject = setApiKeyToObject;
|
|
100
|
+
/**
|
|
101
|
+
*
|
|
102
|
+
* @export
|
|
103
|
+
*/
|
|
104
|
+
var setBasicAuthToObject = function (object, configuration) {
|
|
105
|
+
if (configuration && (configuration.username || configuration.password)) {
|
|
106
|
+
object["auth"] = { username: configuration.username, password: configuration.password };
|
|
107
|
+
}
|
|
108
|
+
};
|
|
109
|
+
exports.setBasicAuthToObject = setBasicAuthToObject;
|
|
110
|
+
/**
|
|
111
|
+
*
|
|
112
|
+
* @export
|
|
113
|
+
*/
|
|
114
|
+
var setBearerAuthToObject = function (object, configuration) {
|
|
115
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
116
|
+
var accessToken, _a;
|
|
117
|
+
return __generator(this, function (_b) {
|
|
118
|
+
switch (_b.label) {
|
|
119
|
+
case 0:
|
|
120
|
+
if (!(configuration && configuration.accessToken)) return [3 /*break*/, 5];
|
|
121
|
+
if (!(typeof configuration.accessToken === 'function')) return [3 /*break*/, 2];
|
|
122
|
+
return [4 /*yield*/, configuration.accessToken()];
|
|
123
|
+
case 1:
|
|
124
|
+
_a = _b.sent();
|
|
125
|
+
return [3 /*break*/, 4];
|
|
126
|
+
case 2: return [4 /*yield*/, configuration.accessToken];
|
|
127
|
+
case 3:
|
|
128
|
+
_a = _b.sent();
|
|
129
|
+
_b.label = 4;
|
|
130
|
+
case 4:
|
|
131
|
+
accessToken = _a;
|
|
132
|
+
object["Authorization"] = "Bearer " + accessToken;
|
|
133
|
+
_b.label = 5;
|
|
134
|
+
case 5: return [2 /*return*/];
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
});
|
|
138
|
+
};
|
|
139
|
+
exports.setBearerAuthToObject = setBearerAuthToObject;
|
|
140
|
+
/**
|
|
141
|
+
*
|
|
142
|
+
* @export
|
|
143
|
+
*/
|
|
144
|
+
var setOAuthToObject = function (object, name, scopes, configuration) {
|
|
145
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
146
|
+
var localVarAccessTokenValue, _a;
|
|
147
|
+
return __generator(this, function (_b) {
|
|
148
|
+
switch (_b.label) {
|
|
149
|
+
case 0:
|
|
150
|
+
if (!(configuration && configuration.accessToken)) return [3 /*break*/, 5];
|
|
151
|
+
if (!(typeof configuration.accessToken === 'function')) return [3 /*break*/, 2];
|
|
152
|
+
return [4 /*yield*/, configuration.accessToken(name, scopes)];
|
|
153
|
+
case 1:
|
|
154
|
+
_a = _b.sent();
|
|
155
|
+
return [3 /*break*/, 4];
|
|
156
|
+
case 2: return [4 /*yield*/, configuration.accessToken];
|
|
157
|
+
case 3:
|
|
158
|
+
_a = _b.sent();
|
|
159
|
+
_b.label = 4;
|
|
160
|
+
case 4:
|
|
161
|
+
localVarAccessTokenValue = _a;
|
|
162
|
+
object["Authorization"] = "Bearer " + localVarAccessTokenValue;
|
|
163
|
+
_b.label = 5;
|
|
164
|
+
case 5: return [2 /*return*/];
|
|
165
|
+
}
|
|
166
|
+
});
|
|
167
|
+
});
|
|
168
|
+
};
|
|
169
|
+
exports.setOAuthToObject = setOAuthToObject;
|
|
170
|
+
function setFlattenedQueryParams(urlSearchParams, parameter, key) {
|
|
171
|
+
if (key === void 0) { key = ""; }
|
|
172
|
+
if (parameter == null)
|
|
173
|
+
return;
|
|
174
|
+
if (typeof parameter === "object") {
|
|
175
|
+
if (Array.isArray(parameter)) {
|
|
176
|
+
parameter.forEach(function (item) { return setFlattenedQueryParams(urlSearchParams, item, key); });
|
|
177
|
+
}
|
|
178
|
+
else {
|
|
179
|
+
Object.keys(parameter).forEach(function (currentKey) {
|
|
180
|
+
return setFlattenedQueryParams(urlSearchParams, parameter[currentKey], "".concat(key).concat(key !== '' ? '.' : '').concat(currentKey));
|
|
181
|
+
});
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
else {
|
|
185
|
+
if (urlSearchParams.has(key)) {
|
|
186
|
+
urlSearchParams.append(key, parameter);
|
|
187
|
+
}
|
|
188
|
+
else {
|
|
189
|
+
urlSearchParams.set(key, parameter);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
*
|
|
195
|
+
* @export
|
|
196
|
+
*/
|
|
197
|
+
var setSearchParams = function (url) {
|
|
198
|
+
var objects = [];
|
|
199
|
+
for (var _i = 1; _i < arguments.length; _i++) {
|
|
200
|
+
objects[_i - 1] = arguments[_i];
|
|
201
|
+
}
|
|
202
|
+
var searchParams = new URLSearchParams(url.search);
|
|
203
|
+
setFlattenedQueryParams(searchParams, objects);
|
|
204
|
+
url.search = searchParams.toString();
|
|
205
|
+
};
|
|
206
|
+
exports.setSearchParams = setSearchParams;
|
|
207
|
+
/**
|
|
208
|
+
*
|
|
209
|
+
* @export
|
|
210
|
+
*/
|
|
211
|
+
var serializeDataIfNeeded = function (value, requestOptions, configuration) {
|
|
212
|
+
var nonString = typeof value !== 'string';
|
|
213
|
+
var needsSerialization = nonString && configuration && configuration.isJsonMime
|
|
214
|
+
? configuration.isJsonMime(requestOptions.headers['Content-Type'])
|
|
215
|
+
: nonString;
|
|
216
|
+
return needsSerialization
|
|
217
|
+
? JSON.stringify(value !== undefined ? value : {})
|
|
218
|
+
: (value || "");
|
|
219
|
+
};
|
|
220
|
+
exports.serializeDataIfNeeded = serializeDataIfNeeded;
|
|
221
|
+
/**
|
|
222
|
+
*
|
|
223
|
+
* @export
|
|
224
|
+
*/
|
|
225
|
+
var toPathString = function (url) {
|
|
226
|
+
return url.pathname + url.search + url.hash;
|
|
227
|
+
};
|
|
228
|
+
exports.toPathString = toPathString;
|
|
229
|
+
/**
|
|
230
|
+
*
|
|
231
|
+
* @export
|
|
232
|
+
*/
|
|
233
|
+
var createRequestFunction = function (axiosArgs, globalAxios, BASE_PATH, configuration) {
|
|
234
|
+
return function (axios, basePath) {
|
|
235
|
+
if (axios === void 0) { axios = globalAxios; }
|
|
236
|
+
if (basePath === void 0) { basePath = BASE_PATH; }
|
|
237
|
+
var axiosRequestArgs = __assign(__assign({}, axiosArgs.options), { url: ((configuration === null || configuration === void 0 ? void 0 : configuration.basePath) || basePath) + (0, exports.toPathString)(axiosArgs.urlObj) });
|
|
238
|
+
return axios.request(axiosRequestArgs);
|
|
239
|
+
};
|
|
240
|
+
};
|
|
241
|
+
exports.createRequestFunction = createRequestFunction;
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
export interface ConfigurationParameters {
|
|
2
|
+
apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
|
|
3
|
+
username?: string;
|
|
4
|
+
password?: string;
|
|
5
|
+
accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
|
|
6
|
+
basePath?: string;
|
|
7
|
+
baseOptions?: any;
|
|
8
|
+
formDataCtor?: new () => any;
|
|
9
|
+
}
|
|
10
|
+
export declare class Configuration {
|
|
11
|
+
/**
|
|
12
|
+
* parameter for apiKey security
|
|
13
|
+
* @param name security name
|
|
14
|
+
* @memberof Configuration
|
|
15
|
+
*/
|
|
16
|
+
apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
|
|
17
|
+
/**
|
|
18
|
+
* parameter for basic security
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof Configuration
|
|
22
|
+
*/
|
|
23
|
+
username?: string;
|
|
24
|
+
/**
|
|
25
|
+
* parameter for basic security
|
|
26
|
+
*
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof Configuration
|
|
29
|
+
*/
|
|
30
|
+
password?: string;
|
|
31
|
+
/**
|
|
32
|
+
* parameter for oauth2 security
|
|
33
|
+
* @param name security name
|
|
34
|
+
* @param scopes oauth2 scope
|
|
35
|
+
* @memberof Configuration
|
|
36
|
+
*/
|
|
37
|
+
accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
|
|
38
|
+
/**
|
|
39
|
+
* override base path
|
|
40
|
+
*
|
|
41
|
+
* @type {string}
|
|
42
|
+
* @memberof Configuration
|
|
43
|
+
*/
|
|
44
|
+
basePath?: string;
|
|
45
|
+
/**
|
|
46
|
+
* base options for axios calls
|
|
47
|
+
*
|
|
48
|
+
* @type {any}
|
|
49
|
+
* @memberof Configuration
|
|
50
|
+
*/
|
|
51
|
+
baseOptions?: any;
|
|
52
|
+
/**
|
|
53
|
+
* The FormData constructor that will be used to create multipart form data
|
|
54
|
+
* requests. You can inject this here so that execution environments that
|
|
55
|
+
* do not support the FormData class can still run the generated client.
|
|
56
|
+
*
|
|
57
|
+
* @type {new () => FormData}
|
|
58
|
+
*/
|
|
59
|
+
formDataCtor?: new () => any;
|
|
60
|
+
constructor(param?: ConfigurationParameters);
|
|
61
|
+
/**
|
|
62
|
+
* Check if the given MIME is a JSON MIME.
|
|
63
|
+
* JSON MIME examples:
|
|
64
|
+
* application/json
|
|
65
|
+
* application/json; charset=UTF8
|
|
66
|
+
* APPLICATION/JSON
|
|
67
|
+
* application/vnd.company+json
|
|
68
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
69
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
70
|
+
*/
|
|
71
|
+
isJsonMime(mime: string): boolean;
|
|
72
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.Configuration = void 0;
|
|
6
|
+
var Configuration = /** @class */ (function () {
|
|
7
|
+
function Configuration(param) {
|
|
8
|
+
if (param === void 0) { param = {}; }
|
|
9
|
+
this.apiKey = param.apiKey;
|
|
10
|
+
this.username = param.username;
|
|
11
|
+
this.password = param.password;
|
|
12
|
+
this.accessToken = param.accessToken;
|
|
13
|
+
this.basePath = param.basePath;
|
|
14
|
+
this.baseOptions = param.baseOptions;
|
|
15
|
+
this.formDataCtor = param.formDataCtor;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Check if the given MIME is a JSON MIME.
|
|
19
|
+
* JSON MIME examples:
|
|
20
|
+
* application/json
|
|
21
|
+
* application/json; charset=UTF8
|
|
22
|
+
* APPLICATION/JSON
|
|
23
|
+
* application/vnd.company+json
|
|
24
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
25
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
26
|
+
*/
|
|
27
|
+
Configuration.prototype.isJsonMime = function (mime) {
|
|
28
|
+
var jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
|
|
29
|
+
return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
|
|
30
|
+
};
|
|
31
|
+
return Configuration;
|
|
32
|
+
}());
|
|
33
|
+
exports.Configuration = Configuration;
|
|
@@ -0,0 +1,19 @@
|
|
|
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("./base"), exports);
|
|
18
|
+
__exportStar(require("./common"), exports);
|
|
19
|
+
__exportStar(require("./configuration"), exports);
|
package/doc/.nojekyll
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.
|