Skip to content

Commit 5e8003b

Browse files
author
CI bot
committed
Definitions Update assets_manager
2 parents 7255fdb + a678d0c commit 5e8003b

File tree

6 files changed

+274
-6
lines changed

6 files changed

+274
-6
lines changed

alsdkdefs/apis/assets_manager/api/assets_manager.v1.html

Lines changed: 44 additions & 6 deletions
Large diffs are not rendered by default.

alsdkdefs/apis/assets_manager/assets_manager.v1.yaml

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,87 @@ paths:
154154
$ref: 'responses.yaml#/Forbidden'
155155
'404':
156156
$ref: 'responses.yaml#/DeploymentNotFound'
157+
/assets_manager/v1/{account_id}/deployments/{deployment_id}/networks:
158+
post:
159+
tags:
160+
- Network Operations
161+
operationId: create_network
162+
summary: Create Network
163+
description: Create network
164+
security:
165+
- x-aims-auth-token: []
166+
parameters:
167+
- $ref: 'parameters.yaml#/UrlParamAccountId'
168+
- $ref: 'parameters.yaml#/UrlParamDeploymentId'
169+
- $ref: 'parameters.yaml#/ForceLargeNetwork'
170+
requestBody:
171+
required: true
172+
content:
173+
application/json:
174+
examples:
175+
JSON:
176+
$ref: 'examples.yaml#/CreateNetworkJSON'
177+
schema:
178+
$ref: 'schemas.yaml#/CreateNetwork'
179+
responses:
180+
'200':
181+
description: OK
182+
content:
183+
application/json:
184+
examples:
185+
JSON:
186+
$ref: 'examples.yaml#/NetworkJSON'
187+
schema:
188+
$ref: 'schemas.yaml#/Network'
189+
'400':
190+
description: Bad Request
191+
content:
192+
application/json:
193+
schema:
194+
$ref: 'responses.yaml#/CreateNetworkError'
195+
text/plain:
196+
schema:
197+
type: string
198+
199+
/assets_manager/v1/{account_id}/deployments/{deployment_id}/networks/{network_uuid}:
200+
put:
201+
tags:
202+
- Network Operations
203+
operationId: update_network
204+
summary: Update Network
205+
description: Update network
206+
security:
207+
- x-aims-auth-token: []
208+
parameters:
209+
- $ref: 'parameters.yaml#/UrlParamAccountId'
210+
- $ref: 'parameters.yaml#/UrlParamDeploymentId'
211+
- $ref: 'parameters.yaml#/UrlParamNetworkUuid'
212+
- $ref: 'parameters.yaml#/ForceLargeNetwork'
213+
requestBody:
214+
required: true
215+
content:
216+
application/json:
217+
examples:
218+
JSON:
219+
$ref: 'examples.yaml#/UpdateNetworkJSON'
220+
schema:
221+
$ref: 'schemas.yaml#/UpdateNetwork'
222+
responses:
223+
'200':
224+
description: OK
225+
content:
226+
application/json:
227+
examples:
228+
JSON:
229+
$ref: 'examples.yaml#/NetworkJSON'
230+
schema:
231+
$ref: 'schemas.yaml#/Network'
232+
'400':
233+
description: Bad Request
234+
content:
235+
application/json:
236+
schema:
237+
$ref: 'responses.yaml#/UpdateNetworkError'
238+
text/plain:
239+
schema:
240+
type: string

alsdkdefs/apis/assets_manager/examples.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,21 @@
1+
CreateNetworkJSON:
2+
value:
3+
network_name: Network
4+
cidr_ranges: ['10.0.0.0/16']
5+
6+
UpdateNetworkJSON:
7+
value:
8+
cidr_ranges: ['10.0.0.0/16', '10.1.0.0/16']
9+
10+
NetworkJSON:
11+
value:
12+
key: /dc/network/2C6B298D-B6C6-4798-B498-2180FC1F4996
13+
network_name: Network
14+
network_uuid: 88FCC8F6-EEE8-EE07-6AC5-3E88E85AE310
15+
cidr_ranges: ['10.0.0.0/16']
16+
claim_key: e318c8e213d3accf26aa07fc33e6154b055135862c49b8c5e1
17+
span_port_enabled: false
18+
119
ScopeJSON:
220
value:
321
- deployment_id: 843BD5F3-583D-48D7-B929-616B100D6B7B

