Skip to main content

A small client for the WDC-Rest-API.

Project description

Description

This project includes a very small client to access data form the WebDataCollector-API. It is meant to provide a simple means of accessing the data in Json or as Panda-DataFrames.

Usage

from dsslab.wdc_client import *

# make sure file ~/.wdc exists. Content:
# WDC_HOST=${the_host_you_are_using}
# WDC_TOKEN=${your_token}
# Alternative ways to initialize: see docs of WDCClient
client = WDCClient.fromEnv() 
df = client.loadAsDataFrame(
	'api/endpoint...', {'param1', 'value will be encoded'})

For more information about the client and usable endpoints, see the project homepage of WDC or directly consult the Documentation.

Changelog

  • 0.17.0 Add streaming method WDCClient#streamForEach
  • 0.16.1 Add docs
  • 0.16.0 Send parameter "body" as BODY
  • 0.15.0 WDC.fromEnv uses ~/.wdc file if WDC_HOST has not been previously initialized
  • 0.14.0 Added possiblity to pass native dicts and lists to loadAsXXX-methods
  • 0.13.0 Add method WDCClient.loadAsDF(endpoint: str, **params) for brevity
  • 0.12.0 Fix minor bug for Rate-Limiting.
  • 0.11.0 Transparently handle Rate-Limiting from server.
  • 0.10.0 Moved to new package structure with the namespace dsslab.

Old changelog

  • 0.9.1 Make package obsolete.
  • 0.9.0 Add method WDCClient#put to create PUT-Requests
  • 0.8.2 Fix for duplicate parameters when paging.
  • 0.8.1 Simplify new methods for loading a DomainGraph.
  • 0.8.0 Added new methods for loading DomainGraphs.
  • 0.7.3 Fix README
  • 0.7.2 Include link for generated documentation
  • 0.7.1 Added generated documentation
  • 0.7.0 Added new method WDCClient.loadDomainGraph for loading a DomainGraph as NetworkX-Object
  • 0.6.0 WDCClient throws an WDCException if a request to the server fails
  • 0.5.0 New signatures and methods taking care of encodings and working on large results
  • 0.4.3 Add dependencies pandas["excel, plot"] as they are likely to be used.
  • 0.4.2 Enhance README with Changelog and code-example.
  • 0.4.1 Include a preferred variant for creating WDCClients from the Environment

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

dsslab_wdc_client-0.17.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

dsslab_wdc_client-0.17.0-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file dsslab_wdc_client-0.17.0.tar.gz.

File metadata

  • Download URL: dsslab_wdc_client-0.17.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.10.12 Linux/5.15.0-144-generic

File hashes

Hashes for dsslab_wdc_client-0.17.0.tar.gz
Algorithm Hash digest
SHA256 3644abc7ae7acc57e9120ae52a0479e1eba75951df390f5eb08d6cb28f285958
MD5 3f16a6fbf09a28ea7ebeb7092dc4fb6b
BLAKE2b-256 4d36b89893e197afade7f23606b8731d30f23630f9afc6190b7f08890bfab365

See more details on using hashes here.

File details

Details for the file dsslab_wdc_client-0.17.0-py3-none-any.whl.

File metadata

  • Download URL: dsslab_wdc_client-0.17.0-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.10.12 Linux/5.15.0-144-generic

File hashes

Hashes for dsslab_wdc_client-0.17.0-py3-none-any.whl
Algorithm Hash digest
SHA256 af0e56d4520dc1a711e88ad9d0c1387ed25f7ef48778750c6b5a3a6f5de8b88e
MD5 c5355fab8c2c33c201ed63b86d82a040
BLAKE2b-256 5bb5bba255c9f56fd3f64609712f24997fe3cc19cac40d222ae76dad9613baaf

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