Perform Actions on Salesforce Messaging Session Status Changes
2K views
Jan 9, 2025
Salesforce Messaging Session Status Changed Event(MsgSessStatusChangedEvent) standard Platform Event can be used to track the Messaging Session Status values changes or to perform some actions. Blog Post: https://www.infallibletechie.com/2025/01/track-salesforce-messaging-session-status-changes.html
View Video Transcript
0:08
hello everyone in this video we are
0:10
going to see how to track or
0:15
invoke some action whenever Salesforce
0:19
messaging session record status is
0:22
changed so for example here I created an
0:26
object called messaging session status
0:28
tracker in this this object whenever the
0:31
messaging session record is
0:33
updated and especially the status field
0:37
then I am tracking it and then I
0:40
entering those information onto this
0:43
custom object so this uh messaging
0:47
session record the status was set as
0:50
waiting next to active and finally the
0:53
messaging session record was ended let's
0:57
see how to track this or how to to
1:00
invoke an action to um do some business
1:03
process whenever the messaging session
1:06
record status is changed we cannot write
1:09
a trigger or a record triggered flow on
1:11
the messaging session record to achieve
1:13
it uh
1:15
because this messaging session record
1:18
will be routed bya Omni Channel and the
1:21
Omni channel will uh have additional
1:24
process where it will not fire the
1:28
automations what we have on the
1:29
messaging session record the same thing
1:32
we had it with chat and even with other
1:34
object
1:36
um so in order
1:39
to achieve
1:41
this what I have done is I'm using a
1:45
platform event triggered
1:47
flow in the platform event triggered
1:50
flow I am making use of messaging
1:53
session status changed event so this is
1:56
a standard event which a Salesforce
1:59
provides whenever messaging session
2:01
record is updated especially the status
2:05
this particular standard platform event
2:07
will be triggered so whenever this is
2:10
triggered I am invoking this uh platform
2:15
event triggered flow in this flow I am
2:18
making use of create records flow
2:20
element and then I'm creating messaging
2:23
session status tracker which is a custom
2:26
object the messaging session will be
2:29
from the the platform event standard
2:31
platform event I'm getting the
2:33
identifier of the session so this will
2:35
be the messaging session
2:36
record and uh I'm setting the
2:40
status it is a custom field and this is
2:43
also a custom field on the messaging
2:46
session status tracker custom object for
2:48
this I'm making use of the status of the
2:52
session let's see this in
2:56
action as an agent I'm going available
2:59
in channel for
3:02
messaging as an end user I'm going to
3:04
initiate a messaging
3:15
session so I got it as an agent I'm
3:19
going to assist the
3:22
customer so now if I go to this I should
3:26
be able to see two entries so I'm able
3:28
to receive the uh I am able to see that
3:31
in the messaging session was waiting for
3:33
uh an agent to pick it uh since I was
3:36
available as an agent it got assigned it
3:39
to me so now the status is
3:48
active I'm going to end
3:52
it so the agent should be able to see
3:55
the status is ended
4:00
so now so the platform event was uh uh
4:03
triggered three times when the status
4:05
was set to waiting when the status was
4:08
set to active and as well as when the
4:09
status was set to end
4:11
it it called this create records flow
4:14
element and then it was able to create
4:17
the records in messaging session status
4:20
tracker custom
4:23
object you can make use of the same
4:25
platform even triggered flow as a
4:27
reference and then you can do your uh
4:30
business use case using the right flow
4:35
element to invoke the actions and
4:38
perform and also we can track the status
4:41
changes on the messaging session
4:46
record messaging session record is used
4:48
across multiple channels for example in
4:51
this video uh we saw it for messaging
4:54
for Web
4:55
Channel it is also used for SMS channels
4:59
Facebook Apple messenger uh um and as
5:03
well as for WhatsApp channels so make
5:06
sure uh you are not uh um considering
5:11
those channels make sure you consider
5:13
those channels when you try to develop
5:15
something on this particular uh um
5:18
messaging
5:20
session status changed event platform
5:23
event
5:33
I hope it was
5:40
helpful thank you for watching
#Email & Messaging
#Intelligent Personal Assistants
#Internet Software
#Monitoring Software
#Text & Instant Messaging