> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cogniagent.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Example: Create HR Meeting Handoff Workflow

> Build a four-step workflow to automate HR meeting approval and handoff

This guide details how to build a robust four-step workflow (On Start 1 → Human Step 1 → Ask AI 1 → App Action 1) to automate the approval, summarization, and internal communication for scheduling a new client meeting.

<Steps>
  <Step title="Initialize the Request (On Start 1)">
    The On Start 1 node is the application's entry point, where you provide the initial meeting data.

    1. **Access Configuration:** Select the On Start 1 node
    2. **Input Data (Instructions Field):** Enter the meeting details as simple, clear text:

    ```text theme={null}
    Client Name: Acme Corp
    Meeting Type: Client Onboarding Call
    Contact Email: john.doe@acmecorp.com
    Proposed Time: December 1, 2025 at 2:00 PM CET
    ```

    <Note>
      This data is stored as the variable `{{on_start_1.startingInputData}}`
    </Note>
  </Step>

  <Step title="Manager Approval Gate (Human Step 1)">
    The Human Step 1 node pauses the workflow and brings a manager in to approve the request before it proceeds.

    1. **Connect Nodes:** Link the output of On Start 1 to Human Step 1
    2. **Pattern:** Choose the **Approval** pattern. This gives the node two outcome branches automatically, **Approved** and **Rejected**, so there are no keyword rules to configure.
    3. **Channel and recipient:** Send it over email to the reviewer: `your-email@example.com`
    4. **Request Message:** Include the data for review using a variable:

    > "A new customer request has been received. `{{on_start_1.startingInputData}}`. Do you approve processing this request?"

    The manager replies in plain words. The node reads the reply and continues on the **Approved** or **Rejected** branch.
  </Step>

  <Step title="AI Processing and Summarization (Ask AI 1)">
    The Ask AI 1 node ensures HR receives a professional, concise summary of the approved request. This node executes only after the **Approved** branch is followed.

    1. **Connect Nodes:** Link the Approved output of Human Step 1 to Ask AI 1
    2. **Prompt for AI (System Instruction):** Define the AI's role:

    ```text theme={null}
    You are a professional assistant specializing in summarizing meeting
    requests for quick logging into a database. Your output must be
    concise and use bullet points.
    ```

    <Note>
      The AI's summary is stored as the variable `{{llm_1.response}}`
    </Note>
  </Step>

  <Step title="Automated HR Handoff (App Action 1)">
    The final App Action 1 node sends the notification email to the HR contact, utilizing the AI's summary.

    1. **Connect Nodes:** Link the output of Ask AI 1 to App Action 1
    2. **Action:** Ensure the node is configured for Gmail: Send Email
    3. **Select Method:** Choose the **Fill by AI** tab
    4. **Instructions:** Write the instructions to generate the final email:

    ```text theme={null}
    Draft a new email.

    Set the recipient's address to: your-email@example.com

    Set the subject line to: ACTION REQUIRED: Schedule New Client Meeting

    The body of the email must be structured as follows:
    1. Start with a greeting and a clear request for the recipient to schedule the meeting.
    2. Clearly present the AI-generated summary of the meeting details in the body.
    3. Conclude with a professional closing.

    Do NOT include the original, raw input data in the email body.
    Only use the summary provided below for the details.

    AI Summary (for content): {{llm_1.response}}
    ```

    This instruction uses the AI's summary to build a professional, concise email.
  </Step>
</Steps>

<Check>
  This completes your robust, four-step workflow for the HR Meeting Handoff!
</Check>
