Skip to main content
Wrenn is a secure infrastructure provider for unsafe code and AI agents. You create isolated capsules — lightweight virtual machines — and interact with them through a Python SDK or REST API. Each capsule is a fully isolated environment where you can run commands, read and write files, open interactive terminals, and execute stateful code through a built-in Jupyter kernel.

Quick Start

Install the SDK, set your API key, and run your first command in under five minutes.

Authentication

Learn how to generate an API key and authenticate your requests.

Capsules

Understand how capsules work — creation, lifecycle, and connecting to existing ones.

Code Interpreter

Run stateful Python code with a persistent Jupyter kernel inside a capsule.

What you can do with Wrenn

Wrenn capsules are full microVMs. Inside each capsule you can:
  • Execute commands — foreground, background, and streaming output
  • Manage files — read, write, list, and stream large files
  • Run stateful code — persistent Jupyter kernel with rich output (charts, images, tables)
  • Open a terminal — interactive PTY sessions that survive reconnects
  • Use Git — clone, commit, push, and pull with credential support
  • Access running services — proxy URLs for ports exposed inside the capsule

Commands

Run shell commands, stream output, and manage background processes.

Filesystem

Read, write, and stream files inside your capsule.

Async Support

Use AsyncCapsule for non-blocking operations in async Python applications.

API Reference

Full REST API reference with request and response schemas.

Get started

1

Install the SDK

pip install wrenn
2

Set your API key

export WRENN_API_KEY="wrn_your_api_key_here"
3

Create your first capsule

from wrenn import Capsule

with Capsule(template="minimal", wait=True) as capsule:
    result = capsule.commands.run("echo hello from Wrenn")
    print(result.stdout)  # "hello from Wrenn\n"