quantpylib.datapoller.master
DataPoller
Bases: ABC
__init__(config_keys=None)
Initialize the DataPoller class with the provided configuration keys.
The configuration keys are passed in as dictionaries with the appropriate key-value pair.
An example of the valid key-value format is shown as default arguments.
You can create a .envfile and place your keys there, or set it as environment variables.
All the datapollers are available through this master poller,
by accessing the attribute values datapoller.equities, datapoller.crypto and so on.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
config_keys
|
dict
|
A dictionary containing configuration keys for different data sources.
The key-pair dictionary is formatted as
|
None
|
Attributes:
| Name | Type | Description |
|---|---|---|
equities |
Equities
|
An instance of Equities that uses the specified data pollers and defaults to 'eodhd' as the source. |
metadata |
Metadata
|
An instance of Metadata that uses the specified data pollers and defaults to 'eodhd' as the source. |
crypto |
Crypto
|
An instance of Crypto that uses the specified data pollers and defaults to 'binance' as the source. |
currencies |
Currencies
|
An instance of Currencies that uses the specified data pollers and defaults to 'eodhd' as the source. |
exchange |
Exchange
|
An instance of Exchange that uses the specified data pollers and defaults to 'eodhd' as the source. |
cleanup_clients()
async
Cleans up all clients asynchronously, if applicable.
init_clients()
async
Initializes all clients asynchronously, if applicable.