# Execution Flow Process

The execution process with a third-party platform, particularly utilizing Amazon Connect involves a sequence of steps designed to handle user input effectively and initiate specified workflows within the system:

1. **Caller Initiates a Call**&#x20;
   * The process begins with a caller initiating a call, setting the stage for subsequent actions.
2. **Amazon Connect Triggers Inbound Contact Flow**&#x20;
   * Upon call initiation, Amazon Connect triggers the inbound contact flow, dynamically responding to user input during the interaction.
3. **User Input Handling**&#x20;
   * During the call, the system handles user input, such as pressing a specific key, influencing the subsequent flow within Amazon Connect.
4. **Execute Flow Trigger**&#x20;
   * When a specific user input is received (e.g., pressing 5), a voice message is triggered using text-to-speech. The Execute Flow API is invoked with the specified parameters: Flow ID, Tenant ID, and Payload.
5. **Payload Structure**&#x20;
   * The payload structure encompasses essential information, including the record type (e.g., lead) and user input (e.g., pressing 5), ensuring accurate execution.
6. **Lambda Function Invocation**&#x20;
   * Amazon Connect invokes a Lambda function (e.g., CXF test) configured to call the Execute Flow API of the Executor Service.
7. **Executor Service Execution**&#x20;
   * The Lambda function, acting as an intermediary, executes the Execute Flow API of the Executor Service. The Executor Service processes the request, utilizing the provided parameters, and initiates the specified flow within the CXF application designer.
8. **Flow in CXF Application Designer**&#x20;
   * The Execute Flow API, triggered by the Lambda function, calls a predefined flow within the CXF application designer. This step ensures the seamless execution of designated workflows.
9. **API Call to Third-Party Platform**&#x20;
   * Following the execution within the CXF application, the system calls the API of a third-party platform. This step allows for the integration of external functionalities or data exchange, enhancing overall system capabilities.

\
