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

# Execute a workflow

> Execute a workflow with a file



## OpenAPI

````yaml post /api/v1/workflows/{workflowId}/execute
openapi: 3.1.0
info:
  title: PaperJet API
  description: Secure document extraction API
  version: 1.0.0
servers:
  - url: https://app.getpaperjet.com
    description: Production Server
security:
  - apiKeyAuth: []
paths:
  /api/v1/workflows/{workflowId}/execute:
    post:
      description: Execute a workflow with a file
      operationId: postApiV1Workflows:workflowIdExecute
      parameters:
        - in: path
          name: workflowId
          schema:
            type: string
            pattern: ^wkf_[a-f0-9]{12}$
          required: true
      responses:
        '200':
          description: Execution started
          content:
            application/json:
              schema:
                type: object
                properties:
                  workflowExecutionId:
                    type: string
                  workflowId:
                    type: string
                  status:
                    type: string
                  fileId:
                    type: string
                  filename:
                    type: string
                required:
                  - workflowExecutionId
                  - workflowId
                  - status
                  - fileId
                  - filename
        '400':
          description: Invalid file
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '404':
          description: Workflow not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
        '500':
          description: Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````