Skip to main content

Synapse Cell SDK — E2B-compatible sandboxed code execution, 200x faster, with streaming and filesystem support

Project description

synapserun

Synapse Cell SDK -- E2B-compatible sandboxed code execution, 200x faster.

PyPI npm Python 3.9+ License: MIT

Install

pip install synapserun
npm install @runsynapse/sdk

Zero dependencies -- pure Python stdlib / minimal TS.

Quick Start

from synapse.cell import Cell

cell = Cell(api_key="cell_sk_...")
result = cell.run("print(2 + 2)")
info = cell.get_info()
print(result.stdout)  # "4"
cell.kill()

E2B Migration (one-line change)

# Before (E2B)
from e2b_code_interpreter import Sandbox

# After (Synapse -- same API, 200x faster)
from synapse.e2b_compat import Sandbox

sandbox = Sandbox()
execution = sandbox.run_code("print('hello')")
print(execution.text)  # "hello"
sandbox.kill()

Features (0.3.0)

  • Sandbox lifecycle: create, connect, list, get_info, kill
  • Filesystem: read, write, list, exists, get_info, remove, make_dir, rename
  • Streaming: real-time on_stdout/on_stderr callbacks via SSE
  • Background commands: CommandHandle with is_running/wait/kill
  • Cryptographic receipts: SHA-256 execution chain
  • E2B compatibility: drop-in Sandbox replacement

Full API Reference

See cell/CLAUDE.md for the complete API surface and architecture.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

synapserun-0.3.0.tar.gz (63.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

synapserun-0.3.0-py3-none-any.whl (58.4 kB view details)

Uploaded Python 3

File details

Details for the file synapserun-0.3.0.tar.gz.

File metadata

  • Download URL: synapserun-0.3.0.tar.gz
  • Upload date:
  • Size: 63.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for synapserun-0.3.0.tar.gz
Algorithm Hash digest
SHA256 81b23cf7ef44c95432af7408d0c450f62f0489f0c09c6d92e94931aa874fad93
MD5 2f8228d559768316fd0f3ea983c78cc7
BLAKE2b-256 d9340009c923e25e4154cf6b34e2aec7165bc2e453bbcc1a352863d57dd32b18

See more details on using hashes here.

File details

Details for the file synapserun-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: synapserun-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 58.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for synapserun-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f68cd8df1f1479547aefc20747af0b8e2f0eccb3c4d79bebf3d1ce511118f833
MD5 eec6b51ab07041207b9a33051ef8da01
BLAKE2b-256 ce964a99521f0025cd775f018e3a24fea48ba53e50d885b395c908d2762c2aab

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page