Metadata-Version: 2.4
Name: folsom-fuse
Version: 0.1.0
Summary: Python SDK for the Fuse microVM control plane
Project-URL: Homepage, https://github.com/folsomintel/fuse/tree/main/sdks/python#readme
Project-URL: Repository, https://github.com/folsomintel/fuse.git
Project-URL: Issues, https://github.com/folsomintel/fuse/issues
Author: andrewn6
License: MIT
License-File: LICENSE
Keywords: api-client,firecracker,fuse,microvm,sdk
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Typing :: Typed
Requires-Python: >=3.9
Requires-Dist: httpx>=0.27
Requires-Dist: pydantic>=2.7
Description-Content-Type: text/markdown

# fuse python sdk

python client for the fuse microvm control plane. mirrors the go sdk.

## install

```sh
uv add folsom-fuse
```

## usage

```python
import fuse

with fuse.Client("https://orchestrator.example.com", token="...") as client:
    env = client.environments.create(
        fuse.CreateRequest(task_id="t-1", spec=fuse.Spec(cpus=2, ram_mb=2048))
    )

    for event in client.environments.events(env.id):
        if event.err:
            raise event.err
        print(event.state)
        if fuse.is_terminal_state(event.state):
            break
```

services hang off the client: `client.environments`, `client.snapshots`,
`client.hosts`, `client.api_keys`.

errors raise `fuse.ApiError`; use predicates like `fuse.is_not_found(err)` to
branch on the server error code.

## development

```sh
uv sync
uv run pytest
uv run ruff check .
uv run mypy
```
