@onesignal/node-onesignal 1.0.0-beta5 → 1.0.0-beta7
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/.github/workflows/npm_deploy.yml +7 -5
- package/CHANGELOG.md +13 -10
- package/dist/apis/DefaultApi.d.ts +66 -0
- package/dist/apis/DefaultApi.js +1537 -0
- package/dist/apis/DefaultApi.js.map +1 -0
- package/dist/apis/baseapi.d.ts +18 -0
- package/dist/apis/baseapi.js +46 -0
- package/dist/apis/baseapi.js.map +1 -0
- package/dist/apis/exception.d.ts +10 -0
- package/dist/apis/exception.js +32 -0
- package/dist/apis/exception.js.map +1 -0
- package/dist/auth/auth.d.ts +42 -0
- package/dist/auth/auth.js +109 -0
- package/dist/auth/auth.js.map +1 -0
- package/dist/configuration.d.ts +20 -0
- package/dist/configuration.js +33 -0
- package/dist/configuration.js.map +1 -0
- package/dist/http/http.d.ts +73 -0
- package/dist/http/http.js +215 -0
- package/dist/http/http.js.map +1 -0
- package/dist/http/isomorphic-fetch.d.ts +5 -0
- package/dist/http/isomorphic-fetch.js +33 -0
- package/dist/http/isomorphic-fetch.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.js +29 -0
- package/dist/index.js.map +1 -0
- package/dist/middleware.d.ts +16 -0
- package/dist/middleware.js +18 -0
- package/dist/middleware.js.map +1 -0
- package/dist/models/App.d.ts +47 -0
- package/dist/models/App.js +196 -0
- package/dist/models/App.js.map +1 -0
- package/dist/models/BasicNotification.d.ts +122 -0
- package/dist/models/BasicNotification.js +622 -0
- package/dist/models/BasicNotification.js.map +1 -0
- package/dist/models/BasicNotificationAllOf.d.ts +110 -0
- package/dist/models/BasicNotificationAllOf.js +550 -0
- package/dist/models/BasicNotificationAllOf.js.map +1 -0
- package/dist/models/BasicNotificationAllOfAndroidBackgroundLayout.d.ts +19 -0
- package/dist/models/BasicNotificationAllOfAndroidBackgroundLayout.js +34 -0
- package/dist/models/BasicNotificationAllOfAndroidBackgroundLayout.js.map +1 -0
- package/dist/models/Button.d.ts +19 -0
- package/dist/models/Button.js +34 -0
- package/dist/models/Button.js.map +1 -0
- package/dist/models/CancelNotificationSuccessResponse.d.ts +17 -0
- package/dist/models/CancelNotificationSuccessResponse.js +22 -0
- package/dist/models/CancelNotificationSuccessResponse.js.map +1 -0
- package/dist/models/CreateNotificationBadRequestResponse.d.ts +17 -0
- package/dist/models/CreateNotificationBadRequestResponse.js +22 -0
- package/dist/models/CreateNotificationBadRequestResponse.js.map +1 -0
- package/dist/models/CreateNotificationSuccessResponse.d.ts +21 -0
- package/dist/models/CreateNotificationSuccessResponse.js +40 -0
- package/dist/models/CreateNotificationSuccessResponse.js.map +1 -0
- package/dist/models/CreatePlayerSuccessResponse.d.ts +18 -0
- package/dist/models/CreatePlayerSuccessResponse.js +28 -0
- package/dist/models/CreatePlayerSuccessResponse.js.map +1 -0
- package/dist/models/CreateSegmentBadRequestResponse.d.ts +18 -0
- package/dist/models/CreateSegmentBadRequestResponse.js +28 -0
- package/dist/models/CreateSegmentBadRequestResponse.js.map +1 -0
- package/dist/models/CreateSegmentConflictResponse.d.ts +18 -0
- package/dist/models/CreateSegmentConflictResponse.js +28 -0
- package/dist/models/CreateSegmentConflictResponse.js.map +1 -0
- package/dist/models/CreateSegmentSuccessResponse.d.ts +18 -0
- package/dist/models/CreateSegmentSuccessResponse.js +28 -0
- package/dist/models/CreateSegmentSuccessResponse.js.map +1 -0
- package/dist/models/DeletePlayerBadRequestResponse.d.ts +17 -0
- package/dist/models/DeletePlayerBadRequestResponse.js +22 -0
- package/dist/models/DeletePlayerBadRequestResponse.js.map +1 -0
- package/dist/models/DeletePlayerNotFoundResponse.d.ts +17 -0
- package/dist/models/DeletePlayerNotFoundResponse.js +22 -0
- package/dist/models/DeletePlayerNotFoundResponse.js.map +1 -0
- package/dist/models/DeletePlayerSuccessResponse.d.ts +17 -0
- package/dist/models/DeletePlayerSuccessResponse.js +22 -0
- package/dist/models/DeletePlayerSuccessResponse.js.map +1 -0
- package/dist/models/DeleteSegmentBadRequestResponse.d.ts +17 -0
- package/dist/models/DeleteSegmentBadRequestResponse.js +22 -0
- package/dist/models/DeleteSegmentBadRequestResponse.js.map +1 -0
- package/dist/models/DeleteSegmentNotFoundResponse.d.ts +17 -0
- package/dist/models/DeleteSegmentNotFoundResponse.js +22 -0
- package/dist/models/DeleteSegmentNotFoundResponse.js.map +1 -0
- package/dist/models/DeleteSegmentSuccessResponse.d.ts +17 -0
- package/dist/models/DeleteSegmentSuccessResponse.js +22 -0
- package/dist/models/DeleteSegmentSuccessResponse.js.map +1 -0
- package/dist/models/DeliveryData.d.ts +21 -0
- package/dist/models/DeliveryData.js +46 -0
- package/dist/models/DeliveryData.js.map +1 -0
- package/dist/models/ExportPlayersRequestBody.d.ts +19 -0
- package/dist/models/ExportPlayersRequestBody.js +34 -0
- package/dist/models/ExportPlayersRequestBody.js.map +1 -0
- package/dist/models/ExportPlayersSuccessResponse.d.ts +17 -0
- package/dist/models/ExportPlayersSuccessResponse.js +22 -0
- package/dist/models/ExportPlayersSuccessResponse.js.map +1 -0
- package/dist/models/Filter.d.ts +21 -0
- package/dist/models/Filter.js +40 -0
- package/dist/models/Filter.js.map +1 -0
- package/dist/models/FilterExpressions.d.ts +23 -0
- package/dist/models/FilterExpressions.js +46 -0
- package/dist/models/FilterExpressions.js.map +1 -0
- package/dist/models/FilterNotificationTarget.d.ts +28 -0
- package/dist/models/FilterNotificationTarget.js +88 -0
- package/dist/models/FilterNotificationTarget.js.map +1 -0
- package/dist/models/GetNotificationRequestBody.d.ts +20 -0
- package/dist/models/GetNotificationRequestBody.js +34 -0
- package/dist/models/GetNotificationRequestBody.js.map +1 -0
- package/dist/models/InvalidIdentifierError.d.ts +18 -0
- package/dist/models/InvalidIdentifierError.js +28 -0
- package/dist/models/InvalidIdentifierError.js.map +1 -0
- package/dist/models/Notification.d.ts +123 -0
- package/dist/models/Notification.js +628 -0
- package/dist/models/Notification.js.map +1 -0
- package/dist/models/Notification200Errors.d.ts +18 -0
- package/dist/models/Notification200Errors.js +28 -0
- package/dist/models/Notification200Errors.js.map +1 -0
- package/dist/models/NotificationAllOf.d.ts +17 -0
- package/dist/models/NotificationAllOf.js +22 -0
- package/dist/models/NotificationAllOf.js.map +1 -0
- package/dist/models/NotificationHistoryBadRequestResponse.d.ts +18 -0
- package/dist/models/NotificationHistoryBadRequestResponse.js +28 -0
- package/dist/models/NotificationHistoryBadRequestResponse.js.map +1 -0
- package/dist/models/NotificationHistorySuccessResponse.d.ts +18 -0
- package/dist/models/NotificationHistorySuccessResponse.js +28 -0
- package/dist/models/NotificationHistorySuccessResponse.js.map +1 -0
- package/dist/models/NotificationSlice.d.ts +21 -0
- package/dist/models/NotificationSlice.js +40 -0
- package/dist/models/NotificationSlice.js.map +1 -0
- package/dist/models/NotificationTarget.d.ts +28 -0
- package/dist/models/NotificationTarget.js +88 -0
- package/dist/models/NotificationTarget.js.map +1 -0
- package/dist/models/NotificationWithMeta.d.ts +135 -0
- package/dist/models/NotificationWithMeta.js +688 -0
- package/dist/models/NotificationWithMeta.js.map +1 -0
- package/dist/models/NotificationWithMetaAllOf.d.ts +28 -0
- package/dist/models/NotificationWithMetaAllOf.js +82 -0
- package/dist/models/NotificationWithMetaAllOf.js.map +1 -0
- package/dist/models/ObjectSerializer.d.ts +59 -0
- package/dist/models/ObjectSerializer.js +367 -0
- package/dist/models/ObjectSerializer.js.map +1 -0
- package/dist/models/Operator.d.ts +18 -0
- package/dist/models/Operator.js +22 -0
- package/dist/models/Operator.js.map +1 -0
- package/dist/models/OutcomeData.d.ts +20 -0
- package/dist/models/OutcomeData.js +34 -0
- package/dist/models/OutcomeData.js.map +1 -0
- package/dist/models/OutcomesData.d.ts +18 -0
- package/dist/models/OutcomesData.js +22 -0
- package/dist/models/OutcomesData.js.map +1 -0
- package/dist/models/PlatformDeliveryData.d.ts +27 -0
- package/dist/models/PlatformDeliveryData.js +64 -0
- package/dist/models/PlatformDeliveryData.js.map +1 -0
- package/dist/models/PlatformDeliveryDataEmailAllOf.d.ts +23 -0
- package/dist/models/PlatformDeliveryDataEmailAllOf.js +58 -0
- package/dist/models/PlatformDeliveryDataEmailAllOf.js.map +1 -0
- package/dist/models/PlatformDeliveryDataSmsAllOf.d.ts +19 -0
- package/dist/models/PlatformDeliveryDataSmsAllOf.js +34 -0
- package/dist/models/PlatformDeliveryDataSmsAllOf.js.map +1 -0
- package/dist/models/Player.d.ts +43 -0
- package/dist/models/Player.js +178 -0
- package/dist/models/Player.js.map +1 -0
- package/dist/models/PlayerNotificationTarget.d.ts +26 -0
- package/dist/models/PlayerNotificationTarget.js +76 -0
- package/dist/models/PlayerNotificationTarget.js.map +1 -0
- package/dist/models/PlayerSlice.d.ts +21 -0
- package/dist/models/PlayerSlice.js +40 -0
- package/dist/models/PlayerSlice.js.map +1 -0
- package/dist/models/Purchase.d.ts +19 -0
- package/dist/models/Purchase.js +34 -0
- package/dist/models/Purchase.js.map +1 -0
- package/dist/models/Segment.d.ts +20 -0
- package/dist/models/Segment.js +34 -0
- package/dist/models/Segment.js.map +1 -0
- package/dist/models/SegmentNotificationTarget.d.ts +18 -0
- package/dist/models/SegmentNotificationTarget.js +28 -0
- package/dist/models/SegmentNotificationTarget.js.map +1 -0
- package/dist/models/StringMap.d.ts +59 -0
- package/dist/models/StringMap.js +274 -0
- package/dist/models/StringMap.js.map +1 -0
- package/dist/models/UpdatePlayerSuccessResponse.d.ts +17 -0
- package/dist/models/UpdatePlayerSuccessResponse.js +22 -0
- package/dist/models/UpdatePlayerSuccessResponse.js.map +1 -0
- package/dist/models/UpdatePlayerTagsRequestBody.d.ts +17 -0
- package/dist/models/UpdatePlayerTagsRequestBody.js +22 -0
- package/dist/models/UpdatePlayerTagsRequestBody.js.map +1 -0
- package/dist/models/UpdatePlayerTagsSuccessResponse.d.ts +17 -0
- package/dist/models/UpdatePlayerTagsSuccessResponse.js +22 -0
- package/dist/models/UpdatePlayerTagsSuccessResponse.js.map +1 -0
- package/dist/models/all.d.ts +50 -0
- package/dist/models/all.js +67 -0
- package/dist/models/all.js.map +1 -0
- package/dist/rxjsStub.d.ts +10 -0
- package/dist/rxjsStub.js +33 -0
- package/dist/rxjsStub.js.map +1 -0
- package/dist/servers.d.ts +17 -0
- package/dist/servers.js +32 -0
- package/dist/servers.js.map +1 -0
- package/dist/types/ObjectParamAPI.d.ts +125 -0
- package/dist/types/ObjectParamAPI.js +70 -0
- package/dist/types/ObjectParamAPI.js.map +1 -0
- package/dist/types/ObservableAPI.d.ts +49 -0
- package/dist/types/ObservableAPI.js +472 -0
- package/dist/types/ObservableAPI.js.map +1 -0
- package/dist/types/PromiseAPI.d.ts +46 -0
- package/dist/types/PromiseAPI.js +88 -0
- package/dist/types/PromiseAPI.js.map +1 -0
- package/dist/util.d.ts +2 -0
- package/dist/util.js +29 -0
- package/dist/util.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,1537 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
18
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
19
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
20
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
21
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
22
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
23
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
24
|
+
});
|
|
25
|
+
};
|
|
26
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
27
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
28
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
29
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
30
|
+
function step(op) {
|
|
31
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
32
|
+
while (_) try {
|
|
33
|
+
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;
|
|
34
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
35
|
+
switch (op[0]) {
|
|
36
|
+
case 0: case 1: t = op; break;
|
|
37
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
38
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
39
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
40
|
+
default:
|
|
41
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
42
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
43
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
44
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
45
|
+
if (t[2]) _.ops.pop();
|
|
46
|
+
_.trys.pop(); continue;
|
|
47
|
+
}
|
|
48
|
+
op = body.call(thisArg, _);
|
|
49
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
50
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
54
|
+
exports.DefaultApiResponseProcessor = exports.DefaultApiRequestFactory = void 0;
|
|
55
|
+
var baseapi_1 = require("./baseapi");
|
|
56
|
+
var http_1 = require("../http/http");
|
|
57
|
+
var ObjectSerializer_1 = require("../models/ObjectSerializer");
|
|
58
|
+
var exception_1 = require("./exception");
|
|
59
|
+
var util_1 = require("../util");
|
|
60
|
+
var DefaultApiRequestFactory = (function (_super) {
|
|
61
|
+
__extends(DefaultApiRequestFactory, _super);
|
|
62
|
+
function DefaultApiRequestFactory() {
|
|
63
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
64
|
+
}
|
|
65
|
+
DefaultApiRequestFactory.prototype.cancelNotification = function (appId, notificationId, _options) {
|
|
66
|
+
var _a, _b, _c;
|
|
67
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
68
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
69
|
+
return __generator(this, function (_d) {
|
|
70
|
+
switch (_d.label) {
|
|
71
|
+
case 0:
|
|
72
|
+
_config = _options || this.configuration;
|
|
73
|
+
if (appId === null || appId === undefined) {
|
|
74
|
+
throw new baseapi_1.RequiredError("DefaultApi", "cancelNotification", "appId");
|
|
75
|
+
}
|
|
76
|
+
if (notificationId === null || notificationId === undefined) {
|
|
77
|
+
throw new baseapi_1.RequiredError("DefaultApi", "cancelNotification", "notificationId");
|
|
78
|
+
}
|
|
79
|
+
localVarPath = '/notifications/{notification_id}'
|
|
80
|
+
.replace('{' + 'notification_id' + '}', encodeURIComponent(String(notificationId)));
|
|
81
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.DELETE);
|
|
82
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
83
|
+
if (appId !== undefined) {
|
|
84
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
85
|
+
}
|
|
86
|
+
authMethod = _config.authMethods["app_key"];
|
|
87
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
88
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
89
|
+
case 1:
|
|
90
|
+
_d.sent();
|
|
91
|
+
_d.label = 2;
|
|
92
|
+
case 2:
|
|
93
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
94
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
95
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
96
|
+
case 3:
|
|
97
|
+
_d.sent();
|
|
98
|
+
_d.label = 4;
|
|
99
|
+
case 4: return [2, requestContext];
|
|
100
|
+
}
|
|
101
|
+
});
|
|
102
|
+
});
|
|
103
|
+
};
|
|
104
|
+
DefaultApiRequestFactory.prototype.createApp = function (app, _options) {
|
|
105
|
+
var _a, _b, _c;
|
|
106
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
107
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
108
|
+
return __generator(this, function (_d) {
|
|
109
|
+
switch (_d.label) {
|
|
110
|
+
case 0:
|
|
111
|
+
_config = _options || this.configuration;
|
|
112
|
+
if (app === null || app === undefined) {
|
|
113
|
+
throw new baseapi_1.RequiredError("DefaultApi", "createApp", "app");
|
|
114
|
+
}
|
|
115
|
+
localVarPath = '/apps';
|
|
116
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
117
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
118
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
119
|
+
"application/json"
|
|
120
|
+
]);
|
|
121
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
122
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(app, "App", ""), contentType);
|
|
123
|
+
requestContext.setBody(serializedBody);
|
|
124
|
+
authMethod = _config.authMethods["user_key"];
|
|
125
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
126
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
127
|
+
case 1:
|
|
128
|
+
_d.sent();
|
|
129
|
+
_d.label = 2;
|
|
130
|
+
case 2:
|
|
131
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
132
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
133
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
134
|
+
case 3:
|
|
135
|
+
_d.sent();
|
|
136
|
+
_d.label = 4;
|
|
137
|
+
case 4: return [2, requestContext];
|
|
138
|
+
}
|
|
139
|
+
});
|
|
140
|
+
});
|
|
141
|
+
};
|
|
142
|
+
DefaultApiRequestFactory.prototype.createNotification = function (notification, _options) {
|
|
143
|
+
var _a, _b, _c;
|
|
144
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
145
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
146
|
+
return __generator(this, function (_d) {
|
|
147
|
+
switch (_d.label) {
|
|
148
|
+
case 0:
|
|
149
|
+
_config = _options || this.configuration;
|
|
150
|
+
if (notification === null || notification === undefined) {
|
|
151
|
+
throw new baseapi_1.RequiredError("DefaultApi", "createNotification", "notification");
|
|
152
|
+
}
|
|
153
|
+
localVarPath = '/notifications';
|
|
154
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
155
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
156
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
157
|
+
"application/json"
|
|
158
|
+
]);
|
|
159
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
160
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(notification, "Notification", ""), contentType);
|
|
161
|
+
requestContext.setBody(serializedBody);
|
|
162
|
+
authMethod = _config.authMethods["app_key"];
|
|
163
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
164
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
165
|
+
case 1:
|
|
166
|
+
_d.sent();
|
|
167
|
+
_d.label = 2;
|
|
168
|
+
case 2:
|
|
169
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
170
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
171
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
172
|
+
case 3:
|
|
173
|
+
_d.sent();
|
|
174
|
+
_d.label = 4;
|
|
175
|
+
case 4: return [2, requestContext];
|
|
176
|
+
}
|
|
177
|
+
});
|
|
178
|
+
});
|
|
179
|
+
};
|
|
180
|
+
DefaultApiRequestFactory.prototype.createPlayer = function (player, _options) {
|
|
181
|
+
var _a, _b, _c;
|
|
182
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
183
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
184
|
+
return __generator(this, function (_d) {
|
|
185
|
+
switch (_d.label) {
|
|
186
|
+
case 0:
|
|
187
|
+
_config = _options || this.configuration;
|
|
188
|
+
if (player === null || player === undefined) {
|
|
189
|
+
throw new baseapi_1.RequiredError("DefaultApi", "createPlayer", "player");
|
|
190
|
+
}
|
|
191
|
+
localVarPath = '/players';
|
|
192
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
193
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
194
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
195
|
+
"application/json"
|
|
196
|
+
]);
|
|
197
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
198
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(player, "Player", ""), contentType);
|
|
199
|
+
requestContext.setBody(serializedBody);
|
|
200
|
+
authMethod = _config.authMethods["app_key"];
|
|
201
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
202
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
203
|
+
case 1:
|
|
204
|
+
_d.sent();
|
|
205
|
+
_d.label = 2;
|
|
206
|
+
case 2:
|
|
207
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
208
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
209
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
210
|
+
case 3:
|
|
211
|
+
_d.sent();
|
|
212
|
+
_d.label = 4;
|
|
213
|
+
case 4: return [2, requestContext];
|
|
214
|
+
}
|
|
215
|
+
});
|
|
216
|
+
});
|
|
217
|
+
};
|
|
218
|
+
DefaultApiRequestFactory.prototype.createSegments = function (appId, segment, _options) {
|
|
219
|
+
var _a, _b, _c;
|
|
220
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
221
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
222
|
+
return __generator(this, function (_d) {
|
|
223
|
+
switch (_d.label) {
|
|
224
|
+
case 0:
|
|
225
|
+
_config = _options || this.configuration;
|
|
226
|
+
if (appId === null || appId === undefined) {
|
|
227
|
+
throw new baseapi_1.RequiredError("DefaultApi", "createSegments", "appId");
|
|
228
|
+
}
|
|
229
|
+
localVarPath = '/apps/{app_id}/segments'
|
|
230
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)));
|
|
231
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
232
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
233
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
234
|
+
"application/json"
|
|
235
|
+
]);
|
|
236
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
237
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(segment, "Segment", ""), contentType);
|
|
238
|
+
requestContext.setBody(serializedBody);
|
|
239
|
+
authMethod = _config.authMethods["app_key"];
|
|
240
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
241
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
242
|
+
case 1:
|
|
243
|
+
_d.sent();
|
|
244
|
+
_d.label = 2;
|
|
245
|
+
case 2:
|
|
246
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
247
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
248
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
249
|
+
case 3:
|
|
250
|
+
_d.sent();
|
|
251
|
+
_d.label = 4;
|
|
252
|
+
case 4: return [2, requestContext];
|
|
253
|
+
}
|
|
254
|
+
});
|
|
255
|
+
});
|
|
256
|
+
};
|
|
257
|
+
DefaultApiRequestFactory.prototype.deletePlayer = function (appId, playerId, _options) {
|
|
258
|
+
var _a, _b, _c;
|
|
259
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
260
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
261
|
+
return __generator(this, function (_d) {
|
|
262
|
+
switch (_d.label) {
|
|
263
|
+
case 0:
|
|
264
|
+
_config = _options || this.configuration;
|
|
265
|
+
if (appId === null || appId === undefined) {
|
|
266
|
+
throw new baseapi_1.RequiredError("DefaultApi", "deletePlayer", "appId");
|
|
267
|
+
}
|
|
268
|
+
if (playerId === null || playerId === undefined) {
|
|
269
|
+
throw new baseapi_1.RequiredError("DefaultApi", "deletePlayer", "playerId");
|
|
270
|
+
}
|
|
271
|
+
localVarPath = '/players/{player_id}'
|
|
272
|
+
.replace('{' + 'player_id' + '}', encodeURIComponent(String(playerId)));
|
|
273
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.DELETE);
|
|
274
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
275
|
+
if (appId !== undefined) {
|
|
276
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
277
|
+
}
|
|
278
|
+
authMethod = _config.authMethods["app_key"];
|
|
279
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
280
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
281
|
+
case 1:
|
|
282
|
+
_d.sent();
|
|
283
|
+
_d.label = 2;
|
|
284
|
+
case 2:
|
|
285
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
286
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
287
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
288
|
+
case 3:
|
|
289
|
+
_d.sent();
|
|
290
|
+
_d.label = 4;
|
|
291
|
+
case 4: return [2, requestContext];
|
|
292
|
+
}
|
|
293
|
+
});
|
|
294
|
+
});
|
|
295
|
+
};
|
|
296
|
+
DefaultApiRequestFactory.prototype.deleteSegments = function (appId, segmentId, _options) {
|
|
297
|
+
var _a, _b, _c;
|
|
298
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
299
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
300
|
+
return __generator(this, function (_d) {
|
|
301
|
+
switch (_d.label) {
|
|
302
|
+
case 0:
|
|
303
|
+
_config = _options || this.configuration;
|
|
304
|
+
if (appId === null || appId === undefined) {
|
|
305
|
+
throw new baseapi_1.RequiredError("DefaultApi", "deleteSegments", "appId");
|
|
306
|
+
}
|
|
307
|
+
if (segmentId === null || segmentId === undefined) {
|
|
308
|
+
throw new baseapi_1.RequiredError("DefaultApi", "deleteSegments", "segmentId");
|
|
309
|
+
}
|
|
310
|
+
localVarPath = '/apps/{app_id}/segments/{segment_id}'
|
|
311
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)))
|
|
312
|
+
.replace('{' + 'segment_id' + '}', encodeURIComponent(String(segmentId)));
|
|
313
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.DELETE);
|
|
314
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
315
|
+
authMethod = _config.authMethods["app_key"];
|
|
316
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
317
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
318
|
+
case 1:
|
|
319
|
+
_d.sent();
|
|
320
|
+
_d.label = 2;
|
|
321
|
+
case 2:
|
|
322
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
323
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
324
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
325
|
+
case 3:
|
|
326
|
+
_d.sent();
|
|
327
|
+
_d.label = 4;
|
|
328
|
+
case 4: return [2, requestContext];
|
|
329
|
+
}
|
|
330
|
+
});
|
|
331
|
+
});
|
|
332
|
+
};
|
|
333
|
+
DefaultApiRequestFactory.prototype.exportPlayers = function (appId, exportPlayersRequestBody, _options) {
|
|
334
|
+
var _a, _b, _c;
|
|
335
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
336
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
337
|
+
return __generator(this, function (_d) {
|
|
338
|
+
switch (_d.label) {
|
|
339
|
+
case 0:
|
|
340
|
+
_config = _options || this.configuration;
|
|
341
|
+
if (appId === null || appId === undefined) {
|
|
342
|
+
throw new baseapi_1.RequiredError("DefaultApi", "exportPlayers", "appId");
|
|
343
|
+
}
|
|
344
|
+
localVarPath = '/players/csv_export?app_id={app_id}'
|
|
345
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)));
|
|
346
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
347
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
348
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
349
|
+
"application/json"
|
|
350
|
+
]);
|
|
351
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
352
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(exportPlayersRequestBody, "ExportPlayersRequestBody", ""), contentType);
|
|
353
|
+
requestContext.setBody(serializedBody);
|
|
354
|
+
authMethod = _config.authMethods["app_key"];
|
|
355
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
356
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
357
|
+
case 1:
|
|
358
|
+
_d.sent();
|
|
359
|
+
_d.label = 2;
|
|
360
|
+
case 2:
|
|
361
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
362
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
363
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
364
|
+
case 3:
|
|
365
|
+
_d.sent();
|
|
366
|
+
_d.label = 4;
|
|
367
|
+
case 4: return [2, requestContext];
|
|
368
|
+
}
|
|
369
|
+
});
|
|
370
|
+
});
|
|
371
|
+
};
|
|
372
|
+
DefaultApiRequestFactory.prototype.getApp = function (appId, _options) {
|
|
373
|
+
var _a, _b, _c;
|
|
374
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
375
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
376
|
+
return __generator(this, function (_d) {
|
|
377
|
+
switch (_d.label) {
|
|
378
|
+
case 0:
|
|
379
|
+
_config = _options || this.configuration;
|
|
380
|
+
if (appId === null || appId === undefined) {
|
|
381
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getApp", "appId");
|
|
382
|
+
}
|
|
383
|
+
localVarPath = '/apps/{app_id}'
|
|
384
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)));
|
|
385
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
386
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
387
|
+
authMethod = _config.authMethods["user_key"];
|
|
388
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
389
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
390
|
+
case 1:
|
|
391
|
+
_d.sent();
|
|
392
|
+
_d.label = 2;
|
|
393
|
+
case 2:
|
|
394
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
395
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
396
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
397
|
+
case 3:
|
|
398
|
+
_d.sent();
|
|
399
|
+
_d.label = 4;
|
|
400
|
+
case 4: return [2, requestContext];
|
|
401
|
+
}
|
|
402
|
+
});
|
|
403
|
+
});
|
|
404
|
+
};
|
|
405
|
+
DefaultApiRequestFactory.prototype.getApps = function (_options) {
|
|
406
|
+
var _a, _b, _c;
|
|
407
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
408
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
409
|
+
return __generator(this, function (_d) {
|
|
410
|
+
switch (_d.label) {
|
|
411
|
+
case 0:
|
|
412
|
+
_config = _options || this.configuration;
|
|
413
|
+
localVarPath = '/apps';
|
|
414
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
415
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
416
|
+
authMethod = _config.authMethods["user_key"];
|
|
417
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
418
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
419
|
+
case 1:
|
|
420
|
+
_d.sent();
|
|
421
|
+
_d.label = 2;
|
|
422
|
+
case 2:
|
|
423
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
424
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
425
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
426
|
+
case 3:
|
|
427
|
+
_d.sent();
|
|
428
|
+
_d.label = 4;
|
|
429
|
+
case 4: return [2, requestContext];
|
|
430
|
+
}
|
|
431
|
+
});
|
|
432
|
+
});
|
|
433
|
+
};
|
|
434
|
+
DefaultApiRequestFactory.prototype.getNotification = function (appId, notificationId, _options) {
|
|
435
|
+
var _a, _b, _c;
|
|
436
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
437
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
438
|
+
return __generator(this, function (_d) {
|
|
439
|
+
switch (_d.label) {
|
|
440
|
+
case 0:
|
|
441
|
+
_config = _options || this.configuration;
|
|
442
|
+
if (appId === null || appId === undefined) {
|
|
443
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getNotification", "appId");
|
|
444
|
+
}
|
|
445
|
+
if (notificationId === null || notificationId === undefined) {
|
|
446
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getNotification", "notificationId");
|
|
447
|
+
}
|
|
448
|
+
localVarPath = '/notifications/{notification_id}'
|
|
449
|
+
.replace('{' + 'notification_id' + '}', encodeURIComponent(String(notificationId)));
|
|
450
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
451
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
452
|
+
if (appId !== undefined) {
|
|
453
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
454
|
+
}
|
|
455
|
+
authMethod = _config.authMethods["app_key"];
|
|
456
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
457
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
458
|
+
case 1:
|
|
459
|
+
_d.sent();
|
|
460
|
+
_d.label = 2;
|
|
461
|
+
case 2:
|
|
462
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
463
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
464
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
465
|
+
case 3:
|
|
466
|
+
_d.sent();
|
|
467
|
+
_d.label = 4;
|
|
468
|
+
case 4: return [2, requestContext];
|
|
469
|
+
}
|
|
470
|
+
});
|
|
471
|
+
});
|
|
472
|
+
};
|
|
473
|
+
DefaultApiRequestFactory.prototype.getNotificationHistory = function (notificationId, getNotificationRequestBody, _options) {
|
|
474
|
+
var _a, _b, _c;
|
|
475
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
476
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
477
|
+
return __generator(this, function (_d) {
|
|
478
|
+
switch (_d.label) {
|
|
479
|
+
case 0:
|
|
480
|
+
_config = _options || this.configuration;
|
|
481
|
+
if (notificationId === null || notificationId === undefined) {
|
|
482
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getNotificationHistory", "notificationId");
|
|
483
|
+
}
|
|
484
|
+
if (getNotificationRequestBody === null || getNotificationRequestBody === undefined) {
|
|
485
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getNotificationHistory", "getNotificationRequestBody");
|
|
486
|
+
}
|
|
487
|
+
localVarPath = '/notifications/{notification_id}/history'
|
|
488
|
+
.replace('{' + 'notification_id' + '}', encodeURIComponent(String(notificationId)));
|
|
489
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.POST);
|
|
490
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
491
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
492
|
+
"application/json"
|
|
493
|
+
]);
|
|
494
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
495
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(getNotificationRequestBody, "GetNotificationRequestBody", ""), contentType);
|
|
496
|
+
requestContext.setBody(serializedBody);
|
|
497
|
+
authMethod = _config.authMethods["app_key"];
|
|
498
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
499
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
500
|
+
case 1:
|
|
501
|
+
_d.sent();
|
|
502
|
+
_d.label = 2;
|
|
503
|
+
case 2:
|
|
504
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
505
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
506
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
507
|
+
case 3:
|
|
508
|
+
_d.sent();
|
|
509
|
+
_d.label = 4;
|
|
510
|
+
case 4: return [2, requestContext];
|
|
511
|
+
}
|
|
512
|
+
});
|
|
513
|
+
});
|
|
514
|
+
};
|
|
515
|
+
DefaultApiRequestFactory.prototype.getNotifications = function (appId, limit, offset, kind, _options) {
|
|
516
|
+
var _a, _b, _c;
|
|
517
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
518
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
519
|
+
return __generator(this, function (_d) {
|
|
520
|
+
switch (_d.label) {
|
|
521
|
+
case 0:
|
|
522
|
+
_config = _options || this.configuration;
|
|
523
|
+
if (appId === null || appId === undefined) {
|
|
524
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getNotifications", "appId");
|
|
525
|
+
}
|
|
526
|
+
localVarPath = '/notifications';
|
|
527
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
528
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
529
|
+
if (appId !== undefined) {
|
|
530
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
531
|
+
}
|
|
532
|
+
if (limit !== undefined) {
|
|
533
|
+
requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", ""));
|
|
534
|
+
}
|
|
535
|
+
if (offset !== undefined) {
|
|
536
|
+
requestContext.setQueryParam("offset", ObjectSerializer_1.ObjectSerializer.serialize(offset, "number", ""));
|
|
537
|
+
}
|
|
538
|
+
if (kind !== undefined) {
|
|
539
|
+
requestContext.setQueryParam("kind", ObjectSerializer_1.ObjectSerializer.serialize(kind, "0 | 1 | 3", ""));
|
|
540
|
+
}
|
|
541
|
+
authMethod = _config.authMethods["app_key"];
|
|
542
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
543
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
544
|
+
case 1:
|
|
545
|
+
_d.sent();
|
|
546
|
+
_d.label = 2;
|
|
547
|
+
case 2:
|
|
548
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
549
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
550
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
551
|
+
case 3:
|
|
552
|
+
_d.sent();
|
|
553
|
+
_d.label = 4;
|
|
554
|
+
case 4: return [2, requestContext];
|
|
555
|
+
}
|
|
556
|
+
});
|
|
557
|
+
});
|
|
558
|
+
};
|
|
559
|
+
DefaultApiRequestFactory.prototype.getOutcomes = function (appId, outcomeNames, outcomeNames2, outcomeTimeRange, outcomePlatforms, outcomeAttribution, _options) {
|
|
560
|
+
var _a, _b, _c;
|
|
561
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
562
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
563
|
+
return __generator(this, function (_d) {
|
|
564
|
+
switch (_d.label) {
|
|
565
|
+
case 0:
|
|
566
|
+
_config = _options || this.configuration;
|
|
567
|
+
if (appId === null || appId === undefined) {
|
|
568
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getOutcomes", "appId");
|
|
569
|
+
}
|
|
570
|
+
if (outcomeNames === null || outcomeNames === undefined) {
|
|
571
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getOutcomes", "outcomeNames");
|
|
572
|
+
}
|
|
573
|
+
localVarPath = '/apps/{app_id}/outcomes'
|
|
574
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)));
|
|
575
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
576
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
577
|
+
if (outcomeNames !== undefined) {
|
|
578
|
+
requestContext.setQueryParam("outcome_names", ObjectSerializer_1.ObjectSerializer.serialize(outcomeNames, "string", ""));
|
|
579
|
+
}
|
|
580
|
+
if (outcomeNames2 !== undefined) {
|
|
581
|
+
requestContext.setQueryParam("outcome_names[]", ObjectSerializer_1.ObjectSerializer.serialize(outcomeNames2, "string", ""));
|
|
582
|
+
}
|
|
583
|
+
if (outcomeTimeRange !== undefined) {
|
|
584
|
+
requestContext.setQueryParam("outcome_time_range", ObjectSerializer_1.ObjectSerializer.serialize(outcomeTimeRange, "string", ""));
|
|
585
|
+
}
|
|
586
|
+
if (outcomePlatforms !== undefined) {
|
|
587
|
+
requestContext.setQueryParam("outcome_platforms", ObjectSerializer_1.ObjectSerializer.serialize(outcomePlatforms, "string", ""));
|
|
588
|
+
}
|
|
589
|
+
if (outcomeAttribution !== undefined) {
|
|
590
|
+
requestContext.setQueryParam("outcome_attribution", ObjectSerializer_1.ObjectSerializer.serialize(outcomeAttribution, "string", ""));
|
|
591
|
+
}
|
|
592
|
+
authMethod = _config.authMethods["app_key"];
|
|
593
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
594
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
595
|
+
case 1:
|
|
596
|
+
_d.sent();
|
|
597
|
+
_d.label = 2;
|
|
598
|
+
case 2:
|
|
599
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
600
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
601
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
602
|
+
case 3:
|
|
603
|
+
_d.sent();
|
|
604
|
+
_d.label = 4;
|
|
605
|
+
case 4: return [2, requestContext];
|
|
606
|
+
}
|
|
607
|
+
});
|
|
608
|
+
});
|
|
609
|
+
};
|
|
610
|
+
DefaultApiRequestFactory.prototype.getPlayer = function (appId, playerId, emailAuthHash, _options) {
|
|
611
|
+
var _a, _b, _c;
|
|
612
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
613
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
614
|
+
return __generator(this, function (_d) {
|
|
615
|
+
switch (_d.label) {
|
|
616
|
+
case 0:
|
|
617
|
+
_config = _options || this.configuration;
|
|
618
|
+
if (appId === null || appId === undefined) {
|
|
619
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getPlayer", "appId");
|
|
620
|
+
}
|
|
621
|
+
if (playerId === null || playerId === undefined) {
|
|
622
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getPlayer", "playerId");
|
|
623
|
+
}
|
|
624
|
+
localVarPath = '/players/{player_id}'
|
|
625
|
+
.replace('{' + 'player_id' + '}', encodeURIComponent(String(playerId)));
|
|
626
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
627
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
628
|
+
if (appId !== undefined) {
|
|
629
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
630
|
+
}
|
|
631
|
+
if (emailAuthHash !== undefined) {
|
|
632
|
+
requestContext.setQueryParam("email_auth_hash", ObjectSerializer_1.ObjectSerializer.serialize(emailAuthHash, "string", ""));
|
|
633
|
+
}
|
|
634
|
+
authMethod = _config.authMethods["app_key"];
|
|
635
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
636
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
637
|
+
case 1:
|
|
638
|
+
_d.sent();
|
|
639
|
+
_d.label = 2;
|
|
640
|
+
case 2:
|
|
641
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
642
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
643
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
644
|
+
case 3:
|
|
645
|
+
_d.sent();
|
|
646
|
+
_d.label = 4;
|
|
647
|
+
case 4: return [2, requestContext];
|
|
648
|
+
}
|
|
649
|
+
});
|
|
650
|
+
});
|
|
651
|
+
};
|
|
652
|
+
DefaultApiRequestFactory.prototype.getPlayers = function (appId, limit, offset, _options) {
|
|
653
|
+
var _a, _b, _c;
|
|
654
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
655
|
+
var _config, localVarPath, requestContext, authMethod, defaultAuth;
|
|
656
|
+
return __generator(this, function (_d) {
|
|
657
|
+
switch (_d.label) {
|
|
658
|
+
case 0:
|
|
659
|
+
_config = _options || this.configuration;
|
|
660
|
+
if (appId === null || appId === undefined) {
|
|
661
|
+
throw new baseapi_1.RequiredError("DefaultApi", "getPlayers", "appId");
|
|
662
|
+
}
|
|
663
|
+
localVarPath = '/players';
|
|
664
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
665
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
666
|
+
if (appId !== undefined) {
|
|
667
|
+
requestContext.setQueryParam("app_id", ObjectSerializer_1.ObjectSerializer.serialize(appId, "string", ""));
|
|
668
|
+
}
|
|
669
|
+
if (limit !== undefined) {
|
|
670
|
+
requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", ""));
|
|
671
|
+
}
|
|
672
|
+
if (offset !== undefined) {
|
|
673
|
+
requestContext.setQueryParam("offset", ObjectSerializer_1.ObjectSerializer.serialize(offset, "number", ""));
|
|
674
|
+
}
|
|
675
|
+
authMethod = _config.authMethods["app_key"];
|
|
676
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
677
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
678
|
+
case 1:
|
|
679
|
+
_d.sent();
|
|
680
|
+
_d.label = 2;
|
|
681
|
+
case 2:
|
|
682
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
683
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
684
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
685
|
+
case 3:
|
|
686
|
+
_d.sent();
|
|
687
|
+
_d.label = 4;
|
|
688
|
+
case 4: return [2, requestContext];
|
|
689
|
+
}
|
|
690
|
+
});
|
|
691
|
+
});
|
|
692
|
+
};
|
|
693
|
+
DefaultApiRequestFactory.prototype.updateApp = function (appId, app, _options) {
|
|
694
|
+
var _a, _b, _c;
|
|
695
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
696
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
697
|
+
return __generator(this, function (_d) {
|
|
698
|
+
switch (_d.label) {
|
|
699
|
+
case 0:
|
|
700
|
+
_config = _options || this.configuration;
|
|
701
|
+
if (appId === null || appId === undefined) {
|
|
702
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updateApp", "appId");
|
|
703
|
+
}
|
|
704
|
+
if (app === null || app === undefined) {
|
|
705
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updateApp", "app");
|
|
706
|
+
}
|
|
707
|
+
localVarPath = '/apps/{app_id}'
|
|
708
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)));
|
|
709
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.PUT);
|
|
710
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
711
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
712
|
+
"application/json"
|
|
713
|
+
]);
|
|
714
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
715
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(app, "App", ""), contentType);
|
|
716
|
+
requestContext.setBody(serializedBody);
|
|
717
|
+
authMethod = _config.authMethods["user_key"];
|
|
718
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
719
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
720
|
+
case 1:
|
|
721
|
+
_d.sent();
|
|
722
|
+
_d.label = 2;
|
|
723
|
+
case 2:
|
|
724
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
725
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
726
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
727
|
+
case 3:
|
|
728
|
+
_d.sent();
|
|
729
|
+
_d.label = 4;
|
|
730
|
+
case 4: return [2, requestContext];
|
|
731
|
+
}
|
|
732
|
+
});
|
|
733
|
+
});
|
|
734
|
+
};
|
|
735
|
+
DefaultApiRequestFactory.prototype.updatePlayer = function (playerId, player, _options) {
|
|
736
|
+
var _a, _b, _c;
|
|
737
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
738
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
739
|
+
return __generator(this, function (_d) {
|
|
740
|
+
switch (_d.label) {
|
|
741
|
+
case 0:
|
|
742
|
+
_config = _options || this.configuration;
|
|
743
|
+
if (playerId === null || playerId === undefined) {
|
|
744
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updatePlayer", "playerId");
|
|
745
|
+
}
|
|
746
|
+
if (player === null || player === undefined) {
|
|
747
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updatePlayer", "player");
|
|
748
|
+
}
|
|
749
|
+
localVarPath = '/players/{player_id}'
|
|
750
|
+
.replace('{' + 'player_id' + '}', encodeURIComponent(String(playerId)));
|
|
751
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.PUT);
|
|
752
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
753
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
754
|
+
"application/json"
|
|
755
|
+
]);
|
|
756
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
757
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(player, "Player", ""), contentType);
|
|
758
|
+
requestContext.setBody(serializedBody);
|
|
759
|
+
authMethod = _config.authMethods["app_key"];
|
|
760
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
761
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
762
|
+
case 1:
|
|
763
|
+
_d.sent();
|
|
764
|
+
_d.label = 2;
|
|
765
|
+
case 2:
|
|
766
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
767
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
768
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
769
|
+
case 3:
|
|
770
|
+
_d.sent();
|
|
771
|
+
_d.label = 4;
|
|
772
|
+
case 4: return [2, requestContext];
|
|
773
|
+
}
|
|
774
|
+
});
|
|
775
|
+
});
|
|
776
|
+
};
|
|
777
|
+
DefaultApiRequestFactory.prototype.updatePlayerTags = function (appId, externalUserId, updatePlayerTagsRequestBody, _options) {
|
|
778
|
+
var _a, _b, _c;
|
|
779
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
780
|
+
var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
|
|
781
|
+
return __generator(this, function (_d) {
|
|
782
|
+
switch (_d.label) {
|
|
783
|
+
case 0:
|
|
784
|
+
_config = _options || this.configuration;
|
|
785
|
+
if (appId === null || appId === undefined) {
|
|
786
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updatePlayerTags", "appId");
|
|
787
|
+
}
|
|
788
|
+
if (externalUserId === null || externalUserId === undefined) {
|
|
789
|
+
throw new baseapi_1.RequiredError("DefaultApi", "updatePlayerTags", "externalUserId");
|
|
790
|
+
}
|
|
791
|
+
localVarPath = '/apps/{app_id}/users/{external_user_id}'
|
|
792
|
+
.replace('{' + 'app_id' + '}', encodeURIComponent(String(appId)))
|
|
793
|
+
.replace('{' + 'external_user_id' + '}', encodeURIComponent(String(externalUserId)));
|
|
794
|
+
requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.PUT);
|
|
795
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
796
|
+
contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
|
|
797
|
+
"application/json"
|
|
798
|
+
]);
|
|
799
|
+
requestContext.setHeaderParam("Content-Type", contentType);
|
|
800
|
+
serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(updatePlayerTagsRequestBody, "UpdatePlayerTagsRequestBody", ""), contentType);
|
|
801
|
+
requestContext.setBody(serializedBody);
|
|
802
|
+
authMethod = _config.authMethods["app_key"];
|
|
803
|
+
if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
|
|
804
|
+
return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
|
|
805
|
+
case 1:
|
|
806
|
+
_d.sent();
|
|
807
|
+
_d.label = 2;
|
|
808
|
+
case 2:
|
|
809
|
+
defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
|
|
810
|
+
if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
|
|
811
|
+
return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
|
|
812
|
+
case 3:
|
|
813
|
+
_d.sent();
|
|
814
|
+
_d.label = 4;
|
|
815
|
+
case 4: return [2, requestContext];
|
|
816
|
+
}
|
|
817
|
+
});
|
|
818
|
+
});
|
|
819
|
+
};
|
|
820
|
+
return DefaultApiRequestFactory;
|
|
821
|
+
}(baseapi_1.BaseAPIRequestFactory));
|
|
822
|
+
exports.DefaultApiRequestFactory = DefaultApiRequestFactory;
|
|
823
|
+
var DefaultApiResponseProcessor = (function () {
|
|
824
|
+
function DefaultApiResponseProcessor() {
|
|
825
|
+
}
|
|
826
|
+
DefaultApiResponseProcessor.prototype.cancelNotification = function (response) {
|
|
827
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
828
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
829
|
+
return __generator(this, function (_l) {
|
|
830
|
+
switch (_l.label) {
|
|
831
|
+
case 0:
|
|
832
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
833
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
834
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
835
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
836
|
+
return [4, response.body.text()];
|
|
837
|
+
case 1:
|
|
838
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
839
|
+
"CancelNotificationSuccessResponse", ""]);
|
|
840
|
+
return [2, body];
|
|
841
|
+
case 2:
|
|
842
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
843
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
844
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
845
|
+
return [4, response.body.text()];
|
|
846
|
+
case 3:
|
|
847
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
848
|
+
"CancelNotificationSuccessResponse", ""]);
|
|
849
|
+
return [2, body];
|
|
850
|
+
case 4:
|
|
851
|
+
_j = exception_1.ApiException.bind;
|
|
852
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
853
|
+
return [4, response.getBodyAsAny()];
|
|
854
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
855
|
+
}
|
|
856
|
+
});
|
|
857
|
+
});
|
|
858
|
+
};
|
|
859
|
+
DefaultApiResponseProcessor.prototype.createApp = function (response) {
|
|
860
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
861
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
862
|
+
return __generator(this, function (_l) {
|
|
863
|
+
switch (_l.label) {
|
|
864
|
+
case 0:
|
|
865
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
866
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
867
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
868
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
869
|
+
return [4, response.body.text()];
|
|
870
|
+
case 1:
|
|
871
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
872
|
+
"App", ""]);
|
|
873
|
+
return [2, body];
|
|
874
|
+
case 2:
|
|
875
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
876
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
877
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
878
|
+
return [4, response.body.text()];
|
|
879
|
+
case 3:
|
|
880
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
881
|
+
"App", ""]);
|
|
882
|
+
return [2, body];
|
|
883
|
+
case 4:
|
|
884
|
+
_j = exception_1.ApiException.bind;
|
|
885
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
886
|
+
return [4, response.getBodyAsAny()];
|
|
887
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
888
|
+
}
|
|
889
|
+
});
|
|
890
|
+
});
|
|
891
|
+
};
|
|
892
|
+
DefaultApiResponseProcessor.prototype.createNotification = function (response) {
|
|
893
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
894
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, _o, _p;
|
|
895
|
+
return __generator(this, function (_q) {
|
|
896
|
+
switch (_q.label) {
|
|
897
|
+
case 0:
|
|
898
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
899
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
900
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
901
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
902
|
+
return [4, response.body.text()];
|
|
903
|
+
case 1:
|
|
904
|
+
body = _b.apply(_a, [_d.apply(_c, [_q.sent(), contentType]),
|
|
905
|
+
"CreateNotificationSuccessResponse", ""]);
|
|
906
|
+
return [2, body];
|
|
907
|
+
case 2:
|
|
908
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
909
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
910
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
911
|
+
return [4, response.body.text()];
|
|
912
|
+
case 3:
|
|
913
|
+
body = _f.apply(_e, [_h.apply(_g, [_q.sent(), contentType]),
|
|
914
|
+
"CreateNotificationBadRequestResponse", ""]);
|
|
915
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
916
|
+
case 4:
|
|
917
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 6];
|
|
918
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
919
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
920
|
+
return [4, response.body.text()];
|
|
921
|
+
case 5:
|
|
922
|
+
body = _k.apply(_j, [_m.apply(_l, [_q.sent(), contentType]),
|
|
923
|
+
"CreateNotificationSuccessResponse", ""]);
|
|
924
|
+
return [2, body];
|
|
925
|
+
case 6:
|
|
926
|
+
_o = exception_1.ApiException.bind;
|
|
927
|
+
_p = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
928
|
+
return [4, response.getBodyAsAny()];
|
|
929
|
+
case 7: throw new (_o.apply(exception_1.ApiException, _p.concat([_q.sent(), response.headers])))();
|
|
930
|
+
}
|
|
931
|
+
});
|
|
932
|
+
});
|
|
933
|
+
};
|
|
934
|
+
DefaultApiResponseProcessor.prototype.createPlayer = function (response) {
|
|
935
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
936
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
937
|
+
return __generator(this, function (_l) {
|
|
938
|
+
switch (_l.label) {
|
|
939
|
+
case 0:
|
|
940
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
941
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
942
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
943
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
944
|
+
return [4, response.body.text()];
|
|
945
|
+
case 1:
|
|
946
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
947
|
+
"CreatePlayerSuccessResponse", ""]);
|
|
948
|
+
return [2, body];
|
|
949
|
+
case 2:
|
|
950
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
951
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
952
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
953
|
+
return [4, response.body.text()];
|
|
954
|
+
case 3:
|
|
955
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
956
|
+
"CreatePlayerSuccessResponse", ""]);
|
|
957
|
+
return [2, body];
|
|
958
|
+
case 4:
|
|
959
|
+
_j = exception_1.ApiException.bind;
|
|
960
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
961
|
+
return [4, response.getBodyAsAny()];
|
|
962
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
963
|
+
}
|
|
964
|
+
});
|
|
965
|
+
});
|
|
966
|
+
};
|
|
967
|
+
DefaultApiResponseProcessor.prototype.createSegments = function (response) {
|
|
968
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
969
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, _s, _t;
|
|
970
|
+
return __generator(this, function (_u) {
|
|
971
|
+
switch (_u.label) {
|
|
972
|
+
case 0:
|
|
973
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
974
|
+
if (!(0, util_1.isCodeInRange)("201", response.httpStatusCode)) return [3, 2];
|
|
975
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
976
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
977
|
+
return [4, response.body.text()];
|
|
978
|
+
case 1:
|
|
979
|
+
body = _b.apply(_a, [_d.apply(_c, [_u.sent(), contentType]),
|
|
980
|
+
"CreateSegmentSuccessResponse", ""]);
|
|
981
|
+
return [2, body];
|
|
982
|
+
case 2:
|
|
983
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
984
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
985
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
986
|
+
return [4, response.body.text()];
|
|
987
|
+
case 3:
|
|
988
|
+
body = _f.apply(_e, [_h.apply(_g, [_u.sent(), contentType]),
|
|
989
|
+
"CreateSegmentBadRequestResponse", ""]);
|
|
990
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
991
|
+
case 4:
|
|
992
|
+
if (!(0, util_1.isCodeInRange)("409", response.httpStatusCode)) return [3, 6];
|
|
993
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
994
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
995
|
+
return [4, response.body.text()];
|
|
996
|
+
case 5:
|
|
997
|
+
body = _k.apply(_j, [_m.apply(_l, [_u.sent(), contentType]),
|
|
998
|
+
"CreateSegmentConflictResponse", ""]);
|
|
999
|
+
throw new exception_1.ApiException(409, "Conflict", body, response.headers);
|
|
1000
|
+
case 6:
|
|
1001
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 8];
|
|
1002
|
+
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1003
|
+
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1004
|
+
return [4, response.body.text()];
|
|
1005
|
+
case 7:
|
|
1006
|
+
body = _p.apply(_o, [_r.apply(_q, [_u.sent(), contentType]),
|
|
1007
|
+
"CreateSegmentSuccessResponse", ""]);
|
|
1008
|
+
return [2, body];
|
|
1009
|
+
case 8:
|
|
1010
|
+
_s = exception_1.ApiException.bind;
|
|
1011
|
+
_t = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1012
|
+
return [4, response.getBodyAsAny()];
|
|
1013
|
+
case 9: throw new (_s.apply(exception_1.ApiException, _t.concat([_u.sent(), response.headers])))();
|
|
1014
|
+
}
|
|
1015
|
+
});
|
|
1016
|
+
});
|
|
1017
|
+
};
|
|
1018
|
+
DefaultApiResponseProcessor.prototype.deletePlayer = function (response) {
|
|
1019
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1020
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, _s, _t;
|
|
1021
|
+
return __generator(this, function (_u) {
|
|
1022
|
+
switch (_u.label) {
|
|
1023
|
+
case 0:
|
|
1024
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1025
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1026
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1027
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1028
|
+
return [4, response.body.text()];
|
|
1029
|
+
case 1:
|
|
1030
|
+
body = _b.apply(_a, [_d.apply(_c, [_u.sent(), contentType]),
|
|
1031
|
+
"DeletePlayerSuccessResponse", ""]);
|
|
1032
|
+
return [2, body];
|
|
1033
|
+
case 2:
|
|
1034
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
1035
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1036
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1037
|
+
return [4, response.body.text()];
|
|
1038
|
+
case 3:
|
|
1039
|
+
body = _f.apply(_e, [_h.apply(_g, [_u.sent(), contentType]),
|
|
1040
|
+
"DeletePlayerBadRequestResponse", ""]);
|
|
1041
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
1042
|
+
case 4:
|
|
1043
|
+
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 6];
|
|
1044
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1045
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1046
|
+
return [4, response.body.text()];
|
|
1047
|
+
case 5:
|
|
1048
|
+
body = _k.apply(_j, [_m.apply(_l, [_u.sent(), contentType]),
|
|
1049
|
+
"DeletePlayerNotFoundResponse", ""]);
|
|
1050
|
+
throw new exception_1.ApiException(404, "Not Found", body, response.headers);
|
|
1051
|
+
case 6:
|
|
1052
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 8];
|
|
1053
|
+
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1054
|
+
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1055
|
+
return [4, response.body.text()];
|
|
1056
|
+
case 7:
|
|
1057
|
+
body = _p.apply(_o, [_r.apply(_q, [_u.sent(), contentType]),
|
|
1058
|
+
"DeletePlayerSuccessResponse", ""]);
|
|
1059
|
+
return [2, body];
|
|
1060
|
+
case 8:
|
|
1061
|
+
_s = exception_1.ApiException.bind;
|
|
1062
|
+
_t = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1063
|
+
return [4, response.getBodyAsAny()];
|
|
1064
|
+
case 9: throw new (_s.apply(exception_1.ApiException, _t.concat([_u.sent(), response.headers])))();
|
|
1065
|
+
}
|
|
1066
|
+
});
|
|
1067
|
+
});
|
|
1068
|
+
};
|
|
1069
|
+
DefaultApiResponseProcessor.prototype.deleteSegments = function (response) {
|
|
1070
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1071
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, body, _o, _p, _q, _r, _s, _t;
|
|
1072
|
+
return __generator(this, function (_u) {
|
|
1073
|
+
switch (_u.label) {
|
|
1074
|
+
case 0:
|
|
1075
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1076
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1077
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1078
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1079
|
+
return [4, response.body.text()];
|
|
1080
|
+
case 1:
|
|
1081
|
+
body = _b.apply(_a, [_d.apply(_c, [_u.sent(), contentType]),
|
|
1082
|
+
"DeleteSegmentSuccessResponse", ""]);
|
|
1083
|
+
return [2, body];
|
|
1084
|
+
case 2:
|
|
1085
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
1086
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1087
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1088
|
+
return [4, response.body.text()];
|
|
1089
|
+
case 3:
|
|
1090
|
+
body = _f.apply(_e, [_h.apply(_g, [_u.sent(), contentType]),
|
|
1091
|
+
"DeleteSegmentBadRequestResponse", ""]);
|
|
1092
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
1093
|
+
case 4:
|
|
1094
|
+
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3, 6];
|
|
1095
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1096
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1097
|
+
return [4, response.body.text()];
|
|
1098
|
+
case 5:
|
|
1099
|
+
body = _k.apply(_j, [_m.apply(_l, [_u.sent(), contentType]),
|
|
1100
|
+
"DeleteSegmentNotFoundResponse", ""]);
|
|
1101
|
+
throw new exception_1.ApiException(404, "Not Found", body, response.headers);
|
|
1102
|
+
case 6:
|
|
1103
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 8];
|
|
1104
|
+
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1105
|
+
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1106
|
+
return [4, response.body.text()];
|
|
1107
|
+
case 7:
|
|
1108
|
+
body = _p.apply(_o, [_r.apply(_q, [_u.sent(), contentType]),
|
|
1109
|
+
"DeleteSegmentSuccessResponse", ""]);
|
|
1110
|
+
return [2, body];
|
|
1111
|
+
case 8:
|
|
1112
|
+
_s = exception_1.ApiException.bind;
|
|
1113
|
+
_t = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1114
|
+
return [4, response.getBodyAsAny()];
|
|
1115
|
+
case 9: throw new (_s.apply(exception_1.ApiException, _t.concat([_u.sent(), response.headers])))();
|
|
1116
|
+
}
|
|
1117
|
+
});
|
|
1118
|
+
});
|
|
1119
|
+
};
|
|
1120
|
+
DefaultApiResponseProcessor.prototype.exportPlayers = function (response) {
|
|
1121
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1122
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, _o, _p;
|
|
1123
|
+
return __generator(this, function (_q) {
|
|
1124
|
+
switch (_q.label) {
|
|
1125
|
+
case 0:
|
|
1126
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1127
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1128
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1129
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1130
|
+
return [4, response.body.text()];
|
|
1131
|
+
case 1:
|
|
1132
|
+
body = _b.apply(_a, [_d.apply(_c, [_q.sent(), contentType]),
|
|
1133
|
+
"ExportPlayersSuccessResponse", ""]);
|
|
1134
|
+
return [2, body];
|
|
1135
|
+
case 2:
|
|
1136
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
1137
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1138
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1139
|
+
return [4, response.body.text()];
|
|
1140
|
+
case 3:
|
|
1141
|
+
body = _f.apply(_e, [_h.apply(_g, [_q.sent(), contentType]),
|
|
1142
|
+
"object", ""]);
|
|
1143
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
1144
|
+
case 4:
|
|
1145
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 6];
|
|
1146
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1147
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1148
|
+
return [4, response.body.text()];
|
|
1149
|
+
case 5:
|
|
1150
|
+
body = _k.apply(_j, [_m.apply(_l, [_q.sent(), contentType]),
|
|
1151
|
+
"ExportPlayersSuccessResponse", ""]);
|
|
1152
|
+
return [2, body];
|
|
1153
|
+
case 6:
|
|
1154
|
+
_o = exception_1.ApiException.bind;
|
|
1155
|
+
_p = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1156
|
+
return [4, response.getBodyAsAny()];
|
|
1157
|
+
case 7: throw new (_o.apply(exception_1.ApiException, _p.concat([_q.sent(), response.headers])))();
|
|
1158
|
+
}
|
|
1159
|
+
});
|
|
1160
|
+
});
|
|
1161
|
+
};
|
|
1162
|
+
DefaultApiResponseProcessor.prototype.getApp = function (response) {
|
|
1163
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1164
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1165
|
+
return __generator(this, function (_l) {
|
|
1166
|
+
switch (_l.label) {
|
|
1167
|
+
case 0:
|
|
1168
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1169
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1170
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1171
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1172
|
+
return [4, response.body.text()];
|
|
1173
|
+
case 1:
|
|
1174
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1175
|
+
"App", ""]);
|
|
1176
|
+
return [2, body];
|
|
1177
|
+
case 2:
|
|
1178
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1179
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1180
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1181
|
+
return [4, response.body.text()];
|
|
1182
|
+
case 3:
|
|
1183
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1184
|
+
"App", ""]);
|
|
1185
|
+
return [2, body];
|
|
1186
|
+
case 4:
|
|
1187
|
+
_j = exception_1.ApiException.bind;
|
|
1188
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1189
|
+
return [4, response.getBodyAsAny()];
|
|
1190
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1191
|
+
}
|
|
1192
|
+
});
|
|
1193
|
+
});
|
|
1194
|
+
};
|
|
1195
|
+
DefaultApiResponseProcessor.prototype.getApps = function (response) {
|
|
1196
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1197
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1198
|
+
return __generator(this, function (_l) {
|
|
1199
|
+
switch (_l.label) {
|
|
1200
|
+
case 0:
|
|
1201
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1202
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1203
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1204
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1205
|
+
return [4, response.body.text()];
|
|
1206
|
+
case 1:
|
|
1207
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1208
|
+
"Array<App>", ""]);
|
|
1209
|
+
return [2, body];
|
|
1210
|
+
case 2:
|
|
1211
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1212
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1213
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1214
|
+
return [4, response.body.text()];
|
|
1215
|
+
case 3:
|
|
1216
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1217
|
+
"Array<App>", ""]);
|
|
1218
|
+
return [2, body];
|
|
1219
|
+
case 4:
|
|
1220
|
+
_j = exception_1.ApiException.bind;
|
|
1221
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1222
|
+
return [4, response.getBodyAsAny()];
|
|
1223
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1224
|
+
}
|
|
1225
|
+
});
|
|
1226
|
+
});
|
|
1227
|
+
};
|
|
1228
|
+
DefaultApiResponseProcessor.prototype.getNotification = function (response) {
|
|
1229
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1230
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1231
|
+
return __generator(this, function (_l) {
|
|
1232
|
+
switch (_l.label) {
|
|
1233
|
+
case 0:
|
|
1234
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1235
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1236
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1237
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1238
|
+
return [4, response.body.text()];
|
|
1239
|
+
case 1:
|
|
1240
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1241
|
+
"NotificationWithMeta", ""]);
|
|
1242
|
+
return [2, body];
|
|
1243
|
+
case 2:
|
|
1244
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1245
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1246
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1247
|
+
return [4, response.body.text()];
|
|
1248
|
+
case 3:
|
|
1249
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1250
|
+
"NotificationWithMeta", ""]);
|
|
1251
|
+
return [2, body];
|
|
1252
|
+
case 4:
|
|
1253
|
+
_j = exception_1.ApiException.bind;
|
|
1254
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1255
|
+
return [4, response.getBodyAsAny()];
|
|
1256
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1257
|
+
}
|
|
1258
|
+
});
|
|
1259
|
+
});
|
|
1260
|
+
};
|
|
1261
|
+
DefaultApiResponseProcessor.prototype.getNotificationHistory = function (response) {
|
|
1262
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1263
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, _o, _p;
|
|
1264
|
+
return __generator(this, function (_q) {
|
|
1265
|
+
switch (_q.label) {
|
|
1266
|
+
case 0:
|
|
1267
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1268
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1269
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1270
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1271
|
+
return [4, response.body.text()];
|
|
1272
|
+
case 1:
|
|
1273
|
+
body = _b.apply(_a, [_d.apply(_c, [_q.sent(), contentType]),
|
|
1274
|
+
"NotificationHistorySuccessResponse", ""]);
|
|
1275
|
+
return [2, body];
|
|
1276
|
+
case 2:
|
|
1277
|
+
if (!(0, util_1.isCodeInRange)("400", response.httpStatusCode)) return [3, 4];
|
|
1278
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1279
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1280
|
+
return [4, response.body.text()];
|
|
1281
|
+
case 3:
|
|
1282
|
+
body = _f.apply(_e, [_h.apply(_g, [_q.sent(), contentType]),
|
|
1283
|
+
"NotificationHistoryBadRequestResponse", ""]);
|
|
1284
|
+
throw new exception_1.ApiException(400, "Bad Request", body, response.headers);
|
|
1285
|
+
case 4:
|
|
1286
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 6];
|
|
1287
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1288
|
+
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1289
|
+
return [4, response.body.text()];
|
|
1290
|
+
case 5:
|
|
1291
|
+
body = _k.apply(_j, [_m.apply(_l, [_q.sent(), contentType]),
|
|
1292
|
+
"NotificationHistorySuccessResponse", ""]);
|
|
1293
|
+
return [2, body];
|
|
1294
|
+
case 6:
|
|
1295
|
+
_o = exception_1.ApiException.bind;
|
|
1296
|
+
_p = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1297
|
+
return [4, response.getBodyAsAny()];
|
|
1298
|
+
case 7: throw new (_o.apply(exception_1.ApiException, _p.concat([_q.sent(), response.headers])))();
|
|
1299
|
+
}
|
|
1300
|
+
});
|
|
1301
|
+
});
|
|
1302
|
+
};
|
|
1303
|
+
DefaultApiResponseProcessor.prototype.getNotifications = function (response) {
|
|
1304
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1305
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1306
|
+
return __generator(this, function (_l) {
|
|
1307
|
+
switch (_l.label) {
|
|
1308
|
+
case 0:
|
|
1309
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1310
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1311
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1312
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1313
|
+
return [4, response.body.text()];
|
|
1314
|
+
case 1:
|
|
1315
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1316
|
+
"NotificationSlice", ""]);
|
|
1317
|
+
return [2, body];
|
|
1318
|
+
case 2:
|
|
1319
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1320
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1321
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1322
|
+
return [4, response.body.text()];
|
|
1323
|
+
case 3:
|
|
1324
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1325
|
+
"NotificationSlice", ""]);
|
|
1326
|
+
return [2, body];
|
|
1327
|
+
case 4:
|
|
1328
|
+
_j = exception_1.ApiException.bind;
|
|
1329
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1330
|
+
return [4, response.getBodyAsAny()];
|
|
1331
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1332
|
+
}
|
|
1333
|
+
});
|
|
1334
|
+
});
|
|
1335
|
+
};
|
|
1336
|
+
DefaultApiResponseProcessor.prototype.getOutcomes = function (response) {
|
|
1337
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1338
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1339
|
+
return __generator(this, function (_l) {
|
|
1340
|
+
switch (_l.label) {
|
|
1341
|
+
case 0:
|
|
1342
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1343
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1344
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1345
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1346
|
+
return [4, response.body.text()];
|
|
1347
|
+
case 1:
|
|
1348
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1349
|
+
"OutcomesData", ""]);
|
|
1350
|
+
return [2, body];
|
|
1351
|
+
case 2:
|
|
1352
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1353
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1354
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1355
|
+
return [4, response.body.text()];
|
|
1356
|
+
case 3:
|
|
1357
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1358
|
+
"OutcomesData", ""]);
|
|
1359
|
+
return [2, body];
|
|
1360
|
+
case 4:
|
|
1361
|
+
_j = exception_1.ApiException.bind;
|
|
1362
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1363
|
+
return [4, response.getBodyAsAny()];
|
|
1364
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1365
|
+
}
|
|
1366
|
+
});
|
|
1367
|
+
});
|
|
1368
|
+
};
|
|
1369
|
+
DefaultApiResponseProcessor.prototype.getPlayer = function (response) {
|
|
1370
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1371
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1372
|
+
return __generator(this, function (_l) {
|
|
1373
|
+
switch (_l.label) {
|
|
1374
|
+
case 0:
|
|
1375
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1376
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1377
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1378
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1379
|
+
return [4, response.body.text()];
|
|
1380
|
+
case 1:
|
|
1381
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1382
|
+
"Player", ""]);
|
|
1383
|
+
return [2, body];
|
|
1384
|
+
case 2:
|
|
1385
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1386
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1387
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1388
|
+
return [4, response.body.text()];
|
|
1389
|
+
case 3:
|
|
1390
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1391
|
+
"Player", ""]);
|
|
1392
|
+
return [2, body];
|
|
1393
|
+
case 4:
|
|
1394
|
+
_j = exception_1.ApiException.bind;
|
|
1395
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1396
|
+
return [4, response.getBodyAsAny()];
|
|
1397
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1398
|
+
}
|
|
1399
|
+
});
|
|
1400
|
+
});
|
|
1401
|
+
};
|
|
1402
|
+
DefaultApiResponseProcessor.prototype.getPlayers = function (response) {
|
|
1403
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1404
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1405
|
+
return __generator(this, function (_l) {
|
|
1406
|
+
switch (_l.label) {
|
|
1407
|
+
case 0:
|
|
1408
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1409
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1410
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1411
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1412
|
+
return [4, response.body.text()];
|
|
1413
|
+
case 1:
|
|
1414
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1415
|
+
"PlayerSlice", ""]);
|
|
1416
|
+
return [2, body];
|
|
1417
|
+
case 2:
|
|
1418
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1419
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1420
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1421
|
+
return [4, response.body.text()];
|
|
1422
|
+
case 3:
|
|
1423
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1424
|
+
"PlayerSlice", ""]);
|
|
1425
|
+
return [2, body];
|
|
1426
|
+
case 4:
|
|
1427
|
+
_j = exception_1.ApiException.bind;
|
|
1428
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1429
|
+
return [4, response.getBodyAsAny()];
|
|
1430
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1431
|
+
}
|
|
1432
|
+
});
|
|
1433
|
+
});
|
|
1434
|
+
};
|
|
1435
|
+
DefaultApiResponseProcessor.prototype.updateApp = function (response) {
|
|
1436
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1437
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1438
|
+
return __generator(this, function (_l) {
|
|
1439
|
+
switch (_l.label) {
|
|
1440
|
+
case 0:
|
|
1441
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1442
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1443
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1444
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1445
|
+
return [4, response.body.text()];
|
|
1446
|
+
case 1:
|
|
1447
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1448
|
+
"App", ""]);
|
|
1449
|
+
return [2, body];
|
|
1450
|
+
case 2:
|
|
1451
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1452
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1453
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1454
|
+
return [4, response.body.text()];
|
|
1455
|
+
case 3:
|
|
1456
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1457
|
+
"App", ""]);
|
|
1458
|
+
return [2, body];
|
|
1459
|
+
case 4:
|
|
1460
|
+
_j = exception_1.ApiException.bind;
|
|
1461
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1462
|
+
return [4, response.getBodyAsAny()];
|
|
1463
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1464
|
+
}
|
|
1465
|
+
});
|
|
1466
|
+
});
|
|
1467
|
+
};
|
|
1468
|
+
DefaultApiResponseProcessor.prototype.updatePlayer = function (response) {
|
|
1469
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1470
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1471
|
+
return __generator(this, function (_l) {
|
|
1472
|
+
switch (_l.label) {
|
|
1473
|
+
case 0:
|
|
1474
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1475
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1476
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1477
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1478
|
+
return [4, response.body.text()];
|
|
1479
|
+
case 1:
|
|
1480
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1481
|
+
"UpdatePlayerSuccessResponse", ""]);
|
|
1482
|
+
return [2, body];
|
|
1483
|
+
case 2:
|
|
1484
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1485
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1486
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1487
|
+
return [4, response.body.text()];
|
|
1488
|
+
case 3:
|
|
1489
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1490
|
+
"UpdatePlayerSuccessResponse", ""]);
|
|
1491
|
+
return [2, body];
|
|
1492
|
+
case 4:
|
|
1493
|
+
_j = exception_1.ApiException.bind;
|
|
1494
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1495
|
+
return [4, response.getBodyAsAny()];
|
|
1496
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1497
|
+
}
|
|
1498
|
+
});
|
|
1499
|
+
});
|
|
1500
|
+
};
|
|
1501
|
+
DefaultApiResponseProcessor.prototype.updatePlayerTags = function (response) {
|
|
1502
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
1503
|
+
var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, _j, _k;
|
|
1504
|
+
return __generator(this, function (_l) {
|
|
1505
|
+
switch (_l.label) {
|
|
1506
|
+
case 0:
|
|
1507
|
+
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1508
|
+
if (!(0, util_1.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
|
|
1509
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1510
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1511
|
+
return [4, response.body.text()];
|
|
1512
|
+
case 1:
|
|
1513
|
+
body = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1514
|
+
"UpdatePlayerTagsSuccessResponse", ""]);
|
|
1515
|
+
return [2, body];
|
|
1516
|
+
case 2:
|
|
1517
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 4];
|
|
1518
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1519
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1520
|
+
return [4, response.body.text()];
|
|
1521
|
+
case 3:
|
|
1522
|
+
body = _f.apply(_e, [_h.apply(_g, [_l.sent(), contentType]),
|
|
1523
|
+
"UpdatePlayerTagsSuccessResponse", ""]);
|
|
1524
|
+
return [2, body];
|
|
1525
|
+
case 4:
|
|
1526
|
+
_j = exception_1.ApiException.bind;
|
|
1527
|
+
_k = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
|
|
1528
|
+
return [4, response.getBodyAsAny()];
|
|
1529
|
+
case 5: throw new (_j.apply(exception_1.ApiException, _k.concat([_l.sent(), response.headers])))();
|
|
1530
|
+
}
|
|
1531
|
+
});
|
|
1532
|
+
});
|
|
1533
|
+
};
|
|
1534
|
+
return DefaultApiResponseProcessor;
|
|
1535
|
+
}());
|
|
1536
|
+
exports.DefaultApiResponseProcessor = DefaultApiResponseProcessor;
|
|
1537
|
+
//# sourceMappingURL=DefaultApi.js.map
|