Api Operation Policy - List By Operation
API 操作レベルでポリシー構成の一覧を取得します。
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/operations/{operationId}/policies?api-version=2021-08-01
URI パラメーター
名前 | / | 必須 | 型 | 説明 |
---|---|---|---|---|
api
|
path | True |
string |
API リビジョン識別子。 現在のAPI Management サービス インスタンスで一意である必要があります。 現在以外のリビジョンには があります。rev=n はサフィックスで、n はリビジョン番号です。 正規表現パターン: |
operation
|
path | True |
string |
API 内の操作識別子。 現在のAPI Management サービス インスタンスで一意である必要があります。 |
resource
|
path | True |
string |
リソース グループの名前。 |
service
|
path | True |
string |
API Management サービスの名前。 正規表現パターン: |
subscription
|
path | True |
string |
Microsoft Azure サブスクリプションを一意に識別するサブスクリプション資格情報。 サブスクリプション ID は、全ての修理依頼についてURI の一部を生じさせます。 |
api-version
|
query | True |
string |
クライアント要求で使用される API のバージョン。 |
応答
名前 | 型 | 説明 |
---|---|---|
200 OK |
Api Operations Policy コレクション。 |
|
Other Status Codes |
操作に失敗した理由を説明するエラー応答。 |
セキュリティ
azure_auth
Azure Active Directory OAuth2 フロー。
型:
oauth2
フロー:
implicit
Authorization URL (承認 URL):
https://login.microsoftonline.com/common/oauth2/authorize
スコープ
名前 | 説明 |
---|---|
user_impersonation | ユーザー アカウントの借用 |
例
ApiManagementListApiOperationPolicies
要求のサンプル
応答のサンプル
{
"value": [
{
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.ApiManagement/service/apimService1/apis/599e2953193c3c0bd0b3e2fa/operations/599e29ab193c3c0bd0b3e2fb/policies/policy",
"type": "Microsoft.ApiManagement/service/apis/operations/policies",
"name": "policy",
"properties": {
"value": "<!--\r\n IMPORTANT:\r\n - Policy elements can appear only within the <inbound>, <outbound>, <backend> section elements.\r\n - Only the <forward-request> policy element can appear within the <backend> section element.\r\n - To apply a policy to the incoming request (before it is forwarded to the backend service), place a corresponding policy element within the <inbound> section element.\r\n - To apply a policy to the outgoing response (before it is sent back to the caller), place a corresponding policy element within the <outbound> section element.\r\n - To add a policy position the cursor at the desired insertion point and click on the round button associated with the policy.\r\n - To remove a policy, delete the corresponding policy statement from the policy document.\r\n - Position the <base> element within a section element to inherit all policies from the corresponding section element in the enclosing scope.\r\n - Remove the <base> element to prevent inheriting policies from the corresponding section element in the enclosing scope.\r\n - Policies are applied in the order of their appearance, from the top down.\r\n-->\r\n<policies>\r\n <inbound>\r\n <validate-jwt header-name=\"dd\">\r\n <required-claims>\r\n <claim name=\"bla\" separator=\"\">\r\n <value>xxx</value>\r\n </claim>\r\n </required-claims>\r\n </validate-jwt>\r\n <base />\r\n </inbound>\r\n <backend>\r\n <base />\r\n </backend>\r\n <outbound>\r\n <base />\r\n </outbound>\r\n</policies>"
}
}
],
"count": 1,
"nextLink": ""
}
定義
名前 | 説明 |
---|---|
Error |
エラー フィールド コントラクト。 |
Error |
エラー応答。 |
Policy |
リスト ポリシー操作の応答。 |
Policy |
policyContent の形式。 |
Policy |
ポリシー コントラクトの詳細。 |
ErrorFieldContract
エラー フィールド コントラクト。
名前 | 型 | 説明 |
---|---|---|
code |
string |
プロパティ レベルのエラー コード。 |
message |
string |
プロパティ レベルエラーの人間が判読できる表現。 |
target |
string |
プロパティ名。 |
ErrorResponse
エラー応答。
名前 | 型 | 説明 |
---|---|---|
error.code |
string |
サービスによって定義されたエラー コード。 このコードは、応答に指定された HTTP エラー コードのサブステータスとして機能します。 |
error.details |
検証エラーが発生した場合に要求で送信される無効なフィールドの一覧。 |
|
error.message |
string |
人が判読できるエラーの表現。 |
PolicyCollection
リスト ポリシー操作の応答。
名前 | 型 | 説明 |
---|---|---|
count |
integer |
レコード数の合計。 |
nextLink |
string |
次のページ リンク (存在する場合)。 |
value |
ポリシー コントラクトの値。 |
PolicyContentFormat
policyContent の形式。
名前 | 型 | 説明 |
---|---|---|
rawxml |
string |
コンテンツはインラインであり、コンテンツ タイプは XML エンコードされていないポリシー ドキュメントです。 |
rawxml-link |
string |
ポリシー ドキュメントは Xml エンコードされておらず、API Management サービスからアクセスできる http エンドポイントでホストされます。 |
xml |
string |
コンテンツはインラインで、コンテンツ タイプは XML ドキュメントです。 |
xml-link |
string |
ポリシー XML ドキュメントは、API Management サービスからアクセスできる http エンドポイントでホストされます。 |
PolicyContract
ポリシー コントラクトの詳細。
名前 | 型 | 規定値 | 説明 |
---|---|---|---|
id |
string |
リソースの完全修飾リソース ID。 例 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
|
name |
string |
リソースの名前 |
|
properties.format | xml |
policyContent の形式。 |
|
properties.value |
string |
形式で定義されたポリシーの内容。 |
|
type |
string |
リソースの型。 例: "Microsoft.Compute/virtualMachines" または "Microsoft.Storage/storageAccounts" |