Simple interface for GME Web API
Project description
GME Web API
Simple Interface to use the GME Web Api programmatically
As the GME does not provide a public API to access data, I've made this library to allow the use of the web facing API used by the site to retrieve the values for various energy prices.
It may be subject to changes and the mechanism used for auth by the site could change anytime.
For now this has the package "requests" as the only dependency, this could be removed by using the built-in urllib3 module, but it's much more cumbersome to use, so that's it, if you don't like it, contributions are welcome!
Usage is pretty basic.
import the package, initialize the api, get prices
everything apart the dates are type checked and enumerated trough classes so just check the source to get the options for the parameters, default to today pun with 15m prices.
it should be a package on pypi but i had no time for that yet, so you'll need to use this as a repo dependency if you want to use it programmatically.
import gmewebapi
#or
#from src import gmewebapi
#if using locally from venv
gme = gmewebapi.GME()
gme.initialize()
gme.getPrice(20260620, 20260621, Granularita, Mercato, Zona, Tipologia)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gmewebapi-0.1.2.tar.gz.
File metadata
- Download URL: gmewebapi-0.1.2.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.23 {"installer":{"name":"uv","version":"0.11.23","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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
751f911b22ec396b4b7207d756763f97373a271a9ad6dd43535bb72d602c3684
|
|
| MD5 |
69e705e2bf56b4c80ef0c9a0ad1f628c
|
|
| BLAKE2b-256 |
eca7853a3b933731f06c02fa5618f2e4b25d3ca8f63f651e808d71c7149d825f
|
File details
Details for the file gmewebapi-0.1.2-py3-none-any.whl.
File metadata
- Download URL: gmewebapi-0.1.2-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.23 {"installer":{"name":"uv","version":"0.11.23","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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5103f1e6861839c15d844ab1672b85eddacf9cb94ca6d6a9efad3cedbeee7325
|
|
| MD5 |
066a6170c4ca32b0d9107b360c73d348
|
|
| BLAKE2b-256 |
ff204b818cae8e2b84728f14fb2e5c5e533dad57d06647f489ac1a3c571d69cc
|