OpenBBTerminal
OpenBBTerminal copied to clipboard
DRAFT - Add new premium source End of Day Historical Data
Note this is a DRAFT PR - Work in Progress - do not review
This source has a wide variety of data and pricing options so this PR's data could cover many of the features currently implemented.
The EOD Historical Data Premium source has an SDK that provides interfaces to data that can be found here.
Requirements
-
You need to request an API key with the EOD team.
-
Create your account here.
-
Please be aware of the pricing plans and policies. Different plans have different data accesses. - Once registered you will receive an API KEY that provides 20 free requests per day.
-
There is a DEMO key for a single ticker MCD.US:
use keys, eodhd demo
in terminal thenstocks, load MCD.US
The demo key now works for several symbols: AAPL, MSFT, MCD, TSLA, VTI, EURUSD and BTCUSD to cover all possible asset types! This key gives access to all data to test.
- Provider covers London and World Wide datasets.
I have implemented the initial Stocks menu for a ticker but have not added any parameters yet.
Parameters: ticker(str): Required - Name of the instrument to retrieve data. Consists of two parts: {TICKER}.{EXCHANGE}, then you can use, for example, MCD.MX for Mexican Stock Exchange. or MCD.US for NYSE. Check the list of supported exchanges to get more information about stock markets the EOD API do support.
Not currently implemented: period(str): Optional - Use 'd' for daily, 'w' for weekly, 'm' for monthly prices. By default, daily prices will be shown. order(str): Optional - Use 'a' for ascending dates (from old to new), 'd' for descending dates (from new to old). By default, dates are shown in ascending order. from_(str) and to(str): Optional - The format is 'YYYY-MM-DD'. If you need data from Jan 5, 2017, to Feb 10, 2017, you should use from_='2017-01-05' and to='2017-02-10'
- Please describe the tests that you ran to verify your changes.
- Provide instructions so we can reproduce.
- Please also list any relevant details for your test configuration.
Checklist:
- [ ] Update our Hugo documentation following these guidelines.
- [ ] Update our tests following these guidelines.
- [ ] Make sure you are following our CONTRIBUTING guidelines.
- [ ] If a feature was added make sure to add it to the corresponding scripts file.
Others
- [ ] I have performed a self-review of my own code.
- [ ] I have commented my code, particularly in hard-to-understand areas.
- [ ] My code passes all the checks pylint, flake8, black, ... To speed up development you should run
pre-commit install
. - [ ] New and existing unit tests pass locally with my changes. You can test this locally using
pytest tests/...
.
Overall I love the idea, more data means more possible users, and more possible partnerships. @DidierRLopes do you think that the eod package should be not installed by default and we can tell a user how to install it after installing the terminal. This way the users who dont use this data will not have to download the extra package, or is it too small to worry about?
Overall I love the idea, more data means more possible users, and more possible partnerships. @DidierRLopes do you think that the eod package should be not installed by default and we can tell a user how to install it after installing the terminal. This way the users who dont use this data will not have to download the extra package, or is it too small to worry about?
or even that the current users will have access to more quality data. In the long run the idea is that we start supporting multiple data sources for each command and we should push that data source selection down to the user.
It is too small to worry about for now :)
or even that the current users will have access to more quality data. In the long run the idea is that we start supporting multiple data sources for each command and we should push that data source selection down to the user.
It is too small to worry about for now :)
Perfect! Also I just realized they have a free API plan, for 20 calls a day. So this is definitely something we want people to have access to.
or even that the current users will have access to more quality data. In the long run the idea is that we start supporting multiple data sources for each command and we should push that data source selection down to the user. It is too small to worry about for now :)
Perfect! Also I just realized they have a free API plan, for 20 calls a day. So this is definitely something we want people to have access to.
On this I could code from scratch and not use the eod library if you prefer, coding for pulling data with rest is straight forward, I am open to either.
Hey @pauljsymonds,
Would you have time to finish this soon? Thanks!
Yes I am planning to make time sometime next week to get into this again.
Overall I love the idea, more data means more possible users, and more possible partnerships. @DidierRLopes do you think that the eod package should be not installed by default and we can tell a user how to install it after installing the terminal. This way the users who dont use this data will not have to download the extra package, or is it too small to worry about?
or even that the current users will have access to more quality data. In the long run the idea is that we start supporting multiple data sources for each command and we should push that data source selection down to the user.
It is too small to worry about for now :)
For now I will leave it using eod package so we can include the initial feature, but I am also considering removing it and coding in the urls dynamically when I extend the functionality to the Fundamentals.
This provider has a huge amount of data available to subscribers at different pricing levels.
I am having issues after loading a ticker.
![Screen Shot 2022-08-30 at 6 16 36 PM](https://user-images.githubusercontent.com/72827203/187553663-503fec6a-f80b-4f80-82bb-617dae5a7557.png)
I am having issues after loading a ticker.
![]()
Odd for me this works:
load -t aapl -w --source eodhd
load -t aapl -m --source eodhd
but
load -t aapl --source eodhd
and
load -t aapl -w --source eodhd
are returning the same results
I am also only using the 'demo' key for this source at this time.
Question
Where is the following populated from?
2022 Aug 31, 02:45 (🦋) /stocks/ $ load -t aapl -m --source eodhd
**Loading Daily** AAPL stock with starting period 2019-08-27 for analysis.
Always displays 'Daily' regardless of the parameter passed.