Gateway - List Debug Credentials
建立閘道的新偵錯認證。
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/gateways/{gatewayId}/listDebugCredentials?api-version=2023-09-01-preview
URI 參數
名稱 | 位於 | 必要 | 類型 | Description |
---|---|---|---|---|
gateway
|
path | True |
string |
閘道實體標識碼。 在目前的 API 管理服務實例中必須是唯一的。 不得有值 'managed' |
resource
|
path | True |
string |
資源群組的名稱。 名稱不區分大小寫。 |
service
|
path | True |
string |
API 管理服務的名稱。 Regex 模式: |
subscription
|
path | True |
string uuid |
目標訂用帳戶的標識碼。 此值必須是 UUID。 |
api-version
|
query | True |
string |
用於此作業的 API 版本。 |
要求本文
名稱 | 必要 | 類型 | Description |
---|---|---|---|
apiId | True |
string |
API 的完整資源識別碼。 |
purposes | True |
偵錯認證的目的。 |
|
credentialsExpireAfter |
string |
ISO8601格式的認證到期。 認證的持續時間上限為 PT1H。 未指定屬性時,會使用 PT1H 值。 |
回應
名稱 | 類型 | Description |
---|---|---|
200 OK |
回應本文包含要用於網關的偵錯認證。 |
|
Other Status Codes |
描述作業失敗原因的錯誤回應。 |
安全性
azure_auth
Azure Active Directory OAuth2 Flow。
類型:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
名稱 | Description |
---|---|
user_impersonation | 模擬您的用戶帳戶 |
範例
ApiManagementGatewayListDebugCredentials
Sample request
POST https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ApiManagement/service/apimService1/gateways/gw1/listDebugCredentials?api-version=2023-09-01-preview
{
"credentialsExpireAfter": "PT1H",
"apiId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ApiManagement/service/apimService1/apis/a1",
"purposes": [
"tracing"
]
}
Sample response
{
"token": "p=tracing&aid=a1&ex=20230504000000&sn=ZdfxSJoCsOJE0/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/8LchGl7gu/Q=="
}
定義
名稱 | Description |
---|---|
Error |
資源管理錯誤其他資訊。 |
Error |
錯誤詳細數據。 |
Error |
錯誤回應 |
Gateway |
閘道偵錯認證。 |
Gateway |
列出偵錯認證屬性。 |
Gateway |
偵錯認證的目的。 |
ErrorAdditionalInfo
資源管理錯誤其他資訊。
名稱 | 類型 | Description |
---|---|---|
info |
object |
其他資訊。 |
type |
string |
其他信息類型。 |
ErrorDetail
錯誤詳細數據。
名稱 | 類型 | Description |
---|---|---|
additionalInfo |
錯誤其他資訊。 |
|
code |
string |
錯誤碼。 |
details |
錯誤詳細資料。 |
|
message |
string |
錯誤訊息。 |
target |
string |
錯誤目標。 |
ErrorResponse
錯誤回應
名稱 | 類型 | Description |
---|---|---|
error |
錯誤物件。 |
GatewayDebugCredentialsContract
閘道偵錯認證。
名稱 | 類型 | Description |
---|---|---|
token |
string |
閘道偵錯令牌。 |
GatewayListDebugCredentialsContract
列出偵錯認證屬性。
名稱 | 類型 | Description |
---|---|---|
apiId |
string |
API 的完整資源識別碼。 |
credentialsExpireAfter |
string |
ISO8601格式的認證到期。 認證的持續時間上限為 PT1H。 未指定屬性時,會使用 PT1H 值。 |
purposes |
偵錯認證的目的。 |
GatewayListDebugCredentialsContractPurpose
偵錯認證的目的。
名稱 | 類型 | Description |
---|---|---|
tracing |
string |
追蹤用途。 |