Skip to navigation

On Flow Ended

View as Markdown

Triggered once, when the session finishes — with the results of what it connected, or with the reason it has none.

This is the event that means finished. Its payload carries is_closed: true at the top — however the session ended, with an aes_key or without one —, and that field, not the widget closing nor your customer leaving, is what tells you a session is over and its results are final.

What data carries, and what actually travels

The schema below describes data decrypted — on purpose, so this reference has a model you can read and code against. What arrives at your endpoint depends on how the session was created:

  • With an aes_key: data is a single string, aes::Base64(IV + Ciphertext + Tag). Decrypt it and you get exactly the object documented below. The walkthrough and the code are in Payload Encryption.
  • Without an aes_key: data is not in the body at all — absent, not null. Your customer’s financial records never travel in the clear: read them from Get Session Results.
A session can end without results

Cancelled by your customer, cancelled by you before anything was connected, timed out, failed: status_code says which, and data then carries the reason rather than the records — user_feedback with what your customer answered in the cancellation dialog, system_feedback when the platform is what stopped it. No results are coming afterwards.

messages: what the session found, beside what it read. The messages list carries the situations the session detected — most sessions carry none. Route the flag ones: they mean the session found something about your customer or their data that deserves a decision on yours, such as two banks that disagree about who your customer is. Automate on message_id, never on the wording.

Events are delivered at least once: deduplicate by session_id and event.

Answer 2xx as soon as the payload reaches you, whatever your processing does with it afterwards: any other status is recorded as a failed delivery even though the event arrived. Answering a delivery has the handler to copy.

Payload

The payload of this webhook request is an object.
event_class"FinancialRiderV1FlowEvent"Required

Payload class discriminator — always this value for Financial Rider events.

app_idstringRequiredformat: "object-id"
customer_idstringRequired1-64 characters
session_idstringRequiredformat: "object-id"
producer"financial-rider"Required
The flow that produced the event.
event"financial-rider:ended"Required

The event type: ended.

status_codeenumRequired
Describes the status of a flow.
is_closedtrueRequired

Always true: the session is over and its results are final — however it ended, and whether data travels or not. This field, not the widget closing, is what says a session is finished.

datestringOptionalformat: "datetime"
status_messagestring or nullOptional
dataobjectOptional

The session’s final results.

  • Documented decrypted, delivered encrypted. With an aes_key on the session this field is the aes::Base64(IV + Ciphertext + Tag) string of the object described here, which decrypts into the session results; without one it is not in the body at all, and the results are read from the session results endpoint instead.
  • A session that ended without results — cancelled, timed out, failed — carries the reason instead, as WebhookEndedErrorPayload.

Response

200
Successful Response
422
Validation Error