A product in IOI can have many purposes. Sometimes, a product is just a set of questions with the purpose of collecting data. Other times, a product may do many other things - for example, sell and issue a policy to the client. It can also be a bundle with many purposes all built and mixed together.
Basically, you can use your imagination when it comes to how you want to use your product.
To accommodate this variety, Events and Actions provide the means.
What is an event?
During and after user interaction with a product (answering the questions), a variety of options can be presented to the user. For example, a user could have an option to: save their progress, request contact by 3rd party, request a quote, or purchase coverage.
These options are called Events, and when a user initiates an event, we refer to that as Firing an event.
What is an action?
After an event has been fired, any number of things can happen. Each of those "things" that happen is called an Action.
Actions can perform a variety of tasks. For example, there's an action that will: Map client intake to a PDF document and send it via email to the address(es) you specify. Some actions will take a payload of data collected and send it to some remote web endpoint.
Pro tip: Each event could have multiple, same, or different actions.
How are events and actions added to the product?
Events are added to a specific workflow on a product. To start, select a product and a workflow. To add an event, click + Add new event link.
Each event can be added only once in a workflow. Otherwise, it would not make much sense to, for example, add the "Get Quote" event twice. You can however add any number of actions to that event.
Once an event is added and selected, to the right of it you can click + Add new action to add a new action.
How are events fired?
Events may be fired either programmatically via API, or from one of the IOI products.
Firing an event in the Portal and/or Copilot
Portals and the Copilot are pre-defined to look for existence of several events. Even if product/event-group defines additional events, they may be ignored as they are not relevant to the intended use of these products.
The simplest example of a event firing in a Portal/Copilot is "Get Quotes" button. When a user clicks this button, a "GET_QUOTES" event payload will be sent to IOI. In turn, IOI will look for all workflows available to the user that define a event "GET_QUOTES". All actions defined behind those events will be executed.
Firing a event via API
Events may be fired via API.