The following exception has occurred:

Insufficient Privileges: You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary.Class.ConnectApi.ChatterFeeds.postFeedElementBatch: line 1254

ConnectApi.ChatterFeeds.postFeedElementBatch(Network.getNetworkId(), batchInputs);

Note : Enable Chatter is set to True, Edit Posts on Records I Own is set to True, Edit My Own Posts is set to True

1 Answer 1


For ConnectApi to post, the posting user needs to have sharing on the parent record of the FeedItem. Before executing the line in you code, insert the Sharing for the user. I ran into this issue when I was trying to create feeditems where the execution context was initiated by an unshared user. If you post the code, I can look further into it. Hope this helps.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .