$apptivoSiteKey, // Apptivo siteKey "arg1" => $apptivoAccessKey, // Apptivo SiteAccess Key "arg2" => $leadDetails, // Lead Details data array ); try { /* Call Apptivo Services with lead data*/ $response = $client->__soapCall('createLeadWithLeadSource', array($params)); // 'createLeadWithLeadSource' is the Apptivo web service method name } catch (Exception $e) { // display error message while calling apptivo services if($e->getMessage() == 'not-null property references a null or transient value: com.sirahu.apptivo.model.entity.AppComLookup.firmId') { echo "