Skip to main content

The Trip Flow

This page explains the overall structure and concepts behind the Fluxir trip flow. This trip flow provides a robust and flexible model for creating service applications around travel. By combining traveler data, contextual requirements, and document processing, the workflow simplifies complex regulatory processes and helps users build complete and valid applications.

Key Concepts

Refer to the Fluxir Concepts page to understand the foundational elements that structure this workflow.

What Is the Trip Flow?

The trip flow in Fluxir represents the lifecycle of requesting and applying for a travel-related service (such as a visa or travel authorization). The process involves gathering required documents, selecting a traveler, validating identity, and submitting a finalized application.

This flow ensures that:

  • All service-specific requirements are collected dynamically based on the trip context.
  • The correct identity and supporting documents are provided.
  • Data merging and validation are performed before final submission.

High-Level Stages

The trip flow is composed of several stages, each with a specific purpose:

1. Service Discovery and Trip Initialization

  • Fetch Service Intents: Determine which travel services are available based on origin, destination, and dates.
  • Create Trip: Define the trip that will be associated with the selected services.
  • Get Document Schema: Retrieve a list of required documents for the selected services and traveler.

2. Traveler Selection and Document Preparation

  • Get List of Travelers: Choose the traveler for whom the application will be made.
  • Select a Traveler: Assign the traveler to the trip context.
  • Create a Service Application: Initialize a draft application to hold user data and documents.

3. Context and Identity Gathering

  • Get Context: Retrieve contextual requirements for the application.
  • Identify Fields to Merge: Identify which values are already available from the context or existing user data.

4. Identity Document Handling

If identity documents are required, this subprocess is triggered:

  • Recognize Identity Document: Use OCR or similar techniques to extract data.
  • Upload File to Storage: Temporarily store the document.
  • Create or Update Identity Document: Populate structured identity data.
  • Get Context: Retrieve updated context with new identity data.
  • Identify Fields to Merge: Re-evaluate what data can be auto-filled.
  • Confirm Merged Fields: Allow the user to confirm extracted values.
  • Merge Field Values: Populate the application form using merged values.

5. Final Application Composition

  • Save Current Application: Save the partially filled service application.
  • Get a Field: Prompt for any remaining required fields.
  • Field Type Evaluation: Handle each field based on its input type (text, file, etc.).
  • Upload File to Storage (if applicable): Handle file-type inputs.
  • Confirm Merged Value: Confirm the input.
  • Merge Field Values: Add the field to the current application.
  • Save Current Application: Persist the updates.

Why It Matters

The Fluxir trip flow is designed to:

  • Reduce redundant data entry by dynamically merging context and traveler information.
  • Ensure correctness through identity document validation.
  • Handle complex document requirements in a modular, extensible way.
  • Allow applications to be saved incrementally, supporting multi-step or asynchronous input collection.

What's Next?

Now that you familiarized yourself with the concepts of creating a trip, refer to the Create a Trip API Guide, and see how to execute this process with Fluxir API.