@stack-spot/portal-network 0.236.0 → 0.237.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,11 +8,11 @@ import * as Oazapfts from "@oazapfts/runtime";
8
8
  import * as QS from "@oazapfts/runtime/query";
9
9
  export const defaults: Oazapfts.Defaults<Oazapfts.CustomHeaders> = {
10
10
  headers: {},
11
- baseUrl: "https://api.platform.zup.corp",
11
+ baseUrl: "https://api.platform.stg.zup.corp",
12
12
  };
13
13
  const oazapfts = Oazapfts.runtime(defaults);
14
14
  export const servers = {
15
- generatedServerUrl: "https://api.platform.zup.corp"
15
+ generatedServerUrl: "https://api.platform.stg.zup.corp"
16
16
  };
17
17
  export type Tag = {
18
18
  key: string;
@@ -23,299 +23,52 @@ export type Target = {
23
23
  projectIds: string[];
24
24
  };
25
25
  export type JsonNode = any;
26
- export type RoleMetadata = {
27
- creationTimestamp?: string;
28
- deletionTimestamp?: string;
26
+ export type ResourceMetadata = {
27
+ id: string;
29
28
  name: string;
29
+ labels: {
30
+ [key: string]: string;
31
+ };
32
+ creationTimestamp: string;
33
+ deletionTimestamp?: string;
34
+ uid?: string;
30
35
  };
31
- export type RoleSpecPermission = {
36
+ export type Permission = {
32
37
  create: boolean;
33
38
  read: boolean;
34
39
  update: boolean;
35
40
  "delete": boolean;
36
41
  };
37
42
  export type RoleSpec = {
38
- boundary: RoleSpecPermission;
39
- boundarySSO: RoleSpecPermission;
40
- certificate: RoleSpecPermission;
41
- cidr: RoleSpecPermission;
42
- dnsRecord: RoleSpecPermission;
43
- dnsZone: RoleSpecPermission;
44
- fmsPolicy: RoleSpecPermission;
45
- folder: RoleSpecPermission;
46
- foundation: RoleSpecPermission;
47
- iamIdentityCenter: RoleSpecPermission;
48
- network: RoleSpecPermission;
49
- project: RoleSpecPermission;
50
- role: RoleSpecPermission;
51
- serviceControlPolicy: RoleSpecPermission;
52
- vpn: RoleSpecPermission;
53
- };
54
- export type Role = {
55
- metadata: RoleMetadata;
56
- spec: RoleSpec;
57
- };
58
- export type TunnelStatus = {
59
- tunnel1?: string;
60
- tunnel2?: string;
61
- };
62
- export type VpnDetails = {
63
- peerCustomerGatewayIp: string;
64
- destinationCidrBlock: string;
65
- tunnelStatus: TunnelStatus;
66
- };
67
- export type VpnResponse = {
68
- stackSpotAccountId: string;
69
- foundationId: string;
70
- vpnId: string;
71
- details: VpnDetails;
72
- tags: Tag[];
73
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
74
- createdAt: string;
75
- updatedAt: string;
76
- deletedAt?: string;
77
- };
78
- export type ServiceControlPolicyMetadata = {
79
- creationTimestamp?: string;
80
- deletionTimestamp?: string;
81
- /** Universally Unique Lexicographically Sortable Identifier */
82
- id?: string;
83
- };
84
- export type ServiceControlPolicySpecTarget = {
85
- folderIds: string[];
86
- projectIds: string[];
87
- };
88
- export type ServiceControlPolicySpec = {
89
- /** Universally Unique Lexicographically Sortable Identifier */
90
- foundationId: string;
91
43
  name: string;
92
- description: string;
93
- content: string;
94
- target: ServiceControlPolicySpecTarget;
95
- tags: Tag[];
44
+ boundary: Permission;
45
+ boundarySSO: Permission;
46
+ certificate: Permission;
47
+ cidr: Permission;
48
+ dnsRecord: Permission;
49
+ dnsZone: Permission;
50
+ fmsPolicy: Permission;
51
+ folder: Permission;
52
+ foundation: Permission;
53
+ iamIdentityCenter: Permission;
54
+ network: Permission;
55
+ project: Permission;
56
+ role: Permission;
57
+ serviceControlPolicy: Permission;
58
+ vpn: Permission;
96
59
  };
97
- export type ServiceControlPolicyStatus = {
98
- state: "READY" | "PENDING" | "DELETING" | "ERROR";
60
+ export type ResourceCondition = {
61
+ state: "READY" | "PENDING" | "ERROR" | "UNKNOWN" | "DELETING";
62
+ lastUpdateTimestamp: string;
99
63
  message?: string;
100
- lastUpdateTimestamp?: string;
101
- };
102
- export type ServiceControlPolicy = {
103
- metadata?: ServiceControlPolicyMetadata;
104
- spec: ServiceControlPolicySpec;
105
- status?: ServiceControlPolicyStatus;
106
- };
107
- export type SecTool = {
108
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
109
- };
110
- export type SecTools = {
111
- guardDuty: SecTool;
112
- inspector: SecTool;
113
- securityHub: SecTool;
114
- };
115
- export type FoundationDetails = {
116
- name: string;
117
- description: string;
118
- cloudProvider: string;
119
- region: string;
120
- secTools: SecTools;
121
- secProjectTags: Tag[];
122
- };
123
- export type FoundationResponse = {
124
- stackSpotAccountId: string;
125
- foundationId: string;
126
- foundationName: string;
127
- details: FoundationDetails;
128
- tags: Tag[];
129
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
130
- createdAt: string;
131
- updatedAt: string;
132
- deletedAt?: string;
133
- };
134
- export type ProjectDetails = {
135
- name: string;
136
- folderName: string;
137
- providerAccountId?: string;
138
- };
139
- export type ProjectResponse = {
140
- stackSpotAccountId: string;
141
- foundationId: string;
142
- parentFolderId: string;
143
- projectId: string;
144
- details: ProjectDetails;
145
- tags: Tag[];
146
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
147
- createdAt: string;
148
- updatedAt: string;
149
- deletedAt?: string;
150
- };
151
- export type NetworkSubnetDetails = {
152
- az?: string;
153
- cidr?: string;
154
- id?: string;
155
- "type": "NAT" | "PRIVATE" | "PUBLIC";
156
- };
157
- export type NetworkDetails = {
158
- cidrs?: string[];
159
- name: string;
160
- "type": "WORKLOAD" | "OUTBOUND" | "CORE";
161
- subnets: NetworkSubnetDetails[];
162
- };
163
- export type NetworkResponse = {
164
- stackSpotAccountId: string;
165
- foundationId: string;
166
- projectId: string;
167
- networkId: string;
168
- details: NetworkDetails;
169
- tags: Tag[];
170
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
171
- createdAt: string;
172
- updatedAt: string;
173
- deletedAt?: string;
174
- };
175
- export type FolderContent = {
176
- "type": "FOLDER" | "PROJECT";
177
- id: string;
178
- name: string;
179
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
180
- };
181
- export type FolderDetails = {
182
- name: string;
183
- pendingResources: boolean;
184
- content: FolderContent[];
185
- };
186
- export type FolderResponse = {
187
- stackSpotAccountId: string;
188
- foundationId: string;
189
- parentFolderId: string;
190
- folderId: string;
191
- details: FolderDetails;
192
- tags: Tag[];
193
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
194
- createdAt: string;
195
- updatedAt: string;
196
- deletedAt?: string;
197
- };
198
- export type DnsZoneDetails = {
199
- domain: string;
200
- dnsZoneType: string;
201
- };
202
- export type DnsZoneResponse = {
203
- stackSpotAccountId: string;
204
- foundationId: string;
205
- dnsZoneId: string;
206
- details: DnsZoneDetails;
207
- tags: Tag[];
208
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
209
- createdAt: string;
210
- updatedAt: string;
211
- deletedAt?: string;
212
- };
213
- export type DnsRecordDetails = {
214
- recordName: string;
215
- records: string[];
216
- ttl: number;
217
- "type": "A" | "AAAA" | "CAA" | "CNAME" | "MX" | "PTR" | "SOA" | "SRV" | "TXT";
218
- dnsZoneName: string;
219
- };
220
- export type DnsRecordResponse = {
221
- stackSpotAccountId: string;
222
- foundationId: string;
223
- dnsZoneId: string;
224
- dnsRecordId: string;
225
- details: DnsRecordDetails;
226
- tags: Tag[];
227
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
228
- createdAt: string;
229
- updatedAt: string;
230
- deletedAt?: string;
231
- };
232
- export type CidrDetails = {
233
- cidrNotation: string;
234
- networkAddress: string;
235
- netmask: string;
236
- broadcastAddress: string;
237
- lowAddress: string;
238
- highAddress: string;
239
- addressCount: number;
240
- };
241
- export type CidrResponse = {
242
- stackSpotAccountId: string;
243
- foundationId: string;
244
- cidrId: string;
245
- details: CidrDetails;
246
- tags: Tag[];
247
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
248
- createdAt: string;
249
- updatedAt: string;
250
- deletedAt?: string;
251
- };
252
- export type CertificateDomainValidation = {
253
- domainName?: string;
254
- recordName?: string;
255
- recordType?: string;
256
- recordValue?: string;
257
- };
258
- export type CertificateDetails = {
259
- name: string;
260
- forInbound: "TRUE" | "FALSE";
261
- certificateStatus?: string;
262
- domainName?: string;
263
- domainValidation?: CertificateDomainValidation[];
264
- notAfter?: string;
265
- notBefore?: string;
266
- "type"?: string;
267
- validationMethod?: string;
268
- };
269
- export type CertificateResponse = {
270
- stackSpotAccountId: string;
271
- foundationId: string;
272
- certificateId: string;
273
- details: CertificateDetails;
274
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
275
- tags: Tag[];
276
- createdAt: string;
277
- updatedAt: string;
278
- deletedAt?: string;
279
- };
280
- export type BoundaryDetails = {
281
- name: string;
282
- description: string;
283
- policyDocument: string;
284
64
  };
285
- export type BoundaryResponse = {
286
- foundationId: string;
287
- boundaryId: string;
288
- details: BoundaryDetails;
289
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
290
- tags: Tag[];
291
- createdAt: string;
292
- updatedAt: string;
293
- deletedAt?: string;
294
- };
295
- export type BoundarySsoDetails = {
296
- name: string;
297
- description: string;
298
- policyDocument: string;
299
- };
300
- export type BoundarySsoResponse = {
301
- foundationId: string;
302
- boundarySSOId: string;
303
- details: BoundarySsoDetails;
304
- status: "READY" | "PENDING" | "DELETING" | "ERROR";
305
- tags: Tag[];
306
- createdAt: string;
307
- updatedAt: string;
308
- deletedAt?: string;
65
+ export type ResourceStatus = {
66
+ condition: ResourceCondition;
309
67
  };
310
- export type ResourceMetadata = {
311
- id: string;
312
- name: string;
313
- labels: {
314
- [key: string]: string;
315
- };
316
- creationTimestamp: string;
317
- deletionTimestamp?: string;
318
- uid?: string;
68
+ export type Role = {
69
+ metadata: ResourceMetadata;
70
+ spec: RoleSpec;
71
+ status?: ResourceStatus;
319
72
  };
320
73
  export type FoundationSpec = {
321
74
  region: string;
@@ -328,11 +81,6 @@ export type FoundationSpec = {
328
81
  tags: Tag[];
329
82
  secAccountTags: Tag[];
330
83
  };
331
- export type ResourceCondition = {
332
- state: "READY" | "PENDING" | "ERROR" | "UNKNOWN" | "DELETING";
333
- lastUpdateTimestamp: string;
334
- message?: string;
335
- };
336
84
  export type Pool = {
337
85
  arn?: string;
338
86
  id?: string;
@@ -380,10 +128,19 @@ export type CoreAccounts = {
380
128
  secSharedServices?: CoreAccount;
381
129
  secTransit?: CoreAccount;
382
130
  };
131
+ export type SecTool = {
132
+ status?: "READY" | "PENDING" | "ERROR" | "UNKNOWN" | "DELETING";
133
+ };
134
+ export type SecTools = {
135
+ guardDuty?: SecTool;
136
+ inspector?: SecTool;
137
+ securityHub?: SecTool;
138
+ };
383
139
  export type FoundationStatus = {
384
140
  condition: ResourceCondition;
385
141
  coreAccounts?: CoreAccounts;
386
142
  orgRootId?: string;
143
+ preMortenOUId?: string;
387
144
  secTools?: SecTools;
388
145
  };
389
146
  export type Foundation = {
@@ -400,14 +157,38 @@ export type VpnSpec = {
400
157
  peerCustomerGatewayIp: string;
401
158
  tags: Tag[];
402
159
  };
160
+ export type VpnConfiguration = {
161
+ ikev1?: string;
162
+ ikev2?: string;
163
+ };
403
164
  export type VpnStatus = {
404
165
  condition: ResourceCondition;
166
+ customerGatewayId?: string;
167
+ vpnGatewayId?: string;
168
+ tunnelStatus?: string[];
169
+ configuration?: VpnConfiguration;
405
170
  };
406
171
  export type Vpn = {
407
172
  metadata: ResourceMetadata;
408
173
  spec: VpnSpec;
409
174
  status?: VpnStatus;
410
175
  };
176
+ export type ServiceControlPolicySpec = {
177
+ foundationRef: FoundationRef;
178
+ name: string;
179
+ description: string;
180
+ content: JsonNode;
181
+ target: Target;
182
+ tags: Tag[];
183
+ };
184
+ export type ServiceControlPolicyStatus = {
185
+ condition: ResourceCondition;
186
+ };
187
+ export type ServiceControlPolicy = {
188
+ metadata: ResourceMetadata;
189
+ spec: ServiceControlPolicySpec;
190
+ status?: ServiceControlPolicyStatus;
191
+ };
411
192
  export type FolderRef = {
412
193
  name: string;
413
194
  };
@@ -829,169 +610,6 @@ export type AccountAssignment = {
829
610
  spec: AccountAssignmentSpec;
830
611
  status?: AccountAssignmentStatus;
831
612
  };
832
- export type ListRole = {
833
- content: Role[];
834
- };
835
- export type ListFoundationResponse = {
836
- stackSpotAccountId: string;
837
- pendingResources: boolean;
838
- content: FoundationResponse[];
839
- };
840
- export type CreateFoundationRequest = {
841
- name: string;
842
- description: string;
843
- cloudProvider: string;
844
- region: string;
845
- masterAccountId: string;
846
- auditAccountId: string;
847
- prefix: string;
848
- orgId: string;
849
- portfolioId: string;
850
- logArchiveAccountId: string;
851
- };
852
- export type ListVpnResponse = {
853
- stackSpotAccountId: string;
854
- foundationId: string;
855
- pendingResources: boolean;
856
- content: VpnResponse[];
857
- };
858
- export type CreateVpnRequest = {
859
- peerCustomerGatewayIp: string;
860
- destinationCidrBlock: string;
861
- tags?: Tag[];
862
- };
863
- export type ListServiceControlPolicy = {
864
- /** Universally Unique Lexicographically Sortable Identifier */
865
- foundationId?: string;
866
- pendingResources: boolean;
867
- content: ServiceControlPolicy[];
868
- };
869
- export type ListProjectResponse = {
870
- stackSpotAccountId: string;
871
- foundationId: string;
872
- parentFolderId?: string;
873
- pendingResources: boolean;
874
- content: ProjectResponse[];
875
- };
876
- export type CreateProjectRequest = {
877
- parentFolderId: string;
878
- name: string;
879
- description: string;
880
- tags?: Tag[];
881
- };
882
- export type ListNetworkResponse = {
883
- stackSpotAccountId: string;
884
- foundationId: string;
885
- projectId?: string;
886
- pendingResources: boolean;
887
- content: NetworkResponse[];
888
- };
889
- export type CreateNetworkRequest = {
890
- projectId: string;
891
- prefixLength: number;
892
- name: string;
893
- "type": "WORKLOAD" | "OUTBOUND" | "CORE";
894
- tags?: Tag[];
895
- };
896
- export type CreateFolderRequest = {
897
- parentFolderId: string;
898
- name: string;
899
- tags?: Tag[];
900
- };
901
- export type ListDnsZoneResponse = {
902
- stackSpotAccountId: string;
903
- foundationId: string;
904
- pendingResources: boolean;
905
- content: DnsZoneResponse[];
906
- };
907
- export type CreateDnsZoneRequest = {
908
- domain: string;
909
- "type": "PUBLIC" | "PRIVATE";
910
- projectId?: string;
911
- tags?: Tag[];
912
- };
913
- export type ListDnsRecordResponse = {
914
- stackSpotAccountId: string;
915
- foundationId: string;
916
- projectId?: string;
917
- dnsZoneId?: string;
918
- pendingResources: boolean;
919
- content: DnsRecordResponse[];
920
- };
921
- export type CreateDnsRecordRequest = {
922
- dnsZoneId: string;
923
- projectId?: string;
924
- recordName: string;
925
- records: string[];
926
- ttl: number;
927
- "type": "A" | "AAAA" | "CAA" | "CNAME" | "MX" | "PTR" | "SOA" | "SRV" | "TXT";
928
- };
929
- export type ListCidrResponse = {
930
- stackSpotAccountId: string;
931
- foundationId: string;
932
- pendingResources: boolean;
933
- content: CidrResponse[];
934
- };
935
- export type CreateCidrRequest = {
936
- address: string;
937
- prefix: number;
938
- tags?: Tag[];
939
- };
940
- export type ListCertificateResponse = {
941
- stackSpotAccountId: string;
942
- foundationId: string;
943
- pendingResources: boolean;
944
- content: CertificateResponse[];
945
- };
946
- export type CreateCertificateRequestBase = {
947
- tags?: Tag[];
948
- certificateName: string;
949
- forInbound: "TRUE" | "FALSE";
950
- "type": string;
951
- };
952
- export type CreatePublicCertificateRequest = {
953
- "type": "CreatePublicCertificateRequest";
954
- } & CreateCertificateRequestBase & {
955
- domainName: string;
956
- };
957
- export type ImportCertificateRequest = {
958
- "type": "ImportCertificateRequest";
959
- } & CreateCertificateRequestBase & {
960
- certificateBody: string;
961
- certificatePrivateKey: string;
962
- certificateChain?: string;
963
- };
964
- export type ListBoundaryResponse = {
965
- foundationId: string;
966
- pendingResources: boolean;
967
- content: BoundaryResponse[];
968
- };
969
- export type CreateBoundaryRequest = {
970
- name: string;
971
- description: string;
972
- policyDocument: JsonNode;
973
- tags: Tag[];
974
- };
975
- export type ListBoundarySsoResponse = {
976
- foundationId: string;
977
- pendingResources: boolean;
978
- content: BoundarySsoResponse[];
979
- };
980
- export type CreateBoundarySsoRequest = {
981
- name: string;
982
- description: string;
983
- policyDocument: JsonNode;
984
- tags: Tag[];
985
- };
986
- export type Configuration = {
987
- ikev1: string;
988
- ikev2: string;
989
- };
990
- export type VpnConfigurationResponse = {
991
- vpnId: string;
992
- foundationId: string;
993
- configuration: Configuration;
994
- };
995
613
  export function vpnControllerPutTags({ $namespace, name, body }: {
996
614
  $namespace: string;
997
615
  name: string;
@@ -1058,6 +676,16 @@ export function serviceControlPolicyControllerPutContent({ $namespace, name, jso
1058
676
  body: jsonNode
1059
677
  })));
1060
678
  }
679
+ export function foundationControllerPutSecProjectTags({ $namespace, body }: {
680
+ $namespace: string;
681
+ body: Tag[];
682
+ }, opts?: Oazapfts.RequestOpts) {
683
+ return oazapfts.ok(oazapfts.fetchText(`/v2/foundations/${encodeURIComponent($namespace)}/sec-project-tags`, oazapfts.json({
684
+ ...opts,
685
+ method: "PUT",
686
+ body
687
+ })));
688
+ }
1061
689
  export function projectControllerPutTags({ $namespace, name, body }: {
1062
690
  $namespace: string;
1063
691
  name: string;
@@ -1190,6 +818,17 @@ export function boundarySsoControllerPutTags({ $namespace, name, body }: {
1190
818
  body
1191
819
  })));
1192
820
  }
821
+ export function boundarySsoControllerPutPolicyDocument({ $namespace, name, jsonNode }: {
822
+ $namespace: string;
823
+ name: string;
824
+ jsonNode: JsonNode;
825
+ }, opts?: Oazapfts.RequestOpts) {
826
+ return oazapfts.ok(oazapfts.fetchText(`/v2/foundations/${encodeURIComponent($namespace)}/boundary-ssos/${encodeURIComponent(name)}/policy-document`, oazapfts.json({
827
+ ...opts,
828
+ method: "PUT",
829
+ body: jsonNode
830
+ })));
831
+ }
1193
832
  export function boundaryControllerPutTags({ $namespace, name, body }: {
1194
833
  $namespace: string;
1195
834
  name: string;
@@ -1201,393 +840,79 @@ export function boundaryControllerPutTags({ $namespace, name, body }: {
1201
840
  body
1202
841
  })));
1203
842
  }
1204
- export function getRole({ roleName }: {
1205
- roleName: string;
843
+ export function boundaryControllerPutPolicyDocument({ $namespace, name, jsonNode }: {
844
+ $namespace: string;
845
+ name: string;
846
+ jsonNode: JsonNode;
1206
847
  }, opts?: Oazapfts.RequestOpts) {
848
+ return oazapfts.ok(oazapfts.fetchText(`/v2/foundations/${encodeURIComponent($namespace)}/boundaries/${encodeURIComponent(name)}/policy-document`, oazapfts.json({
849
+ ...opts,
850
+ method: "PUT",
851
+ body: jsonNode
852
+ })));
853
+ }
854
+ export function roleControllerList(opts?: Oazapfts.RequestOpts) {
1207
855
  return oazapfts.ok(oazapfts.fetchJson<{
1208
856
  status: 200;
1209
- data: Role;
1210
- }>(`/portal/roles/${encodeURIComponent(roleName)}`, {
857
+ data: Role[];
858
+ }>("/v2/roles", {
1211
859
  ...opts
1212
860
  }));
1213
861
  }
1214
- export function putRole({ roleName, role }: {
1215
- roleName: string;
1216
- role: Role;
862
+ export function roleControllerCreate({ roleSpec }: {
863
+ roleSpec: RoleSpec;
1217
864
  }, opts?: Oazapfts.RequestOpts) {
1218
- return oazapfts.ok(oazapfts.fetchJson<{
1219
- status: 202;
1220
- data: Role;
1221
- }>(`/portal/roles/${encodeURIComponent(roleName)}`, oazapfts.json({
865
+ return oazapfts.ok(oazapfts.fetchText("/v2/roles", oazapfts.json({
1222
866
  ...opts,
1223
- method: "PUT",
1224
- body: role
867
+ method: "POST",
868
+ body: roleSpec
1225
869
  })));
1226
870
  }
1227
- export function deleteRole({ roleName }: {
1228
- roleName: string;
1229
- }, opts?: Oazapfts.RequestOpts) {
1230
- return oazapfts.ok(oazapfts.fetchText(`/portal/roles/${encodeURIComponent(roleName)}`, {
1231
- ...opts,
1232
- method: "DELETE"
871
+ export function foundationControllerList(opts?: Oazapfts.RequestOpts) {
872
+ return oazapfts.ok(oazapfts.fetchJson<{
873
+ status: 200;
874
+ data: Foundation[];
875
+ }>("/v2/foundations", {
876
+ ...opts
1233
877
  }));
1234
878
  }
1235
- export function putVpnTags({ authorization, xAccountId, foundationId, vpnId, body }: {
1236
- authorization: string;
1237
- xAccountId?: string;
1238
- foundationId: string;
1239
- vpnId: string;
1240
- body: Tag[];
879
+ export function foundationControllerCreate({ foundationSpec }: {
880
+ foundationSpec: FoundationSpec;
1241
881
  }, opts?: Oazapfts.RequestOpts) {
1242
- return oazapfts.ok(oazapfts.fetchJson<{
1243
- status: 202;
1244
- data: VpnResponse;
1245
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns/${encodeURIComponent(vpnId)}/tags`, oazapfts.json({
882
+ return oazapfts.ok(oazapfts.fetchText("/v2/foundations", oazapfts.json({
1246
883
  ...opts,
1247
- method: "PUT",
1248
- body,
1249
- headers: oazapfts.mergeHeaders(opts?.headers, {
1250
- Authorization: authorization,
1251
- "x-account-id": xAccountId
1252
- })
884
+ method: "POST",
885
+ body: foundationSpec
1253
886
  })));
1254
887
  }
1255
- export function getServiceControlPolicy({ foundationId, serviceControlPolicyId }: {
1256
- foundationId: string;
1257
- serviceControlPolicyId: string;
888
+ export function vpnControllerList({ $namespace }: {
889
+ $namespace: string;
1258
890
  }, opts?: Oazapfts.RequestOpts) {
1259
891
  return oazapfts.ok(oazapfts.fetchJson<{
1260
892
  status: 200;
1261
- data: ServiceControlPolicy;
1262
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/service-control-policies/${encodeURIComponent(serviceControlPolicyId)}`, {
893
+ data: Vpn[];
894
+ }>(`/v2/foundations/${encodeURIComponent($namespace)}/vpns`, {
1263
895
  ...opts
1264
896
  }));
1265
897
  }
1266
- export function putServiceControlPolicy({ foundationId, serviceControlPolicyId, serviceControlPolicy }: {
1267
- foundationId: string;
1268
- serviceControlPolicyId: string;
1269
- serviceControlPolicy: ServiceControlPolicy;
898
+ export function vpnControllerCreate({ $namespace, vpnSpec }: {
899
+ $namespace: string;
900
+ vpnSpec: VpnSpec;
1270
901
  }, opts?: Oazapfts.RequestOpts) {
1271
- return oazapfts.ok(oazapfts.fetchJson<{
1272
- status: 202;
1273
- data: ServiceControlPolicy;
1274
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/service-control-policies/${encodeURIComponent(serviceControlPolicyId)}`, oazapfts.json({
902
+ return oazapfts.ok(oazapfts.fetchText(`/v2/foundations/${encodeURIComponent($namespace)}/vpns`, oazapfts.json({
1275
903
  ...opts,
1276
- method: "PUT",
1277
- body: serviceControlPolicy
904
+ method: "POST",
905
+ body: vpnSpec
1278
906
  })));
1279
907
  }
1280
- export function deleteServiceControlPolicy({ foundationId, serviceControlPolicyId }: {
1281
- foundationId: string;
1282
- serviceControlPolicyId: string;
908
+ export function serviceControlPolicyControllerList({ $namespace }: {
909
+ $namespace: string;
1283
910
  }, opts?: Oazapfts.RequestOpts) {
1284
911
  return oazapfts.ok(oazapfts.fetchJson<{
1285
- status: 202;
1286
- data: ServiceControlPolicy;
1287
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/service-control-policies/${encodeURIComponent(serviceControlPolicyId)}`, {
1288
- ...opts,
1289
- method: "DELETE"
1290
- }));
1291
- }
1292
- export function putFoundationSecProjectTags({ foundationId, body }: {
1293
- foundationId: string;
1294
- body: Tag[];
1295
- }, opts?: Oazapfts.RequestOpts) {
1296
- return oazapfts.ok(oazapfts.fetchJson<{
1297
- status: 202;
1298
- data: FoundationResponse;
1299
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/sec-project-tags`, oazapfts.json({
1300
- ...opts,
1301
- method: "PUT",
1302
- body
1303
- })));
1304
- }
1305
- export function putProjectTags({ authorization, xAccountId, foundationId, projectId, body }: {
1306
- authorization: string;
1307
- xAccountId?: string;
1308
- foundationId: string;
1309
- projectId: string;
1310
- body: Tag[];
1311
- }, opts?: Oazapfts.RequestOpts) {
1312
- return oazapfts.ok(oazapfts.fetchJson<{
1313
- status: 202;
1314
- data: ProjectResponse;
1315
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/projects/${encodeURIComponent(projectId)}/tags`, oazapfts.json({
1316
- ...opts,
1317
- method: "PUT",
1318
- body,
1319
- headers: oazapfts.mergeHeaders(opts?.headers, {
1320
- Authorization: authorization,
1321
- "x-account-id": xAccountId
1322
- })
1323
- })));
1324
- }
1325
- export function putNetworkTags({ authorization, xAccountId, foundationId, networkId, body }: {
1326
- authorization: string;
1327
- xAccountId?: string;
1328
- foundationId: string;
1329
- networkId: string;
1330
- body: Tag[];
1331
- }, opts?: Oazapfts.RequestOpts) {
1332
- return oazapfts.ok(oazapfts.fetchJson<{
1333
- status: 202;
1334
- data: NetworkResponse;
1335
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/networks/${encodeURIComponent(networkId)}/tags`, oazapfts.json({
1336
- ...opts,
1337
- method: "PUT",
1338
- body,
1339
- headers: oazapfts.mergeHeaders(opts?.headers, {
1340
- Authorization: authorization,
1341
- "x-account-id": xAccountId
1342
- })
1343
- })));
1344
- }
1345
- export function getFolderTags({ authorization, xAccountId, foundationId, folderId }: {
1346
- authorization: string;
1347
- xAccountId?: string;
1348
- foundationId: string;
1349
- folderId: string;
1350
- }, opts?: Oazapfts.RequestOpts) {
1351
- return oazapfts.ok(oazapfts.fetchJson<{
1352
- status: 202;
1353
- data: Tag[];
1354
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/folders/${encodeURIComponent(folderId)}/tags`, {
1355
- ...opts,
1356
- headers: oazapfts.mergeHeaders(opts?.headers, {
1357
- Authorization: authorization,
1358
- "x-account-id": xAccountId
1359
- })
1360
- }));
1361
- }
1362
- export function putFolderTags({ authorization, xAccountId, foundationId, folderId, body }: {
1363
- authorization: string;
1364
- xAccountId?: string;
1365
- foundationId: string;
1366
- folderId: string;
1367
- body: Tag[];
1368
- }, opts?: Oazapfts.RequestOpts) {
1369
- return oazapfts.ok(oazapfts.fetchJson<{
1370
- status: 202;
1371
- data: FolderResponse;
1372
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/folders/${encodeURIComponent(folderId)}/tags`, oazapfts.json({
1373
- ...opts,
1374
- method: "PUT",
1375
- body,
1376
- headers: oazapfts.mergeHeaders(opts?.headers, {
1377
- Authorization: authorization,
1378
- "x-account-id": xAccountId
1379
- })
1380
- })));
1381
- }
1382
- export function putDnsZoneTags({ authorization, xAccountId, foundationId, dnsZoneId, body }: {
1383
- authorization: string;
1384
- xAccountId?: string;
1385
- foundationId: string;
1386
- dnsZoneId: string;
1387
- body: Tag[];
1388
- }, opts?: Oazapfts.RequestOpts) {
1389
- return oazapfts.ok(oazapfts.fetchJson<{
1390
- status: 202;
1391
- data: DnsZoneResponse;
1392
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-zones/${encodeURIComponent(dnsZoneId)}/tags`, oazapfts.json({
1393
- ...opts,
1394
- method: "PUT",
1395
- body,
1396
- headers: oazapfts.mergeHeaders(opts?.headers, {
1397
- Authorization: authorization,
1398
- "x-account-id": xAccountId
1399
- })
1400
- })));
1401
- }
1402
- export function putDnsRecordRecords({ authorization, xAccountId, foundationId, dnsRecordId, body }: {
1403
- authorization: string;
1404
- xAccountId?: string;
1405
- foundationId: string;
1406
- dnsRecordId: string;
1407
- body: string[];
1408
- }, opts?: Oazapfts.RequestOpts) {
1409
- return oazapfts.ok(oazapfts.fetchJson<{
1410
- status: 200;
1411
- data: DnsRecordResponse;
1412
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-records/${encodeURIComponent(dnsRecordId)}/records`, oazapfts.json({
1413
- ...opts,
1414
- method: "PUT",
1415
- body,
1416
- headers: oazapfts.mergeHeaders(opts?.headers, {
1417
- Authorization: authorization,
1418
- "x-account-id": xAccountId
1419
- })
1420
- })));
1421
- }
1422
- export function putCidrTags({ authorization, xAccountId, foundationId, cidrId, body }: {
1423
- authorization: string;
1424
- xAccountId?: string;
1425
- foundationId: string;
1426
- cidrId: string;
1427
- body: Tag[];
1428
- }, opts?: Oazapfts.RequestOpts) {
1429
- return oazapfts.ok(oazapfts.fetchJson<{
1430
- status: 202;
1431
- data: CidrResponse;
1432
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/cidrs/${encodeURIComponent(cidrId)}/tags`, oazapfts.json({
1433
- ...opts,
1434
- method: "PUT",
1435
- body,
1436
- headers: oazapfts.mergeHeaders(opts?.headers, {
1437
- Authorization: authorization,
1438
- "x-account-id": xAccountId
1439
- })
1440
- })));
1441
- }
1442
- export function putCertificateTags({ authorization, xAccountId, foundationId, certificateId, body }: {
1443
- authorization: string;
1444
- xAccountId?: string;
1445
- foundationId: string;
1446
- certificateId: string;
1447
- body: Tag[];
1448
- }, opts?: Oazapfts.RequestOpts) {
1449
- return oazapfts.ok(oazapfts.fetchJson<{
1450
- status: 202;
1451
- data: CertificateResponse;
1452
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/certificates/${encodeURIComponent(certificateId)}/tags`, oazapfts.json({
1453
- ...opts,
1454
- method: "PUT",
1455
- body,
1456
- headers: oazapfts.mergeHeaders(opts?.headers, {
1457
- Authorization: authorization,
1458
- "x-account-id": xAccountId
1459
- })
1460
- })));
1461
- }
1462
- export function putBoundaryTags({ foundationId, boundaryId, body }: {
1463
- foundationId: string;
1464
- boundaryId: string;
1465
- body: Tag[];
1466
- }, opts?: Oazapfts.RequestOpts) {
1467
- return oazapfts.ok(oazapfts.fetchJson<{
1468
- status: 202;
1469
- data: BoundaryResponse;
1470
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries/${encodeURIComponent(boundaryId)}/tags`, oazapfts.json({
1471
- ...opts,
1472
- method: "PUT",
1473
- body
1474
- })));
1475
- }
1476
- export function putBoundaryPolicyDocument({ foundationId, boundaryId, body }: {
1477
- foundationId: string;
1478
- boundaryId: string;
1479
- body: string;
1480
- }, opts?: Oazapfts.RequestOpts) {
1481
- return oazapfts.ok(oazapfts.fetchJson<{
1482
- status: 202;
1483
- data: BoundaryResponse;
1484
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries/${encodeURIComponent(boundaryId)}/policy-document`, {
1485
- ...opts,
1486
- method: "PUT",
1487
- body
1488
- }));
1489
- }
1490
- export function putBoundaryDescription({ foundationId, boundaryId, body }: {
1491
- foundationId: string;
1492
- boundaryId: string;
1493
- body: string;
1494
- }, opts?: Oazapfts.RequestOpts) {
1495
- return oazapfts.ok(oazapfts.fetchJson<{
1496
- status: 202;
1497
- data: BoundaryResponse;
1498
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries/${encodeURIComponent(boundaryId)}/description`, {
1499
- ...opts,
1500
- method: "PUT",
1501
- body
1502
- }));
1503
- }
1504
- export function putBoundarySsoTags({ foundationId, boundarySsoId, body }: {
1505
- foundationId: string;
1506
- boundarySsoId: string;
1507
- body: Tag[];
1508
- }, opts?: Oazapfts.RequestOpts) {
1509
- return oazapfts.ok(oazapfts.fetchJson<{
1510
- status: 202;
1511
- data: BoundarySsoResponse;
1512
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso/${encodeURIComponent(boundarySsoId)}/tags`, oazapfts.json({
1513
- ...opts,
1514
- method: "PUT",
1515
- body
1516
- })));
1517
- }
1518
- export function putBoundarySsoPolicyDocument({ foundationId, boundarySsoId, body }: {
1519
- foundationId: string;
1520
- boundarySsoId: string;
1521
- body: string;
1522
- }, opts?: Oazapfts.RequestOpts) {
1523
- return oazapfts.ok(oazapfts.fetchJson<{
1524
- status: 202;
1525
- data: BoundarySsoResponse;
1526
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso/${encodeURIComponent(boundarySsoId)}/policy-document`, {
1527
- ...opts,
1528
- method: "PUT",
1529
- body
1530
- }));
1531
- }
1532
- export function putBoundarySsoDescription({ foundationId, boundarySsoId, body }: {
1533
- foundationId: string;
1534
- boundarySsoId: string;
1535
- body: string;
1536
- }, opts?: Oazapfts.RequestOpts) {
1537
- return oazapfts.ok(oazapfts.fetchJson<{
1538
- status: 202;
1539
- data: BoundarySsoResponse;
1540
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso/${encodeURIComponent(boundarySsoId)}/description`, {
1541
- ...opts,
1542
- method: "PUT",
1543
- body
1544
- }));
1545
- }
1546
- export function foundationControllerList(opts?: Oazapfts.RequestOpts) {
1547
- return oazapfts.ok(oazapfts.fetchJson<{
1548
- status: 200;
1549
- data: Foundation[];
1550
- }>("/v2/foundations", {
1551
- ...opts
1552
- }));
1553
- }
1554
- export function foundationControllerCreate({ foundationSpec }: {
1555
- foundationSpec: FoundationSpec;
1556
- }, opts?: Oazapfts.RequestOpts) {
1557
- return oazapfts.ok(oazapfts.fetchText("/v2/foundations", oazapfts.json({
1558
- ...opts,
1559
- method: "POST",
1560
- body: foundationSpec
1561
- })));
1562
- }
1563
- export function vpnControllerList({ $namespace }: {
1564
- $namespace: string;
1565
- }, opts?: Oazapfts.RequestOpts) {
1566
- return oazapfts.ok(oazapfts.fetchJson<{
1567
- status: 200;
1568
- data: Vpn[];
1569
- }>(`/v2/foundations/${encodeURIComponent($namespace)}/vpns`, {
1570
- ...opts
1571
- }));
1572
- }
1573
- export function vpnControllerCreate({ $namespace, vpnSpec }: {
1574
- $namespace: string;
1575
- vpnSpec: VpnSpec;
1576
- }, opts?: Oazapfts.RequestOpts) {
1577
- return oazapfts.ok(oazapfts.fetchText(`/v2/foundations/${encodeURIComponent($namespace)}/vpns`, oazapfts.json({
1578
- ...opts,
1579
- method: "POST",
1580
- body: vpnSpec
1581
- })));
1582
- }
1583
- export function serviceControlPolicyControllerList({ $namespace }: {
1584
- $namespace: string;
1585
- }, opts?: Oazapfts.RequestOpts) {
1586
- return oazapfts.ok(oazapfts.fetchJson<{
1587
- status: 200;
1588
- data: ServiceControlPolicy[];
1589
- }>(`/v2/foundations/${encodeURIComponent($namespace)}/service-control-policies`, {
1590
- ...opts
912
+ status: 200;
913
+ data: ServiceControlPolicy[];
914
+ }>(`/v2/foundations/${encodeURIComponent($namespace)}/service-control-policies`, {
915
+ ...opts
1591
916
  }));
1592
917
  }
1593
918
  export function serviceControlPolicyControllerCreate({ $namespace, serviceControlPolicySpec }: {
@@ -1643,13 +968,16 @@ export function permissionSetControllerCreate({ $namespace, permissionSetSpec }:
1643
968
  body: permissionSetSpec
1644
969
  })));
1645
970
  }
1646
- export function networkControllerList({ $namespace }: {
971
+ export function networkControllerListBy({ $namespace, projectName }: {
1647
972
  $namespace: string;
973
+ projectName?: string;
1648
974
  }, opts?: Oazapfts.RequestOpts) {
1649
975
  return oazapfts.ok(oazapfts.fetchJson<{
1650
976
  status: 200;
1651
977
  data: Network[];
1652
- }>(`/v2/foundations/${encodeURIComponent($namespace)}/networks`, {
978
+ }>(`/v2/foundations/${encodeURIComponent($namespace)}/networks${QS.query(QS.explode({
979
+ projectName
980
+ }))}`, {
1653
981
  ...opts
1654
982
  }));
1655
983
  }
@@ -2014,430 +1342,24 @@ export function accountAssignmentControllerCreate({ $namespace, accountAssignmen
2014
1342
  body: accountAssignmentSpec
2015
1343
  })));
2016
1344
  }
2017
- export function listRole(opts?: Oazapfts.RequestOpts) {
2018
- return oazapfts.ok(oazapfts.fetchJson<{
2019
- status: 200;
2020
- data: ListRole;
2021
- }>("/portal/roles", {
2022
- ...opts
2023
- }));
2024
- }
2025
- export function createRole({ role }: {
2026
- role: Role;
2027
- }, opts?: Oazapfts.RequestOpts) {
2028
- return oazapfts.ok(oazapfts.fetchJson<{
2029
- status: 202;
2030
- data: Role;
2031
- }>("/portal/roles", oazapfts.json({
2032
- ...opts,
2033
- method: "POST",
2034
- body: role
2035
- })));
2036
- }
2037
- export function listFoundations({ authorization, xAccountId }: {
2038
- authorization: string;
2039
- xAccountId?: string;
2040
- }, opts?: Oazapfts.RequestOpts) {
2041
- return oazapfts.ok(oazapfts.fetchJson<{
2042
- status: 202;
2043
- data: ListFoundationResponse;
2044
- }>("/portal/foundations", {
2045
- ...opts,
2046
- headers: oazapfts.mergeHeaders(opts?.headers, {
2047
- Authorization: authorization,
2048
- "x-account-id": xAccountId
2049
- })
2050
- }));
2051
- }
2052
- export function createFoundation({ authorization, xAccountId, createFoundationRequest }: {
2053
- authorization: string;
2054
- xAccountId?: string;
2055
- createFoundationRequest: CreateFoundationRequest;
2056
- }, opts?: Oazapfts.RequestOpts) {
2057
- return oazapfts.ok(oazapfts.fetchJson<{
2058
- status: 202;
2059
- data: FoundationResponse;
2060
- }>("/portal/foundations", oazapfts.json({
2061
- ...opts,
2062
- method: "POST",
2063
- body: createFoundationRequest,
2064
- headers: oazapfts.mergeHeaders(opts?.headers, {
2065
- Authorization: authorization,
2066
- "x-account-id": xAccountId
2067
- })
2068
- })));
2069
- }
2070
- export function listVpns({ authorization, xAccountId, foundationId }: {
2071
- authorization: string;
2072
- xAccountId?: string;
2073
- foundationId: string;
2074
- }, opts?: Oazapfts.RequestOpts) {
2075
- return oazapfts.ok(oazapfts.fetchJson<{
2076
- status: 200;
2077
- data: ListVpnResponse;
2078
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns`, {
2079
- ...opts,
2080
- headers: oazapfts.mergeHeaders(opts?.headers, {
2081
- Authorization: authorization,
2082
- "x-account-id": xAccountId
2083
- })
2084
- }));
2085
- }
2086
- export function createVpn({ authorization, xAccountId, foundationId, createVpnRequest }: {
2087
- authorization: string;
2088
- xAccountId?: string;
2089
- foundationId: string;
2090
- createVpnRequest: CreateVpnRequest;
2091
- }, opts?: Oazapfts.RequestOpts) {
2092
- return oazapfts.ok(oazapfts.fetchJson<{
2093
- status: 202;
2094
- data: VpnResponse;
2095
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns`, oazapfts.json({
2096
- ...opts,
2097
- method: "POST",
2098
- body: createVpnRequest,
2099
- headers: oazapfts.mergeHeaders(opts?.headers, {
2100
- Authorization: authorization,
2101
- "x-account-id": xAccountId
2102
- })
2103
- })));
2104
- }
2105
- export function listServiceControlPolicy({ foundationId }: {
2106
- foundationId: string;
2107
- }, opts?: Oazapfts.RequestOpts) {
2108
- return oazapfts.ok(oazapfts.fetchJson<{
2109
- status: 200;
2110
- data: ListServiceControlPolicy;
2111
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/service-control-policies`, {
2112
- ...opts
2113
- }));
2114
- }
2115
- export function createServiceControlPolicy({ foundationId, serviceControlPolicy }: {
2116
- foundationId: string;
2117
- serviceControlPolicy: ServiceControlPolicy;
2118
- }, opts?: Oazapfts.RequestOpts) {
2119
- return oazapfts.ok(oazapfts.fetchJson<{
2120
- status: 202;
2121
- data: ServiceControlPolicy;
2122
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/service-control-policies`, oazapfts.json({
2123
- ...opts,
2124
- method: "POST",
2125
- body: serviceControlPolicy
2126
- })));
2127
- }
2128
- export function listProject({ authorization, xAccountId, foundationId, parentFolderId }: {
2129
- authorization: string;
2130
- xAccountId?: string;
2131
- foundationId: string;
2132
- parentFolderId?: string;
2133
- }, opts?: Oazapfts.RequestOpts) {
2134
- return oazapfts.ok(oazapfts.fetchJson<{
2135
- status: 200;
2136
- data: ListProjectResponse;
2137
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/projects${QS.query(QS.explode({
2138
- parentFolderId
2139
- }))}`, {
2140
- ...opts,
2141
- headers: oazapfts.mergeHeaders(opts?.headers, {
2142
- Authorization: authorization,
2143
- "x-account-id": xAccountId
2144
- })
2145
- }));
2146
- }
2147
- export function createProject({ authorization, xAccountId, foundationId, createProjectRequest }: {
2148
- authorization: string;
2149
- xAccountId?: string;
2150
- foundationId: string;
2151
- createProjectRequest: CreateProjectRequest;
2152
- }, opts?: Oazapfts.RequestOpts) {
2153
- return oazapfts.ok(oazapfts.fetchJson<{
2154
- status: 202;
2155
- data: ProjectResponse;
2156
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/projects`, oazapfts.json({
2157
- ...opts,
2158
- method: "POST",
2159
- body: createProjectRequest,
2160
- headers: oazapfts.mergeHeaders(opts?.headers, {
2161
- Authorization: authorization,
2162
- "x-account-id": xAccountId
2163
- })
2164
- })));
2165
- }
2166
- export function listNetwork({ authorization, xAccountId, foundationId, projectId }: {
2167
- authorization: string;
2168
- xAccountId?: string;
2169
- foundationId: string;
2170
- projectId?: string;
2171
- }, opts?: Oazapfts.RequestOpts) {
2172
- return oazapfts.ok(oazapfts.fetchJson<{
2173
- status: 200;
2174
- data: ListNetworkResponse;
2175
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/networks${QS.query(QS.explode({
2176
- projectId
2177
- }))}`, {
2178
- ...opts,
2179
- headers: oazapfts.mergeHeaders(opts?.headers, {
2180
- Authorization: authorization,
2181
- "x-account-id": xAccountId
2182
- })
2183
- }));
2184
- }
2185
- export function createNetwork({ authorization, xAccountId, foundationId, createNetworkRequest }: {
2186
- authorization: string;
2187
- xAccountId?: string;
2188
- foundationId: string;
2189
- createNetworkRequest: CreateNetworkRequest;
2190
- }, opts?: Oazapfts.RequestOpts) {
2191
- return oazapfts.ok(oazapfts.fetchJson<{
2192
- status: 202;
2193
- data: NetworkResponse;
2194
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/networks`, oazapfts.json({
2195
- ...opts,
2196
- method: "POST",
2197
- body: createNetworkRequest,
2198
- headers: oazapfts.mergeHeaders(opts?.headers, {
2199
- Authorization: authorization,
2200
- "x-account-id": xAccountId
2201
- })
2202
- })));
2203
- }
2204
- export function getFolder({ authorization, xAccountId, foundationId, folderId }: {
2205
- authorization: string;
2206
- xAccountId?: string;
2207
- foundationId: string;
2208
- folderId: string;
2209
- }, opts?: Oazapfts.RequestOpts) {
2210
- return oazapfts.ok(oazapfts.fetchJson<{
2211
- status: 200;
2212
- data: FolderResponse;
2213
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/folders${QS.query(QS.explode({
2214
- folderId
2215
- }))}`, {
2216
- ...opts,
2217
- headers: oazapfts.mergeHeaders(opts?.headers, {
2218
- Authorization: authorization,
2219
- "x-account-id": xAccountId
2220
- })
2221
- }));
2222
- }
2223
- export function createFolder({ authorization, xAccountId, foundationId, createFolderRequest }: {
2224
- authorization: string;
2225
- xAccountId?: string;
2226
- foundationId: string;
2227
- createFolderRequest: CreateFolderRequest;
2228
- }, opts?: Oazapfts.RequestOpts) {
2229
- return oazapfts.ok(oazapfts.fetchJson<{
2230
- status: 202;
2231
- data: FolderResponse;
2232
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/folders`, oazapfts.json({
2233
- ...opts,
2234
- method: "POST",
2235
- body: createFolderRequest,
2236
- headers: oazapfts.mergeHeaders(opts?.headers, {
2237
- Authorization: authorization,
2238
- "x-account-id": xAccountId
2239
- })
2240
- })));
2241
- }
2242
- export function listDnsZone({ authorization, xAccountId, foundationId, projectId, privacy }: {
2243
- authorization: string;
2244
- xAccountId?: string;
2245
- foundationId: string;
2246
- projectId?: string;
2247
- privacy?: "PUBLIC" | "PRIVATE";
2248
- }, opts?: Oazapfts.RequestOpts) {
2249
- return oazapfts.ok(oazapfts.fetchJson<{
2250
- status: 200;
2251
- data: ListDnsZoneResponse;
2252
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-zones${QS.query(QS.explode({
2253
- projectId,
2254
- privacy
2255
- }))}`, {
2256
- ...opts,
2257
- headers: oazapfts.mergeHeaders(opts?.headers, {
2258
- Authorization: authorization,
2259
- "x-account-id": xAccountId
2260
- })
2261
- }));
2262
- }
2263
- export function createDnsZone({ authorization, xAccountId, foundationId, createDnsZoneRequest }: {
2264
- authorization: string;
2265
- xAccountId?: string;
2266
- foundationId: string;
2267
- createDnsZoneRequest: CreateDnsZoneRequest;
2268
- }, opts?: Oazapfts.RequestOpts) {
2269
- return oazapfts.ok(oazapfts.fetchJson<{
2270
- status: 202;
2271
- data: DnsZoneResponse;
2272
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-zones`, oazapfts.json({
2273
- ...opts,
2274
- method: "POST",
2275
- body: createDnsZoneRequest,
2276
- headers: oazapfts.mergeHeaders(opts?.headers, {
2277
- Authorization: authorization,
2278
- "x-account-id": xAccountId
2279
- })
2280
- })));
2281
- }
2282
- export function listDnsRecord({ authorization, xAccountId, foundationId, projectId, dnsZoneId }: {
2283
- authorization: string;
2284
- xAccountId?: string;
2285
- foundationId: string;
2286
- projectId?: string;
2287
- dnsZoneId?: string;
2288
- }, opts?: Oazapfts.RequestOpts) {
2289
- return oazapfts.ok(oazapfts.fetchJson<{
2290
- status: 200;
2291
- data: ListDnsRecordResponse;
2292
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-records${QS.query(QS.explode({
2293
- projectId,
2294
- dnsZoneId
2295
- }))}`, {
2296
- ...opts,
2297
- headers: oazapfts.mergeHeaders(opts?.headers, {
2298
- Authorization: authorization,
2299
- "x-account-id": xAccountId
2300
- })
2301
- }));
2302
- }
2303
- export function createDnsRecord({ authorization, xAccountId, foundationId, createDnsRecordRequest }: {
2304
- authorization: string;
2305
- xAccountId?: string;
2306
- foundationId: string;
2307
- createDnsRecordRequest: CreateDnsRecordRequest;
2308
- }, opts?: Oazapfts.RequestOpts) {
2309
- return oazapfts.ok(oazapfts.fetchJson<{
2310
- status: 202;
2311
- data: DnsRecordResponse;
2312
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-records`, oazapfts.json({
2313
- ...opts,
2314
- method: "POST",
2315
- body: createDnsRecordRequest,
2316
- headers: oazapfts.mergeHeaders(opts?.headers, {
2317
- Authorization: authorization,
2318
- "x-account-id": xAccountId
2319
- })
2320
- })));
2321
- }
2322
- export function listCidr({ authorization, xAccountId, foundationId }: {
2323
- authorization: string;
2324
- xAccountId?: string;
2325
- foundationId: string;
2326
- }, opts?: Oazapfts.RequestOpts) {
2327
- return oazapfts.ok(oazapfts.fetchJson<{
2328
- status: 200;
2329
- data: ListCidrResponse;
2330
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/cidrs`, {
2331
- ...opts,
2332
- headers: oazapfts.mergeHeaders(opts?.headers, {
2333
- Authorization: authorization,
2334
- "x-account-id": xAccountId
2335
- })
2336
- }));
2337
- }
2338
- export function createCidr({ authorization, xAccountId, foundationId, createCidrRequest }: {
2339
- authorization: string;
2340
- xAccountId?: string;
2341
- foundationId: string;
2342
- createCidrRequest: CreateCidrRequest;
2343
- }, opts?: Oazapfts.RequestOpts) {
2344
- return oazapfts.ok(oazapfts.fetchJson<{
2345
- status: 202;
2346
- data: CidrResponse;
2347
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/cidrs`, oazapfts.json({
2348
- ...opts,
2349
- method: "POST",
2350
- body: createCidrRequest,
2351
- headers: oazapfts.mergeHeaders(opts?.headers, {
2352
- Authorization: authorization,
2353
- "x-account-id": xAccountId
2354
- })
2355
- })));
2356
- }
2357
- export function listCertificates({ authorization, xAccountId, foundationId, forInbound }: {
2358
- authorization: string;
2359
- xAccountId?: string;
2360
- foundationId: string;
2361
- forInbound?: "TRUE" | "FALSE";
2362
- }, opts?: Oazapfts.RequestOpts) {
2363
- return oazapfts.ok(oazapfts.fetchJson<{
2364
- status: 200;
2365
- data: ListCertificateResponse;
2366
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/certificates${QS.query(QS.explode({
2367
- forInbound
2368
- }))}`, {
2369
- ...opts,
2370
- headers: oazapfts.mergeHeaders(opts?.headers, {
2371
- Authorization: authorization,
2372
- "x-account-id": xAccountId
2373
- })
2374
- }));
2375
- }
2376
- export function createCertificate({ authorization, xAccountId, foundationId, body }: {
2377
- authorization: string;
2378
- xAccountId?: string;
2379
- foundationId: string;
2380
- body: CreatePublicCertificateRequest | ImportCertificateRequest;
2381
- }, opts?: Oazapfts.RequestOpts) {
2382
- return oazapfts.ok(oazapfts.fetchJson<{
2383
- status: 202;
2384
- data: CertificateResponse;
2385
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/certificates`, oazapfts.json({
2386
- ...opts,
2387
- method: "POST",
2388
- body,
2389
- headers: oazapfts.mergeHeaders(opts?.headers, {
2390
- Authorization: authorization,
2391
- "x-account-id": xAccountId
2392
- })
2393
- })));
2394
- }
2395
- export function listBoundary({ foundationId }: {
2396
- foundationId: string;
1345
+ export function roleControllerGet({ name }: {
1346
+ name: string;
2397
1347
  }, opts?: Oazapfts.RequestOpts) {
2398
1348
  return oazapfts.ok(oazapfts.fetchJson<{
2399
1349
  status: 200;
2400
- data: ListBoundaryResponse;
2401
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries`, {
1350
+ data: Role;
1351
+ }>(`/v2/roles/${encodeURIComponent(name)}`, {
2402
1352
  ...opts
2403
1353
  }));
2404
1354
  }
2405
- export function createBoundary({ foundationId, createBoundaryRequest }: {
2406
- foundationId: string;
2407
- createBoundaryRequest: CreateBoundaryRequest;
1355
+ export function roleControllerDelete({ name }: {
1356
+ name: string;
2408
1357
  }, opts?: Oazapfts.RequestOpts) {
2409
- return oazapfts.ok(oazapfts.fetchJson<{
2410
- status: 202;
2411
- data: BoundaryResponse;
2412
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries`, oazapfts.json({
1358
+ return oazapfts.ok(oazapfts.fetchText(`/v2/roles/${encodeURIComponent(name)}`, {
2413
1359
  ...opts,
2414
- method: "POST",
2415
- body: createBoundaryRequest
2416
- })));
2417
- }
2418
- export function listBoundarySso({ foundationId }: {
2419
- foundationId: string;
2420
- }, opts?: Oazapfts.RequestOpts) {
2421
- return oazapfts.ok(oazapfts.fetchJson<{
2422
- status: 200;
2423
- data: ListBoundarySsoResponse;
2424
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso`, {
2425
- ...opts
1360
+ method: "DELETE"
2426
1361
  }));
2427
1362
  }
2428
- export function createBoundarySso({ foundationId, createBoundarySsoRequest }: {
2429
- foundationId: string;
2430
- createBoundarySsoRequest: CreateBoundarySsoRequest;
2431
- }, opts?: Oazapfts.RequestOpts) {
2432
- return oazapfts.ok(oazapfts.fetchJson<{
2433
- status: 202;
2434
- data: BoundarySsoResponse;
2435
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso`, oazapfts.json({
2436
- ...opts,
2437
- method: "POST",
2438
- body: createBoundarySsoRequest
2439
- })));
2440
- }
2441
1363
  export function oidcControllerGet(opts?: Oazapfts.RequestOpts) {
2442
1364
  return oazapfts.ok(oazapfts.fetchJson<{
2443
1365
  status: 200;
@@ -2899,328 +1821,10 @@ export function accountAssignmentControllerDelete({ $namespace, name }: {
2899
1821
  export function finOpsControllerGet(opts?: Oazapfts.RequestOpts) {
2900
1822
  return oazapfts.ok(oazapfts.fetchJson<{
2901
1823
  status: 200;
2902
- data: string;
1824
+ data: {
1825
+ [key: string]: string;
1826
+ };
2903
1827
  }>("/v2/finops", {
2904
1828
  ...opts
2905
1829
  }));
2906
1830
  }
2907
- export function getOidc(opts?: Oazapfts.RequestOpts) {
2908
- return oazapfts.ok(oazapfts.fetchJson<{
2909
- status: 200;
2910
- data: string;
2911
- }>("/portal/oidc", {
2912
- ...opts
2913
- }));
2914
- }
2915
- export function getFoundation({ authorization, xAccountId, foundationId }: {
2916
- authorization: string;
2917
- xAccountId?: string;
2918
- foundationId: string;
2919
- }, opts?: Oazapfts.RequestOpts) {
2920
- return oazapfts.ok(oazapfts.fetchJson<{
2921
- status: 202;
2922
- data: FoundationResponse;
2923
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}`, {
2924
- ...opts,
2925
- headers: oazapfts.mergeHeaders(opts?.headers, {
2926
- Authorization: authorization,
2927
- "x-account-id": xAccountId
2928
- })
2929
- }));
2930
- }
2931
- export function getVpn({ authorization, xAccountId, foundationId, vpnId }: {
2932
- authorization: string;
2933
- xAccountId?: string;
2934
- foundationId: string;
2935
- vpnId: string;
2936
- }, opts?: Oazapfts.RequestOpts) {
2937
- return oazapfts.ok(oazapfts.fetchJson<{
2938
- status: 200;
2939
- data: VpnResponse;
2940
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns/${encodeURIComponent(vpnId)}`, {
2941
- ...opts,
2942
- headers: oazapfts.mergeHeaders(opts?.headers, {
2943
- Authorization: authorization,
2944
- "x-account-id": xAccountId
2945
- })
2946
- }));
2947
- }
2948
- export function deleteVpn({ authorization, xAccountId, foundationId, vpnId }: {
2949
- authorization: string;
2950
- xAccountId?: string;
2951
- foundationId: string;
2952
- vpnId: string;
2953
- }, opts?: Oazapfts.RequestOpts) {
2954
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns/${encodeURIComponent(vpnId)}`, {
2955
- ...opts,
2956
- method: "DELETE",
2957
- headers: oazapfts.mergeHeaders(opts?.headers, {
2958
- Authorization: authorization,
2959
- "x-account-id": xAccountId
2960
- })
2961
- }));
2962
- }
2963
- export function getVpnConfiguration({ authorization, xAccountId, foundationId, vpnId }: {
2964
- authorization: string;
2965
- xAccountId?: string;
2966
- foundationId: string;
2967
- vpnId: string;
2968
- }, opts?: Oazapfts.RequestOpts) {
2969
- return oazapfts.ok(oazapfts.fetchJson<{
2970
- status: 200;
2971
- data: VpnConfigurationResponse;
2972
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/vpns/${encodeURIComponent(vpnId)}/configuration`, {
2973
- ...opts,
2974
- headers: oazapfts.mergeHeaders(opts?.headers, {
2975
- Authorization: authorization,
2976
- "x-account-id": xAccountId
2977
- })
2978
- }));
2979
- }
2980
- export function getProject({ authorization, xAccountId, foundationId, projectId }: {
2981
- authorization: string;
2982
- xAccountId?: string;
2983
- foundationId: string;
2984
- projectId: string;
2985
- }, opts?: Oazapfts.RequestOpts) {
2986
- return oazapfts.ok(oazapfts.fetchJson<{
2987
- status: 200;
2988
- data: ProjectResponse;
2989
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/projects/${encodeURIComponent(projectId)}`, {
2990
- ...opts,
2991
- headers: oazapfts.mergeHeaders(opts?.headers, {
2992
- Authorization: authorization,
2993
- "x-account-id": xAccountId
2994
- })
2995
- }));
2996
- }
2997
- export function deleteProject({ authorization, xAccountId, foundationId, projectId }: {
2998
- authorization: string;
2999
- xAccountId?: string;
3000
- foundationId: string;
3001
- projectId: string;
3002
- }, opts?: Oazapfts.RequestOpts) {
3003
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/projects/${encodeURIComponent(projectId)}`, {
3004
- ...opts,
3005
- method: "DELETE",
3006
- headers: oazapfts.mergeHeaders(opts?.headers, {
3007
- Authorization: authorization,
3008
- "x-account-id": xAccountId
3009
- })
3010
- }));
3011
- }
3012
- export function getNetwork({ authorization, xAccountId, foundationId, networkId }: {
3013
- authorization: string;
3014
- xAccountId?: string;
3015
- foundationId: string;
3016
- networkId: string;
3017
- }, opts?: Oazapfts.RequestOpts) {
3018
- return oazapfts.ok(oazapfts.fetchJson<{
3019
- status: 200;
3020
- data: NetworkResponse;
3021
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/networks/${encodeURIComponent(networkId)}`, {
3022
- ...opts,
3023
- headers: oazapfts.mergeHeaders(opts?.headers, {
3024
- Authorization: authorization,
3025
- "x-account-id": xAccountId
3026
- })
3027
- }));
3028
- }
3029
- export function deleteNetwork({ authorization, xAccountId, foundationId, networkId }: {
3030
- authorization: string;
3031
- xAccountId?: string;
3032
- foundationId: string;
3033
- networkId: string;
3034
- }, opts?: Oazapfts.RequestOpts) {
3035
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/networks/${encodeURIComponent(networkId)}`, {
3036
- ...opts,
3037
- method: "DELETE",
3038
- headers: oazapfts.mergeHeaders(opts?.headers, {
3039
- Authorization: authorization,
3040
- "x-account-id": xAccountId
3041
- })
3042
- }));
3043
- }
3044
- export function getDnsZone({ authorization, xAccountId, foundationId, dnsZoneId }: {
3045
- authorization: string;
3046
- xAccountId?: string;
3047
- foundationId: string;
3048
- dnsZoneId: string;
3049
- }, opts?: Oazapfts.RequestOpts) {
3050
- return oazapfts.ok(oazapfts.fetchJson<{
3051
- status: 200;
3052
- data: DnsZoneResponse;
3053
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-zones/${encodeURIComponent(dnsZoneId)}`, {
3054
- ...opts,
3055
- headers: oazapfts.mergeHeaders(opts?.headers, {
3056
- Authorization: authorization,
3057
- "x-account-id": xAccountId
3058
- })
3059
- }));
3060
- }
3061
- export function deleteDnsZone({ authorization, xAccountId, foundationId, dnsZoneId }: {
3062
- authorization: string;
3063
- xAccountId?: string;
3064
- foundationId: string;
3065
- dnsZoneId: string;
3066
- }, opts?: Oazapfts.RequestOpts) {
3067
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-zones/${encodeURIComponent(dnsZoneId)}`, {
3068
- ...opts,
3069
- method: "DELETE",
3070
- headers: oazapfts.mergeHeaders(opts?.headers, {
3071
- Authorization: authorization,
3072
- "x-account-id": xAccountId
3073
- })
3074
- }));
3075
- }
3076
- export function getDnsRecord({ authorization, xAccountId, foundationId, dnsRecordId }: {
3077
- authorization: string;
3078
- xAccountId?: string;
3079
- foundationId: string;
3080
- dnsRecordId: string;
3081
- }, opts?: Oazapfts.RequestOpts) {
3082
- return oazapfts.ok(oazapfts.fetchJson<{
3083
- status: 200;
3084
- data: DnsRecordResponse;
3085
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-records/${encodeURIComponent(dnsRecordId)}`, {
3086
- ...opts,
3087
- headers: oazapfts.mergeHeaders(opts?.headers, {
3088
- Authorization: authorization,
3089
- "x-account-id": xAccountId
3090
- })
3091
- }));
3092
- }
3093
- export function deleteDnsRecord({ authorization, xAccountId, foundationId, dnsRecordId }: {
3094
- authorization: string;
3095
- xAccountId?: string;
3096
- foundationId: string;
3097
- dnsRecordId: string;
3098
- }, opts?: Oazapfts.RequestOpts) {
3099
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/dns-records/${encodeURIComponent(dnsRecordId)}`, {
3100
- ...opts,
3101
- method: "DELETE",
3102
- headers: oazapfts.mergeHeaders(opts?.headers, {
3103
- Authorization: authorization,
3104
- "x-account-id": xAccountId
3105
- })
3106
- }));
3107
- }
3108
- export function getCidr({ authorization, xAccountId, foundationId, cidrId }: {
3109
- authorization: string;
3110
- xAccountId?: string;
3111
- foundationId: string;
3112
- cidrId: string;
3113
- }, opts?: Oazapfts.RequestOpts) {
3114
- return oazapfts.ok(oazapfts.fetchJson<{
3115
- status: 200;
3116
- data: CidrResponse;
3117
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/cidrs/${encodeURIComponent(cidrId)}`, {
3118
- ...opts,
3119
- headers: oazapfts.mergeHeaders(opts?.headers, {
3120
- Authorization: authorization,
3121
- "x-account-id": xAccountId
3122
- })
3123
- }));
3124
- }
3125
- export function deleteCidr({ authorization, xAccountId, foundationId, cidrId }: {
3126
- authorization: string;
3127
- xAccountId?: string;
3128
- foundationId: string;
3129
- cidrId: string;
3130
- }, opts?: Oazapfts.RequestOpts) {
3131
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/cidrs/${encodeURIComponent(cidrId)}`, {
3132
- ...opts,
3133
- method: "DELETE",
3134
- headers: oazapfts.mergeHeaders(opts?.headers, {
3135
- Authorization: authorization,
3136
- "x-account-id": xAccountId
3137
- })
3138
- }));
3139
- }
3140
- export function getCertificate({ authorization, xAccountId, foundationId, certificateId }: {
3141
- authorization: string;
3142
- xAccountId?: string;
3143
- foundationId: string;
3144
- certificateId: string;
3145
- }, opts?: Oazapfts.RequestOpts) {
3146
- return oazapfts.ok(oazapfts.fetchJson<{
3147
- status: 200;
3148
- data: CertificateResponse;
3149
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/certificates/${encodeURIComponent(certificateId)}`, {
3150
- ...opts,
3151
- headers: oazapfts.mergeHeaders(opts?.headers, {
3152
- Authorization: authorization,
3153
- "x-account-id": xAccountId
3154
- })
3155
- }));
3156
- }
3157
- export function deleteCertificate({ authorization, xAccountId, foundationId, certificateId }: {
3158
- authorization: string;
3159
- xAccountId?: string;
3160
- foundationId: string;
3161
- certificateId: string;
3162
- }, opts?: Oazapfts.RequestOpts) {
3163
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/certificates/${encodeURIComponent(certificateId)}`, {
3164
- ...opts,
3165
- method: "DELETE",
3166
- headers: oazapfts.mergeHeaders(opts?.headers, {
3167
- Authorization: authorization,
3168
- "x-account-id": xAccountId
3169
- })
3170
- }));
3171
- }
3172
- export function getBoundary({ foundationId, boundaryId }: {
3173
- foundationId: string;
3174
- boundaryId: string;
3175
- }, opts?: Oazapfts.RequestOpts) {
3176
- return oazapfts.ok(oazapfts.fetchJson<{
3177
- status: 200;
3178
- data: BoundaryResponse;
3179
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries/${encodeURIComponent(boundaryId)}`, {
3180
- ...opts
3181
- }));
3182
- }
3183
- export function deleteBoundary({ foundationId, boundaryId }: {
3184
- foundationId: string;
3185
- boundaryId: string;
3186
- }, opts?: Oazapfts.RequestOpts) {
3187
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries/${encodeURIComponent(boundaryId)}`, {
3188
- ...opts,
3189
- method: "DELETE"
3190
- }));
3191
- }
3192
- export function getBoundarySso({ foundationId, boundarySsoId }: {
3193
- foundationId: string;
3194
- boundarySsoId: string;
3195
- }, opts?: Oazapfts.RequestOpts) {
3196
- return oazapfts.ok(oazapfts.fetchJson<{
3197
- status: 200;
3198
- data: BoundarySsoResponse;
3199
- }>(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso/${encodeURIComponent(boundarySsoId)}`, {
3200
- ...opts
3201
- }));
3202
- }
3203
- export function deleteBoundarySso({ foundationId, boundarySsoId }: {
3204
- foundationId: string;
3205
- boundarySsoId: string;
3206
- }, opts?: Oazapfts.RequestOpts) {
3207
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/boundaries-sso/${encodeURIComponent(boundarySsoId)}`, {
3208
- ...opts,
3209
- method: "DELETE"
3210
- }));
3211
- }
3212
- export function deleteFolder({ authorization, xAccountId, foundationId, folderId }: {
3213
- authorization: string;
3214
- xAccountId?: string;
3215
- foundationId: string;
3216
- folderId: string;
3217
- }, opts?: Oazapfts.RequestOpts) {
3218
- return oazapfts.ok(oazapfts.fetchText(`/portal/foundations/${encodeURIComponent(foundationId)}/folders/${encodeURIComponent(folderId)}`, {
3219
- ...opts,
3220
- method: "DELETE",
3221
- headers: oazapfts.mergeHeaders(opts?.headers, {
3222
- Authorization: authorization,
3223
- "x-account-id": xAccountId
3224
- })
3225
- }));
3226
- }