Skip to main content

LCPDelta Python Package

Project description

LCPDelta Python Package

The LCPDelta Python package provides streamlined access to data available from the Enact, FLEXtrack APIs.

It contains helper methods for requesting data from our API endpoints or subscribing to push groups, all of which are detailed on our developer documentation site.

Installation

The Python package requires Python 3.10 or greater, and can be installed via:

pip install LCPDelta

Usage

The Enact and FLEXtrack modules can be imported as follows:

from lcp_delta import enact
import lcp_delta.flextrack as flextrack

The package requires a username and API key, which will be emailed on signup. Helper objects can then be instantiated as follows:

username = "insert_username_here"
public_api_key = "insert_public_api_key_here"

enact_api_helper = enact.APIHelper(username, public_api_key)
enact_dps_helper = enact.DPSHelper(username, public_api_key)
flextrack_api_helper = flextrack.APIHelper(username, public_api_key)

From here, you can call any of the available helper methods to retrieve data in one call or listen for pushes. The following example makes use of Enact's Series Data endpoint:

from_date = date(2023,10,1)
to_date = date(2024,10,1)

series_id = "LcpDemandvsGrid"

response = enact_api_helper.get_series_data(
    series_id,
    from_date,
    to_date,
    country_id = "Gb",
    time_zone_id="UTC"
)

print(response.head(5))

Check out our API guides for detailed instructions on getting started with the API, our Recipes page for example scripts using our Python package, and our API reference for details on each specific API endpoint (and corresponding Python package method).

Full documentation of our API and Python package can be found on our documentation site.

Contributing

Check out our contribution guidelines and code of conduct.

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

lcpdelta-2.1.1a8.tar.gz (26.5 kB view details)

Uploaded Source

Built Distribution

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

LCPDelta-2.1.1a8-py3-none-any.whl (35.5 kB view details)

Uploaded Python 3

File details

Details for the file lcpdelta-2.1.1a8.tar.gz.

File metadata

  • Download URL: lcpdelta-2.1.1a8.tar.gz
  • Upload date:
  • Size: 26.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for lcpdelta-2.1.1a8.tar.gz
Algorithm Hash digest
SHA256 e3ca69c289a3a5874a8f3d020785aa2854b07c6ea30e338292912c0cef317e3c
MD5 5d08deb5491e5af8d4e7e052ebcef9b3
BLAKE2b-256 b49bb0b873e31b471a0a96b9b8b7c4385d87dc1cfd2e934735f636be3283532d

See more details on using hashes here.

Provenance

The following attestation bundles were made for lcpdelta-2.1.1a8.tar.gz:

Publisher: release.yml on lcp-llp/lcpdelta-enact

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file LCPDelta-2.1.1a8-py3-none-any.whl.

File metadata

  • Download URL: LCPDelta-2.1.1a8-py3-none-any.whl
  • Upload date:
  • Size: 35.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for LCPDelta-2.1.1a8-py3-none-any.whl
Algorithm Hash digest
SHA256 06031107ef2c49c8356ceb7f3e03906ae8c4c21845fafb5923fd3c8946bd8a83
MD5 279eeb6b9ef1c2f775bf37835a7f0790
BLAKE2b-256 92ae6951b7d115ac417b3236be1b53cc29bea0ceab17e990edc60fe9baefa05b

See more details on using hashes here.

Provenance

The following attestation bundles were made for LCPDelta-2.1.1a8-py3-none-any.whl:

Publisher: release.yml on lcp-llp/lcpdelta-enact

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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