Skip to main content

EETC Data Hub Client Library

Project description

EETC Data Client

Python client for consuming the EETC Data Hub REST API. Used for retrieving data managed by EETC Data Hub.

Usage examples

"""
Getting historical daily price data for AAPL.
"""

from eetc_data_client.client import EETCDataClient

client = EETCDataClient(api_key="getYourApiKeyFromUsOnRequest")

aapl_price_data_df = client.get_price_data("AAPL")
print(aapl_price_data_df.head())
"""
Getting fundamentals for AAPL.
"""

from eetc_data_client.client import EETCDataClient

client = EETCDataClient(api_key="getYourApiKeyFromUsOnRequest")

aapl_fundamentals_data_df = client.get_fundamentals_data("AAPL", frequency="Quarterly")
print(aapl_fundamentals_data_df.head())
"""
Getting (macroeconomic) indicator data for Chinese exports.
"""

from eetc_data_client.client import EETCDataClient

client = EETCDataClient(api_key="getYourApiKeyFromUsOnRequest")

china_exports_data_df = client.get_macroeconomic_data("Exports in USD - China")
print(china_exports_data_df.head())

Available (macroeconomic) indicators

To get the available (macroeconomic) indicators use the get_indicators() method. """ Getting historical macroeconomic data for Chinese exports. """

from eetc_data_client.client import EETCDataClient

client = EETCDataClient(api_key="getYourApiKeyFromUsOnRequest")

indicators = client.get_indicators()
print(indicators)

Development

System requirements

To run the project locally and work on it, you need the following:

  • Python 3.8+

Project setup

sudo apt-get install build-essential
make update_and_install_python_requirements

Adding a new Python package

  1. Add the package name to requirements.in
  2. Run:
make update_and_install_python_requirements

Publishing new package versions to PyPi

  1. Update [build_system] section in pyproject.toml in case new dependencies are added or existing dependency versions were updated.
  2. Update version field in [project] section in pyproject.toml whenever there is a new change to the project.
  3. Publish package on PyPi Test, run command:
make publish_package_on_pypi_test
  1. If everything is ok on PyPi Test, publish on "real" PyPi using the command:
make publish_package_on_pypi

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

eetc_data_client-2.1.0.tar.gz (8.0 kB view hashes)

Uploaded Source

Built Distribution

eetc_data_client-2.1.0-py3-none-any.whl (5.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page