@stack-spot/portal-network 0.56.0 → 0.56.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.
@@ -0,0 +1,1575 @@
1
+ /**
2
+ * OpenAPI definition
3
+ * v0
4
+ * DO NOT MODIFY - This file has been generated using oazapfts.
5
+ * See https://www.npmjs.com/package/oazapfts
6
+ */
7
+ import * as Oazapfts from "@oazapfts/runtime";
8
+ import * as QS from "@oazapfts/runtime/query";
9
+ export const defaults: Oazapfts.Defaults<Oazapfts.CustomHeaders> = {
10
+ headers: {},
11
+ baseUrl: "https://cloud-cloud-runtime-api.dev.stackspot.com",
12
+ };
13
+ const oazapfts = Oazapfts.runtime(defaults);
14
+ export const servers = {
15
+ generatedServerUrl: "https://cloud-cloud-runtime-api.dev.stackspot.com"
16
+ };
17
+ export type EnvVar = {
18
+ key: string;
19
+ value: string;
20
+ };
21
+ export type ReplicaNum = {
22
+ min?: number;
23
+ max?: number;
24
+ };
25
+ export type CreateDeploymentRequestV2 = {
26
+ runtimeId: string;
27
+ applicationId?: string;
28
+ applicationName?: string;
29
+ action: string;
30
+ containerPort?: number;
31
+ healthCheckPath?: string;
32
+ imageUrl: string;
33
+ tag: string;
34
+ mem?: number;
35
+ envVars?: EnvVar[];
36
+ cpu?: number;
37
+ replicaNum?: ReplicaNum;
38
+ awsAccount?: string;
39
+ idAwsAccount?: string;
40
+ health?: string;
41
+ applicationURL?: string;
42
+ };
43
+ export type StatusType = number;
44
+ export type ApplicationDtov2 = {
45
+ id?: string;
46
+ name: string;
47
+ description?: string;
48
+ "type": string;
49
+ creator: string;
50
+ url?: string;
51
+ projectId?: string;
52
+ createdAt?: string;
53
+ updatedAt?: string;
54
+ };
55
+ export type RuntimeSpecDto = {
56
+ id: string;
57
+ };
58
+ export type ResourcesDto = {
59
+ memory: string;
60
+ cpu: number;
61
+ };
62
+ export type HpaDto = {
63
+ enabled: boolean;
64
+ max: number;
65
+ min: number;
66
+ cpu: number;
67
+ };
68
+ export type ContainerValuesDto = {
69
+ resources: ResourcesDto;
70
+ volume: string;
71
+ hpa: HpaDto;
72
+ };
73
+ export type ContainerSpecDto = {
74
+ port: string;
75
+ healthCheckPath: string;
76
+ envVars: {
77
+ [key: string]: string;
78
+ };
79
+ imageUrl: string;
80
+ versionTag: string;
81
+ values: ContainerValuesDto;
82
+ };
83
+ export type SpecDto = {
84
+ runtime: RuntimeSpecDto;
85
+ container: ContainerSpecDto;
86
+ };
87
+ export type CreateDeploymentRequest = {
88
+ ulid?: string;
89
+ kind: string;
90
+ apiVersion: string;
91
+ runtimeId: number;
92
+ sourceId: string;
93
+ imageUrl: string;
94
+ metadata?: {
95
+ [key: string]: object;
96
+ };
97
+ action: "START" | "STOP" | "RESTART" | "DEPLOY";
98
+ sourceType: string;
99
+ spec: SpecDto;
100
+ };
101
+ export type ApplicationDto = {
102
+ id?: number;
103
+ ulid?: string;
104
+ name: string;
105
+ description?: string;
106
+ "type": string;
107
+ creator: string;
108
+ projectId: number;
109
+ url?: string;
110
+ projectUlid?: string;
111
+ createdAt?: string;
112
+ updatedAt?: string;
113
+ };
114
+ export type CreateApplicationResponse = {
115
+ id?: number;
116
+ ulid?: string;
117
+ name: string;
118
+ description?: string;
119
+ "type": string;
120
+ creator: string;
121
+ projectId: number;
122
+ url?: string;
123
+ projectUlid?: string;
124
+ createdAt?: string;
125
+ updatedAt?: string;
126
+ };
127
+ export type ProjectDtov2 = {
128
+ id: string;
129
+ name: string;
130
+ description: string;
131
+ environment: string;
132
+ region?: string;
133
+ };
134
+ export type AddOnDto = {
135
+ name: string;
136
+ description: string;
137
+ };
138
+ export type RuntimeDtov2 = {
139
+ id: string;
140
+ name: string;
141
+ description: string;
142
+ "type": "CONTAINER" | "STATIC";
143
+ projects: ProjectDtov2[];
144
+ tags: string[];
145
+ env?: string;
146
+ addons: AddOnDto[];
147
+ };
148
+ export type GetRuntimesByProjectUlidV2 = {
149
+ runtimes: RuntimeDtov2[];
150
+ };
151
+ export type PaginatedResponseApplicationDto = {
152
+ content?: ApplicationDto[];
153
+ last?: boolean;
154
+ totalElements?: number;
155
+ totalPages?: number;
156
+ first?: boolean;
157
+ size?: number;
158
+ "number"?: number;
159
+ numberOfElements?: number;
160
+ empty?: boolean;
161
+ };
162
+ export type GetDeploymentLogsResponse = {
163
+ logs: string;
164
+ };
165
+ export type GetApplicationByUlidResponseV2 = {
166
+ id?: string;
167
+ name: string;
168
+ description?: string;
169
+ "type": string;
170
+ creator: string;
171
+ url?: string;
172
+ projectId?: string;
173
+ createdAt?: string;
174
+ updatedAt?: string;
175
+ };
176
+ export type GetApplicationByProjectResponse = {
177
+ name: string;
178
+ id: string;
179
+ description: string;
180
+ "type": string;
181
+ creator: string;
182
+ projectId: string;
183
+ url?: string;
184
+ };
185
+ export type PaginatedResponseGetApplicationByProjectResponse = {
186
+ content?: GetApplicationByProjectResponse[];
187
+ last?: boolean;
188
+ totalElements?: number;
189
+ totalPages?: number;
190
+ first?: boolean;
191
+ size?: number;
192
+ "number"?: number;
193
+ numberOfElements?: number;
194
+ empty?: boolean;
195
+ };
196
+ export type ProjectDto = {
197
+ ulid: string;
198
+ name: string;
199
+ description: string;
200
+ environment: string;
201
+ region?: string;
202
+ };
203
+ export type GetRuntimeByUlidResponse = {
204
+ ulid: string;
205
+ name: string;
206
+ description: string;
207
+ "type": "CONTAINER" | "STATIC";
208
+ projects: ProjectDto[];
209
+ tags: {
210
+ [key: string]: string;
211
+ };
212
+ };
213
+ export type RegistryDto = {
214
+ id: string;
215
+ name?: string;
216
+ projectId?: string;
217
+ "type": "ECR";
218
+ };
219
+ export type ListResponseRegistryDto = {
220
+ totalCount: number;
221
+ limit: number;
222
+ offset: number;
223
+ data: RegistryDto[];
224
+ };
225
+ export type RepositoryDto = {
226
+ id: string;
227
+ name: string;
228
+ registryId: string;
229
+ repositoryUri: string;
230
+ };
231
+ export type ImageDto = {
232
+ imageUri: string;
233
+ tags: string[];
234
+ digest?: string;
235
+ };
236
+ export type RuntimeDto = {
237
+ ulid: string;
238
+ name: string;
239
+ description: string;
240
+ "type": "CONTAINER" | "STATIC";
241
+ projects: ProjectDto[];
242
+ tags: {
243
+ [key: string]: string;
244
+ };
245
+ };
246
+ export type GetRuntimesByProjectUlid = {
247
+ runtimes: RuntimeDto[];
248
+ };
249
+ export type GetApplicationByUlidResponse = {
250
+ id?: number;
251
+ ulid?: string;
252
+ name: string;
253
+ description?: string;
254
+ "type": string;
255
+ creator: string;
256
+ projectId: number;
257
+ url?: string;
258
+ projectUlid?: string;
259
+ createdAt?: string;
260
+ updatedAt?: string;
261
+ };
262
+ export function createDeployment({ createDeploymentRequestV2 }: {
263
+ createDeploymentRequestV2: CreateDeploymentRequestV2;
264
+ }, opts?: Oazapfts.RequestOpts) {
265
+ return oazapfts.ok(oazapfts.fetchJson<{
266
+ status: 200;
267
+ data: object;
268
+ } | {
269
+ status: 422;
270
+ data: {
271
+ instance?: string;
272
+ "type"?: string;
273
+ parameters?: {
274
+ [key: string]: object;
275
+ };
276
+ title?: string;
277
+ status?: StatusType;
278
+ detail?: string;
279
+ };
280
+ } | {
281
+ status: 500;
282
+ data: {
283
+ instance?: string;
284
+ "type"?: string;
285
+ parameters?: {
286
+ [key: string]: object;
287
+ };
288
+ title?: string;
289
+ status?: StatusType;
290
+ detail?: string;
291
+ };
292
+ }>("/v2/deployments", oazapfts.json({
293
+ ...opts,
294
+ method: "POST",
295
+ body: createDeploymentRequestV2
296
+ })));
297
+ }
298
+ export function createApplication({ applicationDtov2 }: {
299
+ applicationDtov2: ApplicationDtov2;
300
+ }, opts?: Oazapfts.RequestOpts) {
301
+ return oazapfts.ok(oazapfts.fetchJson<{
302
+ status: 200;
303
+ data: ApplicationDtov2;
304
+ } | {
305
+ status: 422;
306
+ data: {
307
+ instance?: string;
308
+ "type"?: string;
309
+ parameters?: {
310
+ [key: string]: object;
311
+ };
312
+ title?: string;
313
+ status?: StatusType;
314
+ detail?: string;
315
+ };
316
+ } | {
317
+ status: 500;
318
+ data: {
319
+ instance?: string;
320
+ "type"?: string;
321
+ parameters?: {
322
+ [key: string]: object;
323
+ };
324
+ title?: string;
325
+ status?: StatusType;
326
+ detail?: string;
327
+ };
328
+ }>("/v2/applications", oazapfts.json({
329
+ ...opts,
330
+ method: "POST",
331
+ body: applicationDtov2
332
+ })));
333
+ }
334
+ export function stopApplication({ applicationId, runtimeId }: {
335
+ applicationId: string;
336
+ runtimeId: string;
337
+ }, opts?: Oazapfts.RequestOpts) {
338
+ return oazapfts.ok(oazapfts.fetchJson<{
339
+ status: 200;
340
+ data: object;
341
+ } | {
342
+ status: 422;
343
+ data: {
344
+ instance?: string;
345
+ "type"?: string;
346
+ parameters?: {
347
+ [key: string]: object;
348
+ };
349
+ title?: string;
350
+ status?: StatusType;
351
+ detail?: string;
352
+ };
353
+ } | {
354
+ status: 500;
355
+ data: {
356
+ instance?: string;
357
+ "type"?: string;
358
+ parameters?: {
359
+ [key: string]: object;
360
+ };
361
+ title?: string;
362
+ status?: StatusType;
363
+ detail?: string;
364
+ };
365
+ }>(`/v2/applications/stop${QS.query(QS.explode({
366
+ applicationId,
367
+ runtimeId
368
+ }))}`, {
369
+ ...opts,
370
+ method: "POST"
371
+ }));
372
+ }
373
+ export function startApplication({ applicationId, runtimeId }: {
374
+ applicationId: string;
375
+ runtimeId: string;
376
+ }, opts?: Oazapfts.RequestOpts) {
377
+ return oazapfts.ok(oazapfts.fetchJson<{
378
+ status: 200;
379
+ data: object;
380
+ } | {
381
+ status: 422;
382
+ data: {
383
+ instance?: string;
384
+ "type"?: string;
385
+ parameters?: {
386
+ [key: string]: object;
387
+ };
388
+ title?: string;
389
+ status?: StatusType;
390
+ detail?: string;
391
+ };
392
+ } | {
393
+ status: 500;
394
+ data: {
395
+ instance?: string;
396
+ "type"?: string;
397
+ parameters?: {
398
+ [key: string]: object;
399
+ };
400
+ title?: string;
401
+ status?: StatusType;
402
+ detail?: string;
403
+ };
404
+ }>(`/v2/applications/start${QS.query(QS.explode({
405
+ applicationId,
406
+ runtimeId
407
+ }))}`, {
408
+ ...opts,
409
+ method: "POST"
410
+ }));
411
+ }
412
+ export function createRuntimeTag({ tagId, runtimeId }: {
413
+ tagId: string;
414
+ runtimeId: string;
415
+ }, opts?: Oazapfts.RequestOpts) {
416
+ return oazapfts.ok(oazapfts.fetchJson<{
417
+ status: 200;
418
+ data: object;
419
+ } | {
420
+ status: 422;
421
+ data: {
422
+ instance?: string;
423
+ "type"?: string;
424
+ parameters?: {
425
+ [key: string]: object;
426
+ };
427
+ title?: string;
428
+ status?: StatusType;
429
+ detail?: string;
430
+ };
431
+ } | {
432
+ status: 500;
433
+ data: {
434
+ instance?: string;
435
+ "type"?: string;
436
+ parameters?: {
437
+ [key: string]: object;
438
+ };
439
+ title?: string;
440
+ status?: StatusType;
441
+ detail?: string;
442
+ };
443
+ }>(`/v1/tags/${encodeURIComponent(tagId)}/${encodeURIComponent(runtimeId)}`, {
444
+ ...opts,
445
+ method: "POST"
446
+ }));
447
+ }
448
+ export function createDeployment1({ createDeploymentRequest }: {
449
+ createDeploymentRequest: CreateDeploymentRequest;
450
+ }, opts?: Oazapfts.RequestOpts) {
451
+ return oazapfts.ok(oazapfts.fetchJson<{
452
+ status: 200;
453
+ data: object;
454
+ } | {
455
+ status: 422;
456
+ data: {
457
+ instance?: string;
458
+ "type"?: string;
459
+ parameters?: {
460
+ [key: string]: object;
461
+ };
462
+ title?: string;
463
+ status?: StatusType;
464
+ detail?: string;
465
+ };
466
+ } | {
467
+ status: 500;
468
+ data: {
469
+ instance?: string;
470
+ "type"?: string;
471
+ parameters?: {
472
+ [key: string]: object;
473
+ };
474
+ title?: string;
475
+ status?: StatusType;
476
+ detail?: string;
477
+ };
478
+ }>("/v1/deployments", oazapfts.json({
479
+ ...opts,
480
+ method: "POST",
481
+ body: createDeploymentRequest
482
+ })));
483
+ }
484
+ export function getNamespace(opts?: Oazapfts.RequestOpts) {
485
+ return oazapfts.ok(oazapfts.fetchJson<{
486
+ status: 200;
487
+ data: string;
488
+ } | {
489
+ status: 422;
490
+ data: {
491
+ instance?: string;
492
+ "type"?: string;
493
+ parameters?: {
494
+ [key: string]: object;
495
+ };
496
+ title?: string;
497
+ status?: StatusType;
498
+ detail?: string;
499
+ };
500
+ } | {
501
+ status: 500;
502
+ data: {
503
+ instance?: string;
504
+ "type"?: string;
505
+ parameters?: {
506
+ [key: string]: object;
507
+ };
508
+ title?: string;
509
+ status?: StatusType;
510
+ detail?: string;
511
+ };
512
+ }>("/v1/deployments/namespace", {
513
+ ...opts
514
+ }));
515
+ }
516
+ export function createNamespace(opts?: Oazapfts.RequestOpts) {
517
+ return oazapfts.ok(oazapfts.fetchJson<{
518
+ status: 200;
519
+ data: string;
520
+ } | {
521
+ status: 422;
522
+ data: {
523
+ instance?: string;
524
+ "type"?: string;
525
+ parameters?: {
526
+ [key: string]: object;
527
+ };
528
+ title?: string;
529
+ status?: StatusType;
530
+ detail?: string;
531
+ };
532
+ } | {
533
+ status: 500;
534
+ data: {
535
+ instance?: string;
536
+ "type"?: string;
537
+ parameters?: {
538
+ [key: string]: object;
539
+ };
540
+ title?: string;
541
+ status?: StatusType;
542
+ detail?: string;
543
+ };
544
+ }>("/v1/deployments/namespace", {
545
+ ...opts,
546
+ method: "POST"
547
+ }));
548
+ }
549
+ export function createApplication1({ applicationDto }: {
550
+ applicationDto: ApplicationDto;
551
+ }, opts?: Oazapfts.RequestOpts) {
552
+ return oazapfts.ok(oazapfts.fetchJson<{
553
+ status: 200;
554
+ data: CreateApplicationResponse;
555
+ } | {
556
+ status: 422;
557
+ data: {
558
+ instance?: string;
559
+ "type"?: string;
560
+ parameters?: {
561
+ [key: string]: object;
562
+ };
563
+ title?: string;
564
+ status?: StatusType;
565
+ detail?: string;
566
+ };
567
+ } | {
568
+ status: 500;
569
+ data: {
570
+ instance?: string;
571
+ "type"?: string;
572
+ parameters?: {
573
+ [key: string]: object;
574
+ };
575
+ title?: string;
576
+ status?: StatusType;
577
+ detail?: string;
578
+ };
579
+ }>("/v1/applications", oazapfts.json({
580
+ ...opts,
581
+ method: "POST",
582
+ body: applicationDto
583
+ })));
584
+ }
585
+ export function getRuntimeByUlid({ runtimeId }: {
586
+ runtimeId: string;
587
+ }, opts?: Oazapfts.RequestOpts) {
588
+ return oazapfts.ok(oazapfts.fetchJson<{
589
+ status: 200;
590
+ data: RuntimeDtov2;
591
+ } | {
592
+ status: 422;
593
+ data: {
594
+ instance?: string;
595
+ "type"?: string;
596
+ parameters?: {
597
+ [key: string]: object;
598
+ };
599
+ title?: string;
600
+ status?: StatusType;
601
+ detail?: string;
602
+ };
603
+ } | {
604
+ status: 500;
605
+ data: {
606
+ instance?: string;
607
+ "type"?: string;
608
+ parameters?: {
609
+ [key: string]: object;
610
+ };
611
+ title?: string;
612
+ status?: StatusType;
613
+ detail?: string;
614
+ };
615
+ }>(`/v2/runtimes/${encodeURIComponent(runtimeId)}`, {
616
+ ...opts
617
+ }));
618
+ }
619
+ export function listRepositories({ limit, offset }: {
620
+ limit?: number;
621
+ offset?: number;
622
+ }, opts?: Oazapfts.RequestOpts) {
623
+ return oazapfts.ok(oazapfts.fetchJson<{
624
+ status: 200;
625
+ data: object;
626
+ } | {
627
+ status: 422;
628
+ data: {
629
+ instance?: string;
630
+ "type"?: string;
631
+ parameters?: {
632
+ [key: string]: object;
633
+ };
634
+ title?: string;
635
+ status?: StatusType;
636
+ detail?: string;
637
+ };
638
+ } | {
639
+ status: 500;
640
+ data: {
641
+ instance?: string;
642
+ "type"?: string;
643
+ parameters?: {
644
+ [key: string]: object;
645
+ };
646
+ title?: string;
647
+ status?: StatusType;
648
+ detail?: string;
649
+ };
650
+ }>(`/v2/registries/repositories${QS.query(QS.explode({
651
+ limit,
652
+ offset
653
+ }))}`, {
654
+ ...opts
655
+ }));
656
+ }
657
+ export function getRepositoryImages({ repositoryId }: {
658
+ repositoryId: string;
659
+ }, opts?: Oazapfts.RequestOpts) {
660
+ return oazapfts.ok(oazapfts.fetchJson<{
661
+ status: 200;
662
+ data: object;
663
+ } | {
664
+ status: 422;
665
+ data: {
666
+ instance?: string;
667
+ "type"?: string;
668
+ parameters?: {
669
+ [key: string]: object;
670
+ };
671
+ title?: string;
672
+ status?: StatusType;
673
+ detail?: string;
674
+ };
675
+ } | {
676
+ status: 500;
677
+ data: {
678
+ instance?: string;
679
+ "type"?: string;
680
+ parameters?: {
681
+ [key: string]: object;
682
+ };
683
+ title?: string;
684
+ status?: StatusType;
685
+ detail?: string;
686
+ };
687
+ }>(`/v2/registries/repositories/${encodeURIComponent(repositoryId)}/images`, {
688
+ ...opts
689
+ }));
690
+ }
691
+ export function listRuntimes({ projectId }: {
692
+ projectId: string;
693
+ }, opts?: Oazapfts.RequestOpts) {
694
+ return oazapfts.ok(oazapfts.fetchJson<{
695
+ status: 200;
696
+ data: GetRuntimesByProjectUlidV2;
697
+ } | {
698
+ status: 422;
699
+ data: {
700
+ instance?: string;
701
+ "type"?: string;
702
+ parameters?: {
703
+ [key: string]: object;
704
+ };
705
+ title?: string;
706
+ status?: StatusType;
707
+ detail?: string;
708
+ };
709
+ } | {
710
+ status: 500;
711
+ data: {
712
+ instance?: string;
713
+ "type"?: string;
714
+ parameters?: {
715
+ [key: string]: object;
716
+ };
717
+ title?: string;
718
+ status?: StatusType;
719
+ detail?: string;
720
+ };
721
+ }>(`/v2/projects/${encodeURIComponent(projectId)}/runtimes`, {
722
+ ...opts
723
+ }));
724
+ }
725
+ export function listApplications({ projectId, limit, offset }: {
726
+ projectId: string;
727
+ limit?: number;
728
+ offset?: number;
729
+ }, opts?: Oazapfts.RequestOpts) {
730
+ return oazapfts.ok(oazapfts.fetchJson<{
731
+ status: 200;
732
+ data: PaginatedResponseApplicationDto;
733
+ } | {
734
+ status: 422;
735
+ data: {
736
+ instance?: string;
737
+ "type"?: string;
738
+ parameters?: {
739
+ [key: string]: object;
740
+ };
741
+ title?: string;
742
+ status?: StatusType;
743
+ detail?: string;
744
+ };
745
+ } | {
746
+ status: 500;
747
+ data: {
748
+ instance?: string;
749
+ "type"?: string;
750
+ parameters?: {
751
+ [key: string]: object;
752
+ };
753
+ title?: string;
754
+ status?: StatusType;
755
+ detail?: string;
756
+ };
757
+ }>(`/v2/projects/${encodeURIComponent(projectId)}/applications${QS.query(QS.explode({
758
+ limit,
759
+ offset
760
+ }))}`, {
761
+ ...opts
762
+ }));
763
+ }
764
+ export function getDeploymentStatus({ deploymentId }: {
765
+ deploymentId: string;
766
+ }, opts?: Oazapfts.RequestOpts) {
767
+ return oazapfts.ok(oazapfts.fetchJson<{
768
+ status: 200;
769
+ data: object;
770
+ } | {
771
+ status: 422;
772
+ data: {
773
+ instance?: string;
774
+ "type"?: string;
775
+ parameters?: {
776
+ [key: string]: object;
777
+ };
778
+ title?: string;
779
+ status?: StatusType;
780
+ detail?: string;
781
+ };
782
+ } | {
783
+ status: 500;
784
+ data: {
785
+ instance?: string;
786
+ "type"?: string;
787
+ parameters?: {
788
+ [key: string]: object;
789
+ };
790
+ title?: string;
791
+ status?: StatusType;
792
+ detail?: string;
793
+ };
794
+ }>(`/v2/deployments/${encodeURIComponent(deploymentId)}/status`, {
795
+ ...opts
796
+ }));
797
+ }
798
+ export function getDeploymentLogs({ deploymentId }: {
799
+ deploymentId: string;
800
+ }, opts?: Oazapfts.RequestOpts) {
801
+ return oazapfts.ok(oazapfts.fetchJson<{
802
+ status: 200;
803
+ data: GetDeploymentLogsResponse;
804
+ } | {
805
+ status: 422;
806
+ data: {
807
+ instance?: string;
808
+ "type"?: string;
809
+ parameters?: {
810
+ [key: string]: object;
811
+ };
812
+ title?: string;
813
+ status?: StatusType;
814
+ detail?: string;
815
+ };
816
+ } | {
817
+ status: 500;
818
+ data: {
819
+ instance?: string;
820
+ "type"?: string;
821
+ parameters?: {
822
+ [key: string]: object;
823
+ };
824
+ title?: string;
825
+ status?: StatusType;
826
+ detail?: string;
827
+ };
828
+ }>(`/v2/deployments/${encodeURIComponent(deploymentId)}/logs`, {
829
+ ...opts
830
+ }));
831
+ }
832
+ export function getDeploymentHealth({ deploymentId }: {
833
+ deploymentId: string;
834
+ }, opts?: Oazapfts.RequestOpts) {
835
+ return oazapfts.ok(oazapfts.fetchJson<{
836
+ status: 200;
837
+ data: object;
838
+ } | {
839
+ status: 422;
840
+ data: {
841
+ instance?: string;
842
+ "type"?: string;
843
+ parameters?: {
844
+ [key: string]: object;
845
+ };
846
+ title?: string;
847
+ status?: StatusType;
848
+ detail?: string;
849
+ };
850
+ } | {
851
+ status: 500;
852
+ data: {
853
+ instance?: string;
854
+ "type"?: string;
855
+ parameters?: {
856
+ [key: string]: object;
857
+ };
858
+ title?: string;
859
+ status?: StatusType;
860
+ detail?: string;
861
+ };
862
+ }>(`/v2/deployments/${encodeURIComponent(deploymentId)}/health`, {
863
+ ...opts
864
+ }));
865
+ }
866
+ export function listDeployments({ applicationId }: {
867
+ applicationId: string;
868
+ }, opts?: Oazapfts.RequestOpts) {
869
+ return oazapfts.ok(oazapfts.fetchJson<{
870
+ status: 200;
871
+ data: object;
872
+ } | {
873
+ status: 422;
874
+ data: {
875
+ instance?: string;
876
+ "type"?: string;
877
+ parameters?: {
878
+ [key: string]: object;
879
+ };
880
+ title?: string;
881
+ status?: StatusType;
882
+ detail?: string;
883
+ };
884
+ } | {
885
+ status: 500;
886
+ data: {
887
+ instance?: string;
888
+ "type"?: string;
889
+ parameters?: {
890
+ [key: string]: object;
891
+ };
892
+ title?: string;
893
+ status?: StatusType;
894
+ detail?: string;
895
+ };
896
+ }>(`/v2/deployments/${encodeURIComponent(applicationId)}`, {
897
+ ...opts
898
+ }));
899
+ }
900
+ export function getApplicationHistory({ projectId, limit, offset }: {
901
+ projectId: string;
902
+ limit?: number;
903
+ offset?: number;
904
+ }, opts?: Oazapfts.RequestOpts) {
905
+ return oazapfts.ok(oazapfts.fetchJson<{
906
+ status: 200;
907
+ } | {
908
+ status: 422;
909
+ data: {
910
+ instance?: string;
911
+ "type"?: string;
912
+ parameters?: {
913
+ [key: string]: object;
914
+ };
915
+ title?: string;
916
+ status?: StatusType;
917
+ detail?: string;
918
+ };
919
+ } | {
920
+ status: 500;
921
+ data: {
922
+ instance?: string;
923
+ "type"?: string;
924
+ parameters?: {
925
+ [key: string]: object;
926
+ };
927
+ title?: string;
928
+ status?: StatusType;
929
+ detail?: string;
930
+ };
931
+ }>(`/v2/applications/${encodeURIComponent(projectId)}/history${QS.query(QS.explode({
932
+ limit,
933
+ offset
934
+ }))}`, {
935
+ ...opts
936
+ }));
937
+ }
938
+ export function getApplication({ applicationId }: {
939
+ applicationId: string;
940
+ }, opts?: Oazapfts.RequestOpts) {
941
+ return oazapfts.ok(oazapfts.fetchJson<{
942
+ status: 200;
943
+ data: GetApplicationByUlidResponseV2;
944
+ } | {
945
+ status: 422;
946
+ data: {
947
+ instance?: string;
948
+ "type"?: string;
949
+ parameters?: {
950
+ [key: string]: object;
951
+ };
952
+ title?: string;
953
+ status?: StatusType;
954
+ detail?: string;
955
+ };
956
+ } | {
957
+ status: 500;
958
+ data: {
959
+ instance?: string;
960
+ "type"?: string;
961
+ parameters?: {
962
+ [key: string]: object;
963
+ };
964
+ title?: string;
965
+ status?: StatusType;
966
+ detail?: string;
967
+ };
968
+ }>(`/v2/applications/${encodeURIComponent(applicationId)}`, {
969
+ ...opts
970
+ }));
971
+ }
972
+ export function listApplications1({ projectId, limit, offset }: {
973
+ projectId: string;
974
+ limit?: number;
975
+ offset?: number;
976
+ }, opts?: Oazapfts.RequestOpts) {
977
+ return oazapfts.ok(oazapfts.fetchJson<{
978
+ status: 200;
979
+ data: PaginatedResponseGetApplicationByProjectResponse;
980
+ } | {
981
+ status: 422;
982
+ data: {
983
+ instance?: string;
984
+ "type"?: string;
985
+ parameters?: {
986
+ [key: string]: object;
987
+ };
988
+ title?: string;
989
+ status?: StatusType;
990
+ detail?: string;
991
+ };
992
+ } | {
993
+ status: 500;
994
+ data: {
995
+ instance?: string;
996
+ "type"?: string;
997
+ parameters?: {
998
+ [key: string]: object;
999
+ };
1000
+ title?: string;
1001
+ status?: StatusType;
1002
+ detail?: string;
1003
+ };
1004
+ }>(`/v2/applications/project/${encodeURIComponent(projectId)}${QS.query(QS.explode({
1005
+ limit,
1006
+ offset
1007
+ }))}`, {
1008
+ ...opts
1009
+ }));
1010
+ }
1011
+ export function getRuntimeByUlid1({ runtimeId }: {
1012
+ runtimeId: string;
1013
+ }, opts?: Oazapfts.RequestOpts) {
1014
+ return oazapfts.ok(oazapfts.fetchJson<{
1015
+ status: 200;
1016
+ data: GetRuntimeByUlidResponse;
1017
+ } | {
1018
+ status: 422;
1019
+ data: {
1020
+ instance?: string;
1021
+ "type"?: string;
1022
+ parameters?: {
1023
+ [key: string]: object;
1024
+ };
1025
+ title?: string;
1026
+ status?: StatusType;
1027
+ detail?: string;
1028
+ };
1029
+ } | {
1030
+ status: 500;
1031
+ data: {
1032
+ instance?: string;
1033
+ "type"?: string;
1034
+ parameters?: {
1035
+ [key: string]: object;
1036
+ };
1037
+ title?: string;
1038
+ status?: StatusType;
1039
+ detail?: string;
1040
+ };
1041
+ }>(`/v1/runtimes/${encodeURIComponent(runtimeId)}`, {
1042
+ ...opts
1043
+ }));
1044
+ }
1045
+ export function getRevisions({ applicationId }: {
1046
+ applicationId: string;
1047
+ }, opts?: Oazapfts.RequestOpts) {
1048
+ return oazapfts.ok(oazapfts.fetchJson<{
1049
+ status: 200;
1050
+ data: object;
1051
+ } | {
1052
+ status: 422;
1053
+ data: {
1054
+ instance?: string;
1055
+ "type"?: string;
1056
+ parameters?: {
1057
+ [key: string]: object;
1058
+ };
1059
+ title?: string;
1060
+ status?: StatusType;
1061
+ detail?: string;
1062
+ };
1063
+ } | {
1064
+ status: 500;
1065
+ data: {
1066
+ instance?: string;
1067
+ "type"?: string;
1068
+ parameters?: {
1069
+ [key: string]: object;
1070
+ };
1071
+ title?: string;
1072
+ status?: StatusType;
1073
+ detail?: string;
1074
+ };
1075
+ }>(`/v1/revision/${encodeURIComponent(applicationId)}`, {
1076
+ ...opts
1077
+ }));
1078
+ }
1079
+ export function list({ limit, offset }: {
1080
+ limit?: number;
1081
+ offset?: number;
1082
+ }, opts?: Oazapfts.RequestOpts) {
1083
+ return oazapfts.ok(oazapfts.fetchJson<{
1084
+ status: 200;
1085
+ data: ListResponseRegistryDto;
1086
+ } | {
1087
+ status: 422;
1088
+ data: {
1089
+ instance?: string;
1090
+ "type"?: string;
1091
+ parameters?: {
1092
+ [key: string]: object;
1093
+ };
1094
+ title?: string;
1095
+ status?: StatusType;
1096
+ detail?: string;
1097
+ };
1098
+ } | {
1099
+ status: 500;
1100
+ data: {
1101
+ instance?: string;
1102
+ "type"?: string;
1103
+ parameters?: {
1104
+ [key: string]: object;
1105
+ };
1106
+ title?: string;
1107
+ status?: StatusType;
1108
+ detail?: string;
1109
+ };
1110
+ }>(`/v1/registries${QS.query(QS.explode({
1111
+ limit,
1112
+ offset
1113
+ }))}`, {
1114
+ ...opts
1115
+ }));
1116
+ }
1117
+ export function listRepositoriesByRegistryId({ limit, offset, id }: {
1118
+ limit?: number;
1119
+ offset?: number;
1120
+ id: string;
1121
+ }, opts?: Oazapfts.RequestOpts) {
1122
+ return oazapfts.ok(oazapfts.fetchJson<{
1123
+ status: 200;
1124
+ data: RepositoryDto[];
1125
+ } | {
1126
+ status: 422;
1127
+ data: {
1128
+ instance?: string;
1129
+ "type"?: string;
1130
+ parameters?: {
1131
+ [key: string]: object;
1132
+ };
1133
+ title?: string;
1134
+ status?: StatusType;
1135
+ detail?: string;
1136
+ };
1137
+ } | {
1138
+ status: 500;
1139
+ data: {
1140
+ instance?: string;
1141
+ "type"?: string;
1142
+ parameters?: {
1143
+ [key: string]: object;
1144
+ };
1145
+ title?: string;
1146
+ status?: StatusType;
1147
+ detail?: string;
1148
+ };
1149
+ }>(`/v1/registries/${encodeURIComponent(id)}/repositories${QS.query(QS.explode({
1150
+ limit,
1151
+ offset
1152
+ }))}`, {
1153
+ ...opts
1154
+ }));
1155
+ }
1156
+ export function listRepositoriesByDefaultRegistryId({ limit, offset }: {
1157
+ limit?: number;
1158
+ offset?: number;
1159
+ }, opts?: Oazapfts.RequestOpts) {
1160
+ return oazapfts.ok(oazapfts.fetchJson<{
1161
+ status: 200;
1162
+ data: object;
1163
+ } | {
1164
+ status: 422;
1165
+ data: {
1166
+ instance?: string;
1167
+ "type"?: string;
1168
+ parameters?: {
1169
+ [key: string]: object;
1170
+ };
1171
+ title?: string;
1172
+ status?: StatusType;
1173
+ detail?: string;
1174
+ };
1175
+ } | {
1176
+ status: 500;
1177
+ data: {
1178
+ instance?: string;
1179
+ "type"?: string;
1180
+ parameters?: {
1181
+ [key: string]: object;
1182
+ };
1183
+ title?: string;
1184
+ status?: StatusType;
1185
+ detail?: string;
1186
+ };
1187
+ }>(`/v1/registries/repositories${QS.query(QS.explode({
1188
+ limit,
1189
+ offset
1190
+ }))}`, {
1191
+ ...opts
1192
+ }));
1193
+ }
1194
+ export function getImages({ repositoryName }: {
1195
+ repositoryName: string;
1196
+ }, opts?: Oazapfts.RequestOpts) {
1197
+ return oazapfts.ok(oazapfts.fetchJson<{
1198
+ status: 200;
1199
+ data: ImageDto[];
1200
+ } | {
1201
+ status: 422;
1202
+ data: {
1203
+ instance?: string;
1204
+ "type"?: string;
1205
+ parameters?: {
1206
+ [key: string]: object;
1207
+ };
1208
+ title?: string;
1209
+ status?: StatusType;
1210
+ detail?: string;
1211
+ };
1212
+ } | {
1213
+ status: 500;
1214
+ data: {
1215
+ instance?: string;
1216
+ "type"?: string;
1217
+ parameters?: {
1218
+ [key: string]: object;
1219
+ };
1220
+ title?: string;
1221
+ status?: StatusType;
1222
+ detail?: string;
1223
+ };
1224
+ }>(`/v1/registries/repositories/${encodeURIComponent(repositoryName)}/images`, {
1225
+ ...opts
1226
+ }));
1227
+ }
1228
+ export function getRepositoryById({ id, registryId }: {
1229
+ id: string;
1230
+ registryId?: string;
1231
+ }, opts?: Oazapfts.RequestOpts) {
1232
+ return oazapfts.ok(oazapfts.fetchJson<{
1233
+ status: 200;
1234
+ data: RepositoryDto;
1235
+ } | {
1236
+ status: 422;
1237
+ data: {
1238
+ instance?: string;
1239
+ "type"?: string;
1240
+ parameters?: {
1241
+ [key: string]: object;
1242
+ };
1243
+ title?: string;
1244
+ status?: StatusType;
1245
+ detail?: string;
1246
+ };
1247
+ } | {
1248
+ status: 500;
1249
+ data: {
1250
+ instance?: string;
1251
+ "type"?: string;
1252
+ parameters?: {
1253
+ [key: string]: object;
1254
+ };
1255
+ title?: string;
1256
+ status?: StatusType;
1257
+ detail?: string;
1258
+ };
1259
+ }>(`/v1/registries/repositories/${encodeURIComponent(id)}${QS.query(QS.explode({
1260
+ registryId
1261
+ }))}`, {
1262
+ ...opts
1263
+ }));
1264
+ }
1265
+ export function listRuntimes1({ projectId }: {
1266
+ projectId: string;
1267
+ }, opts?: Oazapfts.RequestOpts) {
1268
+ return oazapfts.ok(oazapfts.fetchJson<{
1269
+ status: 200;
1270
+ data: GetRuntimesByProjectUlid;
1271
+ } | {
1272
+ status: 422;
1273
+ data: {
1274
+ instance?: string;
1275
+ "type"?: string;
1276
+ parameters?: {
1277
+ [key: string]: object;
1278
+ };
1279
+ title?: string;
1280
+ status?: StatusType;
1281
+ detail?: string;
1282
+ };
1283
+ } | {
1284
+ status: 500;
1285
+ data: {
1286
+ instance?: string;
1287
+ "type"?: string;
1288
+ parameters?: {
1289
+ [key: string]: object;
1290
+ };
1291
+ title?: string;
1292
+ status?: StatusType;
1293
+ detail?: string;
1294
+ };
1295
+ }>(`/v1/projects/${encodeURIComponent(projectId)}/runtimes`, {
1296
+ ...opts
1297
+ }));
1298
+ }
1299
+ export function listApplications2({ projectId, limit, offset }: {
1300
+ projectId: string;
1301
+ limit?: number;
1302
+ offset?: number;
1303
+ }, opts?: Oazapfts.RequestOpts) {
1304
+ return oazapfts.ok(oazapfts.fetchJson<{
1305
+ status: 200;
1306
+ data: PaginatedResponseApplicationDto;
1307
+ } | {
1308
+ status: 422;
1309
+ data: {
1310
+ instance?: string;
1311
+ "type"?: string;
1312
+ parameters?: {
1313
+ [key: string]: object;
1314
+ };
1315
+ title?: string;
1316
+ status?: StatusType;
1317
+ detail?: string;
1318
+ };
1319
+ } | {
1320
+ status: 500;
1321
+ data: {
1322
+ instance?: string;
1323
+ "type"?: string;
1324
+ parameters?: {
1325
+ [key: string]: object;
1326
+ };
1327
+ title?: string;
1328
+ status?: StatusType;
1329
+ detail?: string;
1330
+ };
1331
+ }>(`/v1/projects/${encodeURIComponent(projectId)}/applications${QS.query(QS.explode({
1332
+ limit,
1333
+ offset
1334
+ }))}`, {
1335
+ ...opts
1336
+ }));
1337
+ }
1338
+ export function getDeployment({ deploymentId }: {
1339
+ deploymentId: string;
1340
+ }, opts?: Oazapfts.RequestOpts) {
1341
+ return oazapfts.ok(oazapfts.fetchJson<{
1342
+ status: 200;
1343
+ data: object;
1344
+ } | {
1345
+ status: 422;
1346
+ data: {
1347
+ instance?: string;
1348
+ "type"?: string;
1349
+ parameters?: {
1350
+ [key: string]: object;
1351
+ };
1352
+ title?: string;
1353
+ status?: StatusType;
1354
+ detail?: string;
1355
+ };
1356
+ } | {
1357
+ status: 500;
1358
+ data: {
1359
+ instance?: string;
1360
+ "type"?: string;
1361
+ parameters?: {
1362
+ [key: string]: object;
1363
+ };
1364
+ title?: string;
1365
+ status?: StatusType;
1366
+ detail?: string;
1367
+ };
1368
+ }>(`/v1/deployments/${encodeURIComponent(deploymentId)}`, {
1369
+ ...opts
1370
+ }));
1371
+ }
1372
+ export function getDeploymentStatus1({ deploymentId }: {
1373
+ deploymentId: string;
1374
+ }, opts?: Oazapfts.RequestOpts) {
1375
+ return oazapfts.ok(oazapfts.fetchJson<{
1376
+ status: 200;
1377
+ data: object;
1378
+ } | {
1379
+ status: 422;
1380
+ data: {
1381
+ instance?: string;
1382
+ "type"?: string;
1383
+ parameters?: {
1384
+ [key: string]: object;
1385
+ };
1386
+ title?: string;
1387
+ status?: StatusType;
1388
+ detail?: string;
1389
+ };
1390
+ } | {
1391
+ status: 500;
1392
+ data: {
1393
+ instance?: string;
1394
+ "type"?: string;
1395
+ parameters?: {
1396
+ [key: string]: object;
1397
+ };
1398
+ title?: string;
1399
+ status?: StatusType;
1400
+ detail?: string;
1401
+ };
1402
+ }>(`/v1/deployments/${encodeURIComponent(deploymentId)}/status`, {
1403
+ ...opts
1404
+ }));
1405
+ }
1406
+ export function getDeploymentLogs1({ deploymentId }: {
1407
+ deploymentId: string;
1408
+ }, opts?: Oazapfts.RequestOpts) {
1409
+ return oazapfts.ok(oazapfts.fetchJson<{
1410
+ status: 200;
1411
+ data: GetDeploymentLogsResponse;
1412
+ } | {
1413
+ status: 422;
1414
+ data: {
1415
+ instance?: string;
1416
+ "type"?: string;
1417
+ parameters?: {
1418
+ [key: string]: object;
1419
+ };
1420
+ title?: string;
1421
+ status?: StatusType;
1422
+ detail?: string;
1423
+ };
1424
+ } | {
1425
+ status: 500;
1426
+ data: {
1427
+ instance?: string;
1428
+ "type"?: string;
1429
+ parameters?: {
1430
+ [key: string]: object;
1431
+ };
1432
+ title?: string;
1433
+ status?: StatusType;
1434
+ detail?: string;
1435
+ };
1436
+ }>(`/v1/deployments/${encodeURIComponent(deploymentId)}/logs`, {
1437
+ ...opts
1438
+ }));
1439
+ }
1440
+ export function getDeploymentHealth1({ deploymentId }: {
1441
+ deploymentId: string;
1442
+ }, opts?: Oazapfts.RequestOpts) {
1443
+ return oazapfts.ok(oazapfts.fetchJson<{
1444
+ status: 200;
1445
+ data: object;
1446
+ } | {
1447
+ status: 422;
1448
+ data: {
1449
+ instance?: string;
1450
+ "type"?: string;
1451
+ parameters?: {
1452
+ [key: string]: object;
1453
+ };
1454
+ title?: string;
1455
+ status?: StatusType;
1456
+ detail?: string;
1457
+ };
1458
+ } | {
1459
+ status: 500;
1460
+ data: {
1461
+ instance?: string;
1462
+ "type"?: string;
1463
+ parameters?: {
1464
+ [key: string]: object;
1465
+ };
1466
+ title?: string;
1467
+ status?: StatusType;
1468
+ detail?: string;
1469
+ };
1470
+ }>(`/v1/deployments/${encodeURIComponent(deploymentId)}/health`, {
1471
+ ...opts
1472
+ }));
1473
+ }
1474
+ export function getDeploymentsId({ applicationId }: {
1475
+ applicationId: string;
1476
+ }, opts?: Oazapfts.RequestOpts) {
1477
+ return oazapfts.ok(oazapfts.fetchJson<{
1478
+ status: 200;
1479
+ data: object;
1480
+ } | {
1481
+ status: 422;
1482
+ data: {
1483
+ instance?: string;
1484
+ "type"?: string;
1485
+ parameters?: {
1486
+ [key: string]: object;
1487
+ };
1488
+ title?: string;
1489
+ status?: StatusType;
1490
+ detail?: string;
1491
+ };
1492
+ } | {
1493
+ status: 500;
1494
+ data: {
1495
+ instance?: string;
1496
+ "type"?: string;
1497
+ parameters?: {
1498
+ [key: string]: object;
1499
+ };
1500
+ title?: string;
1501
+ status?: StatusType;
1502
+ detail?: string;
1503
+ };
1504
+ }>(`/v1/deployments/applications/${encodeURIComponent(applicationId)}`, {
1505
+ ...opts
1506
+ }));
1507
+ }
1508
+ export function getApplication1({ applicationId }: {
1509
+ applicationId: string;
1510
+ }, opts?: Oazapfts.RequestOpts) {
1511
+ return oazapfts.ok(oazapfts.fetchJson<{
1512
+ status: 200;
1513
+ data: GetApplicationByUlidResponse;
1514
+ } | {
1515
+ status: 422;
1516
+ data: {
1517
+ instance?: string;
1518
+ "type"?: string;
1519
+ parameters?: {
1520
+ [key: string]: object;
1521
+ };
1522
+ title?: string;
1523
+ status?: StatusType;
1524
+ detail?: string;
1525
+ };
1526
+ } | {
1527
+ status: 500;
1528
+ data: {
1529
+ instance?: string;
1530
+ "type"?: string;
1531
+ parameters?: {
1532
+ [key: string]: object;
1533
+ };
1534
+ title?: string;
1535
+ status?: StatusType;
1536
+ detail?: string;
1537
+ };
1538
+ }>(`/v1/applications/${encodeURIComponent(applicationId)}`, {
1539
+ ...opts
1540
+ }));
1541
+ }
1542
+ export function deleteDeployment({ id }: {
1543
+ id: string;
1544
+ }, opts?: Oazapfts.RequestOpts) {
1545
+ return oazapfts.ok(oazapfts.fetchJson<{
1546
+ status: 200;
1547
+ } | {
1548
+ status: 422;
1549
+ data: {
1550
+ instance?: string;
1551
+ "type"?: string;
1552
+ parameters?: {
1553
+ [key: string]: object;
1554
+ };
1555
+ title?: string;
1556
+ status?: StatusType;
1557
+ detail?: string;
1558
+ };
1559
+ } | {
1560
+ status: 500;
1561
+ data: {
1562
+ instance?: string;
1563
+ "type"?: string;
1564
+ parameters?: {
1565
+ [key: string]: object;
1566
+ };
1567
+ title?: string;
1568
+ status?: StatusType;
1569
+ detail?: string;
1570
+ };
1571
+ }>(`/v1/deployments/${encodeURIComponent(id)}`, {
1572
+ ...opts,
1573
+ method: "DELETE"
1574
+ }));
1575
+ }