Skip to main content

A SDK to consume Eizen services

Project description

EizenSDK

EizenSDK is a Python package that provides a simple interface to interact with the Eizen Analytics API. It handles authentication using Keycloak and provides methods to fetch analytics, zones, sources, and video summaries.

Installation

Ensure you have Python 3.7+ installed. Then, install the package:

pip install eizen-sdk

Usage

Importing and Initializing the SDK

from eizen_sdk import EizenSDK

sdk = EizenSDK(
    username="your_email@example.com",
    password="your_password"
)

Fetching Analytics

analytics = sdk.get_analytics()
print(analytics)

Fetching Zones for an Analytic

zones = sdk.get_analytic_zones(analytic_id=123)
print(zones)

Fetching Sources for a Zone

sources = sdk.get_zone_sources(zone_id=456)
print(sources)

Fetching Sources for an Analytic

sources = sdk.get_analytic_sources(analytic_id=123)
print(sources)

Fetching Source Details

source_details = sdk.get_source_details(source_id=789)
print(source_details)

Fetching Source Summary

source_summary = sdk.get_source_summary(source_id=789)
print(source_summary)

Authentication

EizenSDK handles authentication using Keycloak. It fetches an access token during initialization and refreshes it automatically when expired.

Error Handling

If any request fails, an exception is raised with the HTTP status code and error message.

License

This project is licensed under the MIT License.

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

eizen_sdk-0.1.13.tar.gz (10.5 kB view details)

Uploaded Source

Built Distribution

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

eizen_sdk-0.1.13-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file eizen_sdk-0.1.13.tar.gz.

File metadata

  • Download URL: eizen_sdk-0.1.13.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.2

File hashes

Hashes for eizen_sdk-0.1.13.tar.gz
Algorithm Hash digest
SHA256 17a8b39f2d7c3d662f65b20f88c1d420d4f75de96d2b0f183216bbede4c680df
MD5 a20f0caf6565b407efbd51b628f650e5
BLAKE2b-256 517ccecd50a82d1b8d9cfc8e3eb0a695e1ae145f99edb1f5f18f0da6e36e9913

See more details on using hashes here.

File details

Details for the file eizen_sdk-0.1.13-py3-none-any.whl.

File metadata

  • Download URL: eizen_sdk-0.1.13-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.2

File hashes

Hashes for eizen_sdk-0.1.13-py3-none-any.whl
Algorithm Hash digest
SHA256 68e1f0ded7a374b48368e75f2927c21bba865952c9b35a422284d8171a48149d
MD5 353e498fe67c9817a2ff3ccc55d5606b
BLAKE2b-256 507b17d3e1b566c17ad6621485917dcc372b2bd9e8f28242bcd3c8d050306d0f

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