public async Task <bool> DeleteBlobAsync(string container, string blob) { var response = await this._httpClient.DeleteAsync(StoragesEndpoint.DeleteBlobInContainer(container, blob)); return(response.IsSuccessStatusCode); }
public async Task <IEnumerable <string> > GetBlobsAsync(string container) { return(await this._httpClient.GetFromJsonAsync <IEnumerable <string> >(StoragesEndpoint.GetAllBlobsInContainer(container))); }
public async Task <byte[]> GetBlobAsync(string container, string blob) { var response = await this._httpClient.GetAsync(StoragesEndpoint.GetBlobInContainer(container, blob)); return(response.IsSuccessStatusCode ? await response.Content.ReadAsByteArrayAsync() : null); }
public async Task <bool> PostBlobsAsync(string container, MultipartFormDataContent blob) { var response = await this._httpClient.PostAsync(StoragesEndpoint.PostBlobInContainer(container), blob); return(response.IsSuccessStatusCode); }