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

# Submit Human Input Form

> **Available for**: Chatflow, Workflow apps.

Submits the recipient's response to a paused Human Input form. On acceptance the workflow resumes; follow the resumed run via [Stream Workflow Events](/en/api-reference/workflow-runs/stream-workflow-events). Requires web app delivery on an old Human Input node, or **Initiator** among the recipients of a new one.



## OpenAPI

````yaml /en/api-reference/openapi_service.json post /form/human_input/{form_token}
openapi: 3.0.1
info:
  description: >-
    REST API for Dify applications and knowledge bases. Application endpoints
    authenticate with an app API key; knowledge endpoints authenticate with a
    dataset API key.
  title: Dify Service API
  version: 1.0.0
servers:
  - description: >-
      Base URL of the Dify Service API. For self-hosted deployments, replace it
      with your own API base URL.
    url: https://{api_base_url}
    variables:
      api_base_url:
        default: api.dify.ai/v1
        description: Host and path of the API base URL, without the `https://` prefix.
security:
  - ApiKeyAuth: []
tags:
  - description: Operations related to chat messages and interactions.
    name: Chat Messages
  - description: File upload and preview operations.
    name: Files
  - description: Operations related to end user information.
    name: End Users
  - description: User feedback operations.
    name: Feedback
  - description: Operations related to managing conversations.
    name: Conversations
  - description: Text-to-Speech and Speech-to-Text operations.
    name: Audio
  - description: Operations to retrieve application settings and information.
    name: Applications
  - description: Operations related to managing annotations for direct replies.
    name: Annotations
  - description: Endpoints for resuming paused workflows that require human input.
    name: Human Input
  - description: Operations for executing and managing workflows.
    name: Workflow Runs
  - description: Operations related to text generation and completion.
    name: Completion Messages
  - description: >-
      Operations for managing knowledge bases, including creation,
      configuration, and retrieval.
    name: Knowledge Bases
  - description: >-
      Operations for creating, updating, and managing documents within a
      knowledge base.
    name: Documents
  - description: Operations for managing document chunks and child chunks.
    name: Chunks
  - description: >-
      Operations for managing knowledge base metadata fields and document
      metadata values.
    name: Metadata
  - description: Operations for managing knowledge base tags and tag bindings.
    name: Tags
  - description: Operations for retrieving available models.
    name: Models
  - description: >-
      Operations for managing and running knowledge pipelines, including
      datasource plugins and pipeline execution.
    name: Knowledge Pipeline
  - description: Ask a knowledge base a question and stream the answer.
    name: Queries
  - description: Inspect what a query retrieved and why.
    name: Query Records
  - description: Run a research question in the background and collect its results.
    name: Research Tasks
  - description: >-
      Read the documents in a knowledge base, their files, revisions, and
      chunks; label documents with metadata.
    name: Documents and Chunks
  - description: >-
      Follow, cancel, or retry indexing, and list the knowledge base's
      background tasks.
    name: Indexing Tasks
  - description: >-
      Follow the deletion of a document file, a batch of files, or a source
      until it finishes.
    name: Deletion Jobs
  - description: >-
      Manage the sources that feed a knowledge base, their sync schedules, and
      their connections.
    name: Sources
  - description: >-
      Sync a source now, import website pages or provider items, and follow,
      cancel, or retry the runs.
    name: Source Syncs and Imports
  - description: >-
      Read and change the knowledge base's models and retrieval settings, and
      follow the migration a change starts.
    name: Settings
