---
title: "Prompt a deployment with streaming response"
method: POST
path: "/v2/studio/deployment/prompt/stream"
tags: ["studio"]
---

# Prompt a deployment with streaming response

`POST /v2/studio/deployment/prompt/stream`

Sends a prompt to a specific miniapp generator deployment and returns a streaming response using Server-Sent Events. The response is a continuous stream of Server-Sent Events, not a single JSON payload. Each event contains a JSON object with type, message, and other fields specific to the message type. Requires authentication via API key in the request header. Note: Studio CU is tracked based on LLM token usage, not per API call.

## Request body

- object
  - `conversation_id` string, uuid — Optional conversation ID to continue an existing chat. If not provided, a new conversation will be created.
  - `deployment_id` string, uuid — Deployment ID (UUID). Required if name not provided.
  - `fid` integer — Farcaster ID of the user; if not provided, namespace must be provided
  - `images` object[] — Optional images for multimodal messages. Each image is base64-encoded.
    - `data` string, required — Base64-encoded image data or data URL (data:image/png;base64,...)
    - `mediaType` 'image/jpeg' | 'image/png' | 'image/gif' | 'image/webp', required — MIME type of the image, e.g. image/png
  - `name` string — Kubernetes deployment name. Required if deployment_id not provided.
  - `namespace` string — Optional Kubernetes namespace. If not provided, will query for the active namespace for the given FID.
  - `prompt` string, required — Prompt string to send to the deployment
  - `session_id` string — Optional Claude SDK session ID to resume an existing Claude Code session. Enables session-based conversation continuity.
  - `system_prompt_variant` 'canary' | 'beta' | 'stable' — System prompt variant to use. Defaults to stable if not provided.

## Response `200`

Success

## Other responses

- `202` — 202
- `400` — Bad Request
- `404` — Resource not found
- `413` — Content Too Large
- `500` — Server Error

---

[API](https://skmtc.dev/neynar/apis/neynar-api.md) · [All operations](https://skmtc.dev/neynar/apis/neynar-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/neynar/neynar-api/revisions/dbb91bfb0d1a/schema)
