Metadata-Version: 2.4
Name: blossom-cli
Version: 0.5.6.post2
Summary: A uvx launcher with bundled Rust blossom-cli binaries
Project-URL: Homepage, https://github.com/brenorb/blossom-cli
Project-URL: Repository, https://github.com/brenorb/blossom-cli
Project-URL: Upstream, https://github.com/MonumentalSystems/blossom-rs
Project-URL: Issues, https://github.com/brenorb/blossom-cli/issues
Author: Blossom CLI Wrapper Contributors
License: MIT License
        
        Copyright (c) 2026 Blossom CLI Wrapper Contributors
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
License-File: NOTICE.md
Keywords: blob-storage,blossom,cli,nostr,uvx
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Utilities
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# blossom-cli

`blossom-cli` is a thin Python wrapper that makes the upstream Rust Blossom client available through `uvx`:

```bash
uvx blossom-cli --version
uvx blossom-cli status
uvx blossom-cli upload ./file.pdf
```

The wrapper preserves the upstream command-line API. It does not add, rename, or reinterpret Rust CLI commands. Platform-specific PyPI wheels contain the compiled Rust executable, so supported platforms do not need Rust or Cargo installed. It resolves the upstream executable in this order:

1. `BLOSSOM_RUST_CLI_BIN`, when explicitly configured.
2. The executable bundled in the platform wheel.
3. A `blossom-cli` executable already available on `PATH`.
4. A versioned executable in the user cache.
5. `cargo install blossom-cli --version 0.5.6 --locked` into the user cache as a fallback for source distributions and unsupported platforms.

The published wheels currently target Linux x86_64, macOS x86_64, macOS arm64, and Windows x86_64. On those platforms, a normal invocation is enough:

```bash
uvx blossom-cli --version
```

This package does not contain or reimplement the Blossom protocol. The Rust executable and protocol implementation come from [`MonumentalSystems/blossom-rs`](https://github.com/MonumentalSystems/blossom-rs), which is published under the MIT License. This project exists only to provide a convenient `uvx` entry point for that upstream project.

## Configuration

The upstream CLI continues to own all options and environment variables, including `BLOSSOM_SECRET_KEY`:

```bash
export BLOSSOM_SERVER="https://blossom.example.com"
export BLOSSOM_SECRET_KEY="<your-secret-key>"

uvx blossom-cli --server "$BLOSSOM_SERVER" --format json --no-publish upload ./file.pdf
```

Use `uvx blossom-cli --help` for the complete command surface. Read the upstream documentation for Blossom protocol behavior and server compatibility.

## Development

```bash
uv sync --dev
uv run pytest
uv build
```

To test the wrapper against a locally available Rust executable without compiling anything:

```bash
BLOSSOM_RUST_CLI_BIN=/path/to/blossom-cli uvx --from . blossom-cli --version
```

## License

The wrapper code is released under the MIT License; see [LICENSE](LICENSE). The upstream project has separate MIT license terms reproduced in [licenses/blossom-rs-MIT.txt](licenses/blossom-rs-MIT.txt).
