Flow Context

Flow Context is used by the application to determine which flow path is being executed at any given time (ex. SAML, API), besides that it allows user to easily exchange data between Onegini IdP's Person API and its extensions.
This guide will walk you through the steps required to integrate Flow Context Parameters with extension to Onegini IdP.

Prerequisites

To successfully complete this topic guide you need to ensure following prerequisites:

  • configured Onegini IdP environment as described in quick start
  • have access to Onegini IdP APIs and know the Persons API Basic Authentication credentials

Sending data

Communication is based on http request headers, so if you want to send your own data to Onegini IdP Person API, besides standard headers for authentication you have to add http header on the extension side like shown below:

  X-Onegini-Flow-Context-Params: key1=value1;key2=value2

Reading data

To read data sent as Flow Context on Onegini IdP extension side, you can use FlowContextProvider.getCurrentContext method which returns most recent Flow Context. Parameters that you have sent are available as externalParameters.