I have an API user that pulls data from Salesforce to an external system. i only want to give them the access to the fields and objects that they need for security.

I need to grant them the ability to query OpportunityLineItem field data. The problem is that they cannot see the OpportunityLIneItem object when using the API, I've reproduced this on workbench and data loader and the object is not there.

They have read on Opportunity and Read on Product, still no luck.

Does anyone know what specific permission is needed to access the Opportunity Product object through the API?

  • Do you have Pricebooks set up? Are you saying they can't even describe the object? Or just that they cannot query for it? – Adrian Larson Mar 3 '17 at 15:33
  • I have pricebooks setup and I as an admin can see the object when I go into the data loader to export. This user however cannot. – Dan Wooding Mar 3 '17 at 15:40

In order to access the OpportunityLineItem object you need to have at least the following permissions.

  • Read on Opportunity
  • Read on Product (Product2)
  • Read on Price Book (Pricebook2)

Once all the objects have access you can see the Opportunity Product related list in the UI and you can then describe/query in the API.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.