Skip to main content

Introducing "DitchCarbon", an open-source Python package that allows users to easily call the DitchCarbon API using HTTP requests.

Project description

DitchCarbon Python Package

An open-source Python package that allows users to easily call the DitchCarbon API (v1.0) with type hints etc from within Python.

DitchCarbon is an API that provides information on carbon emissions of different energy sources across the globe. With DitchPy, users can easily retrieve information about the carbon emissions of different energy sources and use it in their own projects.

This package is built on top of the requests library and provides a simple interface for making HTTP requests to the DitchCarbon API. The package includes a set of functions that allow users to retrieve data for specific countries, energy sources, and time periods.

To get started, users can simply install it using pip:

pip install DitchCarbon

Usage

Create an instance of the DitchCarbonClient:

carbon_client = DitchCarbonClient(api_key=API_KEY)

Then call one of the DitchCarbonAPIs endpoints:

carbon_client.get_supplier('Nestle', currency='GBP'))

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

ditchcarbon-0.1.1.tar.gz (19.1 kB view details)

Uploaded Source

Built Distribution

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

ditchcarbon-0.1.1-py3-none-any.whl (16.3 kB view details)

Uploaded Python 3

File details

Details for the file ditchcarbon-0.1.1.tar.gz.

File metadata

  • Download URL: ditchcarbon-0.1.1.tar.gz
  • Upload date:
  • Size: 19.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.13

File hashes

Hashes for ditchcarbon-0.1.1.tar.gz
Algorithm Hash digest
SHA256 a9f2daa34cac626ae2c86b74cd6af243253dffd844dcb1b75d5388bca1f27b87
MD5 19bf1078999dfb6f527807cc5131ca25
BLAKE2b-256 f0895112706b9469c66acb57a64e3b238fecbce16ddcaa8633343ba7557b6f71

See more details on using hashes here.

File details

Details for the file ditchcarbon-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: ditchcarbon-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 16.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.13

File hashes

Hashes for ditchcarbon-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2f801651e40b3e52d9dbf6ac16efa275f9cc256d4d36585435e591ccdbc58ec5
MD5 adcfb7885fa678583ba6eb661974b395
BLAKE2b-256 f0d6335572fdcf7e85d6d9343a8b4a4f6628332cd77c6bb1b6c1d31d82bee221

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