Error while creating call log

Hi Konanki,

I am able to see that you are passing an API to add a call log for a new contact. This would mean that Freshsales will first create a new Contact and then relate the call log to it. 422 error is received when the Freshsales server is not able to process this request.

Specifically for your use-case this will happen when you are trying to add a call log to a new contact and the contact creation fails. This will happen when you are either not passing a value for mandatory or unique fields in the Freshsales account or are passing a non-unique value for a unique field.

Example in Freshsales Growth plan accounts, Email and External ID fields are unique by default and so you will have to pass any one of the two values for contact creation. If any one of them is not passed in your API call then it will fail with 422 error.

In higher plans, you can set a field to be unique. In such an account if Mobile field is a unique field and you already have a contact with a particular mobile number then when you try adding a new call log for new contact creation with the same mobile number then it will fail with 422 error as the mobile number field is not unique.

This was also communicated in the below question raised by Knowlarity team,

More details about unique fields can be seen in below link,