Skip to main content
RunAgent lets you deploy Python-based AI agents and access them from any language with full streaming support.

Key Benefits

  • Deploy agents in seconds - Serverless infrastructure with automatic scaling
  • Access from Python, JS, Go, Rust and coming more - Native-feeling SDKs for every language
  • Built-in streaming - Real-time token streaming for responsive applications

Quick Actions

Hero Light

The Problem Every AI Developer Faces

Suppose you’ve built an incredible AI agent in Python. It uses LangGraph for complex reasoning, leverages powerful tools, and produces amazing results. Your team loves it!

Then reality hits:

Your whole team is excited to use it! But the frontend team needs to access it in JavaScript, your mobile app team wants it in Kotlin, your Unity team wants it in C#, your systems team requires it in Rust.

The traditional approach?

Build separate implementations, REST APIs, WebSocket handlers…
Sound exhausting? That’s because it is!

What RunAgent Actually Does

RunAgent fundamentally changes how AI agent deployment works. Your Python function signatures automatically become API contracts (REST or Streaming) for every supported language.
Once runagent.config.json of your project points to your Python function, they are automatically converted to corresponding API endpoints, and all language SDKs automatically adapt. No API versioning, no breaking changes.
The fastest way to experience the magic is with RunAgent CLI:
1

Install the RunAgent CLI

This installs the powerful RunAgent CLI, which is used to deploy and manage your agents.
pip install runagent
2

Initialize Your Agent

Let’s start with a minimal Agent example.
runagent init my_agent
cd my_agent
This creates a new directory with everything you need to get started:
my_agent/
├── main.py                # Your agent's functions (already defined!)
├── runagent.config.json   # Entrypoints already configured!
└── requirements.txt       # Dependencies
What runagent init created for you:
  • A main.py file with example agent functions (mock_response and mock_response_stream)
  • A runagent.config.json file with entrypoints already configured
  • All the boilerplate needed to make your Python agent accessible from any language
The runagent.config.json file contains all the configuration for your agent, including:
{
  "agent_name": "my_agent",
  "description": "My AI agent",
  "framework": "default",
  "template": "default",
  "version": "1.0.0",
  "created_at": "2025-01-15T10:30:00",
  "agent_id": "f7066c98-0eb2-488c-bb37-a869a93d51ce",
  "template_source": {
    "repo_url": "https://github.com/runagent-dev/runagent.git",
    "author": "runagent-cli",
    "path": "templates/default/default"
  },
  "agent_architecture": {
    "entrypoints": [
      {
        "file": "main.py",
        "module": "mock_response",
        "tag": "minimal"
      },
      {
        "file": "main.py",
        "module": "mock_response_stream",
        "tag": "minimal_stream"
      }
    ]
  },
  "auth_settings": {
    "type": "none"
  },
  "env_vars": {}
}
Key fields:
  • agent_id: A unique identifier for your agent (generated automatically)
  • agent_architecture.entrypoints: Defines which Python functions are accessible as API endpoints
  • auth_settings: Authentication configuration (defaults to “none”)
  • env_vars: Environment variables for your agent
3

Run the Agent Locally

Start your agent locally to test it:
runagent serve .
You will see output similar to:
Agent Details:
- Agent ID: f7066c98-0eb2-488c-bb37-a869a93d51ce
- Host: 127.0.0.1
- Port: 8451
- Framework: default
- Status: ready

Server running at: http://127.0.0.1:8451
API Documentation: http://127.0.0.1:8451/docs

Available endpoints:
- POST /api/v1/agents/.../execute/minimal - Run your agent

INFO: Uvicorn running on http://127.0.0.1:8451 (Press CTRL+C to quit)
That’s it! Your agent is now running and accessible through standard REST API as well as all RunAgent SDKs.
4

Use the Agent in Your Application

Using the RunAgent SDKs, you can access your agent from any supported language. You only need the agent ID and the entrypoint tag. Your mock_response function now becomes accessible in multiple languages:
from runagent import RunAgentClient

# Create a client pointing to your agent
ra = RunAgentClient(
    agent_id="f7066c98-0eb2-488c-bb37-a869a93d51ce",
    entrypoint_tag="minimal",
    local=True
)

# Call your agent
agent_result = ra.run(
    role="user",
    message="Analyze the benefits of remote work for software teams"
)

print(agent_result)
Notice how the same agent logic is accessible from all languages with idiomatic syntax for each.
That’s the core workflow. You’re now ready to deploy your AI agents and integrate them into your applications.

From Local Testing to Production in Seconds

Once you’ve tested your agent locally and confirmed everything works, deploying to production is just one command away. RunAgent Cloud is the fastest AI agent deployment platform, designed to take your local agent from development to production instantly. No complex infrastructure setup, no deployment headaches.

Deploy to Production

runagent deploy .
That’s it. Your agent is now live and accessible globally with:
  • Automatic scaling - Handle one request or one million
  • Global edge network - Low latency worldwide
  • Zero infrastructure management - Focus on your agent, not servers
  • Production-ready security - Enterprise-grade isolation and security
Your deployed agent gets a production URL and agent ID. Simply update your SDK clients to use the production endpoint:
# Switch from local to production
ra = RunAgentClient(
    agent_id="your-production-agent-id",
    entrypoint_tag="minimal",
    local=False  # Now pointing to RunAgent Cloud
)
The same code you tested locally now runs in a fully managed production environment.

Learn More About Deployment

Explore advanced deployment options, environment variables, and monitoring capabilities.

Agent Framework Support

RunAgent works with any Python-based AI agent framework:

Custom Framework

Use any Python-based framework by defining simple entrypoint functions.

Multi-Language SDK Support

RunAgent provides native-like access to your deployed agents across multiple languages:

All Language SDKs

We’re actively developing SDKs for additional languages including C++, C#, Java, and PHP. Want to contribute or request a specific language? Join our Discord community.

Real-Time Streaming Across Languages

In addition to standard REST API responses, you can also stream your agent responses seamlessly through our SDKs. When your entrypoint streams a response, RunAgent makes it feel native in every language SDK:
1

Streaming is Already Set Up

When you ran runagent init, it automatically created both a non-streaming and a streaming function for you. The streaming function is already defined in main.py and configured in runagent.config.json:
main.py
def mock_response_stream(message, role="user") -> Iterator[str]:
  """Test the mock agent with streaming responses"""
  # Your streaming agent logic here
  # Yield chunks of the response as they're generated
  for chunk in generate_response_chunks(message):
      yield chunk
The runagent.config.json already includes this entrypoint with the tag minimal_stream (note the _stream suffix, which tells RunAgent this is a streaming endpoint).
The tag for a streaming entrypoint must end with a _stream suffix. This is how RunAgent identifies it as a streaming endpoint.
2

Run the Agent Locally

Start your agent locally (the streaming endpoint is already available):
runagent serve .
3

Use Streaming in Your Application

Using the RunAgent SDKs, you can stream responses from your agent. The streaming experience feels natural in each language:
from runagent import RunAgentClient

# Create a client with the streaming tag
ra = RunAgentClient(
    agent_id="f7066c98-0eb2-488c-bb37-a869a93d51ce",
    entrypoint_tag="minimal_stream",
    local=True
)

# Stream the response chunk by chunk
for chunk in ra.run(
    role="user",
    message="Analyze the benefits of remote work for software teams"
):
    print(chunk, end='', flush=True)
What’s happening behind the scenes: WebSocket connections, real-time data flow, and native iteration patterns are all handled automatically by RunAgent’s infrastructure.

Next Steps