|
1
|
|
|
# ================================================================================== # |
|
2
|
|
|
# __init__.py - This file is part of the yfrake package. # |
|
3
|
|
|
# ================================================================================== # |
|
4
|
|
|
# # |
|
5
|
|
|
# MIT License # |
|
6
|
|
|
# # |
|
7
|
|
|
# Copyright (c) 2022 Mattias Aabmets # |
|
8
|
|
|
# # |
|
9
|
|
|
# Permission is hereby granted, free of charge, to any person obtaining a copy # |
|
10
|
|
|
# of this software and associated documentation files (the "Software"), to deal # |
|
11
|
|
|
# in the Software without restriction, including without limitation the rights # |
|
12
|
|
|
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # |
|
13
|
|
|
# copies of the Software, and to permit persons to whom the Software is # |
|
14
|
|
|
# furnished to do so, subject to the following conditions: # |
|
15
|
|
|
# # |
|
16
|
|
|
# The above copyright notice and this permission notice shall be included in all # |
|
17
|
|
|
# copies or substantial portions of the Software. # |
|
18
|
|
|
# # |
|
19
|
|
|
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # |
|
20
|
|
|
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # |
|
21
|
|
|
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # |
|
22
|
|
|
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # |
|
23
|
|
|
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # |
|
24
|
|
|
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # |
|
25
|
|
|
# SOFTWARE. # |
|
26
|
|
|
# # |
|
27
|
|
|
# ================================================================================== # |
|
28
|
|
|
base_url: str = 'https://iquery.finance.yahoo.com' |
|
29
|
|
|
paths: dict = { |
|
30
|
|
|
'historical_prices': '/v8/finance/chart/{symbol}', |
|
31
|
|
|
'options': '/v7/finance/options/{symbol}', |
|
32
|
|
|
'insights': '/ws/insights/v2/finance/insights', |
|
33
|
|
|
'quotes_overview': '/v7/finance/quote', |
|
34
|
|
|
'esg_chart': '/v1/finance/esgChart', |
|
35
|
|
|
'quote_type': '/v1/finance/quoteType/{symbol}', |
|
36
|
|
|
'news': '/v1/finance/search', |
|
37
|
|
|
'recommendations': '/v6/finance/recommendationsbysymbol/{symbol}', |
|
38
|
|
|
'shares_outstanding': '/ws/fundamentals-timeseries/v1/finance/timeseries/{symbol}', |
|
39
|
|
|
'validate_symbols': '/v6/finance/quote/validate', |
|
40
|
|
|
'market_summary': '/v6/finance/quote/marketSummary', |
|
41
|
|
|
'trending_symbols': '/v1/finance/trending/US', |
|
42
|
|
|
'currencies': '/v1/finance/currencies', |
|
43
|
|
|
'esg_scores': '/v10/finance/quoteSummary/{symbol}', |
|
44
|
|
|
'purchase_activity': '/v10/finance/quoteSummary/{symbol}', |
|
45
|
|
|
'earnings': '/v10/finance/quoteSummary/{symbol}', |
|
46
|
|
|
'price_overview': '/v10/finance/quoteSummary/{symbol}', |
|
47
|
|
|
'calendar_events': '/v10/finance/quoteSummary/{symbol}', |
|
48
|
|
|
'company_overview': '/v10/finance/quoteSummary/{symbol}', |
|
49
|
|
|
'sec_filings': '/v10/finance/quoteSummary/{symbol}', |
|
50
|
|
|
'detailed_summary': '/v10/finance/quoteSummary/{symbol}', |
|
51
|
|
|
'financials': '/v10/finance/quoteSummary/{symbol}', |
|
52
|
|
|
'recommendation_trend': '/v10/finance/quoteSummary/{symbol}', |
|
53
|
|
|
'ratings_history': '/v10/finance/quoteSummary/{symbol}', |
|
54
|
|
|
'earnings_history': '/v10/finance/quoteSummary/{symbol}', |
|
55
|
|
|
'earnings_trend': '/v10/finance/quoteSummary/{symbol}', |
|
56
|
|
|
'key_statistics': '/v10/finance/quoteSummary/{symbol}', |
|
57
|
|
|
'income_statements': '/v10/finance/quoteSummary/{symbol}', |
|
58
|
|
|
'cashflow_statements': '/v10/finance/quoteSummary/{symbol}', |
|
59
|
|
|
'balance_statements': '/v10/finance/quoteSummary/{symbol}', |
|
60
|
|
|
'institution_ownership': '/v10/finance/quoteSummary/{symbol}', |
|
61
|
|
|
'fund_ownership': '/v10/finance/quoteSummary/{symbol}', |
|
62
|
|
|
'major_holders': '/v10/finance/quoteSummary/{symbol}', |
|
63
|
|
|
'insider_transactions': '/v10/finance/quoteSummary/{symbol}', |
|
64
|
|
|
'insider_holders': '/v10/finance/quoteSummary/{symbol}' |
|
65
|
|
|
} |
|
66
|
|
|
|