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

# Trigger Flow

> Triggers a flow programatically using API



## OpenAPI

````yaml POST /flows/{flow_id}/trigger
openapi: 3.0.1
info:
  title: Keyflow API
  description: An example API that demonstrates the usage of API keys and accepting inputs
  version: 1.0.0
servers:
  - url: https://keyflow-backend-62hevvkvea-uc.a.run.app/api
security: []
paths:
  /flows/{flow_id}/trigger:
    post:
      summary: Triggers a flow programatically using API
      description: Triggers a flow programatically using API
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Trigger'
      responses:
        '201':
          description: Successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TriggerResponse'
        '400':
          description: Bad request
components:
  schemas:
    Trigger:
      type: object
      required:
        - inputs
      additionalProperties: false
      properties:
        inputs:
          type: object
          additionalProperties: true
          description: >-
            The inputs are dependent on the workflow. They should be passed as a
            JSON object.
      example:
        inputs:
          sender_email: someone@example.com
          email_subject: Test Email Subject
          email_body: Test Body
    TriggerResponse:
      type: object
      properties:
        run_link:
          type: string
          description: URL of run
        run_id:
          type: string
          description: The ID of the run that was triggered.
      example:
        run_link: https://www.keyflow.space/flows/builder?runId=xxxxxxx
        run_id: 1

````