/// <summary> /// Changes the state of an AsyncOperation /// </summary> /// <example> /// { "State": "..." } /// </example> /// <remarks> /// Only the State parameter is updated, other fields are ignored /// </remarks> /// <param name="url"></param> /// <param name="newAsyncOp"></param> /// <returns> /// The modified Async Operation /// </returns> public IQuery<AsyncOperation> Update(Uri url, AsyncOperation newAsyncOp) { var sfApiQuery = new ShareFile.Api.Client.Requests.Query<AsyncOperation>(Client); sfApiQuery.Uri(url); sfApiQuery.Body = newAsyncOp; sfApiQuery.HttpMethod = "PATCH"; return sfApiQuery; }
public IQuery<AsyncOperation> Create(AsyncOperation asyncOp) { var sfApiQuery = new ShareFile.Api.Client.Requests.Query<AsyncOperation>(Client); sfApiQuery.From("AsyncOperations"); sfApiQuery.Body = asyncOp; sfApiQuery.HttpMethod = "POST"; return sfApiQuery; }