function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ZarehZareh 

insufficient access rights on cross-reference id

Hi All,
 
We have an integration system that has been running for more than 2 years without any problems. The system creates contacts / leads...etc via the API.
 
Two days ago we started getting the XML response below everytime we try to create leads....the message says: :insufficient access rights on cross-reference id
 
Did something chnage in the API recently ? our code hasnt been updated for two years...would it be some new permissions ?
 
Thanks,
 
 
The XML response looks like this:
 
  <?xml version="1.0" encoding="UTF-8" ?>
- <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <soapenv:Body>
- <createResponse xmlns="urn:partner.soap.sforce.com">
- <result>
- <errors>
  <fields xsi:nil="true" />
  <message>insufficient access rights on cross-reference id</message>
  <statusCode>INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY</statusCode>
  </errors>
  <id xsi:nil="true" />
  <success>false</success>
  </result>
  </createResponse>
  </soapenv:Body>
  </soapenv:Envelope>
 
 
Jay_$APEXJay_$APEX
Could be a couple of things.
I have seen this message a number of times and it isusually something that makes sense, once you figure it out.
Do you know where in your integration this is happening?
What entity are you loading to? And is the process using foreign keys?
davidswanson1davidswanson1
I had the same problem and found that my API user didnt have the correct prermissions. Once I corrected this the api worked again.
GaikwadGaikwad

Hi,

I have the same problem occurred now. What is the necessary step to rectify it?

zigzagzigzag

Gaikwad wrote:

Hi,

I have the same problem occurred now. What is the necessary step to rectify it?



I also have this problem - from a system that worked last week, it has now started happening - and I need to fix it.

Curiously, it works most of the time.  Only when the sender's email address either does not exist in any Contact, or more than one Contact has the email address does it fail in this way.

I am not aware of the rights on our remote system user having been changed recently, but surely someone else is experiencing the same thing?

Allan
DamoMarkDamoMark

I had this error to when deploying from Sandbox to Production.  I turned out to be an issue with the user profiles in Production had different RecordType access to the user profile in the sandbox.

 

Once I got the two profiles to match I got my trigger deployed. 

Sangam RavindharSangam Ravindhar
I got the same issue, and this is related to record type profile access settings on profile page. i am able to fix this once i gave access to the record type i am updating on profile settings page for that user.
Andrew VuAndrew Vu
The main reason of the issue is the API looking for a field in the salesforce base on the supported ID, but the API could not find any fields that match the supported ID.

For example: (using SOAP API)
My code sends data to salesforce for creating a record in the lead, and the data contains a CampaignID. The campaign lookup field in the lead will find the campaign in the campaign table base on the CampaignID. If the campaign table has a record that matches the CampaignID, a record will be created in the lead, and the campaign lookup field in the lead will display the campaign name. If the campaign table does not has a record that matches the CampaignID, no record will be created in the lead. An error will be throwed "insufficient access rights on cross-reference id: xxxxxxxxxxxxxx". (xxxxxxxxxxxxxx is the ID number).
Bart ChapmanBart Chapman
The fix in my case was to edit the site guest profile > object settings > field permissions.  Although the field permissions were set to both visible and editable in the on the object itself (checkbox = True next to all the user profiles), the guest profile is NOT automatically granted these field permissions. If you create a new field and want it updated from a public site flow, you have to go back and explicity allow the guest profile access to the field. It does not inherit permissions. 
Suraj Tripathi 47Suraj Tripathi 47
Hi Zareh,

It is an access issue of your Org, make sure you are provided the access.
just check it.

you can get help from this link :
https://help.salesforce.com/s/articleView?id=000328226&type=1 (https://help.salesforce.com/s/articleView?id=000328226&type=1)


If you find your Solution then mark this as the best answer.


Thank you!

Regards,
Suraj Tripathi