paths:
  /form/human_input/{form_token}:
    post:
      tags:
        - Human Input
      summary: Submit Human Input Form
      description: >-
        **Available for**: Chatflow, Workflow apps.


        Submits the recipient's response to a paused Human Input form. On
        acceptance the workflow resumes; follow the resumed run via [Stream
        Workflow
        Events](/en/api-reference/workflow-runs/stream-workflow-events).
        Requires web app delivery on an old Human Input node, or **Initiator**
        among the recipients of a new one.
      operationId: submitChatflowHumanInputForm
      parameters:
        - description: >-
            Access token for the paused form, returned in the
            `human_input_required` event from the Run Workflow or Send Chat
            Message endpoint in streaming mode.
          in: path
          name: form_token
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            examples:
              approve:
                summary: Request Example
                value:
                  action: approve
                  inputs:
                    attachment:
                      transfer_method: local_file
                      type: image
                      upload_file_id: 3c8fa1b2-7d4e-4f9a-b0c1-d2e3f4a5b6c7
                    attachments:
                      - transfer_method: local_file
                        type: document
                        upload_file_id: 1a77f0df-c0e6-461c-987c-e72526f341ee
                      - transfer_method: remote_url
                        type: document
                        url: https://example.com/report.pdf
                    draft: >-
                      Our April release adds scheduled exports and faster
                      search. Turn them on from the Settings page.
                    feedback: Looks good to ship
                    priority: high
                  user: abc-123
            schema:
              properties:
                action:
                  description: >-
                    ID of the action button the recipient selected. Must match
                    one of the `id` values from the form's `user_actions` list
                    (returned by [Get Human Input
                    Form](/en/api-reference/human-input/get-human-input-form)).
                  type: string
                inputs:
                  additionalProperties: true
                  description: >-
                    Submitted values keyed by each input's
                    `output_variable_name`. Paragraph and select inputs take a
                    string; a `file` input takes one file mapping; a `file-list`
                    input takes an array of file mappings.


                    A file mapping is `{transfer_method: local_file,
                    upload_file_id, type}` or `{transfer_method: remote_url,
                    url, type}`, where `type` is one of the field's
                    `allowed_file_types`. For `local_file`, `upload_file_id` is
                    the `id` from [Upload
                    File](/en/api-reference/files/upload-file).


                    Use a consistent `user` across the run, upload, and submit.
                  type: object
                user:
                  description: >-
                    End-user identifier, defined by your app and unique within
                    it. Service API and web app user IDs are separate, even when
                    identical. See [End User
                    Identity](/en/api-reference/guides/end-user-identity).
                  type: string
              required:
                - inputs
                - action
                - user
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              examples:
                success:
                  summary: Response Example
                  value: {}
              schema:
                type: object
          description: Form submitted successfully. The response body is an empty object.
        '400':
          content:
            application/json:
              examples:
                bad_request:
                  summary: bad_request
                  value:
                    code: bad_request
                    message: The workflow is not paused with an active checkpoint.
                    status: 400
                invalid_form_data_new_node:
                  summary: invalid_form_data (new node)
                  value:
                    code: invalid_form_data
                    message: Submitted fields must match the resolved form
                    status: 400
                invalid_form_data_old_node:
                  summary: invalid_form_data (old node)
                  value:
                    code: invalid_form_data
                    message: 'Missing required inputs: feedback'
                    status: 400
                invalid_param:
                  summary: invalid_param
                  value:
                    code: invalid_param
                    message: Arg user must be provided.
                    status: 400
          description: >-
            - `bad_request` : The form is from the new Human Input node, and its
            run isn't paused when you submit. You can also get this error
            briefly right after the run pauses, while the pause is still being
            saved; submit again a moment later.

            - `invalid_form_data` : Submission failed validation against the
            form definition.

            - `invalid_param` : The required `user` field is missing or empty.
        '404':
          content:
            application/json:
              examples:
                not_found:
                  summary: not_found
                  value:
                    code: not_found
                    message: Form not found
                    status: 404
          description: '`not_found` : Form not found.'
        '412':
          content:
            application/json:
              examples:
                human_input_form_expired:
                  summary: human_input_form_expired
                  value:
                    code: human_input_form_expired
                    message: >-
                      This form has expired,
                      form_id=a1b2c3d4-e5f6-7890-abcd-ef1234567890
                    status: 412
                human_input_form_submitted:
                  summary: human_input_form_submitted
                  value:
                    code: human_input_form_submitted
                    message: >-
                      This form has already been submitted by another user,
                      form_id=a1b2c3d4-e5f6-7890-abcd-ef1234567890
                    status: 412
          description: >-
            - `human_input_form_submitted` : Form already submitted. Forms are
            one-shot; the first response wins regardless of which user submits
            it.

            - `human_input_form_expired` : The form's expiration time has
            passed, or its run was stopped (for example, with [Stop Workflow
            Task](/en/api-reference/workflow-runs/stop-workflow-task) or [Stop
            Chat Message
            Generation](/en/api-reference/chat-messages/stop-chat-message-generation)).
components:
  securitySchemes:
    ApiKeyAuth:
      bearerFormat: API_KEY
      description: >-
        Every request authenticates with an API key: `Authorization: Bearer
        {API_KEY}`. App endpoints take an app API key; knowledge endpoints take
        a knowledge base API key ([Get
        Started](/en/api-reference/guides/get-started)).


        Keep keys server-side; never embed them in client code. Requests with a
        missing or invalid key fail with HTTP `401` (`unauthorized`).
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.