alsdkdefs/apis/assets_manager/parameters.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
ForceLargeNetwork:
2+
schema:
3+
type: boolean
4+
default: false
5+
description: |-
6+
The option is used to suppress the network size validation if specified as
7+
`true`. By default the service checks if the number of IP addresses is that
8+
big for a typical appliance to complete network discovery scans within a
9+
reasonable time.
10+
name: force_large_network
11+
in: query
12+
required: false
13+
114
WriteOption:
215
schema:
316
type: boolean
@@ -9,6 +22,7 @@ WriteOption:
922
name: write
1023
in: query
1124
required: false
25+
1226
UrlParamAccountId:
1327
schema:
1428
type: string
@@ -19,10 +33,19 @@ UrlParamAccountId:
1933
The AIMS account ID whose assets are being accessed. Only valid account IDs are acceptable.
2034
Invalid account IDs result in an `HTTP 404 Not Found` or `HTTP 403 Forbidden`, depending on
2135
the client's access level.
36+
2237
UrlParamDeploymentId:
2338
schema:
2439
type: string
2540
name: deployment_id
2641
in: path
2742
required: true
2843
description: The ID of the deployment source as represented in the deployments service (uppercase UUID).
44+
45+
UrlParamNetworkUuid:
46+
schema:
47+
type: string
48+
name: network_uuid
49+
in: path
50+
required: true
51+
description: The UUID of the network asset as represented in the assets service (uppercase UUID).
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
DeploymentNotFound:
22
description: '`deployment not found`'
3+
34
Unauthorized:
45
description: '`Unauthorized`. The provided `x-aims-auth-token` header could not be authenticated.'
6+
57
Forbidden:
68
description: '`Forbidden`. Insufficient permissions.'
9+
10+
CreateNetworkError:
11+
description: Bad Request
12+
oneOf:
13+
- $ref: 'schemas.yaml#/ErrorTooLargeNetwork'
14+
15+
UpdateNetworkError:
16+
description: Bad Request
17+
oneOf:
18+
- $ref: 'schemas.yaml#/ErrorTooLargeNetwork'

alsdkdefs/apis/assets_manager/schemas.yaml

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,86 @@
1+
CreateNetwork:
2+
description: A network to be created
3+
type: object
4+
properties:
5+
network_name:
6+
$ref: '#/AssetName'
7+
cidr_ranges:
8+
type: array
9+
items:
10+
$ref: '#/CidrBlock'
11+
public_cidr_ranges:
12+
type: array
13+
items:
14+
$ref: '#/CidrBlock'
15+
span_port_enabled:
16+
$ref: '#/SpanPortEnabled'
17+
required:
18+
- network_name
19+
- cidr_ranges
20+
21+
UpdateNetwork:
22+
description: A network to be updated
23+
type: object
24+
properties:
25+
network_name:
26+
$ref: '#/AssetName'
27+
cidr_ranges:
28+
type: array
29+
items:
30+
$ref: '#/CidrBlock'
31+
public_cidr_ranges:
32+
type: array
33+
items:
34+
$ref: '#/CidrBlock'
35+
span_port_enabled:
36+
$ref: '#/SpanPortEnabled'
37+
38+
Network:
39+
description: A network
40+
type: object
41+
properties:
42+
key:
43+
$ref: '#/AssetKey'
44+
network_name:
45+
$ref: '#/AssetName'
46+
network_uuid:
47+
$ref: '#/UUID'
48+
cidr_ranges:
49+
type: array
50+
minItems: 1
51+
items:
52+
$ref: '#/CidrBlock'
53+
claim_key:
54+
$ref: '#/ClaimKey'
55+
public_cidr_ranges:
56+
type: array
57+
items:
58+
$ref: '#/CidrBlock'
59+
span_port_enabled:
60+
$ref: '#/SpanPortEnabled'
61+
required:
62+
- key
63+
- network_name
64+
- cidr_ranges
65+
- claim_key
66+
- span_port_enabled
67+
68+
ErrorTooLargeNetwork:
69+
title: Too large network
70+
type: object
71+
properties:
72+
errorinfo:
73+
type: object
74+
properties:
75+
code:
76+
type: string
77+
enum:
78+
- too_large_network
79+
description:
80+
type: string
81+
error_id:
82+
$ref: '#/UUID'
83+
184
ImportSummary:
285
description: 'Import result summary'
386
type: object
@@ -98,3 +181,13 @@ AssetType:
98181
AssetName:
99182
type: string
100183
description: Asset Name
184+
185+
ClaimKey:
186+
type: string
187+
188+
SpanPortEnabled:
189+
type: boolean
190+
default: false
191+
192+
UUID:
193+
type: string

0 commit comments

Comments
 (0)