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

# Stream a saved workflow

> Run a saved workflow and stream its engine events as SSE.


## OpenAPI

```yaml openapi.json post /v1/workflows/{id}/execute-stream
openapi: 3.1.0
info:
  title: Ocean One API
  version: 2.1.0
servers:
  - url: https://api.plungeai.com
paths:
  /v1/workflows/{id}/execute-stream:
    post:
      summary: Execute a saved workflow with SSE event streaming
      security:
        - ozkBearer: []
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                input:
                  type: string
                inputs:
                  type: object
      responses:
        "200":
          description: 'SSE stream: request_received, workflow_loaded, workflow_started, task_dispatched, streaming_started (streaming agents), token (one frame per provider delta: {"task_id","delta"}), heartbeat, task_completed, workflow_completed (carries execution_summary), workflow_result. Single connection: the gateway drains the provider stream itself; terminal events always arrive on this SSE.'
          content:
            text/event-stream:
              schema:
                type: string
        "413":
          description: payload_too_large — body over 1 MiB (MAX_REQUEST_SIZE)
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
        "429":
          description: rate_limited — Retry-After header
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
components:
  schemas:
    Error:
      type: object
      description: Standard error envelope. Every error response also carries an `X-Error-Code` response header equal to error.code, so a client branches on the header regardless of the negotiated body format (json | yaml | markdown | text). When the request created an execution, the `X-Execution-Id` response header is also set. Errors follow the negotiated format like success bodies.
      properties:
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
          required:
            - code
            - message
          additionalProperties: true
      required:
        - error
  securitySchemes:
    ozkBearer:
      type: http
      scheme: bearer
      description: "ozk_ platform API key (Authorization: Bearer ozk_…)"
```
