Using the API

Create a new user state ID or update an existing one with some initialization data

Changed on
post/init/{flowId}

Request

  • Base URL
    https://api.trulioo.com/wfs/interpreter-v2
  • URL
    https://api.trulioo.com/wfs/interpreter-v2/init/{flowId}
  • Auth
    none required

Path parameters

flowIdstring required

The ID of the flow

Headers

x-hf-sessionstring

ID for a user state in the execution flow (generated in the first interaction with a flow).

When x-hf-session header is used, the provided user state will be updated.

Request body

InitData required

fieldInitDataMap: node id to field id to initial value. webhookUrlKey (optional): key of one of the named webhook URLs configured on the flow's API Export node; when present, customer webhooks for this end client and flow go to that URL instead of the flow-level webhook URL.

Example request

{
  "fieldInitDataMap": {
    "some_node_id": {
      "firstNameFieldId": "John",
      "aNumberFieldId": 123
    },
    "some_node_id2": {
      "anEmailFieldId": "some_email@trulioo.com",
      "phoneNumberFieldId": {
        "area": "+1",
        "country": "CA",
        "number": "2154567890"
      }
    }
  },
  "webhookUrlKey": "dev"
}

Response

Returns the new x-hf-session created or the same one if provided in the x-hf-session

Changes

    • breaking

      the response property became optional for the status

    • breaking

      the response property became optional for the status

    • breaking

      the response property became optional for the status

    • breaking

      the response property became optional for the status

    • breaking

      the response's property type changed from string to integer, and format from no format to int32 for status

    • breaking

      the response's property type changed from string to integer, and format from no format to int32 for status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status