Esempio n. 1
0
        public Sync CreateSync(Sync sync)
        {
            var request = new RestRequest(Method.POST)
            {
                Resource = "/sync",
                RequestFormat = DataFormat.Json
            };
            request.AddBody(sync);

            return _client.Execute<Sync>(request);
        }
        public async Task<Sync> CreateSyncAsync(Sync sync)
        {
            var request = new RestRequest(Method.POST)
            {
                Resource = BulkUrl.Syncs,
                RequestFormat = DataFormat.Json
            };

            request.AddBody(sync);

            IRestResponse<Sync> syncResponse = await _client.ExecuteTaskAsync<Sync>(request);

            return syncResponse.Data;
        }
 public Sync CreateSync(Sync sync)
 {
     return _client.Syncs.CreateSync(sync);
 }