Metadata-Version: 2.5
Name: storage-kernel-provider-local-filesystem
Version: 0.1.0a1
Summary: Local filesystem provider for Storage Kernel.
License-Expression: MIT
License-File: LICENSE
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Typing :: Typed
Requires-Python: >=3.12
Requires-Dist: storage-kernel-contracts<0.2.0,>=0.1.0a1
Requires-Dist: storage-kernel-core<0.2.0,>=0.1.0a1
Description-Content-Type: text/markdown

# storage-kernel-provider-local-filesystem

Local filesystem provider for Storage Kernel.

This provider is useful for local development, tests, CI without cloud
infrastructure, and projects that intentionally store files on disk.

## Install

```bash
uv add storage-kernel-contracts storage-kernel-provider-local-filesystem
```

## Usage

```python
from storage_kernel.contracts import StorageClientOptions, StorageLocation, StoragePath
from storage_kernel.provider_local_filesystem import create_local_filesystem_storage_client

storage = create_local_filesystem_storage_client(
    StorageClientOptions(location=StorageLocation(directory=".storage"))
)

await storage.send_content(StoragePath("docs/readme.txt"), "Hello")
```

`StorageLocation.directory` is mandatory and non-empty. Paths are resolved
safely inside it, and empty logical paths are rejected.

## Provider Options

| Option | Purpose |
| --- | --- |
| `public_base_url` | Enables `get_public_url` for files served by an external static/file server |

## Capabilities

- full binary and text reads/writes
- read streams and writable upload streams
- recursive directory reads and deletes
- same-provider native copy
- safe path resolution inside `StorageLocation.directory`
- public URLs when `public_base_url` is configured

Signed URLs are not supported by the local filesystem provider and raise a
normalized capability error.
