|
| 1 | +<!-- region Generated --> |
| 2 | +# Az.Chaos |
| 3 | +This directory contains the PowerShell module for the Chaos service. |
| 4 | + |
| 5 | +--- |
| 6 | +## Info |
| 7 | +- Modifiable: yes |
| 8 | +- Generated: all |
| 9 | +- Committed: yes |
| 10 | +- Packaged: yes |
| 11 | + |
| 12 | +--- |
| 13 | +## Detail |
| 14 | +This module was primarily generated via [AutoRest](https://github.com/Azure/autorest) using the [PowerShell](https://github.com/Azure/autorest.powershell) extension. |
| 15 | + |
| 16 | +## Module Requirements |
| 17 | +- [Az.Accounts module](https://www.powershellgallery.com/packages/Az.Accounts/), version 2.7.5 or greater |
| 18 | + |
| 19 | +## Authentication |
| 20 | +AutoRest does not generate authentication code for the module. Authentication is handled via Az.Accounts by altering the HTTP payload before it is sent. |
| 21 | + |
| 22 | +## Development |
| 23 | +For information on how to develop for `Az.Chaos`, see [how-to.md](how-to.md). |
| 24 | +<!-- endregion --> |
| 25 | + |
| 26 | +### AutoRest Configuration |
| 27 | +> see https://aka.ms/autorest |
| 28 | +
|
| 29 | +``` yaml |
| 30 | +commit: 907b79c0a6a660826e54dc1f16ea14b831b201d2 |
| 31 | +require: |
| 32 | + - $(this-folder)/../../readme.azure.noprofile.md |
| 33 | +input-file: |
| 34 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/capabilities.json |
| 35 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/capabilityTypes.json |
| 36 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/experiments.json |
| 37 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/operationStatuses.json |
| 38 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/operations.json |
| 39 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/targetTypes.json |
| 40 | + - $(repo)/specification/chaos/resource-manager/Microsoft.Chaos/stable/2024-01-01/targets.json |
| 41 | + |
| 42 | +title: Chaos |
| 43 | +module-version: 0.1.0 |
| 44 | +subject-prefix: $(service-name) |
| 45 | + |
| 46 | +identity-correction-for-post: true |
| 47 | + |
| 48 | +directive: |
| 49 | + - from: swagger-document |
| 50 | + where: $.definitions.TrackedResource.properties.location |
| 51 | + transform: >- |
| 52 | + return { |
| 53 | + "type": "string", |
| 54 | + "x-ms-mutability": [ |
| 55 | + "read", |
| 56 | + "create", |
| 57 | + "update" |
| 58 | + ], |
| 59 | + "description": "The geo-location where the resource lives" |
| 60 | + } |
| 61 | +
|
| 62 | + - from: swagger-document |
| 63 | + where: $.definitions.target |
| 64 | + transform: >- |
| 65 | + return { |
| 66 | + "type": "object", |
| 67 | + "description": "Model that represents a Target resource.", |
| 68 | + "allOf": [ |
| 69 | + { |
| 70 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v2/types.json#/definitions/Resource" |
| 71 | + } |
| 72 | + ], |
| 73 | + "properties": { |
| 74 | + "systemData": { |
| 75 | + "description": "The system metadata of the target resource.", |
| 76 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v2/types.json#/definitions/systemData", |
| 77 | + "readOnly": true |
| 78 | + }, |
| 79 | + "location": { |
| 80 | + "type": "string", |
| 81 | + "description": "Location of the target resource." |
| 82 | + }, |
| 83 | + "properties": { |
| 84 | + "description": "The properties of the target resource.", |
| 85 | + "x-ms-client-flatten": true, |
| 86 | + "$ref": "#/definitions/targetProperties" |
| 87 | + } |
| 88 | + } |
| 89 | + } |
| 90 | +
|
| 91 | + - from: swagger-document |
| 92 | + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Chaos/experiments/{experimentName}"].delete.responses |
| 93 | + transform: >- |
| 94 | + return { |
| 95 | + "200": { |
| 96 | + "description": "OK" |
| 97 | + }, |
| 98 | + "202": { |
| 99 | + "description": "Asynchronous delete operation." |
| 100 | + }, |
| 101 | + "default": { |
| 102 | + "description": "Error response returned if request was unsuccessful.", |
| 103 | + "schema": { |
| 104 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v5/types.json#/definitions/ErrorResponse" |
| 105 | + } |
| 106 | + } |
| 107 | + } |
| 108 | +
|
| 109 | + - from: swagger-document |
| 110 | + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Chaos/experiments/{experimentName}"].patch.responses |
| 111 | + transform: >- |
| 112 | + return { |
| 113 | + "200": { |
| 114 | + "description": "Long running replace experiment operation.", |
| 115 | + "schema": { |
| 116 | + "$ref": "./types/experiments.json#/definitions/experiment" |
| 117 | + } |
| 118 | + }, |
| 119 | + "202": { |
| 120 | + "description": "Long running update operation.", |
| 121 | + "schema": { |
| 122 | + "$ref": "./types/experiments.json#/definitions/experiment" |
| 123 | + } |
| 124 | + }, |
| 125 | + "default": { |
| 126 | + "description": "Error response returned if request was unsuccessful.", |
| 127 | + "schema": { |
| 128 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v5/types.json#/definitions/ErrorResponse" |
| 129 | + } |
| 130 | + } |
| 131 | + } |
| 132 | +
|
| 133 | + - from: swagger-document |
| 134 | + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Chaos/experiments/{experimentName}/start"].post.responses |
| 135 | + transform: >- |
| 136 | + return { |
| 137 | + "200": { |
| 138 | + "description": "Ok.", |
| 139 | + "schema": { |
| 140 | + "$ref": "./types/experiments.json#/definitions/experiment" |
| 141 | + } |
| 142 | + }, |
| 143 | + "202": { |
| 144 | + "description": "Long running start experiment operation." |
| 145 | + }, |
| 146 | + "default": { |
| 147 | + "description": "Error response returned if request was unsuccessful.", |
| 148 | + "schema": { |
| 149 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v5/types.json#/definitions/ErrorResponse" |
| 150 | + } |
| 151 | + } |
| 152 | + } |
| 153 | +
|
| 154 | + - from: swagger-document |
| 155 | + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Chaos/experiments/{experimentName}/cancel"].post.responses |
| 156 | + transform: >- |
| 157 | + return { |
| 158 | + "200": { |
| 159 | + "description": "Ok.", |
| 160 | + "schema": { |
| 161 | + "$ref": "./types/experiments.json#/definitions/experiment" |
| 162 | + } |
| 163 | + }, |
| 164 | + "202": { |
| 165 | + "description": "Long running start experiment operation." |
| 166 | + }, |
| 167 | + "default": { |
| 168 | + "description": "Error response returned if request was unsuccessful.", |
| 169 | + "schema": { |
| 170 | + "$ref": "https://github.com/Azure/azure-rest-api-specs/blob/907b79c0a6a660826e54dc1f16ea14b831b201d2/specification/common-types/resource-management/v5/types.json#/definitions/ErrorResponse" |
| 171 | + } |
| 172 | + } |
| 173 | + } |
| 174 | +
|
| 175 | + - where: |
| 176 | + verb: New |
| 177 | + subject: Experiment |
| 178 | + variant: ^CreateViaIdentityExpanded$|^CreateExpanded$ |
| 179 | + remove: true |
| 180 | + |
| 181 | + - where: |
| 182 | + variant: ^(Create|Update).*(?<!Expanded|JsonFilePath|JsonString)$ |
| 183 | + remove: true |
| 184 | + |
| 185 | + - where: |
| 186 | + verb: Set |
| 187 | + remove: true |
| 188 | + |
| 189 | + - where: |
| 190 | + subject: OperationStatuses |
| 191 | + remove: true |
| 192 | + |
| 193 | + - where: |
| 194 | + verb: Invoke |
| 195 | + set: |
| 196 | + verb: Get |
| 197 | + |
| 198 | + - model-cmdlet: |
| 199 | + - model-name: Selector |
| 200 | + - model-name: Step |
| 201 | + - model-name: Branch |
| 202 | + - model-name: Action |
| 203 | +``` |
0 commit comments