Having the problem with inserting data in custom module 4401 ("Unable to populate data, please check if mandatory value is entered correctly.")
make sure that there is only three field in my custom module.
this code is working fine with Leads. The Problem is only with custom module
$token="AUTH_TOKEN";
$xmlData='<CustomModule1>';
$xmlData.='<row no="1">';
$xmlData.='<FL val="Aero Name">Aeroiq Registration</FL>';
$xmlData.='<FL val="Aero Owner">Abigail DeCou</FL>';
$xmlData.='<FL val="Customer Name">Test Customer Name</FL>';
$xmlData.='</row>';
$xmlData.='</CustomModule1>';
$fields = array(
'newFormat'=>1,
'authtoken'=>$token,
'scope'=>'crmapi',
'xmlData'=>$xmlData
);
$query = http_build_query($fields);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $query);
$result = curl_exec($ch);
$xml = simplexml_load_string($result);
$json = json_encode($xml);
$array = json_decode($json,TRUE);
var_dump($array);
curl_close($ch);