public async Task <bool> UpdateAnomalyDetectionDiskEventRuleAsync(string id, DiskEventAnomalyDetectionConfig body, CancellationToken cancellationToken = default) { var response = await GetAnomalyDetectionDiskEventsUrl() .AppendPathSegment(id) .PutJsonAsync(body, cancellationToken) .ConfigureAwait(false); return(response.IsSuccessStatusCode); }
public async Task <EntityShortRepresentation> AddAnomalyDetectionDiskEventRuleAsync(DiskEventAnomalyDetectionConfig body, CancellationToken cancellationToken = default) { var response = await GetAnomalyDetectionDiskEventsUrl() .PostJsonAsync(body, cancellationToken) .ReceiveJsonWithErrorChecking <EntityShortRepresentation>() .ConfigureAwait(false); return(response); }