/// <summary> /// Delete is used to delete a single key. /// </summary> /// <param name="key">The key name to delete</param> /// <param name="q">Customized write options</param> /// <returns>A write result indicating if the delete attempt succeeded</returns> public Task <WriteResult <bool> > Delete(string key, WriteOptions q, CancellationToken ct = default(CancellationToken)) { KVPair.ValidatePath(key); return(_client.DeleteReturning <bool>(string.Format("/v1/kv/{0}", key.TrimStart('/')), q).Execute(ct)); }
public async Task <WriteResult> Delete(string queryID, WriteOptions q, CancellationToken ct = default(CancellationToken)) { var res = await _client.DeleteReturning <string>(string.Format("/v1/query/{0}", queryID), q).Execute(ct); return(new WriteResult(res)); }