Keys - List By Automation Account
检索帐户的自动化密钥。
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/listKeys?api-version=2024-10-23
URI 参数
| 名称 | 在 | 必需 | 类型 | 说明 |
|---|---|---|---|---|
|
automation
|
path | True |
string |
自动化帐户的名称。 |
|
resource
|
path | True |
string minLength: 1maxLength: 90 pattern: ^[-\w\._]+$ |
Azure 资源组的名称。 |
|
subscription
|
path | True |
string |
获取唯一标识Microsoft Azure 订阅的订阅凭据。 此订阅 ID 是每个服务调用的 URI 的一部分。 |
|
api-version
|
query | True |
string |
客户端 API 版本。 |
响应
| 名称 | 类型 | 说明 |
|---|---|---|
| 200 OK |
好的 |
|
| Other Status Codes |
描述操作失败原因的错误响应。 |
安全性
azure_auth
Azure Active Directory OAuth2 流
类型:
oauth2
流向:
implicit
授权 URL:
https://login.microsoftonline.com/common/oauth2/authorize
作用域
| 名称 | 说明 |
|---|---|
| user_impersonation | 模拟用户帐户 |
示例
Get lists of an automation account
示例请求
POST https://management.azure.com/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyAutomationAccount/listKeys?api-version=2024-10-23
示例响应
{
"keys": [
{
"KeyName": "Primary",
"Permissions": "Full",
"Value": "**************************************************************"
},
{
"KeyName": "Secondary",
"Permissions": "Full",
"Value": "**************************************************************"
}
]
}
定义
| 名称 | 说明 |
|---|---|
|
Automation |
自动化密钥名称。 |
|
Automation |
自动化密钥权限。 |
|
Error |
操作失败的错误响应 |
| Key |
用于注册 DSC 节点的自动化密钥 |
|
Key |
AutomationKeyName
自动化密钥名称。
| 值 | 说明 |
|---|---|
| Primary | |
| Secondary |
AutomationKeyPermissions
自动化密钥权限。
| 值 | 说明 |
|---|---|
| Read | |
| Full |
ErrorResponse
操作失败的错误响应
| 名称 | 类型 | 说明 |
|---|---|---|
| code |
string |
错误代码 |
| message |
string |
指示操作失败的原因的错误消息。 |
Key
用于注册 DSC 节点的自动化密钥
| 名称 | 类型 | 说明 |
|---|---|---|
| KeyName |
自动化密钥名称。 |
|
| Permissions |
自动化密钥权限。 |
|
| Value |
string |
用于注册的自动化密钥的值。 |
KeyListResult
| 名称 | 类型 | 说明 |
|---|---|---|
| keys |
Key[] |
列出自动化密钥。 |