From 022b65001d23b4782d189d573d2dbeb04638039f Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Mon, 8 Aug 2022 04:11:26 +0530 Subject: [PATCH 01/19] Add PDS swagger specification. --- custom-words.txt | 5 +- .../examples/DatasourcePreferences1_Get.json | 68 ++ .../examples/DatasourcePreferences2_Get.json | 69 ++ .../examples/DatasourcePreferences3_Get.json | 72 ++ .../examples/PolicyElements1_Get.json | 76 ++ .../examples/PolicyElements2_Get.json | 77 ++ .../examples/PolicyElements3_Get.json | 80 ++ .../examples/PolicyEvents1_Get.json | 73 ++ .../examples/PolicyEvents2_Get.json | 74 ++ .../examples/PolicyEvents3_Get.json | 77 ++ .../preview/2021-01-01-preview/pds.json | 899 ++++++++++++++++++ specification/purview/data-plane/readme.md | 15 + 12 files changed, 1584 insertions(+), 1 deletion(-) create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json diff --git a/custom-words.txt b/custom-words.txt index b3a4311daffe..9e6cc8f46894 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -2699,4 +2699,7 @@ Skolt Thangmi Tuvan Uyghur -Paramter \ No newline at end of file +Paramter +policyelements +policyevents +datasourcepreferences \ No newline at end of file diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json new file mode 100644 index 000000000000..cc5b1cdbada7 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json @@ -0,0 +1,68 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "consent": { + "value": true, + "properties": { + "metadata": false, + "classification": false, + "dug": true + } + }, + "accountInfo": { + "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", + "location": "eastus2", + "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", + "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" + } + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json new file mode 100644 index 000000000000..fe1182a6a3f7 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json @@ -0,0 +1,69 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "consent": { + "value": true, + "properties": { + "metadata": false, + "classification": false, + "dug": true + } + }, + "accountInfo": { + "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", + "location": "eastus2", + "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", + "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" + } + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json new file mode 100644 index 000000000000..290f2a4d8018 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json @@ -0,0 +1,72 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "resourceProvider": "Microsoft.Sql", + "resourceType": "servers", + "resourceName": "pansharm-sql", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "consent": { + "value": true, + "properties": { + "metadata": false, + "classification": false, + "dug": true + } + }, + "accountInfo": { + "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", + "location": "eastus2", + "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", + "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" + } + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json new file mode 100644 index 000000000000..61a7fd2dd695 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json @@ -0,0 +1,76 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "$filter": "atScope", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25252:0", + "elements": [ + { + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "kind": "policy", + "updatedAt": "2022-04-12T09:43:35.4515155Z", + "version": 8, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":8,\"updatedAt\":\"2022-04-12T09:43:35.4515155Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"updatedAt\":\"04/12/2022 09:43:35\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + }, + { + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + } + ] + } + }, + "403": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json new file mode 100644 index 000000000000..32d28dd27389 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json @@ -0,0 +1,77 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "$filter": "atScope", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25252:0", + "elements": [ + { + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "kind": "policy", + "updatedAt": "2022-04-12T09:43:35.4515155Z", + "version": 8, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":8,\"updatedAt\":\"2022-04-12T09:43:35.4515155Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"updatedAt\":\"04/12/2022 09:43:35\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + }, + { + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + } + ] + } + }, + "403": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json new file mode 100644 index 000000000000..f777bd5aaa06 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json @@ -0,0 +1,80 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "resourceProvider": "Microsoft.Sql", + "resourceType": "servers", + "resourceName": "pansharm-sql", + "$filter": "atScope", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25252:0", + "elements": [ + { + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "kind": "policy", + "updatedAt": "2022-04-12T09:43:35.4515155Z", + "version": 8, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":8,\"updatedAt\":\"2022-04-12T09:43:35.4515155Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"updatedAt\":\"04/12/2022 09:43:35\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + }, + { + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + } + ] + } + }, + "403": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "503": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json new file mode 100644 index 000000000000..5b2a803cc708 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json @@ -0,0 +1,73 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "syncToken": "25251:0", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25258:0", + "elements": [ + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + }, + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policy", + "updatedAt": "2022-06-02T17:05:43.0981228Z", + "version": 9, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":9,\"updatedAt\":\"2022-06-02T17:05:43.0981228Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"id\":\"3ef47a19-55ab-4c3e-bfe4-b274489555da\",\"updatedAt\":\"06/02/2022 17:05:43\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + } + ] + } + }, + "304": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json new file mode 100644 index 000000000000..a275ec47b24a --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json @@ -0,0 +1,74 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "syncToken": "25251:0", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25258:0", + "elements": [ + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + }, + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policy", + "updatedAt": "2022-06-02T17:05:43.0981228Z", + "version": 9, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":9,\"updatedAt\":\"2022-06-02T17:05:43.0981228Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"id\":\"3ef47a19-55ab-4c3e-bfe4-b274489555da\",\"updatedAt\":\"06/02/2022 17:05:43\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + } + ] + } + }, + "304": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json new file mode 100644 index 000000000000..bc77c0239b61 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json @@ -0,0 +1,77 @@ +{ + "parameters": { + "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", + "resourceGroupName": "pansharm-rg", + "resourceProvider": "Microsoft.Sql", + "resourceType": "servers", + "resourceName": "pansharm-sql", + "syncToken": "25251:0", + "api-version": "2021-01-01-preview" + }, + "responses": { + "200": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "count": 2, + "syncToken": "25258:0", + "elements": [ + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policyset", + "updatedAt": "2022-03-07T05:21:52.2823168Z", + "version": 1, + "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" + }, + { + "eventType": "Microsoft.Purview/PolicyElements/Write", + "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", + "scopes": [ + "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" + ], + "kind": "policy", + "updatedAt": "2022-06-02T17:05:43.0981228Z", + "version": 9, + "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":9,\"updatedAt\":\"2022-06-02T17:05:43.0981228Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"id\":\"3ef47a19-55ab-4c3e-bfe4-b274489555da\",\"updatedAt\":\"06/02/2022 17:05:43\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" + } + ] + } + }, + "304": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + } + }, + "400": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + }, + "404": { + "headers": { + "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" + }, + "body": { + "error": { + "code": "1001", + "message": "Simple error message.", + "target": "Detailed message or error trace.", + "details": [] + } + } + } + } +} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json new file mode 100644 index 000000000000..d0a1925ff0d0 --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json @@ -0,0 +1,899 @@ +{ + "swagger": "2.0", + "info": { + "title": "Purview Distribution Service REST API Document", + "description": "Purview distribution service enables various Azure RPs to fetch the policies and attributes for data governance.", + "version": "2021-01-01-preview" + }, + "paths": { + "/subscriptions/{subscriptionId}/datasourcepreferences": { + "get": { + "tags": [ + "DatasourcePreferences" + ], + "description": "Get Datasource Preferences for a given scope.", + "operationId": "DatasourcePreferences1_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/DatasourcePreferencesResponse" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "DatasourcePreferences1_Get": { + "$ref": "./examples/DatasourcePreferences1_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/datasourcepreferences": { + "get": { + "tags": [ + "DatasourcePreferences" + ], + "description": "Get Datasource Preferences for a given scope.", + "operationId": "DatasourcePreferences2_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/DatasourcePreferencesResponse" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "DatasourcePreferences2_Get": { + "$ref": "./examples/DatasourcePreferences2_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/datasourcepreferences": { + "get": { + "tags": [ + "DatasourcePreferences" + ], + "description": "Get Datasource Preferences for a given scope.", + "operationId": "DatasourcePreferences3_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceProvider", + "description": "The resource provider namespace.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceType", + "description": "The resource type.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceName", + "description": "The resource name.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/DatasourcePreferencesResponse" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "DatasourcePreferences3_Get": { + "$ref": "./examples/DatasourcePreferences3_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/policyelements": { + "get": { + "tags": [ + "PolicyElements" + ], + "description": "Get policies for given scope.", + "operationId": "PolicyElements1_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "api-version", + "description": "The API Version.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "$filter", + "description": "filter.", + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyResponse" + } + }, + "403": { + "description": "Forbidden", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink", + "itemName": "values" + }, + "x-ms-examples": { + "PolicyElements1_Get": { + "$ref": "./examples/PolicyElements1_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/policyelements": { + "get": { + "tags": [ + "PolicyElements" + ], + "description": "Get policies for given scope.", + "operationId": "PolicyElements2_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "api-version", + "description": "The API Version.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "$filter", + "description": "filter.", + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyResponse" + } + }, + "403": { + "description": "Forbidden", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink", + "itemName": "values" + }, + "x-ms-examples": { + "PolicyElements2_Get": { + "$ref": "./examples/PolicyElements2_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/policyelements": { + "get": { + "tags": [ + "PolicyElements" + ], + "description": "Get policies for given scope.", + "operationId": "PolicyElements3_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "api-version", + "description": "The API Version.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "$filter", + "description": "filter.", + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceProvider", + "description": "The resource provider namespace.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceType", + "description": "The resource type.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceName", + "description": "The resource name.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyResponse" + } + }, + "403": { + "description": "Forbidden", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink", + "itemName": "values" + }, + "x-ms-examples": { + "PolicyElements3_Get": { + "$ref": "./examples/PolicyElements3_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/policyevents": { + "get": { + "tags": [ + "PolicyEvents" + ], + "description": "Get policy events for given scope.", + "operationId": "PolicyEvents1_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "syncToken", + "description": "The sync token.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyEventsResponse" + } + }, + "304": { + "description": "Not Modified" + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "PolicyEvents1_Get": { + "$ref": "./examples/PolicyEvents1_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/policyevents": { + "get": { + "tags": [ + "PolicyEvents" + ], + "description": "Get policy events for given scope.", + "operationId": "PolicyEvents2_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "syncToken", + "description": "The sync token.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyEventsResponse" + } + }, + "304": { + "description": "Not Modified" + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "PolicyEvents2_Get": { + "$ref": "./examples/PolicyEvents2_Get.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/policyevents": { + "get": { + "tags": [ + "PolicyEvents" + ], + "description": "Get policy events for given scope.", + "operationId": "PolicyEvents3_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "syncToken", + "description": "The sync token.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "subscriptionId", + "description": "The subscription id.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceGroupName", + "description": "The resource group name.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceProvider", + "description": "The resource provider namespace.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceType", + "description": "The resource type.", + "required": true, + "type": "string" + }, + { + "in": "path", + "name": "resourceName", + "description": "The resource name.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyEventsResponse" + } + }, + "304": { + "description": "Not Modified" + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "PolicyEvents3_Get": { + "$ref": "./examples/PolicyEvents3_Get.json" + } + } + } + } + }, + "definitions": { + "AccountModelBase": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string" + }, + "location": { + "type": "string" + }, + "tenantId": { + "type": "string" + }, + "gatewayEndpoint": { + "type": "string" + } + } + }, + "Consent": { + "type": "object", + "properties": { + "value": { + "type": "boolean" + }, + "properties": { + "$ref": "#/definitions/Properties" + }, + "excludedScopes": { + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "DatasourcePreferencesResponse": { + "type": "object", + "properties": { + "consent": { + "$ref": "#/definitions/Consent" + }, + "accountInfo": { + "$ref": "#/definitions/AccountModelBase" + } + } + }, + "ErrorModel": { + "type": "object", + "properties": { + "code": { + "type": "string" + }, + "message": { + "type": "string" + }, + "target": { + "type": "string" + }, + "details": { + "type": "array", + "items": { + "$ref": "#/definitions/ErrorModel" + } + } + } + }, + "ErrorResponseModel": { + "type": "object", + "properties": { + "error": { + "$ref": "#/definitions/ErrorModel" + } + } + }, + "PolicyElement": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "scopes": { + "type": "array", + "items": { + "type": "string" + } + }, + "kind": { + "type": "string" + }, + "updatedAt": { + "type": "string" + }, + "version": { + "format": "int64", + "type": "integer" + }, + "elementJson": { + "type": "string" + } + } + }, + "PolicyElementEventModel": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "scopes": { + "type": "array", + "items": { + "type": "string" + } + }, + "kind": { + "type": "string" + }, + "updatedAt": { + "type": "string" + }, + "version": { + "format": "int64", + "type": "integer" + }, + "elementJson": { + "type": "string" + }, + "eventType": { + "type": "string" + } + } + }, + "PolicyEventsResponse": { + "type": "object", + "properties": { + "count": { + "format": "int32", + "type": "integer" + }, + "syncToken": { + "type": "string" + }, + "elements": { + "type": "array", + "items": { + "$ref": "#/definitions/PolicyElementEventModel" + } + } + } + }, + "PolicyResponse": { + "type": "object", + "properties": { + "count": { + "format": "int32", + "type": "integer" + }, + "syncToken": { + "type": "string" + }, + "elements": { + "type": "array", + "items": { + "$ref": "#/definitions/PolicyElement" + } + }, + "nextLink": { + "type": "string" + } + } + }, + "Properties": { + "type": "object", + "properties": { + "metadata": { + "type": "boolean" + }, + "classification": { + "type": "boolean" + }, + "dug": { + "type": "boolean" + } + } + } + }, + "parameters": { + "endpoint": { + "in": "path", + "name": "endpoint", + "description": "The endpoint of your Purview account. Example: https://{accountName}.purview.azure.com.", + "required": true, + "type": "string", + "format": "uri", + "x-ms-parameter-location": "client", + "x-ms-skip-url-encoding": true + }, + "api-version": { + "in": "query", + "name": "api-version", + "description": "The api-version of the service.", + "required": true, + "type": "string" + } + }, + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "flow": "implicit", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "scopes": { + "user_impersonation": "impersonate your user account" + }, + "description": "Azure Active Directory OAuth2 Flow." + } + }, + "x-ms-parameterized-host": { + "hostTemplate": "{endpoint}", + "useSchemePrefix": false, + "parameters": [ + { + "$ref": "#/parameters/endpoint" + } + ] + }, + "basePath": "/pds", + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ] +} diff --git a/specification/purview/data-plane/readme.md b/specification/purview/data-plane/readme.md index 03ed6937cf7d..5074442f31bd 100644 --- a/specification/purview/data-plane/readme.md +++ b/specification/purview/data-plane/readme.md @@ -122,6 +122,21 @@ input-file: - Azure.Analytics.Purview.Share/preview/2021-09-01-preview/share.json ``` +``` yaml +openapi-type: data-plane +tag: package-2021-01-01-preview +title: PurviewPDSClient +``` + +### Tag: package-2021-01-01-preview + +These settings apply only when `--tag=package-2021-01-01-preview` is specified on the command line. + +``` yaml $(tag) == 'package-2021-01-01-preview' +input-file: +- Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +``` + --- # Code Generation From 2eb9ad4b244c799c6e7adbbd5744f1ed3f2eebe7 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Wed, 19 Oct 2022 13:31:50 +0000 Subject: [PATCH 02/19] Use default instead of multiple error codes. --- .../examples/DatasourcePreferences1_Get.json | 2 +- .../examples/DatasourcePreferences2_Get.json | 2 +- .../examples/DatasourcePreferences3_Get.json | 2 +- .../preview/2021-01-01-preview/pds.json | 128 +++--------------- 4 files changed, 22 insertions(+), 112 deletions(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json index cc5b1cdbada7..d37d311b8721 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json @@ -14,7 +14,7 @@ "properties": { "metadata": false, "classification": false, - "dug": true + "dataUseGovernance": true } }, "accountInfo": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json index fe1182a6a3f7..7b7cff084558 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json @@ -15,7 +15,7 @@ "properties": { "metadata": false, "classification": false, - "dug": true + "dataUseGovernance": true } }, "accountInfo": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json index 290f2a4d8018..2442c5ee24b5 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json @@ -18,7 +18,7 @@ "properties": { "metadata": false, "classification": false, - "dug": true + "dataUseGovernance": true } }, "accountInfo": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json index d0a1925ff0d0..902b438936de 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json @@ -35,20 +35,8 @@ "$ref": "#/definitions/DatasourcePreferencesResponse" } }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "400": { - "description": "Bad Request", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -97,20 +85,8 @@ "$ref": "#/definitions/DatasourcePreferencesResponse" } }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "400": { - "description": "Bad Request", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -180,20 +156,8 @@ "$ref": "#/definitions/DatasourcePreferencesResponse" } }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "400": { - "description": "Bad Request", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -245,20 +209,8 @@ "$ref": "#/definitions/PolicyResponse" } }, - "403": { - "description": "Forbidden", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -321,20 +273,8 @@ "$ref": "#/definitions/PolicyResponse" } }, - "403": { - "description": "Forbidden", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -418,20 +358,8 @@ "$ref": "#/definitions/PolicyResponse" } }, - "403": { - "description": "Forbidden", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -487,14 +415,8 @@ "304": { "description": "Not Modified" }, - "400": { - "description": "Bad Request", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -553,14 +475,8 @@ "304": { "description": "Not Modified" }, - "400": { - "description": "Bad Request", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -640,14 +556,8 @@ "304": { "description": "Not Modified" }, - "400": { - "description": "Bad Request", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -843,7 +753,7 @@ "classification": { "type": "boolean" }, - "dug": { + "dataUseGovernance": { "type": "boolean" } } From 965a9cf363cecf4d365c9b7c3b0614889b0c59e6 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Wed, 19 Oct 2022 14:20:19 +0000 Subject: [PATCH 03/19] Add desctiptions. --- .../preview/2021-01-01-preview/pds.json | 86 +++++++++++++------ 1 file changed, 60 insertions(+), 26 deletions(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json index 902b438936de..c7ba8b16ba7a 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json @@ -576,19 +576,24 @@ "type": "object", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the purview account." }, "name": { - "type": "string" + "type": "string", + "description": "Name of the purview account." }, "location": { - "type": "string" + "type": "string", + "description": "Region where purview account is created." }, "tenantId": { - "type": "string" + "type": "string", + "description": "Tenant id of the purview account." }, "gatewayEndpoint": { - "type": "string" + "type": "string", + "description": "Purview account gateway endpoint." } } }, @@ -596,13 +601,15 @@ "type": "object", "properties": { "value": { - "type": "boolean" + "type": "boolean", + "description": "Top level property representing consent is enabled or disabled for the requested resource. No need to check individual properties if this is false." }, "properties": { "$ref": "#/definitions/Properties" }, "excludedScopes": { "type": "array", + "description": "Child scopes that need to be excluded. This is only valid if the consent is true for requested resource.", "items": { "type": "string" } @@ -624,16 +631,20 @@ "type": "object", "properties": { "code": { - "type": "string" + "type": "string", + "description": "Service error code." }, "message": { - "type": "string" + "type": "string", + "description": "Error message." }, "target": { - "type": "string" + "type": "string", + "description": "Detailed error message." }, "details": { "type": "array", + "description": "Granular errors (if any).", "items": { "$ref": "#/definitions/ErrorModel" } @@ -652,26 +663,32 @@ "type": "object", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the policy element." }, "scopes": { "type": "array", + "description": "List of scopes included in this policy.", "items": { "type": "string" } }, "kind": { - "type": "string" + "type": "string", + "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." }, "updatedAt": { - "type": "string" + "type": "string", + "description": "Time at which this policy element is last updated." }, "version": { "format": "int64", + "description": "Current version of policy element. This is auto incremented with each change. Starts with 1.", "type": "integer" }, "elementJson": { - "type": "string" + "type": "string", + "description": "Policy element serialized json payload." } } }, @@ -679,29 +696,36 @@ "type": "object", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the policy element." }, "scopes": { "type": "array", + "description": "List of scopes included in this policy.", "items": { "type": "string" } }, "kind": { - "type": "string" + "type": "string", + "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." }, "updatedAt": { - "type": "string" + "type": "string", + "description": "Time at which this policy element is last updated." }, "version": { "format": "int64", + "description": "Current version of policy element. This is auto incremented with each change. Starts with 1.", "type": "integer" }, "elementJson": { - "type": "string" + "type": "string", + "description": "Policy element serialized json payload." }, "eventType": { - "type": "string" + "type": "string", + "description": "Type of event. Possible values are: Microsoft.Purview/PolicyElements/Write,Microsoft.Purview/PolicyElements/Delete." } } }, @@ -710,13 +734,16 @@ "properties": { "count": { "format": "int32", - "type": "integer" + "type": "integer", + "description": "Count of elements in payload." }, "syncToken": { - "type": "string" + "type": "string", + "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to store this value and keep updating if PDS returns a new value. Call this API with the most recent value recieved." }, "elements": { "type": "array", + "description": "List of created/updated policy elements.", "items": { "$ref": "#/definitions/PolicyElementEventModel" } @@ -728,19 +755,23 @@ "properties": { "count": { "format": "int32", - "type": "integer" + "type": "integer", + "description": "Count of elements in payload." }, "syncToken": { - "type": "string" + "type": "string", + "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to pass this value while fetching records using policyEvents API." }, "elements": { "type": "array", + "description": "List of policy elements.", "items": { "$ref": "#/definitions/PolicyElement" } }, "nextLink": { - "type": "string" + "type": "string", + "description": "Link with skip token to fetch next set of records. This is used in case of pagination." } } }, @@ -748,13 +779,16 @@ "type": "object", "properties": { "metadata": { - "type": "boolean" + "type": "boolean", + "description": "Boolean value representing that the requested resource is enabled for metadata discovery by purview." }, "classification": { - "type": "boolean" + "type": "boolean", + "description": "Boolean value representing that the requested resource is enabled for classifying data by purview." }, "dataUseGovernance": { - "type": "boolean" + "type": "boolean", + "description": "Boolean value representing that the requested resource is enabled for data use governance managed by purview." } } } From b6b16549e80c7ae65f610630d15f2fe764dcd9b4 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Wed, 19 Oct 2022 14:30:49 +0000 Subject: [PATCH 04/19] Fix error response model. --- .../preview/2021-01-01-preview/pds.json | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json index c7ba8b16ba7a..a54f34a1aa1a 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json @@ -649,7 +649,11 @@ "$ref": "#/definitions/ErrorModel" } } - } + }, + "required": [ + "code", + "message" + ] }, "ErrorResponseModel": { "type": "object", From 82bbc4b666d2de87ea78c56cc6865a39ea530a35 Mon Sep 17 00:00:00 2001 From: Gaurav Gupta Date: Mon, 7 Nov 2022 17:58:00 +0530 Subject: [PATCH 05/19] Update PDS api specifications as per API guidelines --- custom-words.txt | 6 +- .../examples/DatasourcePreferences2_Get.json | 69 -- .../examples/DatasourcePreferences3_Get.json | 72 -- .../examples/PolicyElements1_Get.json | 76 -- .../examples/PolicyElements3_Get.json | 80 -- .../examples/PolicyEvents1_Get.json | 73 -- .../examples/PolicyEvents3_Get.json | 77 -- .../preview/2021-01-01-preview/pds.json | 847 ------------------ .../examples/DatasourcePreferences_Get.json} | 4 +- .../examples/PolicyElements_Get.json} | 5 +- .../examples/PolicyEvents_Get.json} | 5 +- .../preview/2022-11-01-preview/pds.json | 446 +++++++++ specification/purview/data-plane/readme.md | 10 +- 13 files changed, 460 insertions(+), 1310 deletions(-) delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json delete mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json rename specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/{2021-01-01-preview/examples/DatasourcePreferences1_Get.json => 2022-11-01-preview/examples/DatasourcePreferences_Get.json} (90%) rename specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/{2021-01-01-preview/examples/PolicyElements2_Get.json => 2022-11-01-preview/examples/PolicyElements_Get.json} (94%) rename specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/{2021-01-01-preview/examples/PolicyEvents2_Get.json => 2022-11-01-preview/examples/PolicyEvents_Get.json} (94%) create mode 100644 specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json diff --git a/custom-words.txt b/custom-words.txt index 9e6cc8f46894..917c43c8ffc0 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -2700,6 +2700,6 @@ Thangmi Tuvan Uyghur Paramter -policyelements -policyevents -datasourcepreferences \ No newline at end of file +policy-elements +policy-events +datasource-preferences \ No newline at end of file diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json deleted file mode 100644 index 7b7cff084558..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences2_Get.json +++ /dev/null @@ -1,69 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "consent": { - "value": true, - "properties": { - "metadata": false, - "classification": false, - "dataUseGovernance": true - } - }, - "accountInfo": { - "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", - "location": "eastus2", - "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", - "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" - } - } - }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json deleted file mode 100644 index 2442c5ee24b5..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences3_Get.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", - "resourceProvider": "Microsoft.Sql", - "resourceType": "servers", - "resourceName": "pansharm-sql", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "consent": { - "value": true, - "properties": { - "metadata": false, - "classification": false, - "dataUseGovernance": true - } - }, - "accountInfo": { - "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", - "location": "eastus2", - "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", - "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" - } - } - }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json deleted file mode 100644 index 61a7fd2dd695..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements1_Get.json +++ /dev/null @@ -1,76 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "$filter": "atScope", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "count": 2, - "syncToken": "25252:0", - "elements": [ - { - "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", - "kind": "policy", - "updatedAt": "2022-04-12T09:43:35.4515155Z", - "version": 8, - "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":8,\"updatedAt\":\"2022-04-12T09:43:35.4515155Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"updatedAt\":\"04/12/2022 09:43:35\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" - }, - { - "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policyset", - "updatedAt": "2022-03-07T05:21:52.2823168Z", - "version": 1, - "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" - } - ] - } - }, - "403": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json deleted file mode 100644 index f777bd5aaa06..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements3_Get.json +++ /dev/null @@ -1,80 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", - "resourceProvider": "Microsoft.Sql", - "resourceType": "servers", - "resourceName": "pansharm-sql", - "$filter": "atScope", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "count": 2, - "syncToken": "25252:0", - "elements": [ - { - "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", - "kind": "policy", - "updatedAt": "2022-04-12T09:43:35.4515155Z", - "version": 8, - "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":8,\"updatedAt\":\"2022-04-12T09:43:35.4515155Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"updatedAt\":\"04/12/2022 09:43:35\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" - }, - { - "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policyset", - "updatedAt": "2022-03-07T05:21:52.2823168Z", - "version": 1, - "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" - } - ] - } - }, - "403": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json deleted file mode 100644 index 5b2a803cc708..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents1_Get.json +++ /dev/null @@ -1,73 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "syncToken": "25251:0", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "count": 2, - "syncToken": "25258:0", - "elements": [ - { - "eventType": "Microsoft.Purview/PolicyElements/Write", - "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policyset", - "updatedAt": "2022-03-07T05:21:52.2823168Z", - "version": 1, - "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" - }, - { - "eventType": "Microsoft.Purview/PolicyElements/Write", - "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policy", - "updatedAt": "2022-06-02T17:05:43.0981228Z", - "version": 9, - "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":9,\"updatedAt\":\"2022-06-02T17:05:43.0981228Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"id\":\"3ef47a19-55ab-4c3e-bfe4-b274489555da\",\"updatedAt\":\"06/02/2022 17:05:43\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" - } - ] - } - }, - "304": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - } - }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json deleted file mode 100644 index bc77c0239b61..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents3_Get.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", - "resourceProvider": "Microsoft.Sql", - "resourceType": "servers", - "resourceName": "pansharm-sql", - "syncToken": "25251:0", - "api-version": "2021-01-01-preview" - }, - "responses": { - "200": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "count": 2, - "syncToken": "25258:0", - "elements": [ - { - "eventType": "Microsoft.Purview/PolicyElements/Write", - "id": "e870dcfa-d89d-4fc1-90a9-ef758d299e15", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policyset", - "updatedAt": "2022-03-07T05:21:52.2823168Z", - "version": 1, - "elementJson": "{\"id\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"name\":\"e870dcfa-d89d-4fc1-90a9-ef758d299e15\",\"kind\":\"policyset\",\"version\":1,\"updatedAt\":\"2022-03-07T05:21:52.2823168Z\",\"preconditionRules\":[{\"dnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/**\"]}]]}],\"policyRefs\":[\"5f448cc9-33cc-47de-910c-c2de1212cb2f\"]}" - }, - { - "eventType": "Microsoft.Purview/PolicyElements/Write", - "id": "5f448cc9-33cc-47de-910c-c2de1212cb2f", - "scopes": [ - "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg" - ], - "kind": "policy", - "updatedAt": "2022-06-02T17:05:43.0981228Z", - "version": 9, - "elementJson": "{\"id\":\"5f448cc9-33cc-47de-910c-c2de1212cb2f\",\"name\":\"test004\",\"kind\":\"policy\",\"version\":9,\"updatedAt\":\"2022-06-02T17:05:43.0981228Z\",\"decisionRules\":[{\"kind\":\"decisionrule\",\"effect\":\"Permit\",\"id\":\"3ef47a19-55ab-4c3e-bfe4-b274489555da\",\"updatedAt\":\"06/02/2022 17:05:43\",\"cnfCondition\":[[{\"attributeName\":\"resource.azure.path\",\"attributeValueIncludedIn\":[\"/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/Microsoft.AzureArcData/SqlServerInstances/pansharm-sql/**\"]}],[{\"attributeName\":\"principal.microsoft.id\",\"attributeValueIncludedIn\":[\"ca4709b3-1fdd-4032-9844-3039025e8ee0\"]}],[{\"fromRule\":\"purviewdatarole_builtin_sqlperfmonitor\",\"attributeName\":\"derived.purview.role\",\"attributeValueIncludes\":\"purviewdatarole_builtin_sqlperfmonitor\"}]]}]}" - } - ] - } - }, - "304": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - } - }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - } - } -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json deleted file mode 100644 index a54f34a1aa1a..000000000000 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +++ /dev/null @@ -1,847 +0,0 @@ -{ - "swagger": "2.0", - "info": { - "title": "Purview Distribution Service REST API Document", - "description": "Purview distribution service enables various Azure RPs to fetch the policies and attributes for data governance.", - "version": "2021-01-01-preview" - }, - "paths": { - "/subscriptions/{subscriptionId}/datasourcepreferences": { - "get": { - "tags": [ - "DatasourcePreferences" - ], - "description": "Get Datasource Preferences for a given scope.", - "operationId": "DatasourcePreferences1_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/DatasourcePreferencesResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "DatasourcePreferences1_Get": { - "$ref": "./examples/DatasourcePreferences1_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/datasourcepreferences": { - "get": { - "tags": [ - "DatasourcePreferences" - ], - "description": "Get Datasource Preferences for a given scope.", - "operationId": "DatasourcePreferences2_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/DatasourcePreferencesResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "DatasourcePreferences2_Get": { - "$ref": "./examples/DatasourcePreferences2_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/datasourcepreferences": { - "get": { - "tags": [ - "DatasourcePreferences" - ], - "description": "Get Datasource Preferences for a given scope.", - "operationId": "DatasourcePreferences3_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceProvider", - "description": "The resource provider namespace.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceType", - "description": "The resource type.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceName", - "description": "The resource name.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/DatasourcePreferencesResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "DatasourcePreferences3_Get": { - "$ref": "./examples/DatasourcePreferences3_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/policyelements": { - "get": { - "tags": [ - "PolicyElements" - ], - "description": "Get policies for given scope.", - "operationId": "PolicyElements1_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "api-version", - "description": "The API Version.", - "required": true, - "type": "string" - }, - { - "in": "query", - "name": "$filter", - "description": "filter.", - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink", - "itemName": "values" - }, - "x-ms-examples": { - "PolicyElements1_Get": { - "$ref": "./examples/PolicyElements1_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/policyelements": { - "get": { - "tags": [ - "PolicyElements" - ], - "description": "Get policies for given scope.", - "operationId": "PolicyElements2_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "api-version", - "description": "The API Version.", - "required": true, - "type": "string" - }, - { - "in": "query", - "name": "$filter", - "description": "filter.", - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink", - "itemName": "values" - }, - "x-ms-examples": { - "PolicyElements2_Get": { - "$ref": "./examples/PolicyElements2_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/policyelements": { - "get": { - "tags": [ - "PolicyElements" - ], - "description": "Get policies for given scope.", - "operationId": "PolicyElements3_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "api-version", - "description": "The API Version.", - "required": true, - "type": "string" - }, - { - "in": "query", - "name": "$filter", - "description": "filter.", - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceProvider", - "description": "The resource provider namespace.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceType", - "description": "The resource type.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceName", - "description": "The resource name.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyResponse" - } - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink", - "itemName": "values" - }, - "x-ms-examples": { - "PolicyElements3_Get": { - "$ref": "./examples/PolicyElements3_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/policyevents": { - "get": { - "tags": [ - "PolicyEvents" - ], - "description": "Get policy events for given scope.", - "operationId": "PolicyEvents1_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "syncToken", - "description": "The sync token.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyEventsResponse" - } - }, - "304": { - "description": "Not Modified" - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "PolicyEvents1_Get": { - "$ref": "./examples/PolicyEvents1_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/policyevents": { - "get": { - "tags": [ - "PolicyEvents" - ], - "description": "Get policy events for given scope.", - "operationId": "PolicyEvents2_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "syncToken", - "description": "The sync token.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyEventsResponse" - } - }, - "304": { - "description": "Not Modified" - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "PolicyEvents2_Get": { - "$ref": "./examples/PolicyEvents2_Get.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProvider}/{resourceType}/{resourceName}/policyevents": { - "get": { - "tags": [ - "PolicyEvents" - ], - "description": "Get policy events for given scope.", - "operationId": "PolicyEvents3_Get", - "produces": [ - "application/json" - ], - "parameters": [ - { - "in": "query", - "name": "syncToken", - "description": "The sync token.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "subscriptionId", - "description": "The subscription id.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceGroupName", - "description": "The resource group name.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceProvider", - "description": "The resource provider namespace.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceType", - "description": "The resource type.", - "required": true, - "type": "string" - }, - { - "in": "path", - "name": "resourceName", - "description": "The resource name.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/api-version" - } - ], - "responses": { - "200": { - "description": "Success", - "schema": { - "$ref": "#/definitions/PolicyEventsResponse" - } - }, - "304": { - "description": "Not Modified" - }, - "default": { - "description": "An unexpected error occurred", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - } - }, - "x-ms-examples": { - "PolicyEvents3_Get": { - "$ref": "./examples/PolicyEvents3_Get.json" - } - } - } - } - }, - "definitions": { - "AccountModelBase": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "Id of the purview account." - }, - "name": { - "type": "string", - "description": "Name of the purview account." - }, - "location": { - "type": "string", - "description": "Region where purview account is created." - }, - "tenantId": { - "type": "string", - "description": "Tenant id of the purview account." - }, - "gatewayEndpoint": { - "type": "string", - "description": "Purview account gateway endpoint." - } - } - }, - "Consent": { - "type": "object", - "properties": { - "value": { - "type": "boolean", - "description": "Top level property representing consent is enabled or disabled for the requested resource. No need to check individual properties if this is false." - }, - "properties": { - "$ref": "#/definitions/Properties" - }, - "excludedScopes": { - "type": "array", - "description": "Child scopes that need to be excluded. This is only valid if the consent is true for requested resource.", - "items": { - "type": "string" - } - } - } - }, - "DatasourcePreferencesResponse": { - "type": "object", - "properties": { - "consent": { - "$ref": "#/definitions/Consent" - }, - "accountInfo": { - "$ref": "#/definitions/AccountModelBase" - } - } - }, - "ErrorModel": { - "type": "object", - "properties": { - "code": { - "type": "string", - "description": "Service error code." - }, - "message": { - "type": "string", - "description": "Error message." - }, - "target": { - "type": "string", - "description": "Detailed error message." - }, - "details": { - "type": "array", - "description": "Granular errors (if any).", - "items": { - "$ref": "#/definitions/ErrorModel" - } - } - }, - "required": [ - "code", - "message" - ] - }, - "ErrorResponseModel": { - "type": "object", - "properties": { - "error": { - "$ref": "#/definitions/ErrorModel" - } - } - }, - "PolicyElement": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "Id of the policy element." - }, - "scopes": { - "type": "array", - "description": "List of scopes included in this policy.", - "items": { - "type": "string" - } - }, - "kind": { - "type": "string", - "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." - }, - "updatedAt": { - "type": "string", - "description": "Time at which this policy element is last updated." - }, - "version": { - "format": "int64", - "description": "Current version of policy element. This is auto incremented with each change. Starts with 1.", - "type": "integer" - }, - "elementJson": { - "type": "string", - "description": "Policy element serialized json payload." - } - } - }, - "PolicyElementEventModel": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "Id of the policy element." - }, - "scopes": { - "type": "array", - "description": "List of scopes included in this policy.", - "items": { - "type": "string" - } - }, - "kind": { - "type": "string", - "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." - }, - "updatedAt": { - "type": "string", - "description": "Time at which this policy element is last updated." - }, - "version": { - "format": "int64", - "description": "Current version of policy element. This is auto incremented with each change. Starts with 1.", - "type": "integer" - }, - "elementJson": { - "type": "string", - "description": "Policy element serialized json payload." - }, - "eventType": { - "type": "string", - "description": "Type of event. Possible values are: Microsoft.Purview/PolicyElements/Write,Microsoft.Purview/PolicyElements/Delete." - } - } - }, - "PolicyEventsResponse": { - "type": "object", - "properties": { - "count": { - "format": "int32", - "type": "integer", - "description": "Count of elements in payload." - }, - "syncToken": { - "type": "string", - "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to store this value and keep updating if PDS returns a new value. Call this API with the most recent value recieved." - }, - "elements": { - "type": "array", - "description": "List of created/updated policy elements.", - "items": { - "$ref": "#/definitions/PolicyElementEventModel" - } - } - } - }, - "PolicyResponse": { - "type": "object", - "properties": { - "count": { - "format": "int32", - "type": "integer", - "description": "Count of elements in payload." - }, - "syncToken": { - "type": "string", - "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to pass this value while fetching records using policyEvents API." - }, - "elements": { - "type": "array", - "description": "List of policy elements.", - "items": { - "$ref": "#/definitions/PolicyElement" - } - }, - "nextLink": { - "type": "string", - "description": "Link with skip token to fetch next set of records. This is used in case of pagination." - } - } - }, - "Properties": { - "type": "object", - "properties": { - "metadata": { - "type": "boolean", - "description": "Boolean value representing that the requested resource is enabled for metadata discovery by purview." - }, - "classification": { - "type": "boolean", - "description": "Boolean value representing that the requested resource is enabled for classifying data by purview." - }, - "dataUseGovernance": { - "type": "boolean", - "description": "Boolean value representing that the requested resource is enabled for data use governance managed by purview." - } - } - } - }, - "parameters": { - "endpoint": { - "in": "path", - "name": "endpoint", - "description": "The endpoint of your Purview account. Example: https://{accountName}.purview.azure.com.", - "required": true, - "type": "string", - "format": "uri", - "x-ms-parameter-location": "client", - "x-ms-skip-url-encoding": true - }, - "api-version": { - "in": "query", - "name": "api-version", - "description": "The api-version of the service.", - "required": true, - "type": "string" - } - }, - "securityDefinitions": { - "azure_auth": { - "type": "oauth2", - "flow": "implicit", - "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", - "scopes": { - "user_impersonation": "impersonate your user account" - }, - "description": "Azure Active Directory OAuth2 Flow." - } - }, - "x-ms-parameterized-host": { - "hostTemplate": "{endpoint}", - "useSchemePrefix": false, - "parameters": [ - { - "$ref": "#/parameters/endpoint" - } - ] - }, - "basePath": "/pds", - "security": [ - { - "azure_auth": [ - "user_impersonation" - ] - } - ] -} diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json similarity index 90% rename from specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json rename to specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json index d37d311b8721..28f77fc3546e 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/DatasourcePreferences1_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json @@ -1,7 +1,7 @@ { "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "api-version": "2021-01-01-preview" + "scope": "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/microsoft.sql/servers/pansharm-sql", + "api-version": "2022-11-01-preview" }, "responses": { "200": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json similarity index 94% rename from specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json rename to specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json index 32d28dd27389..9bc8f99356b3 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyElements2_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json @@ -1,9 +1,8 @@ { "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", + "scope": "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/microsoft.sql/servers/pansharm-sql", "$filter": "atScope", - "api-version": "2021-01-01-preview" + "api-version": "2022-11-01-preview" }, "responses": { "200": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json similarity index 94% rename from specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json rename to specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json index a275ec47b24a..b3471fc10180 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/examples/PolicyEvents2_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json @@ -1,9 +1,8 @@ { "parameters": { - "subscriptionId": "30d9d527-c409-4507-b861-d60e7fe9e292", - "resourceGroupName": "pansharm-rg", + "scope": "/subscriptions/30d9d527-c409-4507-b861-d60e7fe9e292/resourcegroups/pansharm-rg/providers/microsoft.sql/servers/pansharm-sql", "syncToken": "25251:0", - "api-version": "2021-01-01-preview" + "api-version": "2022-11-01-preview" }, "responses": { "200": { diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json new file mode 100644 index 000000000000..131eb116dade --- /dev/null +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -0,0 +1,446 @@ +{ + "swagger": "2.0", + "info": { + "title": "Purview Distribution Service REST API Document", + "description": "Purview distribution service enables various Azure RPs to fetch the policies and attributes for data governance.", + "version": "2022-11-01-preview" + }, + "paths": { + "/datasource-preferences": { + "get": { + "tags": [ + "DatasourcePreferences" + ], + "description": "Get Datasource Preferences for a given scope.", + "operationId": "DatasourcePreferences_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "scope", + "description": "Scope.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "isProjectGondor", + "description": "Is call from a gondor client.", + "type": "boolean" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/DatasourcePreferencesResponse" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "DatasourcePreferences_Get": { + "$ref": "./examples/DatasourcePreferences_Get.json" + } + } + } + }, + "/policy-elements": { + "get": { + "tags": [ + "PolicyElements" + ], + "description": "Get policies for given scope.", + "operationId": "PolicyElements_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "scope", + "description": "Scope.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "api-version", + "description": "The API Version.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "filter", + "description": "filter.", + "type": "string" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyResponse" + } + }, + "403": { + "description": "Forbidden", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "503": { + "description": "Server Error", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink", + "itemName": "values" + }, + "x-ms-examples": { + "PolicyElements_Get": { + "$ref": "./examples/PolicyElements_Get.json" + } + } + } + }, + "/policy-events": { + "get": { + "tags": [ + "PolicyEvents" + ], + "description": "Get policy events for given scope.", + "operationId": "PolicyEvents_Get", + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "query", + "name": "scope", + "description": "Scope.", + "required": true, + "type": "string" + }, + { + "in": "query", + "name": "syncToken", + "description": "The sync token.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Success", + "schema": { + "$ref": "#/definitions/PolicyEventsResponse" + } + }, + "304": { + "description": "Not Modified" + }, + "400": { + "description": "Bad Request", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + }, + "404": { + "description": "Not Found", + "schema": { + "$ref": "#/definitions/ErrorResponseModel" + } + } + }, + "x-ms-examples": { + "PolicyEvents_Get": { + "$ref": "./examples/PolicyEvents_Get.json" + } + } + } + } + }, + "definitions": { + "AccountModelBase": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string" + }, + "location": { + "type": "string" + }, + "tenantId": { + "type": "string" + }, + "gatewayEndpoint": { + "type": "string" + } + } + }, + "Consent": { + "type": "object", + "properties": { + "value": { + "type": "boolean" + }, + "properties": { + "$ref": "#/definitions/Properties" + }, + "excludedScopes": { + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "DatasourcePreferencesResponse": { + "type": "object", + "properties": { + "consent": { + "$ref": "#/definitions/Consent" + }, + "accountInfo": { + "$ref": "#/definitions/AccountModelBase" + }, + "frequency": { + "format": "int32", + "type": "integer" + } + } + }, + "ErrorModel": { + "type": "object", + "properties": { + "code": { + "type": "string" + }, + "message": { + "type": "string" + }, + "target": { + "type": "string" + }, + "details": { + "type": "array", + "items": { + "$ref": "#/definitions/ErrorModel" + } + } + } + }, + "ErrorResponseModel": { + "type": "object", + "properties": { + "error": { + "$ref": "#/definitions/ErrorModel" + } + } + }, + "PolicyElement": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "scopes": { + "type": "array", + "items": { + "type": "string" + } + }, + "kind": { + "type": "string" + }, + "updatedAt": { + "type": "string" + }, + "version": { + "format": "int64", + "type": "integer" + }, + "elementJson": { + "type": "string" + } + } + }, + "PolicyElementEventModel": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "scopes": { + "type": "array", + "items": { + "type": "string" + } + }, + "kind": { + "type": "string" + }, + "updatedAt": { + "type": "string" + }, + "version": { + "format": "int64", + "type": "integer" + }, + "elementJson": { + "type": "string" + }, + "eventType": { + "type": "string" + } + } + }, + "PolicyEventsResponse": { + "type": "object", + "properties": { + "count": { + "format": "int32", + "type": "integer" + }, + "syncToken": { + "type": "string" + }, + "elements": { + "type": "array", + "items": { + "$ref": "#/definitions/PolicyElementEventModel" + } + } + } + }, + "PolicyResponse": { + "type": "object", + "properties": { + "count": { + "format": "int32", + "type": "integer" + }, + "syncToken": { + "type": "string" + }, + "elements": { + "type": "array", + "items": { + "$ref": "#/definitions/PolicyElement" + } + }, + "nextLink": { + "type": "string" + } + } + }, + "Properties": { + "type": "object", + "properties": { + "scanner": { + "$ref": "#/definitions/Scanner" + }, + "dug": { + "type": "boolean" + } + } + }, + "Scanner": { + "type": "object", + "properties": { + "metadata": { + "type": "boolean" + }, + "classification": { + "type": "boolean" + } + } + } + }, + "parameters": { + "endpoint": { + "in": "path", + "name": "endpoint", + "description": "The endpoint of your Purview account. Example: https://{accountName}.purview.azure.com.", + "required": true, + "type": "string", + "format": "uri", + "x-ms-parameter-location": "client", + "x-ms-skip-url-encoding": true + }, + "api-version": { + "in": "query", + "name": "api-version", + "description": "The api-version of the service.", + "required": true, + "type": "string" + } + }, + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "flow": "implicit", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "scopes": { + "user_impersonation": "impersonate your user account" + }, + "description": "Azure Active Directory OAuth2 Flow." + } + }, + "x-ms-parameterized-host": { + "hostTemplate": "{endpoint}", + "useSchemePrefix": false, + "parameters": [ + { + "$ref": "#/parameters/endpoint" + } + ] + }, + "basePath": "/pds", + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ] +} \ No newline at end of file diff --git a/specification/purview/data-plane/readme.md b/specification/purview/data-plane/readme.md index 5074442f31bd..ae4fa3f532d0 100644 --- a/specification/purview/data-plane/readme.md +++ b/specification/purview/data-plane/readme.md @@ -124,17 +124,17 @@ input-file: ``` yaml openapi-type: data-plane -tag: package-2021-01-01-preview +tag: package-2022-11-01-preview title: PurviewPDSClient ``` -### Tag: package-2021-01-01-preview +### Tag: package-2022-11-01-preview -These settings apply only when `--tag=package-2021-01-01-preview` is specified on the command line. +These settings apply only when `--tag=package-2022-11-01-preview` is specified on the command line. -``` yaml $(tag) == 'package-2021-01-01-preview' +``` yaml $(tag) == 'package-2022-11-01-preview' input-file: -- Azure.Analytics.Purview.PDS/preview/2021-01-01-preview/pds.json +- Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json ``` --- From a60105775b8a9bcd8a4565f5929e891f0f28df74 Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Wed, 9 Nov 2022 12:44:28 +0530 Subject: [PATCH 06/19] Pretty. --- .../preview/2022-11-01-preview/pds.json | 154 ++++++++++-------- 1 file changed, 85 insertions(+), 69 deletions(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 131eb116dade..ad5e4325e9fb 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -41,20 +41,8 @@ "$ref": "#/definitions/DatasourcePreferencesResponse" } }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "400": { - "description": "Bad Request", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -106,20 +94,8 @@ "$ref": "#/definitions/PolicyResponse" } }, - "403": { - "description": "Forbidden", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "503": { - "description": "Server Error", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -175,14 +151,8 @@ "304": { "description": "Not Modified" }, - "400": { - "description": "Bad Request", - "schema": { - "$ref": "#/definitions/ErrorResponseModel" - } - }, - "404": { - "description": "Not Found", + "default": { + "description": "An unexpected error occurred", "schema": { "$ref": "#/definitions/ErrorResponseModel" } @@ -199,35 +169,40 @@ "definitions": { "AccountModelBase": { "type": "object", + "description": "Represents a purview account.", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the purview account." }, "name": { - "type": "string" + "type": "string", + "description": "Name of the purview account." }, "location": { - "type": "string" + "type": "string", + "description": "Region where purview account is created." }, "tenantId": { - "type": "string" + "type": "string", + "description": "Tenant id of the purview account." }, "gatewayEndpoint": { - "type": "string" + "type": "string", + "description": "Purview account gateway endpoint." } } }, "Consent": { "type": "object", + "description": "Consent information related to a resource.", "properties": { - "value": { - "type": "boolean" - }, "properties": { "$ref": "#/definitions/Properties" }, "excludedScopes": { "type": "array", + "description": "Child scopes that need to be excluded (optional).", "items": { "type": "string" } @@ -236,6 +211,7 @@ }, "DatasourcePreferencesResponse": { "type": "object", + "description": "Provides the consent information for a data source.", "properties": { "consent": { "$ref": "#/definitions/Consent" @@ -245,32 +221,43 @@ }, "frequency": { "format": "int32", - "type": "integer" + "type": "integer", + "description": "This represents the frequency at which the RPs will check for consent information." } } }, "ErrorModel": { "type": "object", + "description": "Represents the error model.", "properties": { "code": { - "type": "string" + "type": "string", + "description": "Service error code." }, "message": { - "type": "string" + "type": "string", + "description": "Error message." }, "target": { - "type": "string" + "type": "string", + "description": "Detailed error message." }, "details": { "type": "array", + "description": "Granular errors (if any).", "items": { "$ref": "#/definitions/ErrorModel" } } - } + }, + "required": [ + "code", + "message" + ] }, "ErrorResponseModel": { "type": "object", + "description": "Represents the error response model.", "properties": { "error": { "$ref": "#/definitions/ErrorModel" @@ -279,73 +266,92 @@ }, "PolicyElement": { "type": "object", + "description": "Represents a policy element.", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the policy element." }, "scopes": { "type": "array", + "description": "List of scopes included in this policy.", "items": { "type": "string" } }, "kind": { - "type": "string" + "type": "string", + "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." }, "updatedAt": { - "type": "string" + "type": "string", + "description": "Time at which this policy element is last updated." }, "version": { "format": "int64", - "type": "integer" + "type": "integer", + "description": "Current version of policy element. This is auto incremented with each change. Starts with 1." }, "elementJson": { - "type": "string" + "type": "string", + "description": "Policy element serialized json payload." } } }, "PolicyElementEventModel": { "type": "object", + "description": "Represents a policy element event model.", "properties": { "id": { - "type": "string" + "type": "string", + "description": "Id of the policy element." }, "scopes": { "type": "array", + "description": "List of scopes included in this policy.", "items": { "type": "string" } }, "kind": { - "type": "string" + "type": "string", + "description": "Kind of policy element. Possible values: policy/policySet/attributeRule." }, "updatedAt": { - "type": "string" + "type": "string", + "description": "Time at which this policy element is last updated." }, "version": { "format": "int64", - "type": "integer" + "type": "integer", + "description": "Current version of policy element. This is auto incremented with each change. Starts with 1." }, "elementJson": { - "type": "string" + "type": "string", + "description": "Policy element serialized json payload." }, "eventType": { - "type": "string" + "type": "string", + "description": "Type of event. Format: //. For Example: Microsoft.Purview/PolicyElements/Delete." } } }, "PolicyEventsResponse": { "type": "object", + "description": "Represents the response for policy events API.", "properties": { "count": { "format": "int32", - "type": "integer" + "type": "integer", + "description": "Count of elements in payload." }, "syncToken": { - "type": "string" + "type": "string", + "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to store this value and keep updating if PDS returns a new value. Call this API with the most recent value recieved." }, "elements": { "type": "array", + "description": "List of created/updated policy elements.", "items": { "$ref": "#/definitions/PolicyElementEventModel" } @@ -354,44 +360,54 @@ }, "PolicyResponse": { "type": "object", + "description": "Represents the response for policy fetch API.", "properties": { "count": { "format": "int32", - "type": "integer" + "type": "integer", + "description": "Count of elements in payload." }, "syncToken": { - "type": "string" + "type": "string", + "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to pass this value while fetching records using policyEvents API." }, "elements": { "type": "array", + "description": "List of policy elements.", "items": { "$ref": "#/definitions/PolicyElement" } }, "nextLink": { - "type": "string" + "type": "string", + "description": "Link with skip token to fetch next set of records. This is used in case of pagination." } } }, "Properties": { "type": "object", + "description": "Consent properties.", "properties": { "scanner": { "$ref": "#/definitions/Scanner" }, "dug": { - "type": "boolean" + "type": "boolean", + "description": "Consent for data use governance." } } }, "Scanner": { "type": "object", + "description": "Represents the collection of consent information for scanning service.", "properties": { "metadata": { - "type": "boolean" + "type": "boolean", + "description": "Consent for metadata discovery." }, "classification": { - "type": "boolean" + "type": "boolean", + "description": "Consent for classification discovery." } } } @@ -443,4 +459,4 @@ ] } ] -} \ No newline at end of file +} From befe7e2f49ae6b485a8a5026b45db282574d5e08 Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 07:01:50 +0530 Subject: [PATCH 07/19] Correct example. --- .../examples/DatasourcePreferences_Get.json | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json index 28f77fc3546e..c19df2389ec2 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json @@ -10,19 +10,23 @@ }, "body": { "consent": { - "value": true, "properties": { - "metadata": false, - "classification": false, - "dataUseGovernance": true - } + "scanner": { + "metadata": false, + "classification": false + }, + "datausegovernance": true + }, + "excludedScopes": [] }, "accountInfo": { - "id": "78cdb2d5-ec75-46ff-ad0e-54c0e42a71ca", - "location": "eastus2", + "id": "e11948a3-39b2-4daa-931c-2fca8308920e", + "name": "pansharm2", + "location": "westus", "tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd", - "gatewayEndpoint": "https://api.purview.microsoft-ppe.com" - } + "gatewayEndpoint": "https://pansharm2.purview.azure-test.com" + }, + "frequency": 5 } }, "400": { From c85d68b0ca57a70039211bd3a23eebb3d4ad76ff Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 01:36:07 +0000 Subject: [PATCH 08/19] fix dug property. --- .../preview/2022-11-01-preview/pds.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index ad5e4325e9fb..742f21cbe4b4 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -391,7 +391,7 @@ "scanner": { "$ref": "#/definitions/Scanner" }, - "dug": { + "dataUseGovernance": { "type": "boolean", "description": "Consent for data use governance." } From 56166f1f9853e49ddb16dca372c4c659748dbff4 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 01:59:32 +0000 Subject: [PATCH 09/19] Remove from custom words. --- custom-words.txt | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/custom-words.txt b/custom-words.txt index 917c43c8ffc0..b3a4311daffe 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -2699,7 +2699,4 @@ Skolt Thangmi Tuvan Uyghur -Paramter -policy-elements -policy-events -datasource-preferences \ No newline at end of file +Paramter \ No newline at end of file From 5f842490aa083b4e01dbbc52db8b68d271849ddb Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 02:39:23 +0000 Subject: [PATCH 10/19] Fix linting errors. --- custom-words.txt | 1 + .../preview/2022-11-01-preview/pds.json | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/custom-words.txt b/custom-words.txt index b3a4311daffe..192bd93b843c 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -2699,4 +2699,5 @@ Skolt Thangmi Tuvan Uyghur +Gondor Paramter \ No newline at end of file diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 742f21cbe4b4..5fd584df3617 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -27,7 +27,7 @@ { "in": "query", "name": "isProjectGondor", - "description": "Is call from a gondor client.", + "description": "Is call from a Gondor client.", "type": "boolean" }, { @@ -347,7 +347,7 @@ }, "syncToken": { "type": "string", - "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to store this value and keep updating if PDS returns a new value. Call this API with the most recent value recieved." + "description": "Sync token represents the checkpoint upto which this policy elements list is updated. Client need to store this value and keep updating if PDS returns a new value. Call this API with the most recent value received." }, "elements": { "type": "array", @@ -428,7 +428,8 @@ "name": "api-version", "description": "The api-version of the service.", "required": true, - "type": "string" + "type": "string", + "x-ms-parameter-location": "client" } }, "securityDefinitions": { From 0b45cc59fae6c00416903b093430745e097e25bf Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 02:41:08 +0000 Subject: [PATCH 11/19] Fix errors. --- .../preview/2022-11-01-preview/pds.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 5fd584df3617..df260ee53199 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -419,7 +419,7 @@ "description": "The endpoint of your Purview account. Example: https://{accountName}.purview.azure.com.", "required": true, "type": "string", - "format": "uri", + "format": "url", "x-ms-parameter-location": "client", "x-ms-skip-url-encoding": true }, From 7d666ad1f6dacef9ad3f27c11050e452c8ded492 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 02:44:34 +0000 Subject: [PATCH 12/19] Fix conflict. --- custom-words.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom-words.txt b/custom-words.txt index 192bd93b843c..1ec8b9d4ab04 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -2696,8 +2696,8 @@ Sami Santali Sirmauri Skolt +Gondor Thangmi Tuvan Uyghur -Gondor Paramter \ No newline at end of file From 5246a08418bc2e73a925903831c02ec7c6ba4b32 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 02:47:50 +0000 Subject: [PATCH 13/19] Fix examples. --- .../2022-11-01-preview/examples/DatasourcePreferences_Get.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json index c19df2389ec2..297fa34f15d5 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json @@ -15,7 +15,7 @@ "metadata": false, "classification": false }, - "datausegovernance": true + "dataUseGovernance": true }, "excludedScopes": [] }, From d8cab393e367ccb0615123533bfd1fd5338f2038 Mon Sep 17 00:00:00 2001 From: pansharm-ms <106319348+pansharm-ms@users.noreply.github.com> Date: Thu, 10 Nov 2022 03:00:17 +0000 Subject: [PATCH 14/19] Fix linting errors. --- .../examples/DatasourcePreferences_Get.json | 28 +------------------ .../examples/PolicyElements_Get.json | 28 +------------------ .../examples/PolicyEvents_Get.json | 15 +--------- 3 files changed, 3 insertions(+), 68 deletions(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json index 297fa34f15d5..8c829e0dfc82 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/DatasourcePreferences_Get.json @@ -29,33 +29,7 @@ "frequency": 5 } }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { + "default": { "headers": { "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" }, diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json index 9bc8f99356b3..ef9281642c84 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json @@ -33,33 +33,7 @@ ] } }, - "403": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "503": { + "default": { "headers": { "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" }, diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json index b3471fc10180..c9ae72550998 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json @@ -43,20 +43,7 @@ "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" } }, - "400": { - "headers": { - "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" - }, - "body": { - "error": { - "code": "1001", - "message": "Simple error message.", - "target": "Detailed message or error trace.", - "details": [] - } - } - }, - "404": { + "default": { "headers": { "x-ms-correlation-request-id": "f35b289b-7deb-467b-9976-a163926f981f" }, From b47bf40612de5f1c65e326d89c1ed36beb15994f Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 09:15:00 +0530 Subject: [PATCH 15/19] Linting errors. --- .../preview/2022-11-01-preview/pds.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index df260ee53199..1af056d102d8 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -262,7 +262,10 @@ "error": { "$ref": "#/definitions/ErrorModel" } - } + }, + "required": [ + "error" + ] }, "PolicyElement": { "type": "object", From 2caaee6207ea82041bde156767a204dadaebefc8 Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 09:28:31 +0530 Subject: [PATCH 16/19] Linting errors. --- .../{PolicyElements_Get.json => PolicyElements_List.json} | 0 .../preview/2022-11-01-preview/pds.json | 6 +++--- 2 files changed, 3 insertions(+), 3 deletions(-) rename specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/{PolicyElements_Get.json => PolicyElements_List.json} (100%) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_List.json similarity index 100% rename from specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_Get.json rename to specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyElements_List.json diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 1af056d102d8..7b7e06bd781f 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -61,7 +61,7 @@ "PolicyElements" ], "description": "Get policies for given scope.", - "operationId": "PolicyElements_Get", + "operationId": "PolicyElements_List", "produces": [ "application/json" ], @@ -106,8 +106,8 @@ "itemName": "values" }, "x-ms-examples": { - "PolicyElements_Get": { - "$ref": "./examples/PolicyElements_Get.json" + "PolicyElements_List": { + "$ref": "./examples/PolicyElements_List.json" } } } From 06c2e2bfea479673ac4fe36728d761486ef60e9c Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 12:12:38 +0530 Subject: [PATCH 17/19] Fix operatio Id. --- .../{PolicyEvents_Get.json => PolicyEvents_List.json} | 0 .../preview/2022-11-01-preview/pds.json | 6 +++--- 2 files changed, 3 insertions(+), 3 deletions(-) rename specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/{PolicyEvents_Get.json => PolicyEvents_List.json} (100%) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_List.json similarity index 100% rename from specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_Get.json rename to specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/examples/PolicyEvents_List.json diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 7b7e06bd781f..3eb0fca7f9f6 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -118,7 +118,7 @@ "PolicyEvents" ], "description": "Get policy events for given scope.", - "operationId": "PolicyEvents_Get", + "operationId": "PolicyEvents_List", "produces": [ "application/json" ], @@ -159,8 +159,8 @@ } }, "x-ms-examples": { - "PolicyEvents_Get": { - "$ref": "./examples/PolicyEvents_Get.json" + "PolicyEvents_List": { + "$ref": "./examples/PolicyEvents_List.json" } } } From ae23482bcfc6d65f962452b1813901ad12a86e15 Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 12:23:49 +0530 Subject: [PATCH 18/19] Fix x-ms-pageable. --- .../preview/2022-11-01-preview/pds.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 3eb0fca7f9f6..0ce75636974d 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -103,7 +103,7 @@ }, "x-ms-pageable": { "nextLinkName": "nextLink", - "itemName": "values" + "itemName": "elements" }, "x-ms-examples": { "PolicyElements_List": { From adc96fe197ff4829199e481dff77ff8ccb534fff Mon Sep 17 00:00:00 2001 From: Pankaj Sharma Date: Thu, 10 Nov 2022 14:18:20 +0530 Subject: [PATCH 19/19] Add filter description. --- .../preview/2022-11-01-preview/pds.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json index 0ce75636974d..cd2a0a791ed4 100644 --- a/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json +++ b/specification/purview/data-plane/Azure.Analytics.Purview.PDS/preview/2022-11-01-preview/pds.json @@ -83,7 +83,7 @@ { "in": "query", "name": "filter", - "description": "filter.", + "description": "Optional value to filter policies based on hierarchy of resources. It is of type enum with possible values: AtScope, ChildrenScope, None, All", "type": "string" } ],