Box.V2.Managers.BoxFilesManager.DeleteSharedLinkAsync C# (CSharp) Method

DeleteSharedLinkAsync() public method

Used to delete the shared link for this particular file.
public DeleteSharedLinkAsync ( string id ) : Task
id string
return Task
        public async Task<BoxFile> DeleteSharedLinkAsync(string id)
        {
            id.ThrowIfNullOrWhiteSpace("id");

            BoxRequest request = new BoxRequest(_config.FilesEndpointUri, id)
                .Method(RequestMethod.Put)
                .Payload(_converter.Serialize(new BoxDeleteSharedLinkRequest()));

            IBoxResponse<BoxFile> response = await ToResponseAsync<BoxFile>(request).ConfigureAwait(false);

            return response.ResponseObject;
        }