yfrake.openapi.modules.detailed_summary   A
last analyzed

Complexity

Total Complexity 0

Size/Duplication

Total Lines 210
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 141
dl 0
loc 210
rs 10
c 0
b 0
f 0
wmc 0
1
# ================================================================================== #
2
#   detailed_summary.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
summary = 'Detailed Summary'
29
description = 'Returns the detailed summary of a security identifier.'
30
31
# ---------------------------------------------------------------------------------- #
32
parameters = [
33
    {
34
        'name': 'symbol',
35
        'description': 'Any valid equity security identifier.',
36
        'required': True,
37
        'in': 'query',
38
        'schema': {
39
            'type': str
40
        }
41
    }
42
]
43
44
# ---------------------------------------------------------------------------------- #
45
response = {
46
    'maxAge': int,
47
    'priceHint': {
48
        'raw': int,
49
        'fmt': str,
50
        'longFmt': str
51
    },
52
    'previousClose': {
53
        'raw': float,
54
        'fmt': str
55
    },
56
    'open': {
57
        'raw': float,
58
        'fmt': str
59
    },
60
    'dayLow': {
61
        'raw': float,
62
        'fmt': str
63
    },
64
    'dayHigh': {
65
        'raw': float,
66
        'fmt': str
67
    },
68
    'regularMarketPreviousClose': {
69
        'raw': float,
70
        'fmt': str
71
    },
72
    'regularMarketOpen': {
73
        'raw': float,
74
        'fmt': str
75
    },
76
    'regularMarketDayLow': {
77
        'raw': float,
78
        'fmt': str
79
    },
80
    'regularMarketDayHigh': {
81
        'raw': float,
82
        'fmt': str
83
    },
84
    'dividendRate': {
85
        'raw': float,
86
        'fmt': str
87
    },
88
    'dividendYield': {
89
        'raw': float,
90
        'fmt': str
91
    },
92
    'exDividendDate': {
93
        'raw': int,
94
        'fmt': str
95
    },
96
    'payoutRatio': {
97
        'raw': float,
98
        'fmt': str
99
    },
100
    'fiveYearAvgDividendYield': {
101
        'raw': float,
102
        'fmt': str
103
    },
104
    'beta': {
105
        'raw': float,
106
        'fmt': str
107
    },
108
    'trailingPE': {
109
        'raw': float,
110
        'fmt': str
111
    },
112
    'forwardPE': {
113
        'raw': float,
114
        'fmt': str
115
    },
116
    'volume': {
117
        'raw': int,
118
        'fmt': str,
119
        'longFmt': str
120
    },
121
    'regularMarketVolume': {
122
        'raw': int,
123
        'fmt': str,
124
        'longFmt': str
125
    },
126
    'averageVolume': {
127
        'raw': int,
128
        'fmt': str,
129
        'longFmt': str
130
    },
131
    'averageVolume10days': {
132
        'raw': int,
133
        'fmt': str,
134
        'longFmt': str
135
    },
136
    'averageDailyVolume10Day': {
137
        'raw': int,
138
        'fmt': str,
139
        'longFmt': str
140
    },
141
    'bid': {
142
        'raw': float,
143
        'fmt': str
144
    },
145
    'ask': {
146
        'raw': float,
147
        'fmt': str
148
    },
149
    'bidSize': {
150
        'raw': int,
151
        'fmt': str,
152
        'longFmt': str
153
    },
154
    'askSize': {
155
        'raw': int,
156
        'fmt': str,
157
        'longFmt': str
158
    },
159
    'marketCap': {
160
        'raw': int,
161
        'fmt': str,
162
        'longFmt': str
163
    },
164
    'yield': dict,
165
    'ytdReturn': dict,
166
    'totalAssets': dict,
167
    'expireDate': dict,
168
    'strikePrice': dict,
169
    'openInterest': dict,
170
    'fiftyTwoWeekLow': {
171
        'raw': float,
172
        'fmt': str
173
    },
174
    'fiftyTwoWeekHigh': {
175
        'raw': float,
176
        'fmt': str
177
    },
178
    'priceToSalesTrailing12Months': {
179
        'raw': float,
180
        'fmt': str
181
    },
182
    'fiftyDayAverage': {
183
        'raw': float,
184
        'fmt': str
185
    },
186
    'twoHundredDayAverage': {
187
        'raw': float,
188
        'fmt': str
189
    },
190
    'trailingAnnualDividendRate': {
191
        'raw': float,
192
        'fmt': str
193
    },
194
    'trailingAnnualDividendYield': {
195
        'raw': float,
196
        'fmt': str
197
    },
198
    'navPrice': dict,
199
    'currency': str,
200
    'fromCurrency': str,
201
    'toCurrency': str,
202
    'lastMarket': str,
203
    'volume24Hr': dict,
204
    'volumeAllCurrencies': dict,
205
    'circulatingSupply': dict,
206
    'algorithm': str,
207
    'maxSupply': dict,
208
    'startDate': dict,
209
    'tradeable': bool
210
}
211