swagger: '2.0' info: version: 2020-08-01-preview title: Microsoft Azure AccessControlClient AccessConnector MetadataPolicy API schemes: - https tags: - name: MetadataPolicy paths: /metadataPolicies: get: tags: - MetadataPolicy description: List or Get metadata policies operationId: microsoftAzureMetadatapolicyListall produces: - application/json parameters: - in: query name: collectionName description: The name of an existing collection for which one policy needs to be fetched. type: string - $ref: '#/parameters/api-version' responses: '200': description: Success schema: $ref: '#/definitions/MetadataPolicyList' default: description: An error response received from the Metadata Policy Service schema: $ref: '#/definitions/ErrorResponseModel' headers: x-ms-error-code: type: string description: The error code x-ms-pageable: nextLinkName: nextLink itemName: values x-ms-examples: MetadataPolicy_ListAll: $ref: ./examples/MetadataPolicy_ListAll.json summary: Microsoft Azure Get Metadatapolicies /metadataPolicies/{policyId}: put: tags: - MetadataPolicy description: Updates a metadata policy operationId: microsoftAzureMetadatapolicyUpdate consumes: - application/json produces: - application/json parameters: - in: path name: policyId description: Unique policy id. required: true type: string - $ref: '#/parameters/api-version' - in: body name: body description: Policy to be updated. schema: $ref: '#/definitions/MetadataPolicy' responses: '200': description: Success schema: $ref: '#/definitions/MetadataPolicy' default: description: An error response received from the Metadata Policy Service schema: $ref: '#/definitions/ErrorResponseModel' headers: x-ms-error-code: type: string description: The error code x-ms-examples: MetadataPolicy_Update: $ref: ./examples/MetadataPolicy_Update.json summary: Microsoft Azure Put Metadatapolicies Policyid get: tags: - MetadataPolicy description: Gets a metadata policy operationId: microsoftAzureMetadatapolicyGet produces: - application/json parameters: - in: path name: policyId description: Id of an existing policy that needs to be fetched. required: true type: string - $ref: '#/parameters/api-version' responses: '200': description: Success schema: $ref: '#/definitions/MetadataPolicy' default: description: An error response received from the Metadata Policy Service schema: $ref: '#/definitions/ErrorResponseModel' headers: x-ms-error-code: type: string description: The error code x-ms-examples: MetadataPolicy_Get: $ref: ./examples/MetadataPolicy_Get.json summary: Microsoft Azure Get Metadatapolicies Policyid definitions: MetadataPolicy: type: object properties: name: description: The name of policy type: string id: description: The id of policy type: string version: format: int32 description: The version of policy type: integer properties: $ref: '#/definitions/MetadataPolicyProperties' DecisionRule: description: The decision rule for a policy type: object properties: kind: description: The kind of rule enum: - decisionrule type: string readOnly: true x-ms-enum: name: Kind modelAsString: true effect: description: The effect for rule enum: - Deny - Permit type: string x-ms-enum: name: Decision modelAsString: true dnfCondition: $ref: '#/definitions/DnfCondition' DnfCondition: description: The dnf Condition for a rule type: array items: type: array items: $ref: '#/definitions/AttributeMatcher' AttributeRule: description: The attribute rule for a policy type: object properties: kind: description: The kind of rule enum: - attributerule type: string readOnly: true x-ms-enum: name: Kind modelAsString: true id: description: The id for rule type: string name: description: The name for rule type: string dnfCondition: $ref: '#/definitions/DnfCondition' ErrorResponseModel: description: The error response model for metadata policy required: - error type: object properties: error: $ref: '#/definitions/ErrorModel' MetadataPolicyList: description: List of Metadata Policies required: - values type: object properties: values: type: array items: $ref: '#/definitions/MetadataPolicy' nextLink: type: string MetadataPolicyProperties: type: object properties: description: description: The description of policy type: string decisionRules: description: The DecisionRules of policy type: array items: $ref: '#/definitions/DecisionRule' attributeRules: description: The AttributeRules of policy type: array items: $ref: '#/definitions/AttributeRule' collection: $ref: '#/definitions/CollectionReference' parentCollectionName: description: The parent collection of the policy type: string ErrorModel: description: The error model for metadata policy required: - code - message type: object properties: code: description: The error code type: string message: description: The error message type: string target: description: The error target type: string details: description: The error details type: array items: $ref: '#/definitions/ErrorModel' AttributeMatcher: description: Attribute matcher for a rule type: object properties: attributeName: description: AttributeName type: string attributeValueIncludes: description: Value for attribute type: string attributeValueIncludedIn: description: List of values for attribute type: array items: type: string attributeValueExcludes: description: Value excluded for attribute type: string attributeValueExcludedIn: description: List of values excluded for attribute type: array items: type: string CollectionReference: description: The collection reference for a policy type: object properties: type: description: The type of reference default: CollectionReference type: string referenceName: description: The name of reference type: string parameters: api-version: in: query name: api-version description: The api version to use. required: true type: string x-ms-client-name: ApiVersion x-ms-parameterized-host: hostTemplate: '{endpoint}' useSchemePrefix: false parameters: - $ref: '#/parameters/Endpoint'