Quantcast
Channel: Active questions tagged feeditem - Salesforce Stack Exchange
Viewing all articles
Browse latest Browse all 160

How to detect user is using Experience Cloud/Community Portal during while posting through chatter feed?

$
0
0

I've very entry-level knowledge about Communities & Portal, correct me if my understanding is wrong.

Scenario: Internal users can create Cases in the Org, on the other hand, external users can also create Cases too using Experience Cloud (Communities Portal). So, after creating Cases, they might create chatter posts in the Case.

My aim: Detect whether the chatter post is coming from the internal user or the external user(From Communities) and take action based on it.

My assumed solution:

-> A trigger will be on the FeedItem Object

-> Whenever a user posts in the Chatter Feed, the trigger will be fired.

-> Check the FeedItem object's InsertedById by the trigger.

-> From InsertedById, I can find User>Profile>Salesforce License.

-> After finding the Salesforce License, I can cross-check the License Name whether it matches with any of the Experience Cloud License Names (String value checking)

-> Thus I can detect whether the chatter post was created by the internal or the external Community Portal User.

Please let me know if my assumption is correct or needs tuning. Thank you.


Viewing all articles
Browse latest Browse all 160

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>