AnsweredAssumed Answered

Enterprise 7.5 Rest v10: Unable to create new record using v10 Rest

Question asked by noah on Apr 27, 2015
Latest reply on Apr 28, 2015 by paperless
Unable to create a new record
but the update call works just fine:

Any help will be hugely appreciated, as i've been at this for more than half a day

if (count($filter_response->records)){

  #record does exist, update it
  $id = $filter_response->records[0]->id;
  $thisurl = "{$base_url}/magni_Dates/$id";
  $this_record = call($thisurl, $oauth2_token_response->access_token, 'PUT', $record);
  #save updates in array
  $updates[] = [$thisurl,$this_record];

  die('finished updating record');
  echo 'record does not exist... creating <br/>';
  $thisurl = "{$base_url}/magni_Dates";
  $this_record = call($thisurl, $oauth2_token_response->access_token, 'POST', $record);
  $id = $this_record->records[0]->id;

  $creates[] = [$thisurl, $this_record];
  die('finished creating');