@layer-drone/protocol 0.0.7 → 0.0.9-alpha
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 +220 -49
- package/dist/index.d.ts +220 -49
- package/dist/index.js +598 -11
- package/dist/index.mjs +594 -10
- package/package.json +3 -3
- package/src/client/client/client.ts +181 -0
- package/src/client/client/index.ts +22 -0
- package/src/client/client/types.ts +215 -0
- package/src/client/client/utils.ts +415 -0
- package/src/client/client.gen.ts +2 -3
- package/src/client/core/auth.ts +40 -0
- package/src/client/core/bodySerializer.ts +84 -0
- package/src/client/core/params.ts +141 -0
- package/src/client/core/pathSerializer.ts +179 -0
- package/src/client/core/types.ts +98 -0
- package/src/client/index.ts +2 -2
- package/src/client/sdk.gen.ts +162 -88
- package/src/client/transformers.gen.ts +40 -0
- package/src/client/types.gen.ts +74 -16
- package/src/index.ts +1 -0
package/src/client/sdk.gen.ts
CHANGED
|
@@ -1,50 +1,77 @@
|
|
|
1
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
|
+
import { client as _heyApiClient } from "./client.gen.js";
|
|
2
3
|
import type {
|
|
3
4
|
Client,
|
|
4
5
|
Options as ClientOptions,
|
|
5
6
|
TDataShape,
|
|
6
|
-
} from "
|
|
7
|
-
|
|
8
|
-
import { client as _heyApiClient } from "./client.gen";
|
|
7
|
+
} from "./client/index.js";
|
|
9
8
|
import type {
|
|
10
9
|
ApiTokenControllerCreateTokenData,
|
|
11
|
-
|
|
10
|
+
ApiTokenControllerCreateTokenErrors,
|
|
11
|
+
ApiTokenControllerCreateTokenResponses,
|
|
12
12
|
ApiTokenControllerDeleteTokenData,
|
|
13
|
+
ApiTokenControllerDeleteTokenErrors,
|
|
14
|
+
ApiTokenControllerDeleteTokenResponses,
|
|
13
15
|
ApiTokenControllerGetTokenData,
|
|
16
|
+
ApiTokenControllerGetTokenErrors,
|
|
17
|
+
ApiTokenControllerGetTokenResponses,
|
|
14
18
|
ApiTokenControllerUpdateTokenData,
|
|
15
|
-
|
|
19
|
+
ApiTokenControllerUpdateTokenErrors,
|
|
20
|
+
ApiTokenControllerUpdateTokenResponses,
|
|
16
21
|
AppControllerGetHelloData,
|
|
22
|
+
AppControllerGetHelloResponses,
|
|
23
|
+
ConditionsControllerGetSunAltitudeTimeLimitsData,
|
|
24
|
+
ConditionsControllerGetSunAltitudeTimeLimitsResponses,
|
|
17
25
|
FlightsControllerCreatePresignedUrlsData,
|
|
18
|
-
|
|
26
|
+
FlightsControllerCreatePresignedUrlsErrors,
|
|
27
|
+
FlightsControllerCreatePresignedUrlsResponses,
|
|
19
28
|
FlightsControllerGenerateFlightIdData,
|
|
20
|
-
|
|
29
|
+
FlightsControllerGenerateFlightIdErrors,
|
|
30
|
+
FlightsControllerGenerateFlightIdResponses,
|
|
21
31
|
FlightsControllerValidateFlightData,
|
|
22
|
-
|
|
32
|
+
FlightsControllerValidateFlightErrors,
|
|
33
|
+
FlightsControllerValidateFlightResponses,
|
|
23
34
|
KeysControllerGetProvenanceCryptoKeyData,
|
|
24
|
-
|
|
35
|
+
KeysControllerGetProvenanceCryptoKeyResponses,
|
|
25
36
|
QuotesControllerCreateQuoteData,
|
|
37
|
+
QuotesControllerCreateQuoteErrors,
|
|
38
|
+
QuotesControllerCreateQuoteResponses,
|
|
39
|
+
QuotesControllerGetQuoteData,
|
|
40
|
+
QuotesControllerGetQuoteErrors,
|
|
41
|
+
QuotesControllerGetQuoteResponses,
|
|
26
42
|
RewardsControllerDepositRewardsData,
|
|
27
|
-
|
|
43
|
+
RewardsControllerDepositRewardsErrors,
|
|
44
|
+
RewardsControllerDepositRewardsResponses,
|
|
28
45
|
RewardsControllerDistributeRewardsData,
|
|
29
|
-
|
|
46
|
+
RewardsControllerDistributeRewardsErrors,
|
|
47
|
+
RewardsControllerDistributeRewardsResponses,
|
|
30
48
|
SchemaControllerGetEventSchemaData,
|
|
49
|
+
SchemaControllerGetEventSchemaResponses,
|
|
31
50
|
WebhooksControllerCreateData,
|
|
32
|
-
|
|
51
|
+
WebhooksControllerCreateErrors,
|
|
52
|
+
WebhooksControllerCreateResponses,
|
|
33
53
|
WebhooksControllerDeleteData,
|
|
34
|
-
|
|
54
|
+
WebhooksControllerDeleteErrors,
|
|
55
|
+
WebhooksControllerDeleteResponses,
|
|
35
56
|
WebhooksControllerGetData,
|
|
57
|
+
WebhooksControllerGetErrors,
|
|
36
58
|
WebhooksControllerGetManyData,
|
|
37
|
-
|
|
38
|
-
|
|
59
|
+
WebhooksControllerGetManyErrors,
|
|
60
|
+
WebhooksControllerGetManyResponses,
|
|
61
|
+
WebhooksControllerGetResponses,
|
|
39
62
|
WebhooksControllerGetStatusData,
|
|
40
|
-
|
|
63
|
+
WebhooksControllerGetStatusErrors,
|
|
64
|
+
WebhooksControllerGetStatusResponses,
|
|
41
65
|
WebhooksControllerRegenerateSecretData,
|
|
42
|
-
|
|
66
|
+
WebhooksControllerRegenerateSecretErrors,
|
|
67
|
+
WebhooksControllerRegenerateSecretResponses,
|
|
43
68
|
WebhooksControllerTestData,
|
|
44
|
-
|
|
69
|
+
WebhooksControllerTestErrors,
|
|
70
|
+
WebhooksControllerTestResponses,
|
|
45
71
|
WebhooksControllerUpdateData,
|
|
46
|
-
|
|
47
|
-
|
|
72
|
+
WebhooksControllerUpdateErrors,
|
|
73
|
+
WebhooksControllerUpdateResponses,
|
|
74
|
+
} from "./types.gen.js";
|
|
48
75
|
|
|
49
76
|
export type Options<
|
|
50
77
|
TData extends TDataShape = TDataShape,
|
|
@@ -66,12 +93,14 @@ export type Options<
|
|
|
66
93
|
export const appControllerGetHello = <ThrowOnError extends boolean = false>(
|
|
67
94
|
options?: Options<AppControllerGetHelloData, ThrowOnError>,
|
|
68
95
|
) => {
|
|
69
|
-
return (options?.client ?? _heyApiClient).get<
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
96
|
+
return (options?.client ?? _heyApiClient).get<
|
|
97
|
+
AppControllerGetHelloResponses,
|
|
98
|
+
unknown,
|
|
99
|
+
ThrowOnError
|
|
100
|
+
>({
|
|
101
|
+
url: "/",
|
|
102
|
+
...options,
|
|
103
|
+
});
|
|
75
104
|
};
|
|
76
105
|
|
|
77
106
|
export const keysControllerGetProvenanceCryptoKey = <
|
|
@@ -80,7 +109,7 @@ export const keysControllerGetProvenanceCryptoKey = <
|
|
|
80
109
|
options?: Options<KeysControllerGetProvenanceCryptoKeyData, ThrowOnError>,
|
|
81
110
|
) => {
|
|
82
111
|
return (options?.client ?? _heyApiClient).get<
|
|
83
|
-
|
|
112
|
+
KeysControllerGetProvenanceCryptoKeyResponses,
|
|
84
113
|
unknown,
|
|
85
114
|
ThrowOnError
|
|
86
115
|
>({
|
|
@@ -95,8 +124,8 @@ export const rewardsControllerDepositRewards = <
|
|
|
95
124
|
options: Options<RewardsControllerDepositRewardsData, ThrowOnError>,
|
|
96
125
|
) => {
|
|
97
126
|
return (options.client ?? _heyApiClient).post<
|
|
98
|
-
|
|
99
|
-
|
|
127
|
+
RewardsControllerDepositRewardsResponses,
|
|
128
|
+
RewardsControllerDepositRewardsErrors,
|
|
100
129
|
ThrowOnError
|
|
101
130
|
>({
|
|
102
131
|
security: [
|
|
@@ -109,7 +138,7 @@ export const rewardsControllerDepositRewards = <
|
|
|
109
138
|
...options,
|
|
110
139
|
headers: {
|
|
111
140
|
"Content-Type": "application/json",
|
|
112
|
-
...options
|
|
141
|
+
...options.headers,
|
|
113
142
|
},
|
|
114
143
|
});
|
|
115
144
|
};
|
|
@@ -120,8 +149,8 @@ export const rewardsControllerDistributeRewards = <
|
|
|
120
149
|
options: Options<RewardsControllerDistributeRewardsData, ThrowOnError>,
|
|
121
150
|
) => {
|
|
122
151
|
return (options.client ?? _heyApiClient).post<
|
|
123
|
-
|
|
124
|
-
|
|
152
|
+
RewardsControllerDistributeRewardsResponses,
|
|
153
|
+
RewardsControllerDistributeRewardsErrors,
|
|
125
154
|
ThrowOnError
|
|
126
155
|
>({
|
|
127
156
|
security: [
|
|
@@ -134,7 +163,7 @@ export const rewardsControllerDistributeRewards = <
|
|
|
134
163
|
...options,
|
|
135
164
|
headers: {
|
|
136
165
|
"Content-Type": "application/json",
|
|
137
|
-
...options
|
|
166
|
+
...options.headers,
|
|
138
167
|
},
|
|
139
168
|
});
|
|
140
169
|
};
|
|
@@ -145,8 +174,8 @@ export const apiTokenControllerCreateToken = <
|
|
|
145
174
|
options: Options<ApiTokenControllerCreateTokenData, ThrowOnError>,
|
|
146
175
|
) => {
|
|
147
176
|
return (options.client ?? _heyApiClient).post<
|
|
148
|
-
|
|
149
|
-
|
|
177
|
+
ApiTokenControllerCreateTokenResponses,
|
|
178
|
+
ApiTokenControllerCreateTokenErrors,
|
|
150
179
|
ThrowOnError
|
|
151
180
|
>({
|
|
152
181
|
security: [
|
|
@@ -159,7 +188,7 @@ export const apiTokenControllerCreateToken = <
|
|
|
159
188
|
...options,
|
|
160
189
|
headers: {
|
|
161
190
|
"Content-Type": "application/json",
|
|
162
|
-
...options
|
|
191
|
+
...options.headers,
|
|
163
192
|
},
|
|
164
193
|
});
|
|
165
194
|
};
|
|
@@ -170,8 +199,8 @@ export const apiTokenControllerDeleteToken = <
|
|
|
170
199
|
options: Options<ApiTokenControllerDeleteTokenData, ThrowOnError>,
|
|
171
200
|
) => {
|
|
172
201
|
return (options.client ?? _heyApiClient).delete<
|
|
173
|
-
|
|
174
|
-
|
|
202
|
+
ApiTokenControllerDeleteTokenResponses,
|
|
203
|
+
ApiTokenControllerDeleteTokenErrors,
|
|
175
204
|
ThrowOnError
|
|
176
205
|
>({
|
|
177
206
|
security: [
|
|
@@ -190,7 +219,11 @@ export const apiTokenControllerGetToken = <
|
|
|
190
219
|
>(
|
|
191
220
|
options: Options<ApiTokenControllerGetTokenData, ThrowOnError>,
|
|
192
221
|
) => {
|
|
193
|
-
return (options.client ?? _heyApiClient).get<
|
|
222
|
+
return (options.client ?? _heyApiClient).get<
|
|
223
|
+
ApiTokenControllerGetTokenResponses,
|
|
224
|
+
ApiTokenControllerGetTokenErrors,
|
|
225
|
+
ThrowOnError
|
|
226
|
+
>({
|
|
194
227
|
security: [
|
|
195
228
|
{
|
|
196
229
|
name: "x-api-token",
|
|
@@ -208,8 +241,8 @@ export const apiTokenControllerUpdateToken = <
|
|
|
208
241
|
options: Options<ApiTokenControllerUpdateTokenData, ThrowOnError>,
|
|
209
242
|
) => {
|
|
210
243
|
return (options.client ?? _heyApiClient).patch<
|
|
211
|
-
|
|
212
|
-
|
|
244
|
+
ApiTokenControllerUpdateTokenResponses,
|
|
245
|
+
ApiTokenControllerUpdateTokenErrors,
|
|
213
246
|
ThrowOnError
|
|
214
247
|
>({
|
|
215
248
|
security: [
|
|
@@ -222,7 +255,7 @@ export const apiTokenControllerUpdateToken = <
|
|
|
222
255
|
...options,
|
|
223
256
|
headers: {
|
|
224
257
|
"Content-Type": "application/json",
|
|
225
|
-
...options
|
|
258
|
+
...options.headers,
|
|
226
259
|
},
|
|
227
260
|
});
|
|
228
261
|
};
|
|
@@ -232,22 +265,43 @@ export const quotesControllerCreateQuote = <
|
|
|
232
265
|
>(
|
|
233
266
|
options: Options<QuotesControllerCreateQuoteData, ThrowOnError>,
|
|
234
267
|
) => {
|
|
235
|
-
return (options.client ?? _heyApiClient).post<
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
...options,
|
|
245
|
-
headers: {
|
|
246
|
-
"Content-Type": "application/json",
|
|
247
|
-
...options?.headers,
|
|
268
|
+
return (options.client ?? _heyApiClient).post<
|
|
269
|
+
QuotesControllerCreateQuoteResponses,
|
|
270
|
+
QuotesControllerCreateQuoteErrors,
|
|
271
|
+
ThrowOnError
|
|
272
|
+
>({
|
|
273
|
+
security: [
|
|
274
|
+
{
|
|
275
|
+
name: "x-api-token",
|
|
276
|
+
type: "apiKey",
|
|
248
277
|
},
|
|
278
|
+
],
|
|
279
|
+
url: "/quotes",
|
|
280
|
+
...options,
|
|
281
|
+
headers: {
|
|
282
|
+
"Content-Type": "application/json",
|
|
283
|
+
...options.headers,
|
|
249
284
|
},
|
|
250
|
-
);
|
|
285
|
+
});
|
|
286
|
+
};
|
|
287
|
+
|
|
288
|
+
export const quotesControllerGetQuote = <ThrowOnError extends boolean = false>(
|
|
289
|
+
options: Options<QuotesControllerGetQuoteData, ThrowOnError>,
|
|
290
|
+
) => {
|
|
291
|
+
return (options.client ?? _heyApiClient).get<
|
|
292
|
+
QuotesControllerGetQuoteResponses,
|
|
293
|
+
QuotesControllerGetQuoteErrors,
|
|
294
|
+
ThrowOnError
|
|
295
|
+
>({
|
|
296
|
+
security: [
|
|
297
|
+
{
|
|
298
|
+
name: "x-api-token",
|
|
299
|
+
type: "apiKey",
|
|
300
|
+
},
|
|
301
|
+
],
|
|
302
|
+
url: "/quotes/{id}",
|
|
303
|
+
...options,
|
|
304
|
+
});
|
|
251
305
|
};
|
|
252
306
|
|
|
253
307
|
export const flightsControllerGenerateFlightId = <
|
|
@@ -256,8 +310,8 @@ export const flightsControllerGenerateFlightId = <
|
|
|
256
310
|
options: Options<FlightsControllerGenerateFlightIdData, ThrowOnError>,
|
|
257
311
|
) => {
|
|
258
312
|
return (options.client ?? _heyApiClient).get<
|
|
259
|
-
|
|
260
|
-
|
|
313
|
+
FlightsControllerGenerateFlightIdResponses,
|
|
314
|
+
FlightsControllerGenerateFlightIdErrors,
|
|
261
315
|
ThrowOnError
|
|
262
316
|
>({
|
|
263
317
|
security: [
|
|
@@ -277,8 +331,8 @@ export const flightsControllerCreatePresignedUrls = <
|
|
|
277
331
|
options: Options<FlightsControllerCreatePresignedUrlsData, ThrowOnError>,
|
|
278
332
|
) => {
|
|
279
333
|
return (options.client ?? _heyApiClient).post<
|
|
280
|
-
|
|
281
|
-
|
|
334
|
+
FlightsControllerCreatePresignedUrlsResponses,
|
|
335
|
+
FlightsControllerCreatePresignedUrlsErrors,
|
|
282
336
|
ThrowOnError
|
|
283
337
|
>({
|
|
284
338
|
security: [
|
|
@@ -291,7 +345,7 @@ export const flightsControllerCreatePresignedUrls = <
|
|
|
291
345
|
...options,
|
|
292
346
|
headers: {
|
|
293
347
|
"Content-Type": "application/json",
|
|
294
|
-
...options
|
|
348
|
+
...options.headers,
|
|
295
349
|
},
|
|
296
350
|
});
|
|
297
351
|
};
|
|
@@ -302,8 +356,8 @@ export const flightsControllerValidateFlight = <
|
|
|
302
356
|
options: Options<FlightsControllerValidateFlightData, ThrowOnError>,
|
|
303
357
|
) => {
|
|
304
358
|
return (options.client ?? _heyApiClient).post<
|
|
305
|
-
|
|
306
|
-
|
|
359
|
+
FlightsControllerValidateFlightResponses,
|
|
360
|
+
FlightsControllerValidateFlightErrors,
|
|
307
361
|
ThrowOnError
|
|
308
362
|
>({
|
|
309
363
|
security: [
|
|
@@ -316,30 +370,50 @@ export const flightsControllerValidateFlight = <
|
|
|
316
370
|
...options,
|
|
317
371
|
headers: {
|
|
318
372
|
"Content-Type": "application/json",
|
|
319
|
-
...options
|
|
373
|
+
...options.headers,
|
|
320
374
|
},
|
|
321
375
|
});
|
|
322
376
|
};
|
|
323
377
|
|
|
378
|
+
export const conditionsControllerGetSunAltitudeTimeLimits = <
|
|
379
|
+
ThrowOnError extends boolean = false,
|
|
380
|
+
>(
|
|
381
|
+
options: Options<
|
|
382
|
+
ConditionsControllerGetSunAltitudeTimeLimitsData,
|
|
383
|
+
ThrowOnError
|
|
384
|
+
>,
|
|
385
|
+
) => {
|
|
386
|
+
return (options.client ?? _heyApiClient).get<
|
|
387
|
+
ConditionsControllerGetSunAltitudeTimeLimitsResponses,
|
|
388
|
+
unknown,
|
|
389
|
+
ThrowOnError
|
|
390
|
+
>({
|
|
391
|
+
url: "/conditions/sun-altitude",
|
|
392
|
+
...options,
|
|
393
|
+
});
|
|
394
|
+
};
|
|
395
|
+
|
|
324
396
|
export const schemaControllerGetEventSchema = <
|
|
325
397
|
ThrowOnError extends boolean = false,
|
|
326
398
|
>(
|
|
327
399
|
options?: Options<SchemaControllerGetEventSchemaData, ThrowOnError>,
|
|
328
400
|
) => {
|
|
329
|
-
return (options?.client ?? _heyApiClient).get<
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
401
|
+
return (options?.client ?? _heyApiClient).get<
|
|
402
|
+
SchemaControllerGetEventSchemaResponses,
|
|
403
|
+
unknown,
|
|
404
|
+
ThrowOnError
|
|
405
|
+
>({
|
|
406
|
+
url: "/schema/event",
|
|
407
|
+
...options,
|
|
408
|
+
});
|
|
335
409
|
};
|
|
336
410
|
|
|
337
411
|
export const webhooksControllerGetMany = <ThrowOnError extends boolean = false>(
|
|
338
412
|
options: Options<WebhooksControllerGetManyData, ThrowOnError>,
|
|
339
413
|
) => {
|
|
340
414
|
return (options.client ?? _heyApiClient).get<
|
|
341
|
-
|
|
342
|
-
|
|
415
|
+
WebhooksControllerGetManyResponses,
|
|
416
|
+
WebhooksControllerGetManyErrors,
|
|
343
417
|
ThrowOnError
|
|
344
418
|
>({
|
|
345
419
|
security: [
|
|
@@ -357,8 +431,8 @@ export const webhooksControllerCreate = <ThrowOnError extends boolean = false>(
|
|
|
357
431
|
options: Options<WebhooksControllerCreateData, ThrowOnError>,
|
|
358
432
|
) => {
|
|
359
433
|
return (options.client ?? _heyApiClient).post<
|
|
360
|
-
|
|
361
|
-
|
|
434
|
+
WebhooksControllerCreateResponses,
|
|
435
|
+
WebhooksControllerCreateErrors,
|
|
362
436
|
ThrowOnError
|
|
363
437
|
>({
|
|
364
438
|
security: [
|
|
@@ -371,7 +445,7 @@ export const webhooksControllerCreate = <ThrowOnError extends boolean = false>(
|
|
|
371
445
|
...options,
|
|
372
446
|
headers: {
|
|
373
447
|
"Content-Type": "application/json",
|
|
374
|
-
...options
|
|
448
|
+
...options.headers,
|
|
375
449
|
},
|
|
376
450
|
});
|
|
377
451
|
};
|
|
@@ -380,8 +454,8 @@ export const webhooksControllerDelete = <ThrowOnError extends boolean = false>(
|
|
|
380
454
|
options: Options<WebhooksControllerDeleteData, ThrowOnError>,
|
|
381
455
|
) => {
|
|
382
456
|
return (options.client ?? _heyApiClient).delete<
|
|
383
|
-
|
|
384
|
-
|
|
457
|
+
WebhooksControllerDeleteResponses,
|
|
458
|
+
WebhooksControllerDeleteErrors,
|
|
385
459
|
ThrowOnError
|
|
386
460
|
>({
|
|
387
461
|
security: [
|
|
@@ -399,8 +473,8 @@ export const webhooksControllerGet = <ThrowOnError extends boolean = false>(
|
|
|
399
473
|
options: Options<WebhooksControllerGetData, ThrowOnError>,
|
|
400
474
|
) => {
|
|
401
475
|
return (options.client ?? _heyApiClient).get<
|
|
402
|
-
|
|
403
|
-
|
|
476
|
+
WebhooksControllerGetResponses,
|
|
477
|
+
WebhooksControllerGetErrors,
|
|
404
478
|
ThrowOnError
|
|
405
479
|
>({
|
|
406
480
|
security: [
|
|
@@ -418,8 +492,8 @@ export const webhooksControllerUpdate = <ThrowOnError extends boolean = false>(
|
|
|
418
492
|
options: Options<WebhooksControllerUpdateData, ThrowOnError>,
|
|
419
493
|
) => {
|
|
420
494
|
return (options.client ?? _heyApiClient).put<
|
|
421
|
-
|
|
422
|
-
|
|
495
|
+
WebhooksControllerUpdateResponses,
|
|
496
|
+
WebhooksControllerUpdateErrors,
|
|
423
497
|
ThrowOnError
|
|
424
498
|
>({
|
|
425
499
|
security: [
|
|
@@ -432,7 +506,7 @@ export const webhooksControllerUpdate = <ThrowOnError extends boolean = false>(
|
|
|
432
506
|
...options,
|
|
433
507
|
headers: {
|
|
434
508
|
"Content-Type": "application/json",
|
|
435
|
-
...options
|
|
509
|
+
...options.headers,
|
|
436
510
|
},
|
|
437
511
|
});
|
|
438
512
|
};
|
|
@@ -443,8 +517,8 @@ export const webhooksControllerRegenerateSecret = <
|
|
|
443
517
|
options: Options<WebhooksControllerRegenerateSecretData, ThrowOnError>,
|
|
444
518
|
) => {
|
|
445
519
|
return (options.client ?? _heyApiClient).post<
|
|
446
|
-
|
|
447
|
-
|
|
520
|
+
WebhooksControllerRegenerateSecretResponses,
|
|
521
|
+
WebhooksControllerRegenerateSecretErrors,
|
|
448
522
|
ThrowOnError
|
|
449
523
|
>({
|
|
450
524
|
security: [
|
|
@@ -462,8 +536,8 @@ export const webhooksControllerTest = <ThrowOnError extends boolean = false>(
|
|
|
462
536
|
options: Options<WebhooksControllerTestData, ThrowOnError>,
|
|
463
537
|
) => {
|
|
464
538
|
return (options.client ?? _heyApiClient).post<
|
|
465
|
-
|
|
466
|
-
|
|
539
|
+
WebhooksControllerTestResponses,
|
|
540
|
+
WebhooksControllerTestErrors,
|
|
467
541
|
ThrowOnError
|
|
468
542
|
>({
|
|
469
543
|
security: [
|
|
@@ -483,8 +557,8 @@ export const webhooksControllerGetStatus = <
|
|
|
483
557
|
options: Options<WebhooksControllerGetStatusData, ThrowOnError>,
|
|
484
558
|
) => {
|
|
485
559
|
return (options.client ?? _heyApiClient).get<
|
|
486
|
-
|
|
487
|
-
|
|
560
|
+
WebhooksControllerGetStatusResponses,
|
|
561
|
+
WebhooksControllerGetStatusErrors,
|
|
488
562
|
ThrowOnError
|
|
489
563
|
>({
|
|
490
564
|
security: [
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
|
+
import type {
|
|
3
|
+
ApiTokenControllerUpdateTokenResponse,
|
|
4
|
+
ConditionsControllerGetSunAltitudeTimeLimitsResponse,
|
|
5
|
+
} from "./types.gen.js";
|
|
6
|
+
|
|
7
|
+
const updateApiTokenResponseDtoSchemaResponseTransformer = (data: any) => {
|
|
8
|
+
data.deleted_at = new Date(data.deleted_at);
|
|
9
|
+
data.last_used = new Date(data.last_used);
|
|
10
|
+
return data;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export const apiTokenControllerUpdateTokenResponseTransformer = async (
|
|
14
|
+
data: any,
|
|
15
|
+
): Promise<ApiTokenControllerUpdateTokenResponse> => {
|
|
16
|
+
data = updateApiTokenResponseDtoSchemaResponseTransformer(data);
|
|
17
|
+
return data;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
const getTimeLimitsForSunAltitudeResponseSchemaResponseTransformer = (
|
|
21
|
+
data: any,
|
|
22
|
+
) => {
|
|
23
|
+
data.OptimalSunAltitudePeriod.StartTime = new Date(
|
|
24
|
+
data.OptimalSunAltitudePeriod.StartTime,
|
|
25
|
+
);
|
|
26
|
+
data.OptimalSunAltitudePeriod.EndTime = new Date(
|
|
27
|
+
data.OptimalSunAltitudePeriod.EndTime,
|
|
28
|
+
);
|
|
29
|
+
data.DaylightPeriod.StartTime = new Date(data.DaylightPeriod.StartTime);
|
|
30
|
+
data.DaylightPeriod.EndTime = new Date(data.DaylightPeriod.EndTime);
|
|
31
|
+
return data;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export const conditionsControllerGetSunAltitudeTimeLimitsResponseTransformer =
|
|
35
|
+
async (
|
|
36
|
+
data: any,
|
|
37
|
+
): Promise<ConditionsControllerGetSunAltitudeTimeLimitsResponse> => {
|
|
38
|
+
data = getTimeLimitsForSunAltitudeResponseSchemaResponseTransformer(data);
|
|
39
|
+
return data;
|
|
40
|
+
};
|
package/src/client/types.gen.ts
CHANGED
|
@@ -32,7 +32,7 @@ export type DepositRewardsRequestDto = {
|
|
|
32
32
|
/**
|
|
33
33
|
* An integer where the last 18 places are decimal places
|
|
34
34
|
*/
|
|
35
|
-
amount:
|
|
35
|
+
amount: bigint;
|
|
36
36
|
vaultId: number;
|
|
37
37
|
vaultManagerAddress?: string;
|
|
38
38
|
};
|
|
@@ -54,12 +54,10 @@ export type DistributeRewardsResponseDto = {
|
|
|
54
54
|
export type CreateApiTokenResponseDto = {
|
|
55
55
|
id: string;
|
|
56
56
|
name: string;
|
|
57
|
-
deleted_at:
|
|
58
|
-
last_used:
|
|
57
|
+
deleted_at: Date;
|
|
58
|
+
last_used: Date;
|
|
59
59
|
org: number;
|
|
60
|
-
scopes: Array<
|
|
61
|
-
"manageTokens" | "manageFlights" | "manageWebhooks" | "all"
|
|
62
|
-
> | null;
|
|
60
|
+
scopes: Array<"manageTokens" | "manageFlights" | "manageWebhooks" | "all">;
|
|
63
61
|
};
|
|
64
62
|
|
|
65
63
|
export type CreateApiTokenRequestDto = {
|
|
@@ -76,12 +74,10 @@ export type UpdateApiTokenRequestDto = {
|
|
|
76
74
|
export type UpdateApiTokenResponseDto = {
|
|
77
75
|
id: string;
|
|
78
76
|
name: string;
|
|
79
|
-
deleted_at:
|
|
80
|
-
last_used:
|
|
77
|
+
deleted_at: Date;
|
|
78
|
+
last_used: Date;
|
|
81
79
|
org: number;
|
|
82
|
-
scopes: Array<
|
|
83
|
-
"manageTokens" | "manageFlights" | "manageWebhooks" | "all"
|
|
84
|
-
> | null;
|
|
80
|
+
scopes: Array<"manageTokens" | "manageFlights" | "manageWebhooks" | "all">;
|
|
85
81
|
};
|
|
86
82
|
|
|
87
83
|
export type CreateQuoteRequestDto = {
|
|
@@ -112,6 +108,20 @@ export type ValidateFlightResponseDto = {
|
|
|
112
108
|
message: string;
|
|
113
109
|
};
|
|
114
110
|
|
|
111
|
+
export type GetTimeLimitsForSunAltitudeResponse = {
|
|
112
|
+
OptimalSunAltitudePeriod: {
|
|
113
|
+
StartTime: Date;
|
|
114
|
+
EndTime: Date;
|
|
115
|
+
SunAltitudeAtLimits: number;
|
|
116
|
+
};
|
|
117
|
+
DaylightPeriod: {
|
|
118
|
+
StartTime: Date;
|
|
119
|
+
EndTime: Date;
|
|
120
|
+
SunAltitudeAtLimits: number;
|
|
121
|
+
};
|
|
122
|
+
SunAltitudeInDegrees: number;
|
|
123
|
+
};
|
|
124
|
+
|
|
115
125
|
export type CreateWebhookBody = {
|
|
116
126
|
name: string;
|
|
117
127
|
url: string;
|
|
@@ -131,7 +141,7 @@ export type GetWebhooksResponse = Array<{
|
|
|
131
141
|
event_types: Array<"test" | "protocol.flight.submitted" | "*">;
|
|
132
142
|
active: boolean;
|
|
133
143
|
failure_count: number;
|
|
134
|
-
last_failure_reason: string
|
|
144
|
+
last_failure_reason: string;
|
|
135
145
|
created_at: string;
|
|
136
146
|
updated_at: string;
|
|
137
147
|
}>;
|
|
@@ -143,7 +153,7 @@ export type GetWebhookResponse = {
|
|
|
143
153
|
event_types: Array<"test" | "protocol.flight.submitted" | "*">;
|
|
144
154
|
active: boolean;
|
|
145
155
|
failure_count: number;
|
|
146
|
-
last_failure_reason: string
|
|
156
|
+
last_failure_reason: string;
|
|
147
157
|
created_at: string;
|
|
148
158
|
updated_at: string;
|
|
149
159
|
};
|
|
@@ -162,7 +172,7 @@ export type UpdateWebhookResponse = {
|
|
|
162
172
|
event_types: Array<"test" | "protocol.flight.submitted" | "*">;
|
|
163
173
|
active: boolean;
|
|
164
174
|
failure_count: number;
|
|
165
|
-
last_failure_reason: string
|
|
175
|
+
last_failure_reason: string;
|
|
166
176
|
created_at: string;
|
|
167
177
|
updated_at: string;
|
|
168
178
|
};
|
|
@@ -181,7 +191,7 @@ export type TestWebhookResponse = {
|
|
|
181
191
|
|
|
182
192
|
export type GetWebhookStatusResponse = {
|
|
183
193
|
status: "inactive" | "error" | "connected" | "connecting";
|
|
184
|
-
error?: string
|
|
194
|
+
error?: string;
|
|
185
195
|
};
|
|
186
196
|
|
|
187
197
|
export type AppControllerGetHelloData = {
|
|
@@ -340,6 +350,24 @@ export type QuotesControllerCreateQuoteResponses = {
|
|
|
340
350
|
201: unknown;
|
|
341
351
|
};
|
|
342
352
|
|
|
353
|
+
export type QuotesControllerGetQuoteData = {
|
|
354
|
+
body?: never;
|
|
355
|
+
path: {
|
|
356
|
+
id: string;
|
|
357
|
+
};
|
|
358
|
+
query?: never;
|
|
359
|
+
url: "/quotes/{id}";
|
|
360
|
+
};
|
|
361
|
+
|
|
362
|
+
export type QuotesControllerGetQuoteErrors = {
|
|
363
|
+
401: unknown;
|
|
364
|
+
403: unknown;
|
|
365
|
+
};
|
|
366
|
+
|
|
367
|
+
export type QuotesControllerGetQuoteResponses = {
|
|
368
|
+
200: unknown;
|
|
369
|
+
};
|
|
370
|
+
|
|
343
371
|
export type FlightsControllerGenerateFlightIdData = {
|
|
344
372
|
body?: never;
|
|
345
373
|
path?: never;
|
|
@@ -383,7 +411,7 @@ export type FlightsControllerCreatePresignedUrlsResponses = {
|
|
|
383
411
|
/**
|
|
384
412
|
* Returns presigned URLs for file upload
|
|
385
413
|
*/
|
|
386
|
-
|
|
414
|
+
201: CreateFileResponseDto;
|
|
387
415
|
};
|
|
388
416
|
|
|
389
417
|
export type FlightsControllerCreatePresignedUrlsResponse =
|
|
@@ -411,6 +439,36 @@ export type FlightsControllerValidateFlightResponses = {
|
|
|
411
439
|
export type FlightsControllerValidateFlightResponse =
|
|
412
440
|
FlightsControllerValidateFlightResponses[keyof FlightsControllerValidateFlightResponses];
|
|
413
441
|
|
|
442
|
+
export type ConditionsControllerGetSunAltitudeTimeLimitsData = {
|
|
443
|
+
body?: never;
|
|
444
|
+
path?: never;
|
|
445
|
+
query: {
|
|
446
|
+
/**
|
|
447
|
+
* Latitude in degress (decimal number)
|
|
448
|
+
*/
|
|
449
|
+
lat: number;
|
|
450
|
+
/**
|
|
451
|
+
* Longitude in degress (decimal number)
|
|
452
|
+
*/
|
|
453
|
+
lon: number;
|
|
454
|
+
/**
|
|
455
|
+
* Local time in ISO time format with correct timezone YYYY-MM-DDTHH:MM:SS+hh:mm
|
|
456
|
+
*/
|
|
457
|
+
time: Date;
|
|
458
|
+
};
|
|
459
|
+
url: "/conditions/sun-altitude";
|
|
460
|
+
};
|
|
461
|
+
|
|
462
|
+
export type ConditionsControllerGetSunAltitudeTimeLimitsResponses = {
|
|
463
|
+
/**
|
|
464
|
+
* Returns sun altitude time limits for given coordinates and time
|
|
465
|
+
*/
|
|
466
|
+
200: GetTimeLimitsForSunAltitudeResponse;
|
|
467
|
+
};
|
|
468
|
+
|
|
469
|
+
export type ConditionsControllerGetSunAltitudeTimeLimitsResponse =
|
|
470
|
+
ConditionsControllerGetSunAltitudeTimeLimitsResponses[keyof ConditionsControllerGetSunAltitudeTimeLimitsResponses];
|
|
471
|
+
|
|
414
472
|
export type SchemaControllerGetEventSchemaData = {
|
|
415
473
|
body?: never;
|
|
416
474
|
path?: never;
|
package/src/index.ts
CHANGED