Skip to main content

Asynchronous Python client for CCEE (Brazilian Electric Energy Commercialization Chamber) API

Project description

Voltarium

CI Python 3.13+ License

Modern, asynchronous Python client for the CCEE (Brazilian Electric Energy Commercialization Chamber) API. Built with Python 3.13+ and designed for high-performance energy sector applications.

🚀 Key Features

  • 🔥 Asynchronous: Built with httpx and asyncio for maximum performance
  • 🔒 Type Safe: Complete type hints with Pydantic models for bulletproof code
  • 🛡️ Robust: Automatic OAuth2 token management with intelligent retry logic
  • 🏗️ Real Staging Data: 60+ authentic CCEE credentials for comprehensive testing
  • ⚡ Modern: Python 3.13+ with UV for lightning-fast dependency management
  • ✅ Production Ready: Comprehensive test suite and error handling

📦 Installation

# Using UV (recommended)
uv add voltarium

# Using pip
pip install voltarium

🔥 Quick Start

import asyncio
from voltarium import VoltariumClient

async def main():
    async with VoltariumClient(
        client_id="your_client_id",
        client_secret="your_client_secret"
    ) as client:
        # List retailer migrations with automatic pagination
        migrations = client.list_migrations(
            initial_reference_month="2024-01",
            final_reference_month="2024-12",
            agent_code="12345",
            profile_code="67890"
        )

        # Stream results efficiently
        async for migration in migrations:
            print(f"Migration {migration.migration_id}: {migration.migration_status}")

asyncio.run(main())

🏗️ Real Staging Environment

Test with real CCEE data using our comprehensive staging environment:

from voltarium.sandbox import RETAILERS, UTILITIES
from voltarium import SANDBOX_BASE_URL

# Use real staging credentials
retailer = RETAILERS[0]  # 30+ available retailers
utility = UTILITIES[0]   # 30+ available utilities

# Test with actual CCEE staging API
async with VoltariumClient(
    base_url=SANDBOX_BASE_URL,
    client_id=retailer.client_id,
    client_secret=retailer.client_secret
) as client:
    # All operations work with real data
    migrations = await client.list_migrations(...)

📚 Comprehensive Documentation

Visit our complete documentation for:

🛠️ Development

# Clone and setup
git clone https://github.com/joaodaher/voltarium-python.git
cd voltarium-python

# Install dependencies (requires UV)
task install-dev

# Run tests
task test

# Quality checks
task lint && task format && task typecheck

🎯 Current Status

Alpha Release - Core migration endpoints fully supported:

Retailer Migrations - Complete CRUD operations 🚧 Utility Migrations - Under development 📋 Additional Endpoints - See roadmap

🤝 Contributing

We welcome contributions! Please see our documentation for details on:

  • Feature roadmap and priorities
  • Development setup and guidelines
  • Testing with real staging data

📄 License

Apache License 2.0 - see LICENSE.md for details.


Built for the Brazilian energy sector 🇧🇷 | Powered by modern Python 🐍

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

voltarium-0.5.2.tar.gz (23.3 kB view details)

Uploaded Source

Built Distribution

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

voltarium-0.5.2-py3-none-any.whl (29.5 kB view details)

Uploaded Python 3

File details

Details for the file voltarium-0.5.2.tar.gz.

File metadata

  • Download URL: voltarium-0.5.2.tar.gz
  • Upload date:
  • Size: 23.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • 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 voltarium-0.5.2.tar.gz
Algorithm Hash digest
SHA256 565b86eef1f37de3b139be7d770471ae9e1e1c97a22c4edee64fc7c23fa22a28
MD5 4726f86cc30e5375e70d317ed0d7a8ba
BLAKE2b-256 4f08f4bac726415c595339a79090552c4221b9b4499f6d01dc47275f59a90ab6

See more details on using hashes here.

File details

Details for the file voltarium-0.5.2-py3-none-any.whl.

File metadata

  • Download URL: voltarium-0.5.2-py3-none-any.whl
  • Upload date:
  • Size: 29.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • 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 voltarium-0.5.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0354a3df61976c34bafc9fdf0bbf2f45d39035d777c41682ee9ff06f2ca55cce
MD5 3fa8199e549808b94ed9230e3774a0f0
BLAKE2b-256 aa997d83e5756249d37bb139cab268fe7f1d83799ba9324bfb509282f5935998

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