---
title: "Create Agent Run"
method: POST
path: "/agents/{agent_id}/runs"
tags: ["Agents"]
---

# Create Agent Run

`POST /agents/{agent_id}/runs`

Execute an agent with a message and optional media files. Supports both streaming and non-streaming responses.

**Features:**
- Text message input with optional session management
- Multi-media support: images (PNG, JPEG, WebP), audio (WAV, MP3), video (MP4, WebM, etc.)
- Document processing: PDF, CSV, DOCX, TXT, JSON
- Real-time streaming responses with Server-Sent Events (SSE)
- User and session context preservation

**Streaming Response:**
When `stream=true`, returns SSE events with `event` and `data` fields.

## Path parameters

- `agent_id` string, required

## Response `200`

Agent run executed successfully

- unknown

## Other responses

- `400` — Invalid request or unsupported file type
- `401` — Unauthorized
- `404` — Agent not found
- `422` — Validation Error
- `500` — Internal Server Error

---

[API](https://skmtc.net/agno/apis/agno-api-reference.md) · [All operations](https://skmtc.net/agno/apis/agno-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/agno/agno-api-reference/revisions/5f6149d395d0/schema)
