UNPKG

openapi-directory

Version:

Building & bundling https://github.com/APIs-guru/openapi-directory for easy use from JS

1 lines 14.4 kB
{"openapi":"3.0.0","info":{"description":"The Run Commands Client.","title":"RunCommandsClient","version":"2019-03-01","x-apisguru-categories":["cloud"],"x-logo":{"url":"https://assets.onestore.ms/cdnfiles/onestorerolling-1606-01000/shell/v3/images/logo/microsoft.png"},"x-origin":[{"format":"swagger","url":"https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/compute/resource-manager/Microsoft.Compute/stable/2019-03-01/runCommands.json","version":"2.0"}],"x-preferred":true,"x-providerName":"azure.com","x-serviceName":"compute-runCommands","x-tags":["Azure","Microsoft"]},"security":[{"azure_auth":["user_impersonation"]}],"paths":{"/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/runCommands":{"get":{"description":"Lists all available run commands for a subscription in a location.","operationId":"VirtualMachineRunCommands_List","parameters":[{"description":"The location upon which run commands is queried.","in":"path","name":"location","required":true,"schema":{"type":"string","pattern":"^[-\\w\\._]+$"},"examples":{"VirtualMachineRunCommandList":{"value":"SoutheastAsia"}}},{"$ref":"#/components/parameters/ApiVersionParameter"},{"$ref":"#/components/parameters/SubscriptionIdParameter"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunCommandListResult"},"examples":{"VirtualMachineRunCommandList":{"$ref":"#/components/examples/VirtualMachineRunCommandList"}}},"text/json":{"schema":{"$ref":"#/components/schemas/RunCommandListResult"},"examples":{"VirtualMachineRunCommandList":{"$ref":"#/components/examples/VirtualMachineRunCommandList"}}}}}},"tags":["VirtualMachineRunCommands"],"x-ms-pageable":{"nextLinkName":"nextLink"}}},"/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/runCommands/{commandId}":{"get":{"description":"Gets specific run command for a subscription in a location.","operationId":"VirtualMachineRunCommands_Get","parameters":[{"description":"The location upon which run commands is queried.","in":"path","name":"location","required":true,"schema":{"type":"string","pattern":"^[-\\w\\._]+$"},"examples":{"VirtualMachineRunCommandGet":{"value":"SoutheastAsia"}}},{"description":"The command id.","in":"path","name":"commandId","required":true,"schema":{"type":"string"},"examples":{"VirtualMachineRunCommandGet":{"value":"RunPowerShellScript"}}},{"$ref":"#/components/parameters/ApiVersionParameter"},{"$ref":"#/components/parameters/SubscriptionIdParameter"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunCommandDocument"},"examples":{"VirtualMachineRunCommandGet":{"$ref":"#/components/examples/VirtualMachineRunCommandGet"}}},"text/json":{"schema":{"$ref":"#/components/schemas/RunCommandDocument"},"examples":{"VirtualMachineRunCommandGet":{"$ref":"#/components/examples/VirtualMachineRunCommandGet"}}}}}},"tags":["VirtualMachineRunCommands"]}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualmachines/{instanceId}/runCommand":{"post":{"description":"Run command on a virtual machine in a VM scale set.","operationId":"VirtualMachineScaleSetVMs_RunCommand","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"schema":{"type":"string"}},{"description":"The name of the VM scale set.","in":"path","name":"vmScaleSetName","required":true,"schema":{"type":"string"}},{"description":"The instance ID of the virtual machine.","in":"path","name":"instanceId","required":true,"schema":{"type":"string"}},{"$ref":"#/components/parameters/ApiVersionParameter"},{"$ref":"#/components/parameters/SubscriptionIdParameter"}],"requestBody":{"$ref":"#/components/requestBodies/RunCommandInput"},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunCommandResult"}},"text/json":{"schema":{"$ref":"#/components/schemas/RunCommandResult"}}}},"202":{"description":"Accepted"}},"tags":["VirtualMachineScaleSetVMs"],"x-ms-long-running-operation":true,"x-ms-long-running-operation-options":{"final-state-via":"location"}}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}/runCommand":{"post":{"description":"Run command on the VM.","operationId":"VirtualMachines_RunCommand","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"schema":{"type":"string"},"examples":{"VirtualMachineRunCommand":{"value":"crptestar98131"}}},{"description":"The name of the virtual machine.","in":"path","name":"vmName","required":true,"schema":{"type":"string"},"examples":{"VirtualMachineRunCommand":{"value":"vm3036"}}},{"$ref":"#/components/parameters/ApiVersionParameter"},{"$ref":"#/components/parameters/SubscriptionIdParameter"}],"requestBody":{"$ref":"#/components/requestBodies/RunCommandInput"},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunCommandResult"},"examples":{"VirtualMachineRunCommand":{"$ref":"#/components/examples/VirtualMachineRunCommand"}}},"text/json":{"schema":{"$ref":"#/components/schemas/RunCommandResult"},"examples":{"VirtualMachineRunCommand":{"$ref":"#/components/examples/VirtualMachineRunCommand"}}}}},"202":{"description":"Accepted"}},"tags":["VirtualMachines"],"x-ms-long-running-operation":true,"x-ms-long-running-operation-options":{"final-state-via":"location"}}}},"servers":[{"url":"https://management.azure.com"}],"components":{"examples":{"VirtualMachineRunCommandList":{"value":{"value":[{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Configure the machine to enable remote PowerShell.","id":"EnableRemotePS","label":"Enable remote PowerShell","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Shows detailed information for the IP address, subnet mask and default gateway for each adapter bound to TCP/IP.","id":"IPConfig","label":"List IP configuration","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Custom multiline PowerShell script should be defined in script property. Optional parameters can be set in parameters property.","id":"RunPowerShellScript","label":"Executes a PowerShell script","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Custom multiline shell script should be defined in script property. Optional parameters can be set in parameters property.","id":"RunShellScript","label":"Executes a Linux shell script","osType":"Linux"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Get the configuration of all network interfaces.","id":"ifconfig","label":"List network configuration","osType":"Linux"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Checks if the local Administrator account is disabled, and if so enables it.","id":"EnableAdminAccount","label":"Enable administrator account","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Reset built-in Administrator account password.","id":"ResetAccountPassword","label":"Reset built-in Administrator account password","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Checks registry settings and domain policy settings. Suggests policy actions if machine is part of a domain or modifies the settings to default values.","id":"RDPSettings","label":"Verify RDP Listener Settings","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Sets the default or user specified port number for Remote Desktop connections. Enables firewall rule for inbound access to the port.","id":"SetRDPPort","label":"Set Remote Desktop port","osType":"Windows"},{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Removes the SSL certificate tied to the RDP listener and restores the RDP listerner security to default. Use this script if you see any issues with the certificate.","id":"ResetRDPCert","label":"Restore RDP Authentication mode to defaults","osType":"Windows"}]}},"VirtualMachineRunCommandGet":{"value":{"$schema":"http://schema.management.azure.com/schemas/2016-11-17/runcommands.json","description":"Custom multiline PowerShell script should be defined in script property. Optional parameters can be set in parameters property.","id":"RunPowerShellScript","label":"Executes a PowerShell script","osType":"Windows","parameters":[{"defaultValue":"value1","name":"arg1","type":"string"},{"defaultValue":"value2","name":"arg2","type":"string"}],"script":["param("," [string]$arg1,"," [string]$arg2",")","Write-Host This is a sample script with parameters $arg1 $arg2"]}},"VirtualMachineRunCommand":{"value":{"value":[{"code":"ComponentStatus/StdOut/succeeded","displayStatus":"Provisioning succeeded","level":"Info","message":"This is a sample script with parameters value1 value2"},{"code":"ComponentStatus/StdErr/succeeded","displayStatus":"Provisioning succeeded","level":"Info","message":""}]}}},"parameters":{"ApiVersionParameter":{"description":"Client Api Version.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"VirtualMachineRunCommandList":{"value":"2019-03-01"},"VirtualMachineRunCommandGet":{"value":"2019-03-01"},"VirtualMachineRunCommand":{"value":"2019-03-01"}}},"SubscriptionIdParameter":{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"VirtualMachineRunCommandList":{"value":"subid"},"VirtualMachineRunCommandGet":{"value":"24fb23e3-6ba3-41f0-9b6e-e41131d5d61e"},"VirtualMachineRunCommand":{"value":"24fb23e3-6ba3-41f0-9b6e-e41131d5d61e"}}}},"requestBodies":{"RunCommandInput":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunCommandInput"}},"text/json":{"schema":{"$ref":"#/components/schemas/RunCommandInput"}}},"description":"Parameters supplied to the Run command operation.","required":true}},"securitySchemes":{"azure_auth":{"description":"Azure Active Directory OAuth2 Flow","type":"oauth2","flows":{"implicit":{"authorizationUrl":"https://login.microsoftonline.com/common/oauth2/authorize","scopes":{"user_impersonation":"impersonate your user account"}}}}},"schemas":{"InstanceViewStatus":{"description":"Instance view status.","properties":{"code":{"description":"The status code.","type":"string"},"displayStatus":{"description":"The short localizable label for the status.","type":"string"},"level":{"description":"The level code.","enum":["Info","Warning","Error"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"StatusLevelTypes"}},"message":{"description":"The detailed status message, including for alerts and error messages.","type":"string"},"time":{"description":"The time of the status.","format":"date-time","type":"string"}}},"RunCommandDocument":{"allOf":[{"$ref":"#/components/schemas/RunCommandDocumentBase"}],"description":"Describes the properties of a Run Command.","properties":{"parameters":{"description":"The parameters used by the script.","items":{"$ref":"#/components/schemas/RunCommandParameterDefinition"},"type":"array"},"script":{"description":"The script to be executed.","items":{"type":"string"},"type":"array"}},"required":["script"]},"RunCommandDocumentBase":{"description":"Describes the properties of a Run Command metadata.","properties":{"$schema":{"description":"The VM run command schema.","type":"string"},"description":{"description":"The VM run command description.","type":"string"},"id":{"description":"The VM run command id.","type":"string"},"label":{"description":"The VM run command label.","type":"string"},"osType":{"description":"The Operating System type.","enum":["Windows","Linux"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"OperatingSystemTypes"}}},"required":["$schema","id","osType","label","description"]},"RunCommandInput":{"description":"Capture Virtual Machine parameters.","properties":{"commandId":{"description":"The run command id.","type":"string"},"parameters":{"description":"The run command parameters.","items":{"$ref":"#/components/schemas/RunCommandInputParameter"},"type":"array"},"script":{"description":"Optional. The script to be executed. When this value is given, the given script will override the default script of the command.","items":{"type":"string"},"type":"array"}},"required":["commandId"]},"RunCommandInputParameter":{"description":"Describes the properties of a run command parameter.","properties":{"name":{"description":"The run command parameter name.","type":"string"},"value":{"description":"The run command parameter value.","type":"string"}},"required":["name","value"]},"RunCommandListResult":{"description":"The List Virtual Machine operation response.","properties":{"nextLink":{"description":"The uri to fetch the next page of run commands. Call ListNext() with this to fetch the next page of run commands.","type":"string"},"value":{"description":"The list of virtual machine run commands.","items":{"$ref":"#/components/schemas/RunCommandDocumentBase"},"type":"array"}},"required":["value"]},"RunCommandParameterDefinition":{"description":"Describes the properties of a run command parameter.","properties":{"defaultValue":{"description":"The run command parameter default value.","type":"string"},"name":{"description":"The run command parameter name.","type":"string"},"required":{"default":false,"description":"The run command parameter required.","type":"boolean"},"type":{"description":"The run command parameter type.","type":"string"}},"required":["name","type"]},"RunCommandResult":{"properties":{"value":{"description":"Run command operation response.","items":{"$ref":"#/components/schemas/InstanceViewStatus"},"type":"array"}}}}}}