{ "swagger": "2.0", "info": { "title": "AutomationManagement", "version": "2015-10-31", "x-ms-code-generation-settings": { "useDateTimeOffset": true } }, "host": "management.azure.com", "schemes": [ "https" ], "consumes": [ "application/json", "text/plain; charset=utf-8" ], "produces": [ "application/json", "text/plain; charset=utf-8" ], "security": [ { "azure_auth": [ "user_impersonation" ] } ], "securityDefinitions": { "azure_auth": { "type": "oauth2", "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", "flow": "implicit", "description": "Azure Active Directory OAuth2 Flow", "scopes": { "user_impersonation": "impersonate your user account" } } }, "paths": { "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/configurations/{configurationName}": { "delete": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_Delete", "description": "Delete the dsc configuration identified by configuration name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Delete DSC Configuration": { "$ref": "./examples/deleteDscConfiguration.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "configurationName", "in": "path", "required": true, "type": "string", "description": "The configuration name." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK" }, "204": { "description": "No Content" }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "get": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_Get", "description": "Retrieve the configuration identified by configuration name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Get a DSC Configuration": { "$ref": "./examples/getDscConfiguration.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "configurationName", "in": "path", "required": true, "type": "string", "description": "The configuration name." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/DscConfiguration" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "put": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_CreateOrUpdate", "description": "Create the configuration identified by configuration name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Create or Update Configuration": { "$ref": "./examples/createOrUpdateDscConfiguration.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "configurationName", "in": "path", "required": true, "type": "string", "description": "The create or update parameters for configuration." }, { "name": "parameters", "in": "body", "required": true, "schema": { "$ref": "#/definitions/DscConfigurationCreateOrUpdateParameters" }, "description": "The create or update parameters for configuration." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/DscConfiguration" } }, "201": { "description": "Created", "schema": { "$ref": "#/definitions/DscConfiguration" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "patch": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_Update", "description": "Create the configuration identified by configuration name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Create or Update Configuration": { "$ref": "./examples/updateDscConfiguration.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "configurationName", "in": "path", "required": true, "type": "string", "description": "The create or update parameters for configuration." }, { "name": "parameters", "in": "body", "schema": { "$ref": "#/definitions/DscConfigurationUpdateParameters" }, "description": "The create or update parameters for configuration." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/DscConfiguration" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/configurations/{configurationName}/content": { "get": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_GetContent", "description": "Retrieve the configuration script identified by configuration name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Get DSC Configuration content": { "$ref": "./examples/getDscConfigurationContent.json" } }, "produces": [ "text/powershell" ], "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "configurationName", "in": "path", "required": true, "type": "string", "description": "The configuration name." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "type": "file" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/configurations": { "get": { "tags": [ "DscConfiguration" ], "operationId": "DscConfiguration_ListByAutomationAccount", "description": "Retrieve a list of configurations.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/configurationoperations" }, "x-ms-examples": { "Get DSC Configuration": { "$ref": "./examples/getAllDscConfigurations.json" }, "List Paged DSC Configurations with no filter": { "$ref": "./examples/getPagedDscConfigurationsWithNoFilter.json" }, "List Paged DSC Configurations with name filter": { "$ref": "./examples/getPagedlDscConfigurationsWithNameFilter.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" }, { "name": "$filter", "in": "query", "required": false, "type": "string", "description": "The filter to apply on the operation." }, { "name": "$skip", "in": "query", "required": false, "type": "integer", "description": "The number of rows to skip." }, { "name": "$top", "in": "query", "required": false, "type": "integer", "description": "The number of rows to take." }, { "name": "$inlinecount", "in": "query", "required": false, "type": "string", "description": "Return total rows." } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/DscConfigurationListResult" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } }, "x-ms-pageable": { "nextLinkName": "nextLink" }, "x-ms-odata": "#/definitions/DscConfiguration" } } }, "definitions": { "ContentHash": { "properties": { "algorithm": { "type": "string", "description": "Gets or sets the content hash algorithm used to hash the content." }, "value": { "type": "string", "description": "Gets or sets expected hash value of the content." } }, "required": [ "algorithm", "value" ], "description": "Definition of the runbook property type." }, "ContentSource": { "properties": { "hash": { "$ref": "#/definitions/ContentHash", "description": "Gets or sets the hash." }, "type": { "type": "string", "description": "Gets or sets the content source type.", "enum": [ "embeddedContent", "uri" ], "x-ms-enum": { "name": "ContentSourceType", "modelAsString": true } }, "value": { "type": "string", "description": "Gets or sets the value of the content. This is based on the content source type." }, "version": { "type": "string", "description": "Gets or sets the version of the content." } }, "description": "Definition of the content source." }, "DscConfigurationCreateOrUpdateParameters": { "properties": { "properties": { "$ref": "#/definitions/DscConfigurationCreateOrUpdateProperties", "x-ms-client-flatten": true, "description": "Gets or sets configuration create or update properties." }, "name": { "type": "string", "description": "Gets or sets name of the resource." }, "location": { "type": "string", "description": "Gets or sets the location of the resource." }, "tags": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Gets or sets the tags attached to the resource." } }, "required": [ "properties" ], "description": "The parameters supplied to the create or update configuration operation." }, "DscConfigurationListResult": { "properties": { "value": { "type": "array", "items": { "$ref": "#/definitions/DscConfiguration" }, "description": "Gets or sets a list of configurations." }, "nextLink": { "type": "string", "description": "Gets or sets the next link." }, "totalCount": { "type": "integer", "description": "Gets the total number of configurations matching filter criteria." } }, "description": "The response model for the list configuration operation." }, "DscConfigurationCreateOrUpdateProperties": { "properties": { "logVerbose": { "type": "boolean", "description": "Gets or sets verbose log option." }, "logProgress": { "type": "boolean", "description": "Gets or sets progress log option." }, "source": { "$ref": "#/definitions/ContentSource", "description": "Gets or sets the source." }, "parameters": { "type": "object", "additionalProperties": { "$ref": "#/definitions/DscConfigurationParameter" }, "description": "Gets or sets the configuration parameters." }, "description": { "type": "string", "description": "Gets or sets the description of the configuration." } }, "required": [ "source" ], "description": "The properties to create or update configuration." }, "DscConfigurationParameter": { "properties": { "type": { "type": "string", "description": "Gets or sets the type of the parameter." }, "isMandatory": { "type": "boolean", "description": "Gets or sets a Boolean value to indicate whether the parameter is mandatory or not." }, "position": { "type": "integer", "format": "int32", "description": "Get or sets the position of the parameter." }, "defaultValue": { "type": "string", "description": "Gets or sets the default value of parameter." } }, "description": "Definition of the configuration parameter type." }, "DscConfigurationUpdateParameters": { "properties": { "properties": { "$ref": "#/definitions/DscConfigurationCreateOrUpdateProperties", "x-ms-client-flatten": true, "description": "Gets or sets configuration create or update properties." }, "name": { "type": "string", "description": "Gets or sets name of the resource." }, "tags": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Gets or sets the tags attached to the resource." } }, "description": "The parameters supplied to the create or update configuration operation." }, "DscConfigurationProperties": { "properties": { "provisioningState": { "type": "string", "description": "Gets or sets the provisioning state of the configuration.", "enum": [ "Succeeded" ], "x-ms-enum": { "name": "DscConfigurationProvisioningState", "modelAsString": false } }, "jobCount": { "type": "integer", "format": "int32", "description": "Gets or sets the job count of the configuration." }, "parameters": { "type": "object", "additionalProperties": { "$ref": "#/definitions/DscConfigurationParameter" }, "description": "Gets or sets the configuration parameters." }, "source": { "$ref": "#/definitions/ContentSource", "description": "Gets or sets the source." }, "state": { "type": "string", "description": "Gets or sets the state of the configuration.", "enum": [ "New", "Edit", "Published" ], "x-ms-enum": { "name": "DscConfigurationState", "modelAsString": true } }, "logVerbose": { "type": "boolean", "description": "Gets or sets verbose log option." }, "creationTime": { "type": "string", "format": "date-time", "description": "Gets or sets the creation time.", "x-nullable": false }, "lastModifiedTime": { "type": "string", "format": "date-time", "description": "Gets or sets the last modified time.", "x-nullable": false }, "nodeConfigurationCount": { "type": "integer", "description": "Gets the number of compiled node configurations.", "x-nullable": false }, "description": { "type": "string", "description": "Gets or sets the description." } }, "description": "Definition of the configuration property type." }, "DscConfiguration": { "type": "object", "properties": { "properties": { "$ref": "#/definitions/DscConfigurationProperties", "x-ms-client-flatten": true, "description": "Gets or sets the configuration properties." }, "etag": { "type": "string", "description": "Gets or sets the etag of the resource." } }, "allOf": [ { "$ref": "../../common/v1/definitions.json#/definitions/TrackedResource" } ], "description": "Definition of the configuration type." } }, "parameters": {} }