Skip to main content

solari-sandbox (Python)

Python SDK for Solari Sandboxes — fast, ephemeral code sandboxes (micro-VMs) with a code interpreter, filesystem, ports, and git. Mirrors the TypeScript @solarisdk/sandbox package.

Install

pip install solari-sandbox

Quickstart

import asyncio, os
from solari_sandbox import SandboxClient

async def main():
    client = SandboxClient(api_key=os.environ["SOLARI_API_KEY"])
    sb = await client.create(template="base")
    await sb.connect()
    result = await sb.run_code("print(6 * 7)")
    print(result.stdout)                      # -> 42
    await sb.kill()

asyncio.run(main())

SandboxClient(...) accepts api_key, base_url (default https://api.getsolari.com), and call_timeout_ms. The same slr_live_… key authenticates against both the browser and desktop/sandbox APIs.

Docs: https://getsolari.com

Download files

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

Source Distribution

solari_sandbox-0.2.0.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

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

solari_sandbox-0.2.0-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file solari_sandbox-0.2.0.tar.gz.

File metadata

  • Download URL: solari_sandbox-0.2.0.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for solari_sandbox-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6b9658fa12bc4e8e04541da1b0b53bc3128b1e7b95e17aaa30164011258cadd1
MD5 bc0a5a53db44800e89e7471857fc5f94
BLAKE2b-256 d7d9d2aa014871331114c39cee098952fa500067e37c9150ff7954d9e3c37090

See more details on using hashes here.

File details

Details for the file solari_sandbox-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: solari_sandbox-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for solari_sandbox-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0266fc5c44d37c69190f00fc612d6b09b699af6d3de61c351f91419a02b5b4e8
MD5 4033a70840153baf6b33864606803bda
BLAKE2b-256 848ac979cb7569acca1a7b9e00c71298399028e66232c42566858a2c4d98908d

See more details on using hashes here.

Release history Release notifications | RSS feed

0.2.1

2 files

This release

0.2.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page