@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api PolicyClient
@base https://management.azure.com
@version 2016-04-01
@auth OAuth2
@common_fields {api-version: any # The API version to use for the operation.}
@endpoints 13
@toc {scope}(3), subscriptions(7), {policyAssignmentId}(3)

@group {scope}
@endpoint DELETE /{scope}/providers/Microsoft.Authorization/policyassignments/{policyAssignmentName}
@desc Deletes a policy assignment.
@required {scope: any # The scope of the policy assignment., policyAssignmentName: any # The name of the policy assignment to delete.}
@returns(200) OK - Returns information about the deleted assignment.

@endpoint PUT /{scope}/providers/Microsoft.Authorization/policyassignments/{policyAssignmentName}
@desc Creates a policy assignment.
@required {scope: any # The scope of the policy assignment., policyAssignmentName: any # The name of the policy assignment., parameters: any # Parameters for the policy assignment.}
@returns(201) Created - Returns information about the new policy assignment.

@endpoint GET /{scope}/providers/Microsoft.Authorization/policyassignments/{policyAssignmentName}
@desc Gets a policy assignment.
@required {scope: any # The scope of the policy assignment., policyAssignmentName: any # The name of the policy assignment to get.}
@returns(200) OK - Returns information about the policy assignment.

@endgroup

@group subscriptions
@endpoint GET /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/policyAssignments
@desc Gets policy assignments for the resource group.
@required {resourceGroupName: any # The name of the resource group that contains policy assignments., subscriptionId: any # The ID of the target subscription.}
@optional {$filter: any # The filter to apply on the operation.}
@returns(200) OK - Returns an array of policy assignments.

@endpoint GET /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/policyassignments
@desc Gets policy assignments for a resource.
@required {resourceGroupName: any # The name of the resource group containing the resource. The name is case insensitive., resourceProviderNamespace: any # The namespace of the resource provider., parentResourcePath: any # The parent resource path., resourceType: any # The resource type., resourceName: any # The name of the resource with policy assignments., subscriptionId: any # The ID of the target subscription.}
@optional {$filter: any # The filter to apply on the operation.}
@returns(200) OK - Returns an array of policy assignments.

@endpoint GET /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyassignments
@desc Gets all the policy assignments for a subscription.
@required {subscriptionId: any # The ID of the target subscription.}
@optional {$filter: any # The filter to apply on the operation.}
@returns(200) OK - Returns an array of policy assignments.

@endgroup

@group {policyAssignmentId}
@endpoint DELETE /{policyAssignmentId}
@desc Deletes a policy assignment by ID.
@required {policyAssignmentId: any # The ID of the policy assignment to delete. Use the format '/{scope}/providers/Microsoft.Authorization/policyAssignments/{policy-assignment-name}'.}
@returns(200) OK - Returns information about the policy assignment.

@endpoint PUT /{policyAssignmentId}
@desc Creates a policy assignment by ID.
@required {policyAssignmentId: any # The ID of the policy assignment to create. Use the format '/{scope}/providers/Microsoft.Authorization/policyAssignments/{policy-assignment-name}'., parameters: any # Parameters for policy assignment.}
@returns(201) Created - Returns information about the policy assignment.

@endpoint GET /{policyAssignmentId}
@desc Gets a policy assignment by ID.
@required {policyAssignmentId: any # The ID of the policy assignment to get. Use the format '/{scope}/providers/Microsoft.Authorization/policyAssignments/{policy-assignment-name}'.}
@returns(200) OK - Returns information about the policy assignment.

@endgroup

@group subscriptions
@endpoint PUT /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policydefinitions/{policyDefinitionName}
@desc Creates or updates a policy definition.
@required {policyDefinitionName: any # The name of the policy definition to create., parameters: any # The policy definition properties., subscriptionId: any # The ID of the target subscription.}
@returns(201) Created - Returns information about the policy definition.

@endpoint DELETE /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policydefinitions/{policyDefinitionName}
@desc Deletes a policy definition.
@required {policyDefinitionName: any # The name of the policy definition to delete., subscriptionId: any # The ID of the target subscription.}
@returns(200) OK
@returns(204) No Content

@endpoint GET /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policydefinitions/{policyDefinitionName}
@desc Gets the policy definition.
@required {policyDefinitionName: any # The name of the policy definition to get., subscriptionId: any # The ID of the target subscription.}
@returns(200) OK - Returns information about the policy definition.

@endpoint GET /subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policydefinitions
@desc Gets all the policy definitions for a subscription.
@required {subscriptionId: any # The ID of the target subscription.}
@optional {$filter: any # The filter to apply on the operation.}
@returns(200) OK - Returns ana array of policy definitions.

@endgroup

@end
