swagger: '2.0' info: version: 2020-08-01-preview title: Microsoft Azure AccessControlClient AccessConnector resourceSyncRules API schemes: - https tags: - name: resourceSyncRules paths: ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ExtendedLocation/customLocations/{resourceName}/resourceSyncRules : get: tags: - resourceSyncRules operationId: microsoftAzureResourcesyncrulesListbycustomlocationid summary: Microsoft Azure Lists All Resource Sync Rules In A Custom Location description: Gets a list of Resource Sync Rules in the specified subscription. The operation returns properties of each Resource Sync Rule parameters: - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter - $ref: '#/parameters/ResourceNameParameter' responses: '200': description: OK schema: $ref: '#/definitions/resourceSyncRuleListResult' default: description: Error response describing why the operation failed. schema: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse x-ms-pageable: nextLinkName: nextLink x-ms-examples: List Resource Sync Rules by subscription: $ref: ./examples/ResourceSyncRulesListByCustomLocationID.json ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ExtendedLocation/customLocations/{resourceName}/resourceSyncRules/{childResourceName} : get: tags: - resourceSyncRules operationId: microsoftAzureResourcesyncrulesGet summary: Microsoft Azure Gets A Resource Sync Rule description: Gets the details of the resourceSyncRule with a specified resource group, subscription id Custom Location resource name and Resource Sync Rule name. parameters: - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter - $ref: '#/parameters/ResourceNameParameter' - $ref: '#/parameters/ChildResourceNameParameter' responses: '200': description: OK schema: $ref: '#/definitions/resourceSyncRule' default: description: Error response describing why the operation failed. schema: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse x-ms-examples: Get Custom Location: $ref: ./examples/ResourceSyncRulesGet.json put: tags: - resourceSyncRules operationId: microsoftAzureResourcesyncrulesCreateorupdate summary: Microsoft Azure Creates Or Updates A Resource Sync Rule description: Creates or updates a Resource Sync Rule in the parent Custom Location, Subscription Id and Resource Group parameters: - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter - $ref: '#/parameters/ResourceNameParameter' - $ref: '#/parameters/ChildResourceNameParameter' - name: parameters in: body required: true schema: $ref: '#/definitions/resourceSyncRule' description: Parameters supplied to create or update a Resource Sync Rule. responses: '200': description: OK schema: $ref: '#/definitions/resourceSyncRule' '201': description: Created schema: $ref: '#/definitions/resourceSyncRule' default: description: Error response describing why the operation failed. schema: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse x-ms-long-running-operation: true x-ms-long-running-operation-options: final-state-via: azure-async-operation x-ms-examples: Create/Update Resource Sync Rule: $ref: ./examples/ResourceSyncRulesCreate_Update.json delete: tags: - resourceSyncRules operationId: microsoftAzureResourcesyncrulesDelete summary: Microsoft Azure Deletes A Resource Sync Rule description: Deletes the Resource Sync Rule with the specified Resource Sync Rule Name, Custom Location Resource Name, Resource Group, and Subscription Id. parameters: - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter - $ref: '#/parameters/ResourceNameParameter' - $ref: '#/parameters/ChildResourceNameParameter' responses: '200': description: OK. The response indicates the delete operation is successful. '204': description: NoContent. The response indicates the resourceSyncRule resource is already deleted. default: description: Error response describing why the operation failed. schema: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse x-ms-examples: Delete Resource Sync Rule: $ref: ./examples/ResourceSyncRulesDelete.json patch: tags: - resourceSyncRules operationId: microsoftAzureResourcesyncrulesUpdate summary: Microsoft Azure Updates A Resource Sync Rule description: Updates a Resource Sync Rule with the specified Resource Sync Rule name in the specified Resource Group, Subscription and Custom Location name. parameters: - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter - $ref: ../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter - $ref: '#/parameters/ResourceNameParameter' - $ref: '#/parameters/ChildResourceNameParameter' - name: parameters in: body required: true x-ms-client-flatten: true schema: $ref: '#/definitions/patchableResourceSyncRule' description: The updatable fields of an existing Resource Sync Rule. responses: '200': description: OK schema: $ref: '#/definitions/resourceSyncRule' default: description: Error response describing why the operation failed. schema: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse x-ms-long-running-operation: true x-ms-long-running-operation-options: final-state-via: azure-async-operation x-ms-examples: Update Resource Sync Rule: $ref: ./examples/ResourceSyncRulesPatch.json definitions: resourceSyncRule: description: Resource Sync Rules definition. type: object properties: properties: $ref: '#/definitions/resourceSyncRuleProperties' description: The set of properties specific to a Resource Sync Rule x-ms-client-flatten: true systemData: $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/systemData description: Metadata pertaining to creation and last modification of the resource readOnly: true allOf: - $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/TrackedResource patchableResourceSyncRule: description: The Resource Sync Rules patchable resource definition. type: object x-ms-azure-resource: true x-ms-client-flatten: true properties: properties: $ref: '#/definitions/resourceSyncRuleProperties' description: The Resource Sync Rules patchable properties. x-ms-client-flatten: true tags: description: Resource tags type: object additionalProperties: type: string matchExpressionsProperties: description: Resource Sync Rules matchExpression property definition. type: object properties: key: description: Key is the label key that the selector applies to. type: string operator: description: The Operator field represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist. type: string values: description: The label value type: array items: type: string x-ms-identifiers: [] resourceSyncRuleProperties: description: Properties for a resource sync rule. For an unmapped custom resource, its labels will be used to find out matching resource sync rules using the selector property of the resource sync rule. If this resource sync rule has highest priority among all matching rules, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. type: object properties: priority: description: Priority represents a priority of the Resource Sync Rule type: integer format: int32 provisioningState: description: Provisioning State for the Resource Sync Rule. type: string readOnly: true selector: description: A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match. type: object properties: matchExpressions: $ref: '#/definitions/matchExpressionsList' description: MatchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. x-ms-client-flatten: true matchLabels: description: MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. type: object additionalProperties: type: string targetResourceGroup: description: For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule. type: string resourceSyncRuleListResult: description: The List Resource Sync Rules operation response. type: object properties: nextLink: description: The URL to use for getting the next set of results. type: string readOnly: true value: description: The list of Resource Sync Rules. type: array readOnly: true items: $ref: '#/definitions/resourceSyncRule' x-ms-identifiers: - id matchExpressionsList: description: Resource Sync Rules matchExpression property definition. type: array items: $ref: '#/definitions/matchExpressionsProperties' description: The list of matchExpressions. x-ms-identifiers: [] parameters: ChildResourceNameParameter: name: childResourceName in: path required: true type: string x-ms-parameter-location: method minLength: 1 maxLength: 63 pattern: ^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$ description: Resource Sync Rule name. ResourceNameParameter: name: resourceName in: path required: true type: string x-ms-parameter-location: method minLength: 1 maxLength: 63 pattern: ^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$ description: Custom Locations name. x-ms-parameterized-host: hostTemplate: '{endpoint}' useSchemePrefix: false parameters: - $ref: '#/parameters/Endpoint'