@ember-home/unbound-ts-client 0.0.1 → 0.0.2
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/dist/index.d.mts +1703 -1
- package/dist/index.d.ts +1703 -1
- package/dist/index.js +912 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +911 -0
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1 +1,912 @@
|
|
|
1
|
+
// src/api.ts
|
|
2
|
+
import globalAxios2 from "axios";
|
|
3
|
+
|
|
4
|
+
// src/base.ts
|
|
5
|
+
import globalAxios from "axios";
|
|
6
|
+
var BASE_PATH = "http://localhost".replace(/\/+$/, "");
|
|
7
|
+
var BaseAPI = class {
|
|
8
|
+
constructor(configuration, basePath = BASE_PATH, axios = globalAxios) {
|
|
9
|
+
this.basePath = basePath;
|
|
10
|
+
this.axios = axios;
|
|
11
|
+
if (configuration) {
|
|
12
|
+
this.configuration = configuration;
|
|
13
|
+
this.basePath = configuration.basePath ?? basePath;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
configuration;
|
|
17
|
+
};
|
|
18
|
+
var RequiredError = class extends Error {
|
|
19
|
+
constructor(field, msg) {
|
|
20
|
+
super(msg);
|
|
21
|
+
this.field = field;
|
|
22
|
+
this.name = "RequiredError";
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
var operationServerMap = {};
|
|
26
|
+
|
|
27
|
+
// src/common.ts
|
|
28
|
+
var DUMMY_BASE_URL = "https://example.com";
|
|
29
|
+
var assertParamExists = function(functionName, paramName, paramValue) {
|
|
30
|
+
if (paramValue === null || paramValue === void 0) {
|
|
31
|
+
throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`);
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
var setBasicAuthToObject = function(object, configuration) {
|
|
35
|
+
if (configuration && (configuration.username || configuration.password)) {
|
|
36
|
+
object["auth"] = { username: configuration.username, password: configuration.password };
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
function setFlattenedQueryParams(urlSearchParams, parameter, key = "") {
|
|
40
|
+
if (parameter == null) return;
|
|
41
|
+
if (typeof parameter === "object") {
|
|
42
|
+
if (Array.isArray(parameter)) {
|
|
43
|
+
parameter.forEach((item) => setFlattenedQueryParams(urlSearchParams, item, key));
|
|
44
|
+
} else {
|
|
45
|
+
Object.keys(parameter).forEach(
|
|
46
|
+
(currentKey) => setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== "" ? "." : ""}${currentKey}`)
|
|
47
|
+
);
|
|
48
|
+
}
|
|
49
|
+
} else {
|
|
50
|
+
if (urlSearchParams.has(key)) {
|
|
51
|
+
urlSearchParams.append(key, parameter);
|
|
52
|
+
} else {
|
|
53
|
+
urlSearchParams.set(key, parameter);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
var setSearchParams = function(url, ...objects) {
|
|
58
|
+
const searchParams = new URLSearchParams(url.search);
|
|
59
|
+
setFlattenedQueryParams(searchParams, objects);
|
|
60
|
+
url.search = searchParams.toString();
|
|
61
|
+
};
|
|
62
|
+
var serializeDataIfNeeded = function(value, requestOptions, configuration) {
|
|
63
|
+
const nonString = typeof value !== "string";
|
|
64
|
+
const needsSerialization = nonString && configuration && configuration.isJsonMime ? configuration.isJsonMime(requestOptions.headers["Content-Type"]) : nonString;
|
|
65
|
+
return needsSerialization ? JSON.stringify(value !== void 0 ? value : {}) : value || "";
|
|
66
|
+
};
|
|
67
|
+
var toPathString = function(url) {
|
|
68
|
+
return url.pathname + url.search + url.hash;
|
|
69
|
+
};
|
|
70
|
+
var createRequestFunction = function(axiosArgs, globalAxios3, BASE_PATH2, configuration) {
|
|
71
|
+
return (axios = globalAxios3, basePath = BASE_PATH2) => {
|
|
72
|
+
const axiosRequestArgs = { ...axiosArgs.options, url: (axios.defaults.baseURL ? "" : configuration?.basePath ?? basePath) + axiosArgs.url };
|
|
73
|
+
return axios.request(axiosRequestArgs);
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
// src/api.ts
|
|
78
|
+
var ContactAvatarAvatarTypeEnum = {
|
|
79
|
+
ProfilePic: "profilePic",
|
|
80
|
+
Generic: "generic",
|
|
81
|
+
Initials: "initials"
|
|
82
|
+
};
|
|
83
|
+
var ContactsApiAxiosParamCreator = function(configuration) {
|
|
84
|
+
return {
|
|
85
|
+
/**
|
|
86
|
+
* Create a new contact
|
|
87
|
+
* @summary Contacts Create
|
|
88
|
+
* @param {ContactCreate} contactCreate
|
|
89
|
+
* @param {*} [options] Override http request option.
|
|
90
|
+
* @throws {RequiredError}
|
|
91
|
+
*/
|
|
92
|
+
contactsCreate: async (contactCreate, options = {}) => {
|
|
93
|
+
assertParamExists("contactsCreate", "contactCreate", contactCreate);
|
|
94
|
+
const localVarPath = `/contacts`;
|
|
95
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
96
|
+
let baseOptions;
|
|
97
|
+
if (configuration) {
|
|
98
|
+
baseOptions = configuration.baseOptions;
|
|
99
|
+
}
|
|
100
|
+
const localVarRequestOptions = { method: "POST", ...baseOptions, ...options };
|
|
101
|
+
const localVarHeaderParameter = {};
|
|
102
|
+
const localVarQueryParameter = {};
|
|
103
|
+
localVarHeaderParameter["Content-Type"] = "application/json";
|
|
104
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
105
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
106
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
107
|
+
localVarRequestOptions.data = serializeDataIfNeeded(contactCreate, localVarRequestOptions, configuration);
|
|
108
|
+
return {
|
|
109
|
+
url: toPathString(localVarUrlObj),
|
|
110
|
+
options: localVarRequestOptions
|
|
111
|
+
};
|
|
112
|
+
},
|
|
113
|
+
/**
|
|
114
|
+
* Delete a contact
|
|
115
|
+
* @summary Contacts Delete
|
|
116
|
+
* @param {string} contactId
|
|
117
|
+
* @param {*} [options] Override http request option.
|
|
118
|
+
* @throws {RequiredError}
|
|
119
|
+
*/
|
|
120
|
+
contactsDelete: async (contactId, options = {}) => {
|
|
121
|
+
assertParamExists("contactsDelete", "contactId", contactId);
|
|
122
|
+
const localVarPath = `/contacts/{contact_id}`.replace(`{${"contact_id"}}`, encodeURIComponent(String(contactId)));
|
|
123
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
124
|
+
let baseOptions;
|
|
125
|
+
if (configuration) {
|
|
126
|
+
baseOptions = configuration.baseOptions;
|
|
127
|
+
}
|
|
128
|
+
const localVarRequestOptions = { method: "DELETE", ...baseOptions, ...options };
|
|
129
|
+
const localVarHeaderParameter = {};
|
|
130
|
+
const localVarQueryParameter = {};
|
|
131
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
132
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
133
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
134
|
+
return {
|
|
135
|
+
url: toPathString(localVarUrlObj),
|
|
136
|
+
options: localVarRequestOptions
|
|
137
|
+
};
|
|
138
|
+
},
|
|
139
|
+
/**
|
|
140
|
+
* Get a contact by ID
|
|
141
|
+
* @summary Contacts Get
|
|
142
|
+
* @param {string} contactId
|
|
143
|
+
* @param {*} [options] Override http request option.
|
|
144
|
+
* @throws {RequiredError}
|
|
145
|
+
*/
|
|
146
|
+
contactsGet: async (contactId, options = {}) => {
|
|
147
|
+
assertParamExists("contactsGet", "contactId", contactId);
|
|
148
|
+
const localVarPath = `/contacts/{contact_id}`.replace(`{${"contact_id"}}`, encodeURIComponent(String(contactId)));
|
|
149
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
150
|
+
let baseOptions;
|
|
151
|
+
if (configuration) {
|
|
152
|
+
baseOptions = configuration.baseOptions;
|
|
153
|
+
}
|
|
154
|
+
const localVarRequestOptions = { method: "GET", ...baseOptions, ...options };
|
|
155
|
+
const localVarHeaderParameter = {};
|
|
156
|
+
const localVarQueryParameter = {};
|
|
157
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
158
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
159
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
160
|
+
return {
|
|
161
|
+
url: toPathString(localVarUrlObj),
|
|
162
|
+
options: localVarRequestOptions
|
|
163
|
+
};
|
|
164
|
+
},
|
|
165
|
+
/**
|
|
166
|
+
* List all contacts
|
|
167
|
+
* @summary Contacts List
|
|
168
|
+
* @param {*} [options] Override http request option.
|
|
169
|
+
* @throws {RequiredError}
|
|
170
|
+
*/
|
|
171
|
+
contactsList: async (options = {}) => {
|
|
172
|
+
const localVarPath = `/contacts`;
|
|
173
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
174
|
+
let baseOptions;
|
|
175
|
+
if (configuration) {
|
|
176
|
+
baseOptions = configuration.baseOptions;
|
|
177
|
+
}
|
|
178
|
+
const localVarRequestOptions = { method: "GET", ...baseOptions, ...options };
|
|
179
|
+
const localVarHeaderParameter = {};
|
|
180
|
+
const localVarQueryParameter = {};
|
|
181
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
182
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
183
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
184
|
+
return {
|
|
185
|
+
url: toPathString(localVarUrlObj),
|
|
186
|
+
options: localVarRequestOptions
|
|
187
|
+
};
|
|
188
|
+
},
|
|
189
|
+
/**
|
|
190
|
+
* Update a contact
|
|
191
|
+
* @summary Contacts Update
|
|
192
|
+
* @param {string} contactId
|
|
193
|
+
* @param {ContactUpdate} contactUpdate
|
|
194
|
+
* @param {*} [options] Override http request option.
|
|
195
|
+
* @throws {RequiredError}
|
|
196
|
+
*/
|
|
197
|
+
contactsUpdate: async (contactId, contactUpdate, options = {}) => {
|
|
198
|
+
assertParamExists("contactsUpdate", "contactId", contactId);
|
|
199
|
+
assertParamExists("contactsUpdate", "contactUpdate", contactUpdate);
|
|
200
|
+
const localVarPath = `/contacts/{contact_id}`.replace(`{${"contact_id"}}`, encodeURIComponent(String(contactId)));
|
|
201
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
202
|
+
let baseOptions;
|
|
203
|
+
if (configuration) {
|
|
204
|
+
baseOptions = configuration.baseOptions;
|
|
205
|
+
}
|
|
206
|
+
const localVarRequestOptions = { method: "PATCH", ...baseOptions, ...options };
|
|
207
|
+
const localVarHeaderParameter = {};
|
|
208
|
+
const localVarQueryParameter = {};
|
|
209
|
+
localVarHeaderParameter["Content-Type"] = "application/json";
|
|
210
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
211
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
212
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
213
|
+
localVarRequestOptions.data = serializeDataIfNeeded(contactUpdate, localVarRequestOptions, configuration);
|
|
214
|
+
return {
|
|
215
|
+
url: toPathString(localVarUrlObj),
|
|
216
|
+
options: localVarRequestOptions
|
|
217
|
+
};
|
|
218
|
+
}
|
|
219
|
+
};
|
|
220
|
+
};
|
|
221
|
+
var ContactsApiFp = function(configuration) {
|
|
222
|
+
const localVarAxiosParamCreator = ContactsApiAxiosParamCreator(configuration);
|
|
223
|
+
return {
|
|
224
|
+
/**
|
|
225
|
+
* Create a new contact
|
|
226
|
+
* @summary Contacts Create
|
|
227
|
+
* @param {ContactCreate} contactCreate
|
|
228
|
+
* @param {*} [options] Override http request option.
|
|
229
|
+
* @throws {RequiredError}
|
|
230
|
+
*/
|
|
231
|
+
async contactsCreate(contactCreate, options) {
|
|
232
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.contactsCreate(contactCreate, options);
|
|
233
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
234
|
+
const localVarOperationServerBasePath = operationServerMap["ContactsApi.contactsCreate"]?.[localVarOperationServerIndex]?.url;
|
|
235
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
236
|
+
},
|
|
237
|
+
/**
|
|
238
|
+
* Delete a contact
|
|
239
|
+
* @summary Contacts Delete
|
|
240
|
+
* @param {string} contactId
|
|
241
|
+
* @param {*} [options] Override http request option.
|
|
242
|
+
* @throws {RequiredError}
|
|
243
|
+
*/
|
|
244
|
+
async contactsDelete(contactId, options) {
|
|
245
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.contactsDelete(contactId, options);
|
|
246
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
247
|
+
const localVarOperationServerBasePath = operationServerMap["ContactsApi.contactsDelete"]?.[localVarOperationServerIndex]?.url;
|
|
248
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
249
|
+
},
|
|
250
|
+
/**
|
|
251
|
+
* Get a contact by ID
|
|
252
|
+
* @summary Contacts Get
|
|
253
|
+
* @param {string} contactId
|
|
254
|
+
* @param {*} [options] Override http request option.
|
|
255
|
+
* @throws {RequiredError}
|
|
256
|
+
*/
|
|
257
|
+
async contactsGet(contactId, options) {
|
|
258
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.contactsGet(contactId, options);
|
|
259
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
260
|
+
const localVarOperationServerBasePath = operationServerMap["ContactsApi.contactsGet"]?.[localVarOperationServerIndex]?.url;
|
|
261
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
262
|
+
},
|
|
263
|
+
/**
|
|
264
|
+
* List all contacts
|
|
265
|
+
* @summary Contacts List
|
|
266
|
+
* @param {*} [options] Override http request option.
|
|
267
|
+
* @throws {RequiredError}
|
|
268
|
+
*/
|
|
269
|
+
async contactsList(options) {
|
|
270
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.contactsList(options);
|
|
271
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
272
|
+
const localVarOperationServerBasePath = operationServerMap["ContactsApi.contactsList"]?.[localVarOperationServerIndex]?.url;
|
|
273
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
274
|
+
},
|
|
275
|
+
/**
|
|
276
|
+
* Update a contact
|
|
277
|
+
* @summary Contacts Update
|
|
278
|
+
* @param {string} contactId
|
|
279
|
+
* @param {ContactUpdate} contactUpdate
|
|
280
|
+
* @param {*} [options] Override http request option.
|
|
281
|
+
* @throws {RequiredError}
|
|
282
|
+
*/
|
|
283
|
+
async contactsUpdate(contactId, contactUpdate, options) {
|
|
284
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.contactsUpdate(contactId, contactUpdate, options);
|
|
285
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
286
|
+
const localVarOperationServerBasePath = operationServerMap["ContactsApi.contactsUpdate"]?.[localVarOperationServerIndex]?.url;
|
|
287
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
288
|
+
}
|
|
289
|
+
};
|
|
290
|
+
};
|
|
291
|
+
var ContactsApiFactory = function(configuration, basePath, axios) {
|
|
292
|
+
const localVarFp = ContactsApiFp(configuration);
|
|
293
|
+
return {
|
|
294
|
+
/**
|
|
295
|
+
* Create a new contact
|
|
296
|
+
* @summary Contacts Create
|
|
297
|
+
* @param {ContactCreate} contactCreate
|
|
298
|
+
* @param {*} [options] Override http request option.
|
|
299
|
+
* @throws {RequiredError}
|
|
300
|
+
*/
|
|
301
|
+
contactsCreate(contactCreate, options) {
|
|
302
|
+
return localVarFp.contactsCreate(contactCreate, options).then((request) => request(axios, basePath));
|
|
303
|
+
},
|
|
304
|
+
/**
|
|
305
|
+
* Delete a contact
|
|
306
|
+
* @summary Contacts Delete
|
|
307
|
+
* @param {string} contactId
|
|
308
|
+
* @param {*} [options] Override http request option.
|
|
309
|
+
* @throws {RequiredError}
|
|
310
|
+
*/
|
|
311
|
+
contactsDelete(contactId, options) {
|
|
312
|
+
return localVarFp.contactsDelete(contactId, options).then((request) => request(axios, basePath));
|
|
313
|
+
},
|
|
314
|
+
/**
|
|
315
|
+
* Get a contact by ID
|
|
316
|
+
* @summary Contacts Get
|
|
317
|
+
* @param {string} contactId
|
|
318
|
+
* @param {*} [options] Override http request option.
|
|
319
|
+
* @throws {RequiredError}
|
|
320
|
+
*/
|
|
321
|
+
contactsGet(contactId, options) {
|
|
322
|
+
return localVarFp.contactsGet(contactId, options).then((request) => request(axios, basePath));
|
|
323
|
+
},
|
|
324
|
+
/**
|
|
325
|
+
* List all contacts
|
|
326
|
+
* @summary Contacts List
|
|
327
|
+
* @param {*} [options] Override http request option.
|
|
328
|
+
* @throws {RequiredError}
|
|
329
|
+
*/
|
|
330
|
+
contactsList(options) {
|
|
331
|
+
return localVarFp.contactsList(options).then((request) => request(axios, basePath));
|
|
332
|
+
},
|
|
333
|
+
/**
|
|
334
|
+
* Update a contact
|
|
335
|
+
* @summary Contacts Update
|
|
336
|
+
* @param {string} contactId
|
|
337
|
+
* @param {ContactUpdate} contactUpdate
|
|
338
|
+
* @param {*} [options] Override http request option.
|
|
339
|
+
* @throws {RequiredError}
|
|
340
|
+
*/
|
|
341
|
+
contactsUpdate(contactId, contactUpdate, options) {
|
|
342
|
+
return localVarFp.contactsUpdate(contactId, contactUpdate, options).then((request) => request(axios, basePath));
|
|
343
|
+
}
|
|
344
|
+
};
|
|
345
|
+
};
|
|
346
|
+
var ContactsApi = class extends BaseAPI {
|
|
347
|
+
/**
|
|
348
|
+
* Create a new contact
|
|
349
|
+
* @summary Contacts Create
|
|
350
|
+
* @param {ContactCreate} contactCreate
|
|
351
|
+
* @param {*} [options] Override http request option.
|
|
352
|
+
* @throws {RequiredError}
|
|
353
|
+
* @memberof ContactsApi
|
|
354
|
+
*/
|
|
355
|
+
contactsCreate(contactCreate, options) {
|
|
356
|
+
return ContactsApiFp(this.configuration).contactsCreate(contactCreate, options).then((request) => request(this.axios, this.basePath));
|
|
357
|
+
}
|
|
358
|
+
/**
|
|
359
|
+
* Delete a contact
|
|
360
|
+
* @summary Contacts Delete
|
|
361
|
+
* @param {string} contactId
|
|
362
|
+
* @param {*} [options] Override http request option.
|
|
363
|
+
* @throws {RequiredError}
|
|
364
|
+
* @memberof ContactsApi
|
|
365
|
+
*/
|
|
366
|
+
contactsDelete(contactId, options) {
|
|
367
|
+
return ContactsApiFp(this.configuration).contactsDelete(contactId, options).then((request) => request(this.axios, this.basePath));
|
|
368
|
+
}
|
|
369
|
+
/**
|
|
370
|
+
* Get a contact by ID
|
|
371
|
+
* @summary Contacts Get
|
|
372
|
+
* @param {string} contactId
|
|
373
|
+
* @param {*} [options] Override http request option.
|
|
374
|
+
* @throws {RequiredError}
|
|
375
|
+
* @memberof ContactsApi
|
|
376
|
+
*/
|
|
377
|
+
contactsGet(contactId, options) {
|
|
378
|
+
return ContactsApiFp(this.configuration).contactsGet(contactId, options).then((request) => request(this.axios, this.basePath));
|
|
379
|
+
}
|
|
380
|
+
/**
|
|
381
|
+
* List all contacts
|
|
382
|
+
* @summary Contacts List
|
|
383
|
+
* @param {*} [options] Override http request option.
|
|
384
|
+
* @throws {RequiredError}
|
|
385
|
+
* @memberof ContactsApi
|
|
386
|
+
*/
|
|
387
|
+
contactsList(options) {
|
|
388
|
+
return ContactsApiFp(this.configuration).contactsList(options).then((request) => request(this.axios, this.basePath));
|
|
389
|
+
}
|
|
390
|
+
/**
|
|
391
|
+
* Update a contact
|
|
392
|
+
* @summary Contacts Update
|
|
393
|
+
* @param {string} contactId
|
|
394
|
+
* @param {ContactUpdate} contactUpdate
|
|
395
|
+
* @param {*} [options] Override http request option.
|
|
396
|
+
* @throws {RequiredError}
|
|
397
|
+
* @memberof ContactsApi
|
|
398
|
+
*/
|
|
399
|
+
contactsUpdate(contactId, contactUpdate, options) {
|
|
400
|
+
return ContactsApiFp(this.configuration).contactsUpdate(contactId, contactUpdate, options).then((request) => request(this.axios, this.basePath));
|
|
401
|
+
}
|
|
402
|
+
};
|
|
403
|
+
var HostawayApiAxiosParamCreator = function(configuration) {
|
|
404
|
+
return {
|
|
405
|
+
/**
|
|
406
|
+
*
|
|
407
|
+
* @summary Unifiedwebhook
|
|
408
|
+
* @param {object} body
|
|
409
|
+
* @param {*} [options] Override http request option.
|
|
410
|
+
* @throws {RequiredError}
|
|
411
|
+
*/
|
|
412
|
+
webhook: async (body, options = {}) => {
|
|
413
|
+
assertParamExists("webhook", "body", body);
|
|
414
|
+
const localVarPath = `/hostawayUnifiedWebHooks`;
|
|
415
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
416
|
+
let baseOptions;
|
|
417
|
+
if (configuration) {
|
|
418
|
+
baseOptions = configuration.baseOptions;
|
|
419
|
+
}
|
|
420
|
+
const localVarRequestOptions = { method: "POST", ...baseOptions, ...options };
|
|
421
|
+
const localVarHeaderParameter = {};
|
|
422
|
+
const localVarQueryParameter = {};
|
|
423
|
+
setBasicAuthToObject(localVarRequestOptions, configuration);
|
|
424
|
+
localVarHeaderParameter["Content-Type"] = "application/json";
|
|
425
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
426
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
427
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
428
|
+
localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration);
|
|
429
|
+
return {
|
|
430
|
+
url: toPathString(localVarUrlObj),
|
|
431
|
+
options: localVarRequestOptions
|
|
432
|
+
};
|
|
433
|
+
}
|
|
434
|
+
};
|
|
435
|
+
};
|
|
436
|
+
var HostawayApiFp = function(configuration) {
|
|
437
|
+
const localVarAxiosParamCreator = HostawayApiAxiosParamCreator(configuration);
|
|
438
|
+
return {
|
|
439
|
+
/**
|
|
440
|
+
*
|
|
441
|
+
* @summary Unifiedwebhook
|
|
442
|
+
* @param {object} body
|
|
443
|
+
* @param {*} [options] Override http request option.
|
|
444
|
+
* @throws {RequiredError}
|
|
445
|
+
*/
|
|
446
|
+
async webhook(body, options) {
|
|
447
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.webhook(body, options);
|
|
448
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
449
|
+
const localVarOperationServerBasePath = operationServerMap["HostawayApi.webhook"]?.[localVarOperationServerIndex]?.url;
|
|
450
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
451
|
+
}
|
|
452
|
+
};
|
|
453
|
+
};
|
|
454
|
+
var HostawayApiFactory = function(configuration, basePath, axios) {
|
|
455
|
+
const localVarFp = HostawayApiFp(configuration);
|
|
456
|
+
return {
|
|
457
|
+
/**
|
|
458
|
+
*
|
|
459
|
+
* @summary Unifiedwebhook
|
|
460
|
+
* @param {object} body
|
|
461
|
+
* @param {*} [options] Override http request option.
|
|
462
|
+
* @throws {RequiredError}
|
|
463
|
+
*/
|
|
464
|
+
webhook(body, options) {
|
|
465
|
+
return localVarFp.webhook(body, options).then((request) => request(axios, basePath));
|
|
466
|
+
}
|
|
467
|
+
};
|
|
468
|
+
};
|
|
469
|
+
var HostawayApi = class extends BaseAPI {
|
|
470
|
+
/**
|
|
471
|
+
*
|
|
472
|
+
* @summary Unifiedwebhook
|
|
473
|
+
* @param {object} body
|
|
474
|
+
* @param {*} [options] Override http request option.
|
|
475
|
+
* @throws {RequiredError}
|
|
476
|
+
* @memberof HostawayApi
|
|
477
|
+
*/
|
|
478
|
+
webhook(body, options) {
|
|
479
|
+
return HostawayApiFp(this.configuration).webhook(body, options).then((request) => request(this.axios, this.basePath));
|
|
480
|
+
}
|
|
481
|
+
};
|
|
482
|
+
var TasksApiAxiosParamCreator = function(configuration) {
|
|
483
|
+
return {
|
|
484
|
+
/**
|
|
485
|
+
*
|
|
486
|
+
* @summary Tasks Create
|
|
487
|
+
* @param {string} projectId
|
|
488
|
+
* @param {TaskCreate} taskCreate
|
|
489
|
+
* @param {*} [options] Override http request option.
|
|
490
|
+
* @throws {RequiredError}
|
|
491
|
+
*/
|
|
492
|
+
tasksCreate: async (projectId, taskCreate, options = {}) => {
|
|
493
|
+
assertParamExists("tasksCreate", "projectId", projectId);
|
|
494
|
+
assertParamExists("tasksCreate", "taskCreate", taskCreate);
|
|
495
|
+
const localVarPath = `/projects/{project_id}/tasks`.replace(`{${"project_id"}}`, encodeURIComponent(String(projectId)));
|
|
496
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
497
|
+
let baseOptions;
|
|
498
|
+
if (configuration) {
|
|
499
|
+
baseOptions = configuration.baseOptions;
|
|
500
|
+
}
|
|
501
|
+
const localVarRequestOptions = { method: "POST", ...baseOptions, ...options };
|
|
502
|
+
const localVarHeaderParameter = {};
|
|
503
|
+
const localVarQueryParameter = {};
|
|
504
|
+
localVarHeaderParameter["Content-Type"] = "application/json";
|
|
505
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
506
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
507
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
508
|
+
localVarRequestOptions.data = serializeDataIfNeeded(taskCreate, localVarRequestOptions, configuration);
|
|
509
|
+
return {
|
|
510
|
+
url: toPathString(localVarUrlObj),
|
|
511
|
+
options: localVarRequestOptions
|
|
512
|
+
};
|
|
513
|
+
},
|
|
514
|
+
/**
|
|
515
|
+
*
|
|
516
|
+
* @summary Tasks Delete
|
|
517
|
+
* @param {string} taskId
|
|
518
|
+
* @param {*} [options] Override http request option.
|
|
519
|
+
* @throws {RequiredError}
|
|
520
|
+
*/
|
|
521
|
+
tasksDelete: async (taskId, options = {}) => {
|
|
522
|
+
assertParamExists("tasksDelete", "taskId", taskId);
|
|
523
|
+
const localVarPath = `/tasks/{task_id}`.replace(`{${"task_id"}}`, encodeURIComponent(String(taskId)));
|
|
524
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
525
|
+
let baseOptions;
|
|
526
|
+
if (configuration) {
|
|
527
|
+
baseOptions = configuration.baseOptions;
|
|
528
|
+
}
|
|
529
|
+
const localVarRequestOptions = { method: "DELETE", ...baseOptions, ...options };
|
|
530
|
+
const localVarHeaderParameter = {};
|
|
531
|
+
const localVarQueryParameter = {};
|
|
532
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
533
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
534
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
535
|
+
return {
|
|
536
|
+
url: toPathString(localVarUrlObj),
|
|
537
|
+
options: localVarRequestOptions
|
|
538
|
+
};
|
|
539
|
+
},
|
|
540
|
+
/**
|
|
541
|
+
*
|
|
542
|
+
* @summary Tasks Get
|
|
543
|
+
* @param {string} taskId
|
|
544
|
+
* @param {*} [options] Override http request option.
|
|
545
|
+
* @throws {RequiredError}
|
|
546
|
+
*/
|
|
547
|
+
tasksGet: async (taskId, options = {}) => {
|
|
548
|
+
assertParamExists("tasksGet", "taskId", taskId);
|
|
549
|
+
const localVarPath = `/tasks/{task_id}`.replace(`{${"task_id"}}`, encodeURIComponent(String(taskId)));
|
|
550
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
551
|
+
let baseOptions;
|
|
552
|
+
if (configuration) {
|
|
553
|
+
baseOptions = configuration.baseOptions;
|
|
554
|
+
}
|
|
555
|
+
const localVarRequestOptions = { method: "GET", ...baseOptions, ...options };
|
|
556
|
+
const localVarHeaderParameter = {};
|
|
557
|
+
const localVarQueryParameter = {};
|
|
558
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
559
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
560
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
561
|
+
return {
|
|
562
|
+
url: toPathString(localVarUrlObj),
|
|
563
|
+
options: localVarRequestOptions
|
|
564
|
+
};
|
|
565
|
+
},
|
|
566
|
+
/**
|
|
567
|
+
*
|
|
568
|
+
* @summary Tasks List
|
|
569
|
+
* @param {*} [options] Override http request option.
|
|
570
|
+
* @throws {RequiredError}
|
|
571
|
+
*/
|
|
572
|
+
tasksList: async (options = {}) => {
|
|
573
|
+
const localVarPath = `/tasks`;
|
|
574
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
575
|
+
let baseOptions;
|
|
576
|
+
if (configuration) {
|
|
577
|
+
baseOptions = configuration.baseOptions;
|
|
578
|
+
}
|
|
579
|
+
const localVarRequestOptions = { method: "GET", ...baseOptions, ...options };
|
|
580
|
+
const localVarHeaderParameter = {};
|
|
581
|
+
const localVarQueryParameter = {};
|
|
582
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
583
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
584
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
585
|
+
return {
|
|
586
|
+
url: toPathString(localVarUrlObj),
|
|
587
|
+
options: localVarRequestOptions
|
|
588
|
+
};
|
|
589
|
+
},
|
|
590
|
+
/**
|
|
591
|
+
*
|
|
592
|
+
* @summary Tasks Update
|
|
593
|
+
* @param {string} taskId
|
|
594
|
+
* @param {TaskUpdate} taskUpdate
|
|
595
|
+
* @param {*} [options] Override http request option.
|
|
596
|
+
* @throws {RequiredError}
|
|
597
|
+
*/
|
|
598
|
+
tasksUpdate: async (taskId, taskUpdate, options = {}) => {
|
|
599
|
+
assertParamExists("tasksUpdate", "taskId", taskId);
|
|
600
|
+
assertParamExists("tasksUpdate", "taskUpdate", taskUpdate);
|
|
601
|
+
const localVarPath = `/tasks/{task_id}`.replace(`{${"task_id"}}`, encodeURIComponent(String(taskId)));
|
|
602
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
603
|
+
let baseOptions;
|
|
604
|
+
if (configuration) {
|
|
605
|
+
baseOptions = configuration.baseOptions;
|
|
606
|
+
}
|
|
607
|
+
const localVarRequestOptions = { method: "PATCH", ...baseOptions, ...options };
|
|
608
|
+
const localVarHeaderParameter = {};
|
|
609
|
+
const localVarQueryParameter = {};
|
|
610
|
+
localVarHeaderParameter["Content-Type"] = "application/json";
|
|
611
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
612
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
613
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
614
|
+
localVarRequestOptions.data = serializeDataIfNeeded(taskUpdate, localVarRequestOptions, configuration);
|
|
615
|
+
return {
|
|
616
|
+
url: toPathString(localVarUrlObj),
|
|
617
|
+
options: localVarRequestOptions
|
|
618
|
+
};
|
|
619
|
+
}
|
|
620
|
+
};
|
|
621
|
+
};
|
|
622
|
+
var TasksApiFp = function(configuration) {
|
|
623
|
+
const localVarAxiosParamCreator = TasksApiAxiosParamCreator(configuration);
|
|
624
|
+
return {
|
|
625
|
+
/**
|
|
626
|
+
*
|
|
627
|
+
* @summary Tasks Create
|
|
628
|
+
* @param {string} projectId
|
|
629
|
+
* @param {TaskCreate} taskCreate
|
|
630
|
+
* @param {*} [options] Override http request option.
|
|
631
|
+
* @throws {RequiredError}
|
|
632
|
+
*/
|
|
633
|
+
async tasksCreate(projectId, taskCreate, options) {
|
|
634
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.tasksCreate(projectId, taskCreate, options);
|
|
635
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
636
|
+
const localVarOperationServerBasePath = operationServerMap["TasksApi.tasksCreate"]?.[localVarOperationServerIndex]?.url;
|
|
637
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
638
|
+
},
|
|
639
|
+
/**
|
|
640
|
+
*
|
|
641
|
+
* @summary Tasks Delete
|
|
642
|
+
* @param {string} taskId
|
|
643
|
+
* @param {*} [options] Override http request option.
|
|
644
|
+
* @throws {RequiredError}
|
|
645
|
+
*/
|
|
646
|
+
async tasksDelete(taskId, options) {
|
|
647
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.tasksDelete(taskId, options);
|
|
648
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
649
|
+
const localVarOperationServerBasePath = operationServerMap["TasksApi.tasksDelete"]?.[localVarOperationServerIndex]?.url;
|
|
650
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
651
|
+
},
|
|
652
|
+
/**
|
|
653
|
+
*
|
|
654
|
+
* @summary Tasks Get
|
|
655
|
+
* @param {string} taskId
|
|
656
|
+
* @param {*} [options] Override http request option.
|
|
657
|
+
* @throws {RequiredError}
|
|
658
|
+
*/
|
|
659
|
+
async tasksGet(taskId, options) {
|
|
660
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.tasksGet(taskId, options);
|
|
661
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
662
|
+
const localVarOperationServerBasePath = operationServerMap["TasksApi.tasksGet"]?.[localVarOperationServerIndex]?.url;
|
|
663
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
664
|
+
},
|
|
665
|
+
/**
|
|
666
|
+
*
|
|
667
|
+
* @summary Tasks List
|
|
668
|
+
* @param {*} [options] Override http request option.
|
|
669
|
+
* @throws {RequiredError}
|
|
670
|
+
*/
|
|
671
|
+
async tasksList(options) {
|
|
672
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.tasksList(options);
|
|
673
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
674
|
+
const localVarOperationServerBasePath = operationServerMap["TasksApi.tasksList"]?.[localVarOperationServerIndex]?.url;
|
|
675
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
676
|
+
},
|
|
677
|
+
/**
|
|
678
|
+
*
|
|
679
|
+
* @summary Tasks Update
|
|
680
|
+
* @param {string} taskId
|
|
681
|
+
* @param {TaskUpdate} taskUpdate
|
|
682
|
+
* @param {*} [options] Override http request option.
|
|
683
|
+
* @throws {RequiredError}
|
|
684
|
+
*/
|
|
685
|
+
async tasksUpdate(taskId, taskUpdate, options) {
|
|
686
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.tasksUpdate(taskId, taskUpdate, options);
|
|
687
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
688
|
+
const localVarOperationServerBasePath = operationServerMap["TasksApi.tasksUpdate"]?.[localVarOperationServerIndex]?.url;
|
|
689
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios2, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
690
|
+
}
|
|
691
|
+
};
|
|
692
|
+
};
|
|
693
|
+
var TasksApiFactory = function(configuration, basePath, axios) {
|
|
694
|
+
const localVarFp = TasksApiFp(configuration);
|
|
695
|
+
return {
|
|
696
|
+
/**
|
|
697
|
+
*
|
|
698
|
+
* @summary Tasks Create
|
|
699
|
+
* @param {string} projectId
|
|
700
|
+
* @param {TaskCreate} taskCreate
|
|
701
|
+
* @param {*} [options] Override http request option.
|
|
702
|
+
* @throws {RequiredError}
|
|
703
|
+
*/
|
|
704
|
+
tasksCreate(projectId, taskCreate, options) {
|
|
705
|
+
return localVarFp.tasksCreate(projectId, taskCreate, options).then((request) => request(axios, basePath));
|
|
706
|
+
},
|
|
707
|
+
/**
|
|
708
|
+
*
|
|
709
|
+
* @summary Tasks Delete
|
|
710
|
+
* @param {string} taskId
|
|
711
|
+
* @param {*} [options] Override http request option.
|
|
712
|
+
* @throws {RequiredError}
|
|
713
|
+
*/
|
|
714
|
+
tasksDelete(taskId, options) {
|
|
715
|
+
return localVarFp.tasksDelete(taskId, options).then((request) => request(axios, basePath));
|
|
716
|
+
},
|
|
717
|
+
/**
|
|
718
|
+
*
|
|
719
|
+
* @summary Tasks Get
|
|
720
|
+
* @param {string} taskId
|
|
721
|
+
* @param {*} [options] Override http request option.
|
|
722
|
+
* @throws {RequiredError}
|
|
723
|
+
*/
|
|
724
|
+
tasksGet(taskId, options) {
|
|
725
|
+
return localVarFp.tasksGet(taskId, options).then((request) => request(axios, basePath));
|
|
726
|
+
},
|
|
727
|
+
/**
|
|
728
|
+
*
|
|
729
|
+
* @summary Tasks List
|
|
730
|
+
* @param {*} [options] Override http request option.
|
|
731
|
+
* @throws {RequiredError}
|
|
732
|
+
*/
|
|
733
|
+
tasksList(options) {
|
|
734
|
+
return localVarFp.tasksList(options).then((request) => request(axios, basePath));
|
|
735
|
+
},
|
|
736
|
+
/**
|
|
737
|
+
*
|
|
738
|
+
* @summary Tasks Update
|
|
739
|
+
* @param {string} taskId
|
|
740
|
+
* @param {TaskUpdate} taskUpdate
|
|
741
|
+
* @param {*} [options] Override http request option.
|
|
742
|
+
* @throws {RequiredError}
|
|
743
|
+
*/
|
|
744
|
+
tasksUpdate(taskId, taskUpdate, options) {
|
|
745
|
+
return localVarFp.tasksUpdate(taskId, taskUpdate, options).then((request) => request(axios, basePath));
|
|
746
|
+
}
|
|
747
|
+
};
|
|
748
|
+
};
|
|
749
|
+
var TasksApi = class extends BaseAPI {
|
|
750
|
+
/**
|
|
751
|
+
*
|
|
752
|
+
* @summary Tasks Create
|
|
753
|
+
* @param {string} projectId
|
|
754
|
+
* @param {TaskCreate} taskCreate
|
|
755
|
+
* @param {*} [options] Override http request option.
|
|
756
|
+
* @throws {RequiredError}
|
|
757
|
+
* @memberof TasksApi
|
|
758
|
+
*/
|
|
759
|
+
tasksCreate(projectId, taskCreate, options) {
|
|
760
|
+
return TasksApiFp(this.configuration).tasksCreate(projectId, taskCreate, options).then((request) => request(this.axios, this.basePath));
|
|
761
|
+
}
|
|
762
|
+
/**
|
|
763
|
+
*
|
|
764
|
+
* @summary Tasks Delete
|
|
765
|
+
* @param {string} taskId
|
|
766
|
+
* @param {*} [options] Override http request option.
|
|
767
|
+
* @throws {RequiredError}
|
|
768
|
+
* @memberof TasksApi
|
|
769
|
+
*/
|
|
770
|
+
tasksDelete(taskId, options) {
|
|
771
|
+
return TasksApiFp(this.configuration).tasksDelete(taskId, options).then((request) => request(this.axios, this.basePath));
|
|
772
|
+
}
|
|
773
|
+
/**
|
|
774
|
+
*
|
|
775
|
+
* @summary Tasks Get
|
|
776
|
+
* @param {string} taskId
|
|
777
|
+
* @param {*} [options] Override http request option.
|
|
778
|
+
* @throws {RequiredError}
|
|
779
|
+
* @memberof TasksApi
|
|
780
|
+
*/
|
|
781
|
+
tasksGet(taskId, options) {
|
|
782
|
+
return TasksApiFp(this.configuration).tasksGet(taskId, options).then((request) => request(this.axios, this.basePath));
|
|
783
|
+
}
|
|
784
|
+
/**
|
|
785
|
+
*
|
|
786
|
+
* @summary Tasks List
|
|
787
|
+
* @param {*} [options] Override http request option.
|
|
788
|
+
* @throws {RequiredError}
|
|
789
|
+
* @memberof TasksApi
|
|
790
|
+
*/
|
|
791
|
+
tasksList(options) {
|
|
792
|
+
return TasksApiFp(this.configuration).tasksList(options).then((request) => request(this.axios, this.basePath));
|
|
793
|
+
}
|
|
794
|
+
/**
|
|
795
|
+
*
|
|
796
|
+
* @summary Tasks Update
|
|
797
|
+
* @param {string} taskId
|
|
798
|
+
* @param {TaskUpdate} taskUpdate
|
|
799
|
+
* @param {*} [options] Override http request option.
|
|
800
|
+
* @throws {RequiredError}
|
|
801
|
+
* @memberof TasksApi
|
|
802
|
+
*/
|
|
803
|
+
tasksUpdate(taskId, taskUpdate, options) {
|
|
804
|
+
return TasksApiFp(this.configuration).tasksUpdate(taskId, taskUpdate, options).then((request) => request(this.axios, this.basePath));
|
|
805
|
+
}
|
|
806
|
+
};
|
|
807
|
+
|
|
808
|
+
// src/configuration.ts
|
|
809
|
+
var Configuration = class {
|
|
810
|
+
/**
|
|
811
|
+
* parameter for apiKey security
|
|
812
|
+
* @param name security name
|
|
813
|
+
* @memberof Configuration
|
|
814
|
+
*/
|
|
815
|
+
apiKey;
|
|
816
|
+
/**
|
|
817
|
+
* parameter for basic security
|
|
818
|
+
*
|
|
819
|
+
* @type {string}
|
|
820
|
+
* @memberof Configuration
|
|
821
|
+
*/
|
|
822
|
+
username;
|
|
823
|
+
/**
|
|
824
|
+
* parameter for basic security
|
|
825
|
+
*
|
|
826
|
+
* @type {string}
|
|
827
|
+
* @memberof Configuration
|
|
828
|
+
*/
|
|
829
|
+
password;
|
|
830
|
+
/**
|
|
831
|
+
* parameter for oauth2 security
|
|
832
|
+
* @param name security name
|
|
833
|
+
* @param scopes oauth2 scope
|
|
834
|
+
* @memberof Configuration
|
|
835
|
+
*/
|
|
836
|
+
accessToken;
|
|
837
|
+
/**
|
|
838
|
+
* override base path
|
|
839
|
+
*
|
|
840
|
+
* @type {string}
|
|
841
|
+
* @memberof Configuration
|
|
842
|
+
*/
|
|
843
|
+
basePath;
|
|
844
|
+
/**
|
|
845
|
+
* override server index
|
|
846
|
+
*
|
|
847
|
+
* @type {number}
|
|
848
|
+
* @memberof Configuration
|
|
849
|
+
*/
|
|
850
|
+
serverIndex;
|
|
851
|
+
/**
|
|
852
|
+
* base options for axios calls
|
|
853
|
+
*
|
|
854
|
+
* @type {any}
|
|
855
|
+
* @memberof Configuration
|
|
856
|
+
*/
|
|
857
|
+
baseOptions;
|
|
858
|
+
/**
|
|
859
|
+
* The FormData constructor that will be used to create multipart form data
|
|
860
|
+
* requests. You can inject this here so that execution environments that
|
|
861
|
+
* do not support the FormData class can still run the generated client.
|
|
862
|
+
*
|
|
863
|
+
* @type {new () => FormData}
|
|
864
|
+
*/
|
|
865
|
+
formDataCtor;
|
|
866
|
+
constructor(param = {}) {
|
|
867
|
+
this.apiKey = param.apiKey;
|
|
868
|
+
this.username = param.username;
|
|
869
|
+
this.password = param.password;
|
|
870
|
+
this.accessToken = param.accessToken;
|
|
871
|
+
this.basePath = param.basePath;
|
|
872
|
+
this.serverIndex = param.serverIndex;
|
|
873
|
+
this.baseOptions = {
|
|
874
|
+
...param.baseOptions,
|
|
875
|
+
headers: {
|
|
876
|
+
...param.baseOptions?.headers
|
|
877
|
+
}
|
|
878
|
+
};
|
|
879
|
+
this.formDataCtor = param.formDataCtor;
|
|
880
|
+
}
|
|
881
|
+
/**
|
|
882
|
+
* Check if the given MIME is a JSON MIME.
|
|
883
|
+
* JSON MIME examples:
|
|
884
|
+
* application/json
|
|
885
|
+
* application/json; charset=UTF8
|
|
886
|
+
* APPLICATION/JSON
|
|
887
|
+
* application/vnd.company+json
|
|
888
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
889
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
890
|
+
*/
|
|
891
|
+
isJsonMime(mime) {
|
|
892
|
+
const jsonMime = new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$", "i");
|
|
893
|
+
return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === "application/json-patch+json");
|
|
894
|
+
}
|
|
895
|
+
};
|
|
896
|
+
export {
|
|
897
|
+
Configuration,
|
|
898
|
+
ContactAvatarAvatarTypeEnum,
|
|
899
|
+
ContactsApi,
|
|
900
|
+
ContactsApiAxiosParamCreator,
|
|
901
|
+
ContactsApiFactory,
|
|
902
|
+
ContactsApiFp,
|
|
903
|
+
HostawayApi,
|
|
904
|
+
HostawayApiAxiosParamCreator,
|
|
905
|
+
HostawayApiFactory,
|
|
906
|
+
HostawayApiFp,
|
|
907
|
+
TasksApi,
|
|
908
|
+
TasksApiAxiosParamCreator,
|
|
909
|
+
TasksApiFactory,
|
|
910
|
+
TasksApiFp
|
|
911
|
+
};
|
|
1
912
|
//# sourceMappingURL=index.mjs.map
|