DocumentClient.DeletePermissionAsync
Method
Definition
Overloads
| DeletePermissionAsync(Uri, RequestOptions) |
Delete a permission as an asynchronous operation from the Azure DocumentDB database service. |
| DeletePermissionAsync(String, RequestOptions) |
Delete a Permission from the Azure DocumentDB database service as an asynchronous operation. |
DeletePermissionAsync(Uri, RequestOptions)
Delete a permission as an asynchronous operation from the Azure DocumentDB database service.
public System.Threading.Tasks.Task<Microsoft.Azure.Documents.Client.ResourceResponse<Microsoft.Azure.Documents.Permission>> DeletePermissionAsync (Uri permissionUri, Microsoft.Azure.Documents.Client.RequestOptions options = null);
- permissionUri
- Uri
the URI of the permission to delete.
- options
- RequestOptions
The request options for the request.
The task object representing the service response for the asynchronous operation.
DeletePermissionAsync(String, RequestOptions)
Delete a Permission from the Azure DocumentDB database service as an asynchronous operation.
public System.Threading.Tasks.Task<Microsoft.Azure.Documents.Client.ResourceResponse<Microsoft.Azure.Documents.Permission>> DeletePermissionAsync (string permissionLink, Microsoft.Azure.Documents.Client.RequestOptions options = null);
- permissionLink
- String
The link of the Permission to delete. E.g. dbs/db_rid/users/user_rid/permissions/permission_rid/
- options
- RequestOptions
(Optional) The request options for the request.
A System.Threading.Tasks containing a ResourceResponse<TResource> which will contain information about the request issued.
If permissionLink is not set.
This exception can encapsulate many different types of errors. To determine the specific error always look at the StatusCode property. Some common codes you may get when creating a Document are:
| StatusCode | Reason for exception |
|---|---|
| 404 | NotFound - This means the resource you tried to delete did not exist. |