Open crazyserb opened 2 years ago
Same happens for SSN field, somehow... same error.
The error mentions No field found: Contact.InstagramSocialAccountName
Refer to the table schema here for the Contact table:
https://developer.infusionsoft.com/docs/table-schema/
Fields like FirstName and LastName exist on the table.
But social media related fields don't exist on the Contact table.
Unless they are some new kind of standard fields I haven't encountered before, the table schema doesn't know about them. Whichever the case, they would be custom fields as far as the XMLRPC is concerned and would require an underscore prefix in their name.
I am trying to pass SSN, and FB/IG/Pinterest/Youtube social accounts/URLs to a contact create function:
$contact = array( 'FirstName' => $FNAME, 'LastName' => $LNAME, 'Email' => $EMAIL, 'StreetAddress1' => $STREET, 'City' => $CITY, 'State' => $STATE, 'PostalCode' => $ZIP, 'Country' => $COUNTRY, 'Phone1' => $PHONE, 'SSN' => $SSN, 'FacebookSocialAccountName' => $FacebookSocialAccountName, 'InstagramSocialAccountName' => $InstagramSocialAccountName, 'PinterestSocialAccountName' => $PinterestSocialAccountName, 'YoutubeSocialAccountName' => $YoutubeSocialAccountName, );
and then using this to create that contact:
$contactIDNumber = $infusionsoft->contacts('xml')->add($contact);
But I keep getting this error:
Exception Infusionsoft\Http\HttpException:[NoFieldFound]No field found: Contact.InstagramSocialAccountName at line 34 in file /home/pps/vendor/infusionsoft/php-sdk/src/Infusionsoft/Http/InfusionsoftSerializer.php Infusionsoft\Http\InfusionsoftSerializer->request [ /home/pps/vendor/infusionsoft/php-sdk/src/Infusionsoft/Infusionsoft.php : 456 ] Infusionsoft\Infusionsoft->request [ /home/pps/vendor/infusionsoft/php-sdk/src/Infusionsoft/Api/ContactService.php : 13 ] Infusionsoft\Api\ContactService->add [ /home/pps/public_html/infusionsoft.php : 297 ]
which is that specific line.
Why?
I thought "InstagramSocialAccountName" is a standard Contact field... what am I missing?