I was inserting contact in Salesforce, before inserting contact I usually check if that contact exists in Salesforce or not by the email, If I found the 0 records with this email in Salesforce then I insert it else get the ID of that contact and update it.
But now the issue is that I don't have records with this email in the Contact, so I was getting the response:
 => stdClass Object ( [message] => Use one of these records? [errorCode] => UNKNOWN_EXCEPTION [fields] => Array ( ) )
So I don't get it, what is going this. So I try to create with same email manually via Salesforce dashboard, I get to know that I have Record with the same email address in Lead Object and that's why it is going to show issue like the duplicate record.
You can see the screen below screenshot: https://www.screencast.com/t/3wvQxnElq
So I don't get what is going?
What is the relationship between in Lead and Contacts? Why I was getting this error? How can I fix this?
Can anyone please help me with this.