@nirvana-labs/nirvana 1.19.0 → 1.20.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.
- package/CHANGELOG.md +10 -0
- package/README.md +7 -7
- package/package.json +1 -1
- package/resources/connect/connect.d.mts +3 -3
- package/resources/connect/connect.d.mts.map +1 -1
- package/resources/connect/connect.d.ts +3 -3
- package/resources/connect/connect.d.ts.map +1 -1
- package/resources/connect/connect.js +2 -2
- package/resources/connect/connect.js.map +1 -1
- package/resources/connect/connect.mjs +3 -3
- package/resources/connect/connect.mjs.map +1 -1
- package/resources/connect/flux/flux.d.mts +2 -216
- package/resources/connect/flux/flux.d.mts.map +1 -1
- package/resources/connect/flux/flux.d.ts +2 -216
- package/resources/connect/flux/flux.d.ts.map +1 -1
- package/resources/connect/flux/flux.js +4 -70
- package/resources/connect/flux/flux.js.map +1 -1
- package/resources/connect/flux/flux.mjs +2 -68
- package/resources/connect/flux/flux.mjs.map +1 -1
- package/resources/connect/flux/index.d.mts +1 -1
- package/resources/connect/flux/index.d.mts.map +1 -1
- package/resources/connect/flux/index.d.ts +1 -1
- package/resources/connect/flux/index.d.ts.map +1 -1
- package/resources/connect/flux/index.js +2 -2
- package/resources/connect/flux/index.js.map +1 -1
- package/resources/connect/flux/index.mjs +1 -1
- package/resources/connect/flux/index.mjs.map +1 -1
- package/resources/connect/flux/routes.d.mts +0 -13
- package/resources/connect/flux/routes.d.mts.map +1 -1
- package/resources/connect/flux/routes.d.ts +0 -13
- package/resources/connect/flux/routes.d.ts.map +1 -1
- package/resources/connect/flux/routes.js +0 -12
- package/resources/connect/flux/routes.js.map +1 -1
- package/resources/connect/flux/routes.mjs +0 -12
- package/resources/connect/flux/routes.mjs.map +1 -1
- package/resources/connect/index.d.mts +1 -1
- package/resources/connect/index.d.mts.map +1 -1
- package/resources/connect/index.d.ts +1 -1
- package/resources/connect/index.d.ts.map +1 -1
- package/resources/connect/index.js +2 -2
- package/resources/connect/index.js.map +1 -1
- package/resources/connect/index.mjs +1 -1
- package/resources/connect/index.mjs.map +1 -1
- package/resources/networking/connect/connect.d.mts +130 -0
- package/resources/networking/connect/connect.d.mts.map +1 -0
- package/resources/networking/connect/connect.d.ts +130 -0
- package/resources/networking/connect/connect.d.ts.map +1 -0
- package/resources/networking/connect/connect.js +21 -0
- package/resources/networking/connect/connect.js.map +1 -0
- package/resources/networking/connect/connect.mjs +16 -0
- package/resources/networking/connect/connect.mjs.map +1 -0
- package/resources/networking/connect/connections.d.mts +114 -0
- package/resources/networking/connect/connections.d.mts.map +1 -0
- package/resources/networking/connect/connections.d.ts +114 -0
- package/resources/networking/connect/connections.d.ts.map +1 -0
- package/resources/networking/connect/connections.js +82 -0
- package/resources/networking/connect/connections.js.map +1 -0
- package/resources/networking/connect/connections.mjs +78 -0
- package/resources/networking/connect/connections.mjs.map +1 -0
- package/resources/networking/connect/index.d.mts +4 -0
- package/resources/networking/connect/index.d.mts.map +1 -0
- package/resources/networking/connect/index.d.ts +4 -0
- package/resources/networking/connect/index.d.ts.map +1 -0
- package/resources/networking/connect/index.js +11 -0
- package/resources/networking/connect/index.js.map +1 -0
- package/resources/networking/connect/index.mjs +5 -0
- package/resources/networking/connect/index.mjs.map +1 -0
- package/resources/networking/connect/routes.d.mts +17 -0
- package/resources/networking/connect/routes.d.mts.map +1 -0
- package/resources/networking/connect/routes.d.ts +17 -0
- package/resources/networking/connect/routes.d.ts.map +1 -0
- package/resources/networking/connect/routes.js +21 -0
- package/resources/networking/connect/routes.js.map +1 -0
- package/resources/networking/connect/routes.mjs +17 -0
- package/resources/networking/connect/routes.mjs.map +1 -0
- package/resources/networking/connect.d.mts +2 -0
- package/resources/networking/connect.d.mts.map +1 -0
- package/resources/networking/connect.d.ts +2 -0
- package/resources/networking/connect.d.ts.map +1 -0
- package/resources/networking/connect.js +6 -0
- package/resources/networking/connect.js.map +1 -0
- package/resources/networking/connect.mjs +3 -0
- package/resources/networking/connect.mjs.map +1 -0
- package/resources/networking/index.d.mts +1 -0
- package/resources/networking/index.d.mts.map +1 -1
- package/resources/networking/index.d.ts +1 -0
- package/resources/networking/index.d.ts.map +1 -1
- package/resources/networking/index.js +5 -3
- package/resources/networking/index.js.map +1 -1
- package/resources/networking/index.mjs +1 -0
- package/resources/networking/index.mjs.map +1 -1
- package/resources/networking/networking.d.mts +4 -0
- package/resources/networking/networking.d.mts.map +1 -1
- package/resources/networking/networking.d.ts +4 -0
- package/resources/networking/networking.d.ts.map +1 -1
- package/resources/networking/networking.js +4 -0
- package/resources/networking/networking.js.map +1 -1
- package/resources/networking/networking.mjs +4 -0
- package/resources/networking/networking.mjs.map +1 -1
- package/resources/rpc-nodes/dedicated/blockchains.d.mts +6 -0
- package/resources/rpc-nodes/dedicated/blockchains.d.mts.map +1 -1
- package/resources/rpc-nodes/dedicated/blockchains.d.ts +6 -0
- package/resources/rpc-nodes/dedicated/blockchains.d.ts.map +1 -1
- package/resources/rpc-nodes/dedicated/blockchains.js +6 -0
- package/resources/rpc-nodes/dedicated/blockchains.js.map +1 -1
- package/resources/rpc-nodes/dedicated/blockchains.mjs +6 -0
- package/resources/rpc-nodes/dedicated/blockchains.mjs.map +1 -1
- package/resources/rpc-nodes/dedicated/dedicated.d.mts +13 -0
- package/resources/rpc-nodes/dedicated/dedicated.d.mts.map +1 -1
- package/resources/rpc-nodes/dedicated/dedicated.d.ts +13 -0
- package/resources/rpc-nodes/dedicated/dedicated.d.ts.map +1 -1
- package/resources/rpc-nodes/dedicated/dedicated.js +13 -0
- package/resources/rpc-nodes/dedicated/dedicated.js.map +1 -1
- package/resources/rpc-nodes/dedicated/dedicated.mjs +13 -0
- package/resources/rpc-nodes/dedicated/dedicated.mjs.map +1 -1
- package/resources/rpc-nodes/flex/blockchains.d.mts +6 -0
- package/resources/rpc-nodes/flex/blockchains.d.mts.map +1 -1
- package/resources/rpc-nodes/flex/blockchains.d.ts +6 -0
- package/resources/rpc-nodes/flex/blockchains.d.ts.map +1 -1
- package/resources/rpc-nodes/flex/blockchains.js +6 -0
- package/resources/rpc-nodes/flex/blockchains.js.map +1 -1
- package/resources/rpc-nodes/flex/blockchains.mjs +6 -0
- package/resources/rpc-nodes/flex/blockchains.mjs.map +1 -1
- package/resources/rpc-nodes/flex/flex.d.mts +70 -1
- package/resources/rpc-nodes/flex/flex.d.mts.map +1 -1
- package/resources/rpc-nodes/flex/flex.d.ts +70 -1
- package/resources/rpc-nodes/flex/flex.d.ts.map +1 -1
- package/resources/rpc-nodes/flex/flex.js +51 -0
- package/resources/rpc-nodes/flex/flex.js.map +1 -1
- package/resources/rpc-nodes/flex/flex.mjs +51 -0
- package/resources/rpc-nodes/flex/flex.mjs.map +1 -1
- package/resources/rpc-nodes/flex/index.d.mts +1 -1
- package/resources/rpc-nodes/flex/index.d.mts.map +1 -1
- package/resources/rpc-nodes/flex/index.d.ts +1 -1
- package/resources/rpc-nodes/flex/index.d.ts.map +1 -1
- package/resources/rpc-nodes/flex/index.js.map +1 -1
- package/resources/rpc-nodes/flex/index.mjs +1 -1
- package/resources/rpc-nodes/flex/index.mjs.map +1 -1
- package/resources/rpc-nodes/index.d.mts +1 -1
- package/resources/rpc-nodes/index.d.mts.map +1 -1
- package/resources/rpc-nodes/index.d.ts +1 -1
- package/resources/rpc-nodes/index.d.ts.map +1 -1
- package/resources/rpc-nodes/index.js.map +1 -1
- package/resources/rpc-nodes/index.mjs.map +1 -1
- package/resources/rpc-nodes/rpc-nodes.d.mts +2 -2
- package/resources/rpc-nodes/rpc-nodes.d.mts.map +1 -1
- package/resources/rpc-nodes/rpc-nodes.d.ts +2 -2
- package/resources/rpc-nodes/rpc-nodes.d.ts.map +1 -1
- package/resources/rpc-nodes/rpc-nodes.js.map +1 -1
- package/resources/rpc-nodes/rpc-nodes.mjs +1 -1
- package/resources/rpc-nodes/rpc-nodes.mjs.map +1 -1
- package/src/resources/connect/connect.ts +4 -26
- package/src/resources/connect/flux/flux.ts +3 -281
- package/src/resources/connect/flux/index.ts +1 -12
- package/src/resources/connect/flux/routes.ts +1 -17
- package/src/resources/connect/index.ts +1 -12
- package/src/resources/networking/connect/connect.ts +174 -0
- package/src/resources/networking/connect/connections.ts +148 -0
- package/src/resources/networking/connect/index.ts +14 -0
- package/src/resources/networking/connect/routes.ts +21 -0
- package/src/resources/networking/connect.ts +3 -0
- package/src/resources/networking/index.ts +10 -0
- package/src/resources/networking/networking.ts +24 -0
- package/src/resources/rpc-nodes/dedicated/blockchains.ts +6 -0
- package/src/resources/rpc-nodes/dedicated/dedicated.ts +13 -0
- package/src/resources/rpc-nodes/flex/blockchains.ts +6 -0
- package/src/resources/rpc-nodes/flex/flex.ts +90 -0
- package/src/resources/rpc-nodes/flex/index.ts +9 -1
- package/src/resources/rpc-nodes/index.ts +2 -0
- package/src/resources/rpc-nodes/rpc-nodes.ts +11 -1
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,293 +1,15 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
|
-
import * as OperationsAPI from '../../operations';
|
|
5
|
-
import * as Shared from '../../shared';
|
|
6
4
|
import * as RoutesAPI from './routes';
|
|
7
5
|
import { Routes } from './routes';
|
|
8
|
-
import { APIPromise } from '../../../core/api-promise';
|
|
9
|
-
import { RequestOptions } from '../../../internal/request-options';
|
|
10
|
-
import { path } from '../../../internal/utils/path';
|
|
11
6
|
|
|
12
|
-
export class
|
|
7
|
+
export class Flux extends APIResource {
|
|
13
8
|
routes: RoutesAPI.Routes = new RoutesAPI.Routes(this._client);
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Create a Connect Flux
|
|
17
|
-
*
|
|
18
|
-
* @example
|
|
19
|
-
* ```ts
|
|
20
|
-
* const operation = await client.connect.flux.create({
|
|
21
|
-
* bandwidth_mbps: 50,
|
|
22
|
-
* cidrs: ['10.0.0.0/16'],
|
|
23
|
-
* name: 'my-connect-flux',
|
|
24
|
-
* provider_cidrs: ['172.16.0.0/16'],
|
|
25
|
-
* region: 'us-wdc-1',
|
|
26
|
-
* });
|
|
27
|
-
* ```
|
|
28
|
-
*/
|
|
29
|
-
create(body: FluxCreateParams, options?: RequestOptions): APIPromise<OperationsAPI.Operation> {
|
|
30
|
-
return this._client.post('/v1/connect/flux', { body, ...options });
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
/**
|
|
34
|
-
* Update Connect Flux details
|
|
35
|
-
*
|
|
36
|
-
* @example
|
|
37
|
-
* ```ts
|
|
38
|
-
* const operation = await client.connect.flux.update(
|
|
39
|
-
* 'flux_id',
|
|
40
|
-
* );
|
|
41
|
-
* ```
|
|
42
|
-
*/
|
|
43
|
-
update(
|
|
44
|
-
fluxID: string,
|
|
45
|
-
body: FluxUpdateParams,
|
|
46
|
-
options?: RequestOptions,
|
|
47
|
-
): APIPromise<OperationsAPI.Operation> {
|
|
48
|
-
return this._client.patch(path`/v1/connect/flux/${fluxID}`, { body, ...options });
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
/**
|
|
52
|
-
* List all Connect Flux
|
|
53
|
-
*
|
|
54
|
-
* @example
|
|
55
|
-
* ```ts
|
|
56
|
-
* const fluxList = await client.connect.flux.list();
|
|
57
|
-
* ```
|
|
58
|
-
*/
|
|
59
|
-
list(options?: RequestOptions): APIPromise<FluxList> {
|
|
60
|
-
return this._client.get('/v1/connect/flux', options);
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
/**
|
|
64
|
-
* Delete Connect Flux
|
|
65
|
-
*
|
|
66
|
-
* @example
|
|
67
|
-
* ```ts
|
|
68
|
-
* const operation = await client.connect.flux.delete(
|
|
69
|
-
* 'flux_id',
|
|
70
|
-
* );
|
|
71
|
-
* ```
|
|
72
|
-
*/
|
|
73
|
-
delete(fluxID: string, options?: RequestOptions): APIPromise<OperationsAPI.Operation> {
|
|
74
|
-
return this._client.delete(path`/v1/connect/flux/${fluxID}`, options);
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
/**
|
|
78
|
-
* Get Connect Flux details
|
|
79
|
-
*
|
|
80
|
-
* @example
|
|
81
|
-
* ```ts
|
|
82
|
-
* const flux = await client.connect.flux.get('flux_id');
|
|
83
|
-
* ```
|
|
84
|
-
*/
|
|
85
|
-
get(fluxID: string, options?: RequestOptions): APIPromise<Flux> {
|
|
86
|
-
return this._client.get(path`/v1/connect/flux/${fluxID}`, options);
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* Connect flux details.
|
|
92
|
-
*/
|
|
93
|
-
export interface Flux {
|
|
94
|
-
/**
|
|
95
|
-
* Unique identifier for the Connect Flux
|
|
96
|
-
*/
|
|
97
|
-
id: string;
|
|
98
|
-
|
|
99
|
-
/**
|
|
100
|
-
* ASN
|
|
101
|
-
*/
|
|
102
|
-
asn: number | null;
|
|
103
|
-
|
|
104
|
-
/**
|
|
105
|
-
* AWS provider configuration
|
|
106
|
-
*/
|
|
107
|
-
aws: FluxProviderAWSConfig | null;
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Connect Flux speed in Mbps
|
|
111
|
-
*/
|
|
112
|
-
bandwidth_mbps: FluxBandwidthMbps;
|
|
113
|
-
|
|
114
|
-
/**
|
|
115
|
-
* CIDRs for the Connect Flux
|
|
116
|
-
*/
|
|
117
|
-
cidrs: Array<string>;
|
|
118
|
-
|
|
119
|
-
/**
|
|
120
|
-
* When the Connect Flux was created
|
|
121
|
-
*/
|
|
122
|
-
created_at: string;
|
|
123
|
-
|
|
124
|
-
/**
|
|
125
|
-
* Name of the Connect Flux
|
|
126
|
-
*/
|
|
127
|
-
name: string;
|
|
128
|
-
|
|
129
|
-
/**
|
|
130
|
-
* Provider ASN
|
|
131
|
-
*/
|
|
132
|
-
provider_asn: number | null;
|
|
133
|
-
|
|
134
|
-
/**
|
|
135
|
-
* Provider CIDRs for the Connect Flux
|
|
136
|
-
*/
|
|
137
|
-
provider_cidrs: Array<string>;
|
|
138
|
-
|
|
139
|
-
/**
|
|
140
|
-
* Provider Router IP
|
|
141
|
-
*/
|
|
142
|
-
provider_router_ip: string | null;
|
|
143
|
-
|
|
144
|
-
/**
|
|
145
|
-
* Region the resource is in.
|
|
146
|
-
*/
|
|
147
|
-
region: Shared.RegionName;
|
|
148
|
-
|
|
149
|
-
/**
|
|
150
|
-
* Router IP
|
|
151
|
-
*/
|
|
152
|
-
router_ip: string | null;
|
|
153
|
-
|
|
154
|
-
/**
|
|
155
|
-
* Status of the resource.
|
|
156
|
-
*/
|
|
157
|
-
status: Shared.ResourceStatus;
|
|
158
|
-
|
|
159
|
-
/**
|
|
160
|
-
* Tags to attach to the Connect Flux
|
|
161
|
-
*/
|
|
162
|
-
tags: Array<string>;
|
|
163
|
-
|
|
164
|
-
/**
|
|
165
|
-
* When the Connect Flux was updated
|
|
166
|
-
*/
|
|
167
|
-
updated_at: string;
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
/**
|
|
171
|
-
* Connect Flux speed in Mbps
|
|
172
|
-
*/
|
|
173
|
-
export type FluxBandwidthMbps = 50 | 200 | 500 | 1000 | 2000;
|
|
174
|
-
|
|
175
|
-
export interface FluxList {
|
|
176
|
-
items: Array<Flux>;
|
|
177
9
|
}
|
|
178
10
|
|
|
179
|
-
|
|
180
|
-
* AWS provider configuration
|
|
181
|
-
*/
|
|
182
|
-
export interface FluxProviderAWSConfig {
|
|
183
|
-
/**
|
|
184
|
-
* AWS region where the connection is established
|
|
185
|
-
*/
|
|
186
|
-
region: string;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
/**
|
|
190
|
-
* AWS provider configuration
|
|
191
|
-
*/
|
|
192
|
-
export interface FluxProviderAWSConfigRequest {
|
|
193
|
-
/**
|
|
194
|
-
* AWS account id
|
|
195
|
-
*/
|
|
196
|
-
account_id: string;
|
|
197
|
-
|
|
198
|
-
/**
|
|
199
|
-
* AWS region where the connection will be established
|
|
200
|
-
*/
|
|
201
|
-
region: string;
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
/**
|
|
205
|
-
* Routes supported for Connect Flux.
|
|
206
|
-
*/
|
|
207
|
-
export interface FluxRoute {
|
|
208
|
-
/**
|
|
209
|
-
* Region the resource is in.
|
|
210
|
-
*/
|
|
211
|
-
nirvana_region: Shared.RegionName;
|
|
212
|
-
|
|
213
|
-
/**
|
|
214
|
-
* Provider name.
|
|
215
|
-
*/
|
|
216
|
-
provider: string;
|
|
217
|
-
|
|
218
|
-
/**
|
|
219
|
-
* Provider region name.
|
|
220
|
-
*/
|
|
221
|
-
provider_region: string;
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
export interface FluxRouteList {
|
|
225
|
-
items: Array<FluxRoute>;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
export interface FluxCreateParams {
|
|
229
|
-
/**
|
|
230
|
-
* Connect Flux speed in Mbps
|
|
231
|
-
*/
|
|
232
|
-
bandwidth_mbps: FluxBandwidthMbps;
|
|
233
|
-
|
|
234
|
-
/**
|
|
235
|
-
* CIDRs for the Connect Flux
|
|
236
|
-
*/
|
|
237
|
-
cidrs: Array<string>;
|
|
238
|
-
|
|
239
|
-
/**
|
|
240
|
-
* Name of the Connect Flux
|
|
241
|
-
*/
|
|
242
|
-
name: string;
|
|
243
|
-
|
|
244
|
-
/**
|
|
245
|
-
* Provider CIDRs
|
|
246
|
-
*/
|
|
247
|
-
provider_cidrs: Array<string>;
|
|
248
|
-
|
|
249
|
-
/**
|
|
250
|
-
* Region the resource is in.
|
|
251
|
-
*/
|
|
252
|
-
region: Shared.RegionName;
|
|
253
|
-
|
|
254
|
-
/**
|
|
255
|
-
* AWS provider configuration
|
|
256
|
-
*/
|
|
257
|
-
aws?: FluxProviderAWSConfigRequest;
|
|
258
|
-
|
|
259
|
-
/**
|
|
260
|
-
* Tags to attach to the Connect Flux
|
|
261
|
-
*/
|
|
262
|
-
tags?: Array<string>;
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
export interface FluxUpdateParams {
|
|
266
|
-
/**
|
|
267
|
-
* Name of the Connect Flux.
|
|
268
|
-
*/
|
|
269
|
-
name?: string;
|
|
270
|
-
|
|
271
|
-
/**
|
|
272
|
-
* Tags to attach to the Connect Flux
|
|
273
|
-
*/
|
|
274
|
-
tags?: Array<string>;
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
FluxResource.Routes = Routes;
|
|
278
|
-
|
|
279
|
-
export declare namespace FluxResource {
|
|
280
|
-
export {
|
|
281
|
-
type Flux as Flux,
|
|
282
|
-
type FluxBandwidthMbps as FluxBandwidthMbps,
|
|
283
|
-
type FluxList as FluxList,
|
|
284
|
-
type FluxProviderAWSConfig as FluxProviderAWSConfig,
|
|
285
|
-
type FluxProviderAWSConfigRequest as FluxProviderAWSConfigRequest,
|
|
286
|
-
type FluxRoute as FluxRoute,
|
|
287
|
-
type FluxRouteList as FluxRouteList,
|
|
288
|
-
type FluxCreateParams as FluxCreateParams,
|
|
289
|
-
type FluxUpdateParams as FluxUpdateParams,
|
|
290
|
-
};
|
|
11
|
+
Flux.Routes = Routes;
|
|
291
12
|
|
|
13
|
+
export declare namespace Flux {
|
|
292
14
|
export { Routes as Routes };
|
|
293
15
|
}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
export {
|
|
4
|
-
FluxResource,
|
|
5
|
-
type Flux,
|
|
6
|
-
type FluxBandwidthMbps,
|
|
7
|
-
type FluxList,
|
|
8
|
-
type FluxProviderAWSConfig,
|
|
9
|
-
type FluxProviderAWSConfigRequest,
|
|
10
|
-
type FluxRoute,
|
|
11
|
-
type FluxRouteList,
|
|
12
|
-
type FluxCreateParams,
|
|
13
|
-
type FluxUpdateParams,
|
|
14
|
-
} from './flux';
|
|
3
|
+
export { Flux } from './flux';
|
|
15
4
|
export { Routes } from './routes';
|
|
@@ -1,21 +1,5 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
|
-
import * as FluxAPI from './flux';
|
|
5
|
-
import { APIPromise } from '../../../core/api-promise';
|
|
6
|
-
import { RequestOptions } from '../../../internal/request-options';
|
|
7
4
|
|
|
8
|
-
export class Routes extends APIResource {
|
|
9
|
-
/**
|
|
10
|
-
* List all supported routes with regions for Connect Flux.
|
|
11
|
-
*
|
|
12
|
-
* @example
|
|
13
|
-
* ```ts
|
|
14
|
-
* const fluxRouteList =
|
|
15
|
-
* await client.connect.flux.routes.list();
|
|
16
|
-
* ```
|
|
17
|
-
*/
|
|
18
|
-
list(options?: RequestOptions): APIPromise<FluxAPI.FluxRouteList> {
|
|
19
|
-
return this._client.get('/v1/connect/flux/routes', options);
|
|
20
|
-
}
|
|
21
|
-
}
|
|
5
|
+
export class Routes extends APIResource {}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
export { Connect } from './connect';
|
|
4
|
-
export {
|
|
5
|
-
FluxResource,
|
|
6
|
-
type Flux,
|
|
7
|
-
type FluxBandwidthMbps,
|
|
8
|
-
type FluxList,
|
|
9
|
-
type FluxProviderAWSConfig,
|
|
10
|
-
type FluxProviderAWSConfigRequest,
|
|
11
|
-
type FluxRoute,
|
|
12
|
-
type FluxRouteList,
|
|
13
|
-
type FluxCreateParams,
|
|
14
|
-
type FluxUpdateParams,
|
|
15
|
-
} from './flux/index';
|
|
4
|
+
export { Flux } from './flux/index';
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as Shared from '../../shared';
|
|
5
|
+
import * as ConnectionsAPI from './connections';
|
|
6
|
+
import { ConnectionCreateParams, ConnectionUpdateParams, Connections } from './connections';
|
|
7
|
+
import * as RoutesAPI from './routes';
|
|
8
|
+
import { Routes } from './routes';
|
|
9
|
+
|
|
10
|
+
export class Connect extends APIResource {
|
|
11
|
+
connections: ConnectionsAPI.Connections = new ConnectionsAPI.Connections(this._client);
|
|
12
|
+
routes: RoutesAPI.Routes = new RoutesAPI.Routes(this._client);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Connect Connection speed in Mbps
|
|
17
|
+
*/
|
|
18
|
+
export type ConnectBandwidthMbps = 50 | 200 | 500 | 1000 | 2000;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Connect Connection details.
|
|
22
|
+
*/
|
|
23
|
+
export interface ConnectConnection {
|
|
24
|
+
/**
|
|
25
|
+
* Unique identifier for the Connect Connection
|
|
26
|
+
*/
|
|
27
|
+
id: string;
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* ASN
|
|
31
|
+
*/
|
|
32
|
+
asn: number | null;
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* AWS provider configuration
|
|
36
|
+
*/
|
|
37
|
+
aws: ConnectConnectionAWSConfig | null;
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Connect Connection speed in Mbps
|
|
41
|
+
*/
|
|
42
|
+
bandwidth_mbps: ConnectBandwidthMbps;
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* CIDRs for the Connect Connection
|
|
46
|
+
*/
|
|
47
|
+
cidrs: Array<string>;
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* When the Connect Connection was created
|
|
51
|
+
*/
|
|
52
|
+
created_at: string;
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Name of the Connect Connection
|
|
56
|
+
*/
|
|
57
|
+
name: string;
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Provider ASN
|
|
61
|
+
*/
|
|
62
|
+
provider_asn: number | null;
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Provider CIDRs for the Connect Connection
|
|
66
|
+
*/
|
|
67
|
+
provider_cidrs: Array<string>;
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Provider Router IP for the Connect Connection
|
|
71
|
+
*/
|
|
72
|
+
provider_router_ip: string | null;
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Region the resource is in.
|
|
76
|
+
*/
|
|
77
|
+
region: Shared.RegionName;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Router IP
|
|
81
|
+
*/
|
|
82
|
+
router_ip: string | null;
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* Status of the resource.
|
|
86
|
+
*/
|
|
87
|
+
status: Shared.ResourceStatus;
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Tags to attach to the Connect Connection
|
|
91
|
+
*/
|
|
92
|
+
tags: Array<string>;
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* When the Connect Connection was updated
|
|
96
|
+
*/
|
|
97
|
+
updated_at: string;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* AWS provider configuration
|
|
102
|
+
*/
|
|
103
|
+
export interface ConnectConnectionAWSConfig {
|
|
104
|
+
/**
|
|
105
|
+
* AWS region where the connection is established
|
|
106
|
+
*/
|
|
107
|
+
region: string;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* AWS provider configuration
|
|
112
|
+
*/
|
|
113
|
+
export interface ConnectConnectionAWSConfigRequest {
|
|
114
|
+
/**
|
|
115
|
+
* AWS account id
|
|
116
|
+
*/
|
|
117
|
+
account_id: string;
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* AWS region where the connection will be established
|
|
121
|
+
*/
|
|
122
|
+
region: string;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
export interface ConnectConnectionList {
|
|
126
|
+
items: Array<ConnectConnection>;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Routes supported for Connect.
|
|
131
|
+
*/
|
|
132
|
+
export interface ConnectRoute {
|
|
133
|
+
/**
|
|
134
|
+
* Region the resource is in.
|
|
135
|
+
*/
|
|
136
|
+
nirvana_region: Shared.RegionName;
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Provider name.
|
|
140
|
+
*/
|
|
141
|
+
provider: string;
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* Provider region name.
|
|
145
|
+
*/
|
|
146
|
+
provider_region: string;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
export interface ConnectRouteList {
|
|
150
|
+
items: Array<ConnectRoute>;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
Connect.Connections = Connections;
|
|
154
|
+
Connect.Routes = Routes;
|
|
155
|
+
|
|
156
|
+
export declare namespace Connect {
|
|
157
|
+
export {
|
|
158
|
+
type ConnectBandwidthMbps as ConnectBandwidthMbps,
|
|
159
|
+
type ConnectConnection as ConnectConnection,
|
|
160
|
+
type ConnectConnectionAWSConfig as ConnectConnectionAWSConfig,
|
|
161
|
+
type ConnectConnectionAWSConfigRequest as ConnectConnectionAWSConfigRequest,
|
|
162
|
+
type ConnectConnectionList as ConnectConnectionList,
|
|
163
|
+
type ConnectRoute as ConnectRoute,
|
|
164
|
+
type ConnectRouteList as ConnectRouteList,
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
export {
|
|
168
|
+
Connections as Connections,
|
|
169
|
+
type ConnectionCreateParams as ConnectionCreateParams,
|
|
170
|
+
type ConnectionUpdateParams as ConnectionUpdateParams,
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
export { Routes as Routes };
|
|
174
|
+
}
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as OperationsAPI from '../../operations';
|
|
5
|
+
import * as Shared from '../../shared';
|
|
6
|
+
import * as ConnectAPI from './connect';
|
|
7
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
8
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
9
|
+
import { path } from '../../../internal/utils/path';
|
|
10
|
+
|
|
11
|
+
export class Connections extends APIResource {
|
|
12
|
+
/**
|
|
13
|
+
* Create a Connect Connection
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```ts
|
|
17
|
+
* const operation =
|
|
18
|
+
* await client.networking.connect.connections.create({
|
|
19
|
+
* bandwidth_mbps: 50,
|
|
20
|
+
* cidrs: ['10.0.0.0/16'],
|
|
21
|
+
* name: 'my-connect-connection',
|
|
22
|
+
* provider_cidrs: ['172.16.0.0/16'],
|
|
23
|
+
* region: 'us-wdc-1',
|
|
24
|
+
* });
|
|
25
|
+
* ```
|
|
26
|
+
*/
|
|
27
|
+
create(body: ConnectionCreateParams, options?: RequestOptions): APIPromise<OperationsAPI.Operation> {
|
|
28
|
+
return this._client.post('/v1/networking/connect/connections', { body, ...options });
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Update Connect Connection details
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```ts
|
|
36
|
+
* const operation =
|
|
37
|
+
* await client.networking.connect.connections.update(
|
|
38
|
+
* 'connection_id',
|
|
39
|
+
* );
|
|
40
|
+
* ```
|
|
41
|
+
*/
|
|
42
|
+
update(
|
|
43
|
+
connectionID: string,
|
|
44
|
+
body: ConnectionUpdateParams,
|
|
45
|
+
options?: RequestOptions,
|
|
46
|
+
): APIPromise<OperationsAPI.Operation> {
|
|
47
|
+
return this._client.patch(path`/v1/networking/connect/connections/${connectionID}`, { body, ...options });
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* List all Connect Connections
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* ```ts
|
|
55
|
+
* const connectConnectionList =
|
|
56
|
+
* await client.networking.connect.connections.list();
|
|
57
|
+
* ```
|
|
58
|
+
*/
|
|
59
|
+
list(options?: RequestOptions): APIPromise<ConnectAPI.ConnectConnectionList> {
|
|
60
|
+
return this._client.get('/v1/networking/connect/connections', options);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Delete Connect Connection
|
|
65
|
+
*
|
|
66
|
+
* @example
|
|
67
|
+
* ```ts
|
|
68
|
+
* const operation =
|
|
69
|
+
* await client.networking.connect.connections.delete(
|
|
70
|
+
* 'connection_id',
|
|
71
|
+
* );
|
|
72
|
+
* ```
|
|
73
|
+
*/
|
|
74
|
+
delete(connectionID: string, options?: RequestOptions): APIPromise<OperationsAPI.Operation> {
|
|
75
|
+
return this._client.delete(path`/v1/networking/connect/connections/${connectionID}`, options);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Get Connect Connection details
|
|
80
|
+
*
|
|
81
|
+
* @example
|
|
82
|
+
* ```ts
|
|
83
|
+
* const connectConnection =
|
|
84
|
+
* await client.networking.connect.connections.get(
|
|
85
|
+
* 'connection_id',
|
|
86
|
+
* );
|
|
87
|
+
* ```
|
|
88
|
+
*/
|
|
89
|
+
get(connectionID: string, options?: RequestOptions): APIPromise<ConnectAPI.ConnectConnection> {
|
|
90
|
+
return this._client.get(path`/v1/networking/connect/connections/${connectionID}`, options);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export interface ConnectionCreateParams {
|
|
95
|
+
/**
|
|
96
|
+
* Connect Connection speed in Mbps
|
|
97
|
+
*/
|
|
98
|
+
bandwidth_mbps: ConnectAPI.ConnectBandwidthMbps;
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* CIDRs for the Connect Connection
|
|
102
|
+
*/
|
|
103
|
+
cidrs: Array<string>;
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* Name of the Connect Connection
|
|
107
|
+
*/
|
|
108
|
+
name: string;
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Provider CIDRs
|
|
112
|
+
*/
|
|
113
|
+
provider_cidrs: Array<string>;
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* Region the resource is in.
|
|
117
|
+
*/
|
|
118
|
+
region: Shared.RegionName;
|
|
119
|
+
|
|
120
|
+
/**
|
|
121
|
+
* AWS provider configuration
|
|
122
|
+
*/
|
|
123
|
+
aws?: ConnectAPI.ConnectConnectionAWSConfigRequest;
|
|
124
|
+
|
|
125
|
+
/**
|
|
126
|
+
* Tags to attach to the Connect Connection
|
|
127
|
+
*/
|
|
128
|
+
tags?: Array<string>;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export interface ConnectionUpdateParams {
|
|
132
|
+
/**
|
|
133
|
+
* Name of the Connect Connection.
|
|
134
|
+
*/
|
|
135
|
+
name?: string;
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* Tags to attach to the Connect Connection
|
|
139
|
+
*/
|
|
140
|
+
tags?: Array<string>;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
export declare namespace Connections {
|
|
144
|
+
export {
|
|
145
|
+
type ConnectionCreateParams as ConnectionCreateParams,
|
|
146
|
+
type ConnectionUpdateParams as ConnectionUpdateParams,
|
|
147
|
+
};
|
|
148
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
export {
|
|
4
|
+
Connect,
|
|
5
|
+
type ConnectBandwidthMbps,
|
|
6
|
+
type ConnectConnection,
|
|
7
|
+
type ConnectConnectionAWSConfig,
|
|
8
|
+
type ConnectConnectionAWSConfigRequest,
|
|
9
|
+
type ConnectConnectionList,
|
|
10
|
+
type ConnectRoute,
|
|
11
|
+
type ConnectRouteList,
|
|
12
|
+
} from './connect';
|
|
13
|
+
export { Connections, type ConnectionCreateParams, type ConnectionUpdateParams } from './connections';
|
|
14
|
+
export { Routes } from './routes';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as ConnectAPI from './connect';
|
|
5
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
6
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
7
|
+
|
|
8
|
+
export class Routes extends APIResource {
|
|
9
|
+
/**
|
|
10
|
+
* List all supported routes with regions for Connect.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```ts
|
|
14
|
+
* const connectRouteList =
|
|
15
|
+
* await client.networking.connect.routes.list();
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
list(options?: RequestOptions): APIPromise<ConnectAPI.ConnectRouteList> {
|
|
19
|
+
return this._client.get('/v1/networking/connect/routes', options);
|
|
20
|
+
}
|
|
21
|
+
}
|