@scaleway/sdk-flexibleip 1.0.1
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/LICENSE +191 -0
- package/dist/index.gen.cjs +4 -0
- package/dist/index.gen.d.ts +5 -0
- package/dist/index.gen.js +4 -0
- package/dist/v1alpha1/api.gen.cjs +212 -0
- package/dist/v1alpha1/api.gen.d.ts +99 -0
- package/dist/v1alpha1/api.gen.js +212 -0
- package/dist/v1alpha1/content.gen.cjs +12 -0
- package/dist/v1alpha1/content.gen.d.ts +5 -0
- package/dist/v1alpha1/content.gen.js +12 -0
- package/dist/v1alpha1/index.gen.cjs +21 -0
- package/dist/v1alpha1/index.gen.d.ts +5 -0
- package/dist/v1alpha1/index.gen.js +21 -0
- package/dist/v1alpha1/marshalling.gen.cjs +114 -0
- package/dist/v1alpha1/marshalling.gen.d.ts +13 -0
- package/dist/v1alpha1/marshalling.gen.js +114 -0
- package/dist/v1alpha1/types.gen.d.ts +304 -0
- package/dist/v1alpha1/validation-rules.gen.cjs +12 -0
- package/dist/v1alpha1/validation-rules.gen.d.ts +9 -0
- package/dist/v1alpha1/validation-rules.gen.js +12 -0
- package/package.json +51 -0
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
import type { Zone as ScwZone } from '@scaleway/sdk-client';
|
|
2
|
+
export type FlexibleIPStatus = 'unknown' | 'ready' | 'updating' | 'attached' | 'error' | 'detaching' | 'locked';
|
|
3
|
+
export type ListFlexibleIPsRequestOrderBy = 'created_at_asc' | 'created_at_desc';
|
|
4
|
+
export type MACAddressStatus = 'unknown' | 'ready' | 'updating' | 'used' | 'error' | 'deleting';
|
|
5
|
+
export type MACAddressType = 'unknown_type' | 'vmware' | 'xen' | 'kvm';
|
|
6
|
+
export interface MACAddress {
|
|
7
|
+
/**
|
|
8
|
+
* ID of the flexible IP.
|
|
9
|
+
*/
|
|
10
|
+
id: string;
|
|
11
|
+
/**
|
|
12
|
+
* MAC address of the Virtual MAC.
|
|
13
|
+
*/
|
|
14
|
+
macAddress: string;
|
|
15
|
+
/**
|
|
16
|
+
* Type of virtual MAC.
|
|
17
|
+
*/
|
|
18
|
+
macType: MACAddressType;
|
|
19
|
+
/**
|
|
20
|
+
* Status of virtual MAC.
|
|
21
|
+
*/
|
|
22
|
+
status: MACAddressStatus;
|
|
23
|
+
/**
|
|
24
|
+
* Date on which the virtual MAC was last updated.
|
|
25
|
+
*/
|
|
26
|
+
updatedAt?: Date;
|
|
27
|
+
/**
|
|
28
|
+
* Date on which the virtual MAC was created.
|
|
29
|
+
*/
|
|
30
|
+
createdAt?: Date;
|
|
31
|
+
/**
|
|
32
|
+
* MAC address IP Availability Zone.
|
|
33
|
+
*/
|
|
34
|
+
zone: ScwZone;
|
|
35
|
+
}
|
|
36
|
+
export interface FlexibleIP {
|
|
37
|
+
/**
|
|
38
|
+
* ID of the flexible IP.
|
|
39
|
+
*/
|
|
40
|
+
id: string;
|
|
41
|
+
/**
|
|
42
|
+
* ID of the Organization the flexible IP is attached to.
|
|
43
|
+
*/
|
|
44
|
+
organizationId: string;
|
|
45
|
+
/**
|
|
46
|
+
* ID of the Project the flexible IP is attached to.
|
|
47
|
+
*/
|
|
48
|
+
projectId: string;
|
|
49
|
+
/**
|
|
50
|
+
* Flexible IP description.
|
|
51
|
+
*/
|
|
52
|
+
description: string;
|
|
53
|
+
/**
|
|
54
|
+
* Flexible IP tags.
|
|
55
|
+
*/
|
|
56
|
+
tags: string[];
|
|
57
|
+
/**
|
|
58
|
+
* Date on which the flexible IP was last updated.
|
|
59
|
+
*/
|
|
60
|
+
updatedAt?: Date;
|
|
61
|
+
/**
|
|
62
|
+
* Date on which the flexible IP was created.
|
|
63
|
+
*/
|
|
64
|
+
createdAt?: Date;
|
|
65
|
+
/**
|
|
66
|
+
* - ready : flexible IP is created and ready to be attached to a server or to be associated with a virtual MAC.
|
|
67
|
+
- updating: flexible IP is being attached to a server or a virtual MAC operation is ongoing
|
|
68
|
+
- attached: flexible IP is attached to a server
|
|
69
|
+
- error: a flexible IP operation resulted in an error
|
|
70
|
+
- detaching: flexible IP is being detached from a server
|
|
71
|
+
- locked: the resource of the flexible IP is locked.
|
|
72
|
+
*/
|
|
73
|
+
status: FlexibleIPStatus;
|
|
74
|
+
/**
|
|
75
|
+
* IP of the flexible IP.
|
|
76
|
+
*/
|
|
77
|
+
ipAddress: string;
|
|
78
|
+
/**
|
|
79
|
+
* MAC address of the flexible IP.
|
|
80
|
+
*/
|
|
81
|
+
macAddress?: MACAddress;
|
|
82
|
+
/**
|
|
83
|
+
* ID of the server linked to the flexible IP.
|
|
84
|
+
*/
|
|
85
|
+
serverId?: string;
|
|
86
|
+
/**
|
|
87
|
+
* Reverse DNS value.
|
|
88
|
+
*/
|
|
89
|
+
reverse: string;
|
|
90
|
+
/**
|
|
91
|
+
* Availability Zone of the flexible IP.
|
|
92
|
+
*/
|
|
93
|
+
zone: ScwZone;
|
|
94
|
+
}
|
|
95
|
+
export type AttachFlexibleIPRequest = {
|
|
96
|
+
/**
|
|
97
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
98
|
+
*/
|
|
99
|
+
zone?: ScwZone;
|
|
100
|
+
/**
|
|
101
|
+
* Multiple IDs can be provided, but note that flexible IPs must belong to the same MAC group (see details about MAC groups).
|
|
102
|
+
*/
|
|
103
|
+
fipsIds: string[];
|
|
104
|
+
/**
|
|
105
|
+
* ID of the server on which to attach the flexible IPs.
|
|
106
|
+
*/
|
|
107
|
+
serverId: string;
|
|
108
|
+
};
|
|
109
|
+
export interface AttachFlexibleIPsResponse {
|
|
110
|
+
/**
|
|
111
|
+
* Total count of flexible IPs that are being updated.
|
|
112
|
+
*/
|
|
113
|
+
totalCount: number;
|
|
114
|
+
/**
|
|
115
|
+
* List of flexible IPs in an updating state.
|
|
116
|
+
*/
|
|
117
|
+
flexibleIps: FlexibleIP[];
|
|
118
|
+
}
|
|
119
|
+
export type CreateFlexibleIPRequest = {
|
|
120
|
+
/**
|
|
121
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
122
|
+
*/
|
|
123
|
+
zone?: ScwZone;
|
|
124
|
+
/**
|
|
125
|
+
* ID of the project to associate with the Flexible IP.
|
|
126
|
+
*/
|
|
127
|
+
projectId?: string;
|
|
128
|
+
/**
|
|
129
|
+
* Flexible IP description (max. of 255 characters).
|
|
130
|
+
*/
|
|
131
|
+
description: string;
|
|
132
|
+
/**
|
|
133
|
+
* Tags to associate to the flexible IP.
|
|
134
|
+
*/
|
|
135
|
+
tags?: string[];
|
|
136
|
+
/**
|
|
137
|
+
* ID of the server to which the newly created flexible IP will be attached.
|
|
138
|
+
*/
|
|
139
|
+
serverId?: string;
|
|
140
|
+
/**
|
|
141
|
+
* Value of the reverse DNS.
|
|
142
|
+
*/
|
|
143
|
+
reverse?: string;
|
|
144
|
+
/**
|
|
145
|
+
* Defines whether the flexible IP has an IPv6 address.
|
|
146
|
+
*/
|
|
147
|
+
isIpv6: boolean;
|
|
148
|
+
};
|
|
149
|
+
export type DeleteFlexibleIPRequest = {
|
|
150
|
+
/**
|
|
151
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
152
|
+
*/
|
|
153
|
+
zone?: ScwZone;
|
|
154
|
+
/**
|
|
155
|
+
* ID of the flexible IP to delete.
|
|
156
|
+
*/
|
|
157
|
+
fipId: string;
|
|
158
|
+
};
|
|
159
|
+
export type DeleteMACAddrRequest = {
|
|
160
|
+
/**
|
|
161
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
162
|
+
*/
|
|
163
|
+
zone?: ScwZone;
|
|
164
|
+
/**
|
|
165
|
+
* If the flexible IP belongs to a MAC group, the MAC will be removed from both the MAC group and flexible IP.
|
|
166
|
+
*/
|
|
167
|
+
fipId: string;
|
|
168
|
+
};
|
|
169
|
+
export type DetachFlexibleIPRequest = {
|
|
170
|
+
/**
|
|
171
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
172
|
+
*/
|
|
173
|
+
zone?: ScwZone;
|
|
174
|
+
/**
|
|
175
|
+
* List of flexible IP IDs to detach from a server. Multiple IDs can be provided. Note that flexible IPs must belong to the same MAC group.
|
|
176
|
+
*/
|
|
177
|
+
fipsIds: string[];
|
|
178
|
+
};
|
|
179
|
+
export interface DetachFlexibleIPsResponse {
|
|
180
|
+
/**
|
|
181
|
+
* Total count of flexible IPs that are being detached.
|
|
182
|
+
*/
|
|
183
|
+
totalCount: number;
|
|
184
|
+
/**
|
|
185
|
+
* List of flexible IPs in a detaching state.
|
|
186
|
+
*/
|
|
187
|
+
flexibleIps: FlexibleIP[];
|
|
188
|
+
}
|
|
189
|
+
export type DuplicateMACAddrRequest = {
|
|
190
|
+
/**
|
|
191
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
192
|
+
*/
|
|
193
|
+
zone?: ScwZone;
|
|
194
|
+
/**
|
|
195
|
+
* Note that the flexible IPs need to be attached to the same server.
|
|
196
|
+
*/
|
|
197
|
+
fipId: string;
|
|
198
|
+
/**
|
|
199
|
+
* Note that flexible IPs need to be attached to the same server.
|
|
200
|
+
*/
|
|
201
|
+
duplicateFromFipId: string;
|
|
202
|
+
};
|
|
203
|
+
export type GenerateMACAddrRequest = {
|
|
204
|
+
/**
|
|
205
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
206
|
+
*/
|
|
207
|
+
zone?: ScwZone;
|
|
208
|
+
/**
|
|
209
|
+
* ID of the flexible IP for which to generate a virtual MAC.
|
|
210
|
+
*/
|
|
211
|
+
fipId: string;
|
|
212
|
+
/**
|
|
213
|
+
* TODO.
|
|
214
|
+
*/
|
|
215
|
+
macType: MACAddressType;
|
|
216
|
+
};
|
|
217
|
+
export type GetFlexibleIPRequest = {
|
|
218
|
+
/**
|
|
219
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
220
|
+
*/
|
|
221
|
+
zone?: ScwZone;
|
|
222
|
+
/**
|
|
223
|
+
* ID of the flexible IP.
|
|
224
|
+
*/
|
|
225
|
+
fipId: string;
|
|
226
|
+
};
|
|
227
|
+
export type ListFlexibleIPsRequest = {
|
|
228
|
+
/**
|
|
229
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
230
|
+
*/
|
|
231
|
+
zone?: ScwZone;
|
|
232
|
+
/**
|
|
233
|
+
* Sort order of the returned flexible IPs.
|
|
234
|
+
*/
|
|
235
|
+
orderBy?: ListFlexibleIPsRequestOrderBy;
|
|
236
|
+
/**
|
|
237
|
+
* Page number.
|
|
238
|
+
*/
|
|
239
|
+
page?: number;
|
|
240
|
+
/**
|
|
241
|
+
* Maximum number of flexible IPs per page.
|
|
242
|
+
*/
|
|
243
|
+
pageSize?: number;
|
|
244
|
+
/**
|
|
245
|
+
* Filter by tag, only flexible IPs with one or more matching tags will be returned.
|
|
246
|
+
*/
|
|
247
|
+
tags?: string[];
|
|
248
|
+
/**
|
|
249
|
+
* Filter by status, only flexible IPs with this status will be returned.
|
|
250
|
+
*/
|
|
251
|
+
status?: FlexibleIPStatus[];
|
|
252
|
+
/**
|
|
253
|
+
* Filter by server IDs, only flexible IPs with these server IDs will be returned.
|
|
254
|
+
*/
|
|
255
|
+
serverIds?: string[];
|
|
256
|
+
/**
|
|
257
|
+
* Filter by Organization ID, only flexible IPs from this Organization will be returned.
|
|
258
|
+
*/
|
|
259
|
+
organizationId?: string;
|
|
260
|
+
/**
|
|
261
|
+
* Filter by Project ID, only flexible IPs from this Project will be returned.
|
|
262
|
+
*/
|
|
263
|
+
projectId?: string;
|
|
264
|
+
};
|
|
265
|
+
export interface ListFlexibleIPsResponse {
|
|
266
|
+
/**
|
|
267
|
+
* Total count of matching flexible IPs.
|
|
268
|
+
*/
|
|
269
|
+
totalCount: number;
|
|
270
|
+
/**
|
|
271
|
+
* List of all flexible IPs.
|
|
272
|
+
*/
|
|
273
|
+
flexibleIps: FlexibleIP[];
|
|
274
|
+
}
|
|
275
|
+
export type MoveMACAddrRequest = {
|
|
276
|
+
/**
|
|
277
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
278
|
+
*/
|
|
279
|
+
zone?: ScwZone;
|
|
280
|
+
fipId: string;
|
|
281
|
+
dstFipId: string;
|
|
282
|
+
};
|
|
283
|
+
export type UpdateFlexibleIPRequest = {
|
|
284
|
+
/**
|
|
285
|
+
* Zone to target. If none is passed will use default zone from the config.
|
|
286
|
+
*/
|
|
287
|
+
zone?: ScwZone;
|
|
288
|
+
/**
|
|
289
|
+
* ID of the flexible IP to update.
|
|
290
|
+
*/
|
|
291
|
+
fipId: string;
|
|
292
|
+
/**
|
|
293
|
+
* Flexible IP description (max. 255 characters).
|
|
294
|
+
*/
|
|
295
|
+
description?: string;
|
|
296
|
+
/**
|
|
297
|
+
* Tags associated with the flexible IP.
|
|
298
|
+
*/
|
|
299
|
+
tags?: string[];
|
|
300
|
+
/**
|
|
301
|
+
* Value of the reverse DNS.
|
|
302
|
+
*/
|
|
303
|
+
reverse?: string;
|
|
304
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const ListFlexibleIPsRequest = {
|
|
4
|
+
page: {
|
|
5
|
+
greaterThan: 0
|
|
6
|
+
},
|
|
7
|
+
pageSize: {
|
|
8
|
+
greaterThan: 0,
|
|
9
|
+
lessThanOrEqual: 100
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
exports.ListFlexibleIPsRequest = ListFlexibleIPsRequest;
|
package/package.json
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@scaleway/sdk-flexibleip",
|
|
3
|
+
"version": "1.0.1",
|
|
4
|
+
"description": "Scaleway SDK flexibleip",
|
|
5
|
+
"types": "dist/index.d.ts",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist"
|
|
8
|
+
],
|
|
9
|
+
"type": "module",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"types": "./dist/index.gen.d.ts",
|
|
13
|
+
"import": "./dist/index.gen.js",
|
|
14
|
+
"require": "./dist/index.gen.cjs",
|
|
15
|
+
"default": "./dist/index.gen.js"
|
|
16
|
+
},
|
|
17
|
+
"./*": {
|
|
18
|
+
"types": "./dist/*/index.gen.d.ts",
|
|
19
|
+
"import": "./dist/*/index.gen.js",
|
|
20
|
+
"require": "./dist/*/index.gen.cjs",
|
|
21
|
+
"default": "./dist/*/index.gen.js"
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"repository": {
|
|
25
|
+
"type": "git",
|
|
26
|
+
"directory": "packages_generated/flexibleip"
|
|
27
|
+
},
|
|
28
|
+
"engines": {
|
|
29
|
+
"node": ">=20.18.3"
|
|
30
|
+
},
|
|
31
|
+
"dependencies": {
|
|
32
|
+
"@scaleway/random-name": "5.1.1",
|
|
33
|
+
"@scaleway/sdk-std": "1.0.1"
|
|
34
|
+
},
|
|
35
|
+
"peerDependencies": {
|
|
36
|
+
"@scaleway/sdk-client": "^1.2.1"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@scaleway/sdk-client": "^1.2.1"
|
|
40
|
+
},
|
|
41
|
+
"bundledDependencies": [
|
|
42
|
+
"@scaleway/random-name"
|
|
43
|
+
],
|
|
44
|
+
"scripts": {
|
|
45
|
+
"package:check": "pnpm publint",
|
|
46
|
+
"typecheck": "tsc --noEmit",
|
|
47
|
+
"type:generate": "tsc --declaration -p tsconfig.build.json",
|
|
48
|
+
"build": "vite build --config vite.config.ts && pnpm run type:generate",
|
|
49
|
+
"build:profile": "npx vite-bundle-visualizer -c vite.config.ts"
|
|
50
|
+
}
|
|
51
|
+
}
|