Client actions are actions that Flock clients take when a user interacts with controls like Slash Commands, Attachment Pickers, Launcher Buttons, and so on.
Flock currently supports three kinds of client actions. They are:
Apps can use widgets to render web applications inside an iframe or webview within Flock. They can not only do everything that a normal webapp can, but also interact with the Flock client hosting them.
To know more about setting up a widget, see How do I configure a widget?
To open a browser, you need to provide the following:
You can open the browser in one of the following ways:
Widgets can also launch the browser using flock.js.
action tag can also be used to launch the browser:
<flockml>click <action type="openBrowser" url="<url>" sendContext="true">here</action> to open the browser.</flockml>
You can also choose to silently send an event to your event listener URL instead.
Different controls have different ways in which their respective client actions can be configured:
flock.openBrowsermethods provided by flock.js.
An event is generated every time a client action is triggered.
The events sent by various controls when a client action is triggered are listed below:
The event name along with its attribute provides sufficient context for the client action.
Yes. Your app may send a message to a user who may not have installed your app, or a group where some users may not have installed your app. When these users interact with this message's attachment (e.g. click on an attachment button, or take some action inside the attachment widget), a client action is triggered.
If you verify that the event token sent with the corresponding event is really signed using your app's secret (you should always do this anyways), you can be certain that the event originated from Flock and was actually triggered by the user whose userId is included in the event token (even if they haven't installed the app).