Skip to content

Commit 3c7d65f

Browse files
Merge pull request #6 from StackVista/stac-23211
Stac 23211
2 parents 27640a2 + c422b1e commit 3c7d65f

2 files changed

Lines changed: 30 additions & 1 deletion

File tree

spec/openapi.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ paths:
3535
/stackpack/{stackPackName}/provision: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fprovision" }
3636
/stackpack/{stackPackName}/deprovision/{stackPackInstanceId}: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fdeprovision%2F%7BstackPackInstanceId%7D" }
3737
/stackpack/{stackPackName}/upgrade: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fupgrade" }
38+
/stackpack/{stackPackName}/downgrade: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fdowngrade" }
3839
/stackpack/{stackPackName}/versions: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fversions" }
3940
/stackpack/{stackPackName}/versions/{version}: { $ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fversions%2F%7Bversion%7D" }
4041
/stackpack/{stackPackName}/confirm-manual-steps/{stackPackInstanceId}: {$ref: "stackpack.xapi.yaml#/paths/%2Fstackpack%2F%7BstackPackName%7D%2Fconfirm-manual-steps%2F%7BstackPackInstanceId%7D"}

spec/stackpack.xapi.yaml

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ paths:
9797
required: true
9898
schema:
9999
type: string
100+
- $ref: "#/components/parameters/stackPackVersion"
100101
summary: "Provision API"
101102
operationId: provisionDetails
102103
description: "Provision details"
@@ -168,6 +169,26 @@ paths:
168169
type: string
169170
"500":
170171
$ref: "generic_error_handling.xapi.yaml#/components/responses/genericErrorsResponse"
172+
173+
/stackpack/{stackPackName}/downgrade:
174+
post:
175+
tags:
176+
- stackpack
177+
parameters:
178+
- $ref: "#/components/parameters/stackPackName"
179+
- $ref: "#/components/parameters/requiredStackPackVersion"
180+
summary: "Downgrade API"
181+
operationId: downgradeStackPack
182+
description: "Downgrade a StackPack to an older version. Only supported for StackPacks 2.0; the target version must be lower than the currently installed version."
183+
responses:
184+
"200":
185+
description: "successful"
186+
content:
187+
application/json:
188+
schema:
189+
type: string
190+
"500":
191+
$ref: "generic_error_handling.xapi.yaml#/components/responses/genericErrorsResponse"
171192
/stackpack/{stackPackName}/versions:
172193
get:
173194
tags:
@@ -338,7 +359,14 @@ components:
338359
required: false
339360
schema:
340361
type: string
341-
description: "Optional version string (e.g. '1.2.3'). If not provided, validates the latest version."
362+
description: "Optional version string (e.g. '1.2.3'). If not provided, the latest version is used. When provisioning, the StackPack cannot already be installed at a different version."
363+
requiredStackPackVersion:
364+
in: query
365+
name: version
366+
required: true
367+
schema:
368+
type: string
369+
description: "Version string (e.g. '1.2.3') to downgrade to. Must be lower than the currently installed version."
342370
version:
343371
in: path
344372
name: version

0 commit comments

Comments
 (0)