Skip to main content

Unified object storage client API

Project description

Object Storage Client

A unified object storage client for Rust and Python, supporting S3, GCS, Azure Blob Storage, HTTP/HTTPS, and Local Filesystem. It provides a simple, URL-based API for object operations, including cross-provider copy and move.

Features

  • Unified API: Single interface for various storage backends.
  • Cross-Provider: Copy or move objects between different storage providers (e.g., S3 to Local FS).
  • Multi-Language: Native Rust library with Python 3.14 bindings.
  • CLI: osc command-line tool for quick operations.

Supported Schemes

  • s3://bucket/path (AWS S3)
  • gs://bucket/path or gcs://bucket/path (Google Cloud Storage)
  • az://container/path (Azure Blob Storage)
  • http://host/path or https://host/path (HTTP/HTTPS)
  • file:///absolute/path or local_path (Local Filesystem)

CLI Usage (osc)

The osc tool allows you to interact with object storage directly from your terminal.

Installation

If you have the source code, you can install it using Cargo:

cargo install --path .

Examples

  • Upload a local file:

    osc put my_file.txt s3://my-bucket/remote_file.txt
    
  • Download an object:

    osc get gs://my-bucket/data.json ./local_data.json
    
  • Copy between providers:

    osc cp s3://source-bucket/image.png az://dest-container/image.png
    
  • List objects:

    osc ls s3://my-bucket/logs/
    
  • Delete an object:

    osc rm s3://my-bucket/temp_file.tmp
    

Rust Usage

Installation

Add object-storage-client to your Cargo.toml:

[dependencies]
object-storage-client = { git = "https://github.com/bixority/object-storage-client" }
tokio = { version = "1.0", features = ["full"] }

Example

use object_storage_client::ObjectStorageClient;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = ObjectStorageClient::new();

    // Upload data
    let data = b"Hello from Rust!";
    client.put("s3://my-bucket/hello.txt", &data).await?;

    // Download data
    let retrieved = client.get("s3://my-bucket/hello.txt").await?;
    println!("Retrieved: {:?}", String::from_utf8(retrieved.to_vec())?);

    // Cross-provider copy (S3 to Local)
    client.copy("s3://my-bucket/hello.txt", "file:///tmp/hello_local.txt").await?;

    Ok(())
}

Python 3.14 Usage

Installation

You can install the package using pip. Note that it requires Python 3.14.

pip install git+https://github.com/bixority/object-storage-client

Or if you are developing locally, you can use maturin:

maturin develop

Example

import asyncio
from object_storage_client import ObjectStorageClient

async def main():
    client = ObjectStorageClient()

    # Upload data
    await client.put("s3://my-bucket/python_test.txt", b"Hello from Python 3.14!")

    # Download data
    data = await client.get("s3://my-bucket/python_test.txt")
    print(f"Retrieved: {data.decode()}")

    # List objects
    items = await client.list("s3://my-bucket/")
    print(f"Bucket items: {items}")

    # Cross-provider move (GCS to S3)
    await client.move_object("gs://my-gcs-bucket/data.csv", "s3://my-s3-bucket/data.csv")

if __name__ == "__main__":
    asyncio.run(main())

Developer Instructions

Prerequisites

  • Rust 1.85+ (or latest stable)
  • Python 3.14+
  • maturin (for Python bindings)

Building

  • Rust: cargo build --release
  • Python: maturin build --release
  • CLI: cargo build --bin osc

Testing

cargo test

Project details


Download files

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

Source Distribution

object_storage_client-0.0.17.tar.gz (38.3 kB view details)

Uploaded Source

Built Distributions

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

object_storage_client-0.0.17-cp314-cp314-win_amd64.whl (2.1 MB view details)

Uploaded CPython 3.14Windows x86-64

object_storage_client-0.0.17-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

object_storage_client-0.0.17-cp314-cp314-macosx_11_0_arm64.whl (1.9 MB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

object_storage_client-0.0.17-cp313-cp313-win_amd64.whl (2.1 MB view details)

Uploaded CPython 3.13Windows x86-64

object_storage_client-0.0.17-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

object_storage_client-0.0.17-cp313-cp313-macosx_11_0_arm64.whl (1.9 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

File details

Details for the file object_storage_client-0.0.17.tar.gz.

File metadata

  • Download URL: object_storage_client-0.0.17.tar.gz
  • Upload date:
  • Size: 38.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17.tar.gz
Algorithm Hash digest
SHA256 e0a35ebe275e1eced91867bf30c7bd8c895bbbdd48dffaa9eaafe16f4c6c5c97
MD5 8bbeb3c44536b8d4581e5de38464e421
BLAKE2b-256 57c75374a6c65295f8867e46d70aa992d3fd28e317cb0ce69cbb0f1e131bea0d

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 243ead13db852c2476c095b6a8995de6ccef3749597c5c33dd67467856bcfdf6
MD5 2dde2408d174c12287598e15a6b71994
BLAKE2b-256 610ecb7b87623f9aebf56204827f87e50db5a269aadf993845eafc843aa1bb97

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: CPython 3.14, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 da3296e603ca3f3e8529f8c81f736daf29f0ebafbdc068301dc022fbe656a90f
MD5 97b64828a1ed442f84d93dedfec8b77b
BLAKE2b-256 5ed96dd11f856a66018da0e1614f6937d4273dcb6c1984bfb6a246582113b3cf

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp314-cp314-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.14, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 68fd29a1a0e3a5f5afeb745867b0321e27ee5d6a9a1434c0ef1a46f7f4b3557a
MD5 0854ecf26ac7b772cc650a098fe58f53
BLAKE2b-256 88db6bdf3012f7743e2bda43c7175ed646d2e22034884bd2e1715fbde1cf3f3f

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 a6579115f98c60c175e9dcb1b33d201684e89070f27a6ef7264ec913e0e9b3f9
MD5 aef072b241e5481d42d71f9a60eeeded
BLAKE2b-256 fda6648b7686f608bf5ab3791586b608c193c7e2ba23a00433194ba0276c3980

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 2.1 MB
  • Tags: CPython 3.13, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 80d550d99f8025ba34f1a14c7b1badedda899f7f71b9921b2703a323b2c94058
MD5 835585bb32556fb1b9baa8c4c425067f
BLAKE2b-256 794ac86748f9cbbe03f68af88de84f351f9e15683576ed1e6dd35f4736b229cb

See more details on using hashes here.

File details

Details for the file object_storage_client-0.0.17-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

  • Download URL: object_storage_client-0.0.17-cp313-cp313-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.13, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for object_storage_client-0.0.17-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 d4355bf0b2bf13620bfd44460a5b7187be80b09512468b571f3fd72e49e6ce02
MD5 fcc914143499d4c41bb02fd7e51dfe17
BLAKE2b-256 a11d0473147581c9bb69b1e2cc0a12704d3c93dc740207d9b5774965f2b32d6a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page