Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

EU CBAM & Carbon Tax Calculation Engine — Python SDK

PyPI version Python Versions License: MIT Stanza API

EU CBAM Scope 1/2 embedded emissions and EU ETS carbon tax liability calculator across Iron, Steel, Aluminum, Cement, Fertilizers, and Hydrogen.

Official, zero-dependency Python 3.8+ client library for EU CBAM & Carbon Tax Calculation Engine, built on the Stanza Micro-API Network. Intended for enterprise data pipelines, backend verification, and sub-5ms edge compute.


📦 Installation

pip install stanzaapi-cbam-carbon

🚀 Quickstart

import os
from stanzaapi_cbam_carbon import CbamCarbonClient

# Initialize client (api_key optional for local evaluation)
client = CbamCarbonClient(
    api_key=os.getenv("STANZA_API_KEY")
)

# Execute deterministic validation
response = client.parse({"goods_category":"iron_and_steel","production_country":"TR","quantity_tonnes":500})

if response.get("success"):
    print("Verification Success:", response["data"])
else:
    print("Validation Error:", response.get("error"), response.get("code"))

📄 Example Response

{
  "success": true,
  "data": {
    "goods_category": "iron_and_steel",
    "direct_emissions_tco2e": 950,
    "estimated_ets_liability_eur": 71250
  }
}

⚙️ Client Options

Parameter Type Default Description
api_key Optional[str] os.getenv("STANZA_API_KEY") Your Stanza API Key. Required for production quotas.
base_url Optional[str] "https://api.stanzaapi.com/cbam-carbon" Public edge API base URL.
timeout int 15 Request timeout in seconds.

🔗 Useful Links

📄 License

MIT © Stanza — Powered by Stanza.

Releases

Packages

Contributors

Languages