Skip to main content

Ovrin Python SDK

Official Python client for the Ovrin agent compute cloud.

pip install ovrin

Quick start

import ovrin

client = ovrin.Client(api_key="ovrin_...")

sandbox = client.sandboxes.create(template="python", timeout=3600)
print(sandbox.id)

result = sandbox.run("python -c 'print(2 + 2)'")
print(result.stdout)  # 4

sandbox.files.write("/workspace/hello.txt", "hi")
print(sandbox.files.read("/workspace/hello.txt"))  # hi

sandbox.kill()

The API key defaults to the OVRIN_API_KEY environment variable; the base URL defaults to OVRIN_BASE_URL (or https://api.ovrin.app).

API surface

  • client.sandboxes.create(..., idempotency_key=None, snapshot_id=None, payments=False) / .list() / .get(id) / .delete(id) / .restore(snapshot_id)
  • sandbox.run(command, timeout=None)CommandResult(stdout, stderr, error)
  • sandbox.stream(command) → events as they are produced, rather than only at the end
  • sandbox.run_code(code, context_id=None) — stateful execution; variables survive between calls
  • sandbox.pause() / .resume() / .renew(expires_at) / .snapshot(name=None) — a paused sandbox bills no compute
  • sandbox.endpoint(port) → the public URL for a port inside the sandbox
  • sandbox.files.read(path) / .read_bytes(path) / .write(path, content) — bytes round-trip intact
  • sandbox.files.list(path, depth=1) / .stat(path) / .search(pattern) / .delete(path) / .move(src, dest) / .mkdir(path)
  • client.snapshots.list() / .get(id) / .delete(id)
  • client.templates.list()
  • client.keys.list() / .create() / .delete(id)
  • client.secrets.create(...) / .list() / .delete(name)
  • client.memory.add(...) / .search(...) / .list() / .delete(id)
  • client.payments.set_credentials(...) / .clear_credentials() / .credentials_status() / .create_customer(...) / .create_invoice(...) / .create_payment_link(...) / .list_customers() / .list_invoices() / .list_payment_links()
  • client.usage.get()

Errors

  • ovrin.AuthenticationError — invalid/missing API key (401)
  • ovrin.QuotaError — plan quota exceeded (402)
  • ovrin.NotFoundError — resource not found (404)
  • ovrin.ApiError — other upstream errors

Release files for ovrin 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ovrin 0.1.1
File Size Uploaded
ovrin-0.1.1.tar.gz 37.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ovrin 0.1.1
File Interpreter ABI Platform
ovrin-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 52.7 kB

Release files / ovrin-0.1.1.tar.gz

Download URL ovrin-0.1.1.tar.gz
Size 37.8 kB
Tags Source
SHA-256 checksum
How to use checksums
3b01b15c0343b8210fdcd22eaeced879e1dc1fb1e744abd99eeb706550fd5559
BLAKE2b-256 checksum
How to use checksums
7002179f88086103709aa960999149d4ecbcd4c4906fb9e5920dfb77fba2156c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 11, 2026.

Transparency log

Release files / ovrin-0.1.1-py3-none-any.whl

Download URL ovrin-0.1.1-py3-none-any.whl
Size 14.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
79d37c95bdc8a3908ec8584e7b81f1673b8d2bf2bec03bc1b38e2e4da27d4881
BLAKE2b-256 checksum
How to use checksums
47e278425c893af5e476f88dda225e1bb7161508c070231333f18badfb731418
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 11, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release 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