{ "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" ], "produces": [ "application/json" ], "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}/certificates/{certificateName}": { "delete": { "tags": [ "Certificate" ], "operationId": "Certificate_Delete", "description": "Delete the certificate.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/certificateoperations" }, "x-ms-examples": { "Delete a certificate": { "$ref": "./examples/deleteCertificate.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "certificateName", "in": "path", "required": true, "type": "string", "description": "The name of certificate." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK" }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "get": { "tags": [ "Certificate" ], "operationId": "Certificate_Get", "description": "Retrieve the certificate identified by certificate name.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/certificateoperations" }, "x-ms-examples": { "Get a certificate": { "$ref": "./examples/getCertificate.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "certificateName", "in": "path", "required": true, "type": "string", "description": "The name of certificate." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/Certificate" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "put": { "tags": [ "Certificate" ], "operationId": "Certificate_CreateOrUpdate", "description": "Create a certificate.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/certificateoperations" }, "x-ms-examples": { "Create or update a certificate": { "$ref": "./examples/createOrUpdateCertificate.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "certificateName", "in": "path", "required": true, "type": "string", "description": "The parameters supplied to the create or update certificate operation." }, { "name": "parameters", "in": "body", "required": true, "schema": { "$ref": "#/definitions/CertificateCreateOrUpdateParameters" }, "description": "The parameters supplied to the create or update certificate operation." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "201": { "description": "Created", "schema": { "$ref": "#/definitions/Certificate" } }, "200": { "description": "OK", "schema": { "$ref": "#/definitions/Certificate" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } } }, "patch": { "tags": [ "Certificate" ], "operationId": "Certificate_Update", "description": "Update a certificate.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/certificateoperations" }, "x-ms-examples": { "Update a certificate": { "$ref": "./examples/updateCertificate.json" } }, "parameters": [ { "$ref": "../../common/v1/definitions.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/AutomationAccountNameParameter" }, { "name": "certificateName", "in": "path", "required": true, "type": "string", "description": "The parameters supplied to the update certificate operation." }, { "name": "parameters", "in": "body", "required": true, "schema": { "$ref": "#/definitions/CertificateUpdateParameters" }, "description": "The parameters supplied to the update certificate operation." }, { "$ref": "../../common/v1/definitions.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../common/v1/definitions.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/Certificate" } }, "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}/certificates": { "get": { "tags": [ "Certificate" ], "operationId": "Certificate_ListByAutomationAccount", "description": "Retrieve a list of certificates.", "externalDocs": { "url": "http://aka.ms/azureautomationsdk/certificateoperations" }, "x-ms-examples": { "List certificates": { "$ref": "./examples/listCertificatesByAutomationAccount.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" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/CertificateListResult" } }, "default": { "description": "Automation error response describing why the operation failed.", "schema": { "$ref": "../../common/v1/definitions.json#/definitions/ErrorResponse" } } }, "x-ms-pageable": { "nextLinkName": "nextLink" } } } }, "definitions": { "CertificateCreateOrUpdateProperties": { "properties": { "base64Value": { "type": "string", "description": "Gets or sets the base64 encoded value of the certificate." }, "description": { "type": "string", "description": "Gets or sets the description of the certificate." }, "thumbprint": { "type": "string", "description": "Gets or sets the thumbprint of the certificate." }, "isExportable": { "type": "boolean", "description": "Gets or sets the is exportable flag of the certificate.", "x-nullable": false } }, "required": [ "base64Value" ], "description": "The properties of the create certificate operation." }, "CertificateCreateOrUpdateParameters": { "properties": { "name": { "type": "string", "description": "Gets or sets the name of the certificate." }, "properties": { "$ref": "#/definitions/CertificateCreateOrUpdateProperties", "x-ms-client-flatten": true, "description": "Gets or sets the properties of the certificate." } }, "required": [ "name", "properties" ], "description": "The parameters supplied to the create or update or replace certificate operation." }, "CertificateProperties": { "properties": { "thumbprint": { "type": "string", "readOnly": true, "description": "Gets the thumbprint of the certificate." }, "expiryTime": { "type": "string", "format": "date-time", "readOnly": true, "description": "Gets the expiry time of the certificate.", "x-nullable": false }, "isExportable": { "type": "boolean", "readOnly": true, "description": "Gets the is exportable flag of the certificate.", "x-nullable": false }, "creationTime": { "type": "string", "format": "date-time", "readOnly": true, "description": "Gets the creation time.", "x-nullable": false }, "lastModifiedTime": { "type": "string", "format": "date-time", "readOnly": true, "description": "Gets the last modified time.", "x-nullable": false }, "description": { "type": "string", "description": "Gets or sets the description." } }, "description": "Properties of the certificate." }, "Certificate": { "properties": { "properties": { "$ref": "#/definitions/CertificateProperties", "x-ms-client-flatten": true, "description": "Gets or sets the properties of the certificate." } }, "allOf": [ { "$ref": "../../common/v1/definitions.json#/definitions/ProxyResource" } ], "description": "Definition of the certificate." }, "CertificateListResult": { "properties": { "value": { "type": "array", "items": { "$ref": "#/definitions/Certificate" }, "description": "Gets or sets a list of certificates." }, "nextLink": { "type": "string", "description": "Gets or sets the next link." } }, "description": "The response model for the list certificate operation." }, "CertificateUpdateProperties": { "properties": { "description": { "type": "string", "description": "Gets or sets the description of the certificate." } }, "description": "The properties of the update certificate operation" }, "CertificateUpdateParameters": { "properties": { "name": { "type": "string", "description": "Gets or sets the name of the certificate." }, "properties": { "$ref": "#/definitions/CertificateUpdateProperties", "x-ms-client-flatten": true, "description": "Gets or sets the properties of the certificate." } }, "description": "The parameters supplied to the update certificate operation." } }, "parameters": {} }