finnhub_ruby 1.1.12 → 1.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +5 -2
- data/docs/BondCandles.md +22 -0
- data/docs/BondProfile.md +58 -0
- data/docs/DefaultApi.md +393 -7
- data/docs/InsiderSentiments.md +20 -0
- data/docs/InsiderSentimentsData.md +26 -0
- data/docs/LobbyingData.md +46 -0
- data/docs/LobbyingResult.md +20 -0
- data/docs/UsptoPatent.md +1 -1
- data/docs/VisaApplication.md +62 -0
- data/docs/VisaApplicationResult.md +20 -0
- data/finnhub_ruby-1.1.12.gem +0 -0
- data/finnhub_ruby-1.1.13.gem +0 -0
- data/finnhub_ruby-1.1.14.gem +0 -0
- data/lib/finnhub_ruby/api/default_api.rb +394 -10
- data/lib/finnhub_ruby/models/bond_candles.rb +243 -0
- data/lib/finnhub_ruby/models/bond_profile.rb +419 -0
- data/lib/finnhub_ruby/models/insider_sentiments.rb +231 -0
- data/lib/finnhub_ruby/models/insider_sentiments_data.rb +259 -0
- data/lib/finnhub_ruby/models/lobbying_data.rb +359 -0
- data/lib/finnhub_ruby/models/lobbying_result.rb +231 -0
- data/lib/finnhub_ruby/models/uspto_patent.rb +1 -1
- data/lib/finnhub_ruby/models/visa_application.rb +439 -0
- data/lib/finnhub_ruby/models/visa_application_result.rb +231 -0
- data/lib/finnhub_ruby/version.rb +1 -1
- data/lib/finnhub_ruby.rb +8 -0
- data/spec/models/bond_candles_spec.rb +46 -0
- data/spec/models/bond_profile_spec.rb +154 -0
- data/spec/models/insider_sentiments_data_spec.rb +58 -0
- data/spec/models/insider_sentiments_spec.rb +40 -0
- data/spec/models/lobbying_data_spec.rb +118 -0
- data/spec/models/lobbying_result_spec.rb +40 -0
- data/spec/models/visa_application_result_spec.rb +40 -0
- data/spec/models/visa_application_spec.rb +166 -0
- metadata +37 -2
@@ -90,6 +90,150 @@ module FinnhubRuby
|
|
90
90
|
return data, status_code, headers
|
91
91
|
end
|
92
92
|
|
93
|
+
# Bond price data
|
94
|
+
# Get end-of-day bond's price data.
|
95
|
+
# @param isin [String] ISIN.
|
96
|
+
# @param from [Integer] UNIX timestamp. Interval initial value.
|
97
|
+
# @param to [Integer] UNIX timestamp. Interval end value.
|
98
|
+
# @param [Hash] opts the optional parameters
|
99
|
+
# @return [BondCandles]
|
100
|
+
def bond_price(isin, from, to, opts = {})
|
101
|
+
data, _status_code, _headers = bond_price_with_http_info(isin, from, to, opts)
|
102
|
+
data
|
103
|
+
end
|
104
|
+
|
105
|
+
# Bond price data
|
106
|
+
# Get end-of-day bond's price data.
|
107
|
+
# @param isin [String] ISIN.
|
108
|
+
# @param from [Integer] UNIX timestamp. Interval initial value.
|
109
|
+
# @param to [Integer] UNIX timestamp. Interval end value.
|
110
|
+
# @param [Hash] opts the optional parameters
|
111
|
+
# @return [Array<(BondCandles, Integer, Hash)>] BondCandles data, response status code and response headers
|
112
|
+
def bond_price_with_http_info(isin, from, to, opts = {})
|
113
|
+
if @api_client.config.debugging
|
114
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.bond_price ...'
|
115
|
+
end
|
116
|
+
# verify the required parameter 'isin' is set
|
117
|
+
if @api_client.config.client_side_validation && isin.nil?
|
118
|
+
fail ArgumentError, "Missing the required parameter 'isin' when calling DefaultApi.bond_price"
|
119
|
+
end
|
120
|
+
# verify the required parameter 'from' is set
|
121
|
+
if @api_client.config.client_side_validation && from.nil?
|
122
|
+
fail ArgumentError, "Missing the required parameter 'from' when calling DefaultApi.bond_price"
|
123
|
+
end
|
124
|
+
# verify the required parameter 'to' is set
|
125
|
+
if @api_client.config.client_side_validation && to.nil?
|
126
|
+
fail ArgumentError, "Missing the required parameter 'to' when calling DefaultApi.bond_price"
|
127
|
+
end
|
128
|
+
# resource path
|
129
|
+
local_var_path = '/bond/price'
|
130
|
+
|
131
|
+
# query parameters
|
132
|
+
query_params = opts[:query_params] || {}
|
133
|
+
query_params[:'isin'] = isin
|
134
|
+
query_params[:'from'] = from
|
135
|
+
query_params[:'to'] = to
|
136
|
+
|
137
|
+
# header parameters
|
138
|
+
header_params = opts[:header_params] || {}
|
139
|
+
# HTTP header 'Accept' (if needed)
|
140
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
141
|
+
|
142
|
+
# form parameters
|
143
|
+
form_params = opts[:form_params] || {}
|
144
|
+
|
145
|
+
# http body (model)
|
146
|
+
post_body = opts[:debug_body]
|
147
|
+
|
148
|
+
# return_type
|
149
|
+
return_type = opts[:debug_return_type] || 'BondCandles'
|
150
|
+
|
151
|
+
# auth_names
|
152
|
+
auth_names = opts[:debug_auth_names] || ['api_key']
|
153
|
+
|
154
|
+
new_options = opts.merge(
|
155
|
+
:operation => :"DefaultApi.bond_price",
|
156
|
+
:header_params => header_params,
|
157
|
+
:query_params => query_params,
|
158
|
+
:form_params => form_params,
|
159
|
+
:body => post_body,
|
160
|
+
:auth_names => auth_names,
|
161
|
+
:return_type => return_type
|
162
|
+
)
|
163
|
+
|
164
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
165
|
+
if @api_client.config.debugging
|
166
|
+
@api_client.config.logger.debug "API called: DefaultApi#bond_price\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
167
|
+
end
|
168
|
+
return data, status_code, headers
|
169
|
+
end
|
170
|
+
|
171
|
+
# Bond Profile
|
172
|
+
# Get general information of a bond. You can query by FIGI, ISIN or CUSIP
|
173
|
+
# @param [Hash] opts the optional parameters
|
174
|
+
# @option opts [String] :isin ISIN
|
175
|
+
# @option opts [String] :cusip CUSIP
|
176
|
+
# @option opts [String] :figi FIGI
|
177
|
+
# @return [BondProfile]
|
178
|
+
def bond_profile(opts = {})
|
179
|
+
data, _status_code, _headers = bond_profile_with_http_info(opts)
|
180
|
+
data
|
181
|
+
end
|
182
|
+
|
183
|
+
# Bond Profile
|
184
|
+
# Get general information of a bond. You can query by FIGI, ISIN or CUSIP
|
185
|
+
# @param [Hash] opts the optional parameters
|
186
|
+
# @option opts [String] :isin ISIN
|
187
|
+
# @option opts [String] :cusip CUSIP
|
188
|
+
# @option opts [String] :figi FIGI
|
189
|
+
# @return [Array<(BondProfile, Integer, Hash)>] BondProfile data, response status code and response headers
|
190
|
+
def bond_profile_with_http_info(opts = {})
|
191
|
+
if @api_client.config.debugging
|
192
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.bond_profile ...'
|
193
|
+
end
|
194
|
+
# resource path
|
195
|
+
local_var_path = '/bond/profile'
|
196
|
+
|
197
|
+
# query parameters
|
198
|
+
query_params = opts[:query_params] || {}
|
199
|
+
query_params[:'isin'] = opts[:'isin'] if !opts[:'isin'].nil?
|
200
|
+
query_params[:'cusip'] = opts[:'cusip'] if !opts[:'cusip'].nil?
|
201
|
+
query_params[:'figi'] = opts[:'figi'] if !opts[:'figi'].nil?
|
202
|
+
|
203
|
+
# header parameters
|
204
|
+
header_params = opts[:header_params] || {}
|
205
|
+
# HTTP header 'Accept' (if needed)
|
206
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
207
|
+
|
208
|
+
# form parameters
|
209
|
+
form_params = opts[:form_params] || {}
|
210
|
+
|
211
|
+
# http body (model)
|
212
|
+
post_body = opts[:debug_body]
|
213
|
+
|
214
|
+
# return_type
|
215
|
+
return_type = opts[:debug_return_type] || 'BondProfile'
|
216
|
+
|
217
|
+
# auth_names
|
218
|
+
auth_names = opts[:debug_auth_names] || ['api_key']
|
219
|
+
|
220
|
+
new_options = opts.merge(
|
221
|
+
:operation => :"DefaultApi.bond_profile",
|
222
|
+
:header_params => header_params,
|
223
|
+
:query_params => query_params,
|
224
|
+
:form_params => form_params,
|
225
|
+
:body => post_body,
|
226
|
+
:auth_names => auth_names,
|
227
|
+
:return_type => return_type
|
228
|
+
)
|
229
|
+
|
230
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
231
|
+
if @api_client.config.debugging
|
232
|
+
@api_client.config.logger.debug "API called: DefaultApi#bond_profile\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
233
|
+
end
|
234
|
+
return data, status_code, headers
|
235
|
+
end
|
236
|
+
|
93
237
|
# Basic Financials
|
94
238
|
# Get company basic financials such as margin, P/E ratio, 52-week high/low etc.
|
95
239
|
# @param symbol [String] Symbol of the company: AAPL.
|
@@ -1676,6 +1820,7 @@ module FinnhubRuby
|
|
1676
1820
|
# @option opts [String] :symbol ETF symbol.
|
1677
1821
|
# @option opts [String] :isin ETF isin.
|
1678
1822
|
# @option opts [Integer] :skip Skip the first n results. You can use this parameter to query historical constituents data. The latest result is returned if skip=0 or not set.
|
1823
|
+
# @option opts [String] :date Query holdings by date. You can use either this param or <code>skip</code> param, not both.
|
1679
1824
|
# @return [ETFsHoldings]
|
1680
1825
|
def etfs_holdings(opts = {})
|
1681
1826
|
data, _status_code, _headers = etfs_holdings_with_http_info(opts)
|
@@ -1688,6 +1833,7 @@ module FinnhubRuby
|
|
1688
1833
|
# @option opts [String] :symbol ETF symbol.
|
1689
1834
|
# @option opts [String] :isin ETF isin.
|
1690
1835
|
# @option opts [Integer] :skip Skip the first n results. You can use this parameter to query historical constituents data. The latest result is returned if skip=0 or not set.
|
1836
|
+
# @option opts [String] :date Query holdings by date. You can use either this param or <code>skip</code> param, not both.
|
1691
1837
|
# @return [Array<(ETFsHoldings, Integer, Hash)>] ETFsHoldings data, response status code and response headers
|
1692
1838
|
def etfs_holdings_with_http_info(opts = {})
|
1693
1839
|
if @api_client.config.debugging
|
@@ -1701,6 +1847,7 @@ module FinnhubRuby
|
|
1701
1847
|
query_params[:'symbol'] = opts[:'symbol'] if !opts[:'symbol'].nil?
|
1702
1848
|
query_params[:'isin'] = opts[:'isin'] if !opts[:'isin'].nil?
|
1703
1849
|
query_params[:'skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
1850
|
+
query_params[:'date'] = opts[:'date'] if !opts[:'date'].nil?
|
1704
1851
|
|
1705
1852
|
# header parameters
|
1706
1853
|
header_params = opts[:header_params] || {}
|
@@ -2352,6 +2499,7 @@ module FinnhubRuby
|
|
2352
2499
|
# Get rates for all forex pairs. Ideal for currency conversion
|
2353
2500
|
# @param [Hash] opts the optional parameters
|
2354
2501
|
# @option opts [String] :base Base currency. Default to EUR.
|
2502
|
+
# @option opts [String] :date Date. Leave blank to get the latest data.
|
2355
2503
|
# @return [Forexrates]
|
2356
2504
|
def forex_rates(opts = {})
|
2357
2505
|
data, _status_code, _headers = forex_rates_with_http_info(opts)
|
@@ -2362,6 +2510,7 @@ module FinnhubRuby
|
|
2362
2510
|
# Get rates for all forex pairs. Ideal for currency conversion
|
2363
2511
|
# @param [Hash] opts the optional parameters
|
2364
2512
|
# @option opts [String] :base Base currency. Default to EUR.
|
2513
|
+
# @option opts [String] :date Date. Leave blank to get the latest data.
|
2365
2514
|
# @return [Array<(Forexrates, Integer, Hash)>] Forexrates data, response status code and response headers
|
2366
2515
|
def forex_rates_with_http_info(opts = {})
|
2367
2516
|
if @api_client.config.debugging
|
@@ -2373,6 +2522,7 @@ module FinnhubRuby
|
|
2373
2522
|
# query parameters
|
2374
2523
|
query_params = opts[:query_params] || {}
|
2375
2524
|
query_params[:'base'] = opts[:'base'] if !opts[:'base'].nil?
|
2525
|
+
query_params[:'date'] = opts[:'date'] if !opts[:'date'].nil?
|
2376
2526
|
|
2377
2527
|
# header parameters
|
2378
2528
|
header_params = opts[:header_params] || {}
|
@@ -2604,7 +2754,7 @@ module FinnhubRuby
|
|
2604
2754
|
end
|
2605
2755
|
|
2606
2756
|
# Indices Historical Constituents
|
2607
|
-
# Get full history of index's constituents including symbols and dates of joining and leaving the Index. Currently support <code>^GSPC
|
2757
|
+
# Get full history of index's constituents including symbols and dates of joining and leaving the Index. Currently support <code>^GSPC</code>, <code>^NDX</code>, <code>^DJI</code>
|
2608
2758
|
# @param symbol [String] symbol
|
2609
2759
|
# @param [Hash] opts the optional parameters
|
2610
2760
|
# @return [IndicesHistoricalConstituents]
|
@@ -2614,7 +2764,7 @@ module FinnhubRuby
|
|
2614
2764
|
end
|
2615
2765
|
|
2616
2766
|
# Indices Historical Constituents
|
2617
|
-
# Get full history of index's constituents including symbols and dates of joining and leaving the Index. Currently support <code>^GSPC
|
2767
|
+
# Get full history of index's constituents including symbols and dates of joining and leaving the Index. Currently support <code>^GSPC</code>, <code>^NDX</code>, <code>^DJI</code>
|
2618
2768
|
# @param symbol [String] symbol
|
2619
2769
|
# @param [Hash] opts the optional parameters
|
2620
2770
|
# @return [Array<(IndicesHistoricalConstituents, Integer, Hash)>] IndicesHistoricalConstituents data, response status code and response headers
|
@@ -2667,6 +2817,84 @@ module FinnhubRuby
|
|
2667
2817
|
return data, status_code, headers
|
2668
2818
|
end
|
2669
2819
|
|
2820
|
+
# Insider Sentiment
|
2821
|
+
# Get insider sentiment data for US companies calculated using method discussed <a href=\"https://medium.com/@stock-api/finnhub-insiders-sentiment-analysis-cc43f9f64b3a\" target=\"_blank\">here</a>. The MSPR ranges from -100 for the most negative to 100 for the most positive which can signal price changes in the coming 30-90 days.
|
2822
|
+
# @param symbol [String] Symbol of the company: AAPL.
|
2823
|
+
# @param from [Date] From date: 2020-03-15.
|
2824
|
+
# @param to [Date] To date: 2020-03-16.
|
2825
|
+
# @param [Hash] opts the optional parameters
|
2826
|
+
# @return [InsiderSentiments]
|
2827
|
+
def insider_sentiment(symbol, from, to, opts = {})
|
2828
|
+
data, _status_code, _headers = insider_sentiment_with_http_info(symbol, from, to, opts)
|
2829
|
+
data
|
2830
|
+
end
|
2831
|
+
|
2832
|
+
# Insider Sentiment
|
2833
|
+
# Get insider sentiment data for US companies calculated using method discussed <a href=\"https://medium.com/@stock-api/finnhub-insiders-sentiment-analysis-cc43f9f64b3a\" target=\"_blank\">here</a>. The MSPR ranges from -100 for the most negative to 100 for the most positive which can signal price changes in the coming 30-90 days.
|
2834
|
+
# @param symbol [String] Symbol of the company: AAPL.
|
2835
|
+
# @param from [Date] From date: 2020-03-15.
|
2836
|
+
# @param to [Date] To date: 2020-03-16.
|
2837
|
+
# @param [Hash] opts the optional parameters
|
2838
|
+
# @return [Array<(InsiderSentiments, Integer, Hash)>] InsiderSentiments data, response status code and response headers
|
2839
|
+
def insider_sentiment_with_http_info(symbol, from, to, opts = {})
|
2840
|
+
if @api_client.config.debugging
|
2841
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.insider_sentiment ...'
|
2842
|
+
end
|
2843
|
+
# verify the required parameter 'symbol' is set
|
2844
|
+
if @api_client.config.client_side_validation && symbol.nil?
|
2845
|
+
fail ArgumentError, "Missing the required parameter 'symbol' when calling DefaultApi.insider_sentiment"
|
2846
|
+
end
|
2847
|
+
# verify the required parameter 'from' is set
|
2848
|
+
if @api_client.config.client_side_validation && from.nil?
|
2849
|
+
fail ArgumentError, "Missing the required parameter 'from' when calling DefaultApi.insider_sentiment"
|
2850
|
+
end
|
2851
|
+
# verify the required parameter 'to' is set
|
2852
|
+
if @api_client.config.client_side_validation && to.nil?
|
2853
|
+
fail ArgumentError, "Missing the required parameter 'to' when calling DefaultApi.insider_sentiment"
|
2854
|
+
end
|
2855
|
+
# resource path
|
2856
|
+
local_var_path = '/stock/insider-sentiment'
|
2857
|
+
|
2858
|
+
# query parameters
|
2859
|
+
query_params = opts[:query_params] || {}
|
2860
|
+
query_params[:'symbol'] = symbol
|
2861
|
+
query_params[:'from'] = from
|
2862
|
+
query_params[:'to'] = to
|
2863
|
+
|
2864
|
+
# header parameters
|
2865
|
+
header_params = opts[:header_params] || {}
|
2866
|
+
# HTTP header 'Accept' (if needed)
|
2867
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2868
|
+
|
2869
|
+
# form parameters
|
2870
|
+
form_params = opts[:form_params] || {}
|
2871
|
+
|
2872
|
+
# http body (model)
|
2873
|
+
post_body = opts[:debug_body]
|
2874
|
+
|
2875
|
+
# return_type
|
2876
|
+
return_type = opts[:debug_return_type] || 'InsiderSentiments'
|
2877
|
+
|
2878
|
+
# auth_names
|
2879
|
+
auth_names = opts[:debug_auth_names] || ['api_key']
|
2880
|
+
|
2881
|
+
new_options = opts.merge(
|
2882
|
+
:operation => :"DefaultApi.insider_sentiment",
|
2883
|
+
:header_params => header_params,
|
2884
|
+
:query_params => query_params,
|
2885
|
+
:form_params => form_params,
|
2886
|
+
:body => post_body,
|
2887
|
+
:auth_names => auth_names,
|
2888
|
+
:return_type => return_type
|
2889
|
+
)
|
2890
|
+
|
2891
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2892
|
+
if @api_client.config.debugging
|
2893
|
+
@api_client.config.logger.debug "API called: DefaultApi#insider_sentiment\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2894
|
+
end
|
2895
|
+
return data, status_code, headers
|
2896
|
+
end
|
2897
|
+
|
2670
2898
|
# Insider Transactions
|
2671
2899
|
# Company insider transactions data sourced from <code>Form 3,4,5</code>. This endpoint only covers US companies at the moment. Limit to 100 transactions per API call.
|
2672
2900
|
# @param symbol [String] Symbol of the company: AAPL. Leave this param blank to get the latest transactions.
|
@@ -4213,6 +4441,84 @@ module FinnhubRuby
|
|
4213
4441
|
return data, status_code, headers
|
4214
4442
|
end
|
4215
4443
|
|
4444
|
+
# Senate Lobbying
|
4445
|
+
# Get a list of reported lobbying activities in the Senate and the House.
|
4446
|
+
# @param symbol [String] Symbol.
|
4447
|
+
# @param from [Date] From date <code>YYYY-MM-DD</code>.
|
4448
|
+
# @param to [Date] To date <code>YYYY-MM-DD</code>.
|
4449
|
+
# @param [Hash] opts the optional parameters
|
4450
|
+
# @return [LobbyingResult]
|
4451
|
+
def stock_lobbying(symbol, from, to, opts = {})
|
4452
|
+
data, _status_code, _headers = stock_lobbying_with_http_info(symbol, from, to, opts)
|
4453
|
+
data
|
4454
|
+
end
|
4455
|
+
|
4456
|
+
# Senate Lobbying
|
4457
|
+
# Get a list of reported lobbying activities in the Senate and the House.
|
4458
|
+
# @param symbol [String] Symbol.
|
4459
|
+
# @param from [Date] From date <code>YYYY-MM-DD</code>.
|
4460
|
+
# @param to [Date] To date <code>YYYY-MM-DD</code>.
|
4461
|
+
# @param [Hash] opts the optional parameters
|
4462
|
+
# @return [Array<(LobbyingResult, Integer, Hash)>] LobbyingResult data, response status code and response headers
|
4463
|
+
def stock_lobbying_with_http_info(symbol, from, to, opts = {})
|
4464
|
+
if @api_client.config.debugging
|
4465
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.stock_lobbying ...'
|
4466
|
+
end
|
4467
|
+
# verify the required parameter 'symbol' is set
|
4468
|
+
if @api_client.config.client_side_validation && symbol.nil?
|
4469
|
+
fail ArgumentError, "Missing the required parameter 'symbol' when calling DefaultApi.stock_lobbying"
|
4470
|
+
end
|
4471
|
+
# verify the required parameter 'from' is set
|
4472
|
+
if @api_client.config.client_side_validation && from.nil?
|
4473
|
+
fail ArgumentError, "Missing the required parameter 'from' when calling DefaultApi.stock_lobbying"
|
4474
|
+
end
|
4475
|
+
# verify the required parameter 'to' is set
|
4476
|
+
if @api_client.config.client_side_validation && to.nil?
|
4477
|
+
fail ArgumentError, "Missing the required parameter 'to' when calling DefaultApi.stock_lobbying"
|
4478
|
+
end
|
4479
|
+
# resource path
|
4480
|
+
local_var_path = '/stock/lobbying'
|
4481
|
+
|
4482
|
+
# query parameters
|
4483
|
+
query_params = opts[:query_params] || {}
|
4484
|
+
query_params[:'symbol'] = symbol
|
4485
|
+
query_params[:'from'] = from
|
4486
|
+
query_params[:'to'] = to
|
4487
|
+
|
4488
|
+
# header parameters
|
4489
|
+
header_params = opts[:header_params] || {}
|
4490
|
+
# HTTP header 'Accept' (if needed)
|
4491
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
4492
|
+
|
4493
|
+
# form parameters
|
4494
|
+
form_params = opts[:form_params] || {}
|
4495
|
+
|
4496
|
+
# http body (model)
|
4497
|
+
post_body = opts[:debug_body]
|
4498
|
+
|
4499
|
+
# return_type
|
4500
|
+
return_type = opts[:debug_return_type] || 'LobbyingResult'
|
4501
|
+
|
4502
|
+
# auth_names
|
4503
|
+
auth_names = opts[:debug_auth_names] || ['api_key']
|
4504
|
+
|
4505
|
+
new_options = opts.merge(
|
4506
|
+
:operation => :"DefaultApi.stock_lobbying",
|
4507
|
+
:header_params => header_params,
|
4508
|
+
:query_params => query_params,
|
4509
|
+
:form_params => form_params,
|
4510
|
+
:body => post_body,
|
4511
|
+
:auth_names => auth_names,
|
4512
|
+
:return_type => return_type
|
4513
|
+
)
|
4514
|
+
|
4515
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
4516
|
+
if @api_client.config.debugging
|
4517
|
+
@api_client.config.logger.debug "API called: DefaultApi#stock_lobbying\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
4518
|
+
end
|
4519
|
+
return data, status_code, headers
|
4520
|
+
end
|
4521
|
+
|
4216
4522
|
# Historical NBBO
|
4217
4523
|
# <p>Get historical best bid and offer for US stocks, LSE, TSX, Euronext and Deutsche Borse.</p><p>For US market, this endpoint only serves historical NBBO from the beginning of 2020. To download more historical data, please visit our bulk download page in the Dashboard <a target=\"_blank\" href=\"/dashboard/download\",>here</a>.</p>
|
4218
4524
|
# @param symbol [String] Symbol.
|
@@ -4377,7 +4683,7 @@ module FinnhubRuby
|
|
4377
4683
|
end
|
4378
4684
|
|
4379
4685
|
# Stock Symbol
|
4380
|
-
# List supported stocks. We use the following symbology to identify stocks on Finnhub <code>Exchange_Ticker.Exchange_Code</code>. A list of supported exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4686
|
+
# List supported stocks. We use the following symbology to identify stocks on Finnhub <code>Exchange_Ticker.Exchange_Code</code>. A list of supported exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4381
4687
|
# @param exchange [String] Exchange you want to get the list of symbols from. List of exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4382
4688
|
# @param [Hash] opts the optional parameters
|
4383
4689
|
# @option opts [String] :mic Filter by MIC code.
|
@@ -4390,7 +4696,7 @@ module FinnhubRuby
|
|
4390
4696
|
end
|
4391
4697
|
|
4392
4698
|
# Stock Symbol
|
4393
|
-
# List supported stocks. We use the following symbology to identify stocks on Finnhub <code>Exchange_Ticker.Exchange_Code</code>. A list of supported exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4699
|
+
# List supported stocks. We use the following symbology to identify stocks on Finnhub <code>Exchange_Ticker.Exchange_Code</code>. A list of supported exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4394
4700
|
# @param exchange [String] Exchange you want to get the list of symbols from. List of exchange codes can be found <a href=\"https://docs.google.com/spreadsheets/d/1I3pBxjfXB056-g_JYf_6o3Rns3BV2kMGG1nCatb91ls/edit?usp=sharing\" target=\"_blank\">here</a>.
|
4395
4701
|
# @param [Hash] opts the optional parameters
|
4396
4702
|
# @option opts [String] :mic Filter by MIC code.
|
@@ -4450,7 +4756,7 @@ module FinnhubRuby
|
|
4450
4756
|
end
|
4451
4757
|
|
4452
4758
|
# Tick Data
|
4453
|
-
# <p>Get historical tick data for global exchanges. You can send the request directly to our tick server at <a href=\"https://tick.finnhub.io/\">https://tick.finnhub.io/</a> with the same path and parameters or get redirected there if you call our main server.</p><p>For US market, you can visit our bulk download page in the Dashboard <a target=\"_blank\" href=\"/dashboard/download\",>here</a> to speed up the download process.</p><table class=\"table table-hover\"> <thead> <tr> <th>Exchange</th> <th>Segment</th> <th>Delay</th> </tr> </thead> <tbody> <tr> <td class=\"text-blue\">US CTA/UTP</th> <td>Full SIP</td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">TSX</th> <td><ul><li>TSX</li><li>TSX Venture</li><li>Index</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">LSE</th> <td><ul><li>London Stock Exchange (L)</li><li>LSE International (L)</li><li>LSE European (L)</li></ul></td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">Euronext</th> <td><ul> <li>Euronext Paris (PA)</li> <li>Euronext Amsterdam (AS)</li> <li>Euronext Lisbon (LS)</li> <li>Euronext Brussels (BR)</li> <li>Euronext Oslo (OL)</li> <li>Euronext London (LN)</li> <li>Euronext Dublin (IR)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">Deutsche Börse</th> <td><ul> <li>Frankfurt (F)</li> <li>Xetra (DE)</li> <li>Duesseldorf (DU)</li> <li>Hamburg (HM)</li> <li>Berlin (BE)</li> <li>Hanover (HA)</li> <li>Stoxx (SX)</li> <li>TradeGate (TG)</li> <li>Zertifikate (SC)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr>
|
4759
|
+
# <p>Get historical tick data for global exchanges. You can send the request directly to our tick server at <a href=\"https://tick.finnhub.io/\">https://tick.finnhub.io/</a> with the same path and parameters or get redirected there if you call our main server.</p><p>For US market, you can visit our bulk download page in the Dashboard <a target=\"_blank\" href=\"/dashboard/download\",>here</a> to speed up the download process.</p><table class=\"table table-hover\"> <thead> <tr> <th>Exchange</th> <th>Segment</th> <th>Delay</th> </tr> </thead> <tbody> <tr> <td class=\"text-blue\">US CTA/UTP</th> <td>Full SIP</td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">TSX</th> <td><ul><li>TSX</li><li>TSX Venture</li><li>Index</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">LSE</th> <td><ul><li>London Stock Exchange (L)</li><li>LSE International (L)</li><li>LSE European (L)</li></ul></td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">Euronext</th> <td><ul> <li>Euronext Paris (PA)</li> <li>Euronext Amsterdam (AS)</li> <li>Euronext Lisbon (LS)</li> <li>Euronext Brussels (BR)</li> <li>Euronext Oslo (OL)</li> <li>Euronext London (LN)</li> <li>Euronext Dublin (IR)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">Deutsche Börse</th> <td><ul> <li>Frankfurt (F)</li> <li>Xetra (DE)</li> <li>Duesseldorf (DU)</li> <li>Hamburg (HM)</li> <li>Berlin (BE)</li> <li>Hanover (HA)</li> <li>Stoxx (SX)</li> <li>TradeGate (TG)</li> <li>Zertifikate (SC)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> </tbody> </table>
|
4454
4760
|
# @param symbol [String] Symbol.
|
4455
4761
|
# @param date [Date] Date: 2020-04-02.
|
4456
4762
|
# @param limit [Integer] Limit number of ticks returned. Maximum value: <code>25000</code>
|
@@ -4463,7 +4769,7 @@ module FinnhubRuby
|
|
4463
4769
|
end
|
4464
4770
|
|
4465
4771
|
# Tick Data
|
4466
|
-
# <p>Get historical tick data for global exchanges. You can send the request directly to our tick server at <a href=\"https://tick.finnhub.io/\">https://tick.finnhub.io/</a> with the same path and parameters or get redirected there if you call our main server.</p><p>For US market, you can visit our bulk download page in the Dashboard <a target=\"_blank\" href=\"/dashboard/download\",>here</a> to speed up the download process.</p><table class=\"table table-hover\"> <thead> <tr> <th>Exchange</th> <th>Segment</th> <th>Delay</th> </tr> </thead> <tbody> <tr> <td class=\"text-blue\">US CTA/UTP</th> <td>Full SIP</td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">TSX</th> <td><ul><li>TSX</li><li>TSX Venture</li><li>Index</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">LSE</th> <td><ul><li>London Stock Exchange (L)</li><li>LSE International (L)</li><li>LSE European (L)</li></ul></td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">Euronext</th> <td><ul> <li>Euronext Paris (PA)</li> <li>Euronext Amsterdam (AS)</li> <li>Euronext Lisbon (LS)</li> <li>Euronext Brussels (BR)</li> <li>Euronext Oslo (OL)</li> <li>Euronext London (LN)</li> <li>Euronext Dublin (IR)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">Deutsche Börse</th> <td><ul> <li>Frankfurt (F)</li> <li>Xetra (DE)</li> <li>Duesseldorf (DU)</li> <li>Hamburg (HM)</li> <li>Berlin (BE)</li> <li>Hanover (HA)</li> <li>Stoxx (SX)</li> <li>TradeGate (TG)</li> <li>Zertifikate (SC)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr>
|
4772
|
+
# <p>Get historical tick data for global exchanges. You can send the request directly to our tick server at <a href=\"https://tick.finnhub.io/\">https://tick.finnhub.io/</a> with the same path and parameters or get redirected there if you call our main server.</p><p>For US market, you can visit our bulk download page in the Dashboard <a target=\"_blank\" href=\"/dashboard/download\",>here</a> to speed up the download process.</p><table class=\"table table-hover\"> <thead> <tr> <th>Exchange</th> <th>Segment</th> <th>Delay</th> </tr> </thead> <tbody> <tr> <td class=\"text-blue\">US CTA/UTP</th> <td>Full SIP</td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">TSX</th> <td><ul><li>TSX</li><li>TSX Venture</li><li>Index</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">LSE</th> <td><ul><li>London Stock Exchange (L)</li><li>LSE International (L)</li><li>LSE European (L)</li></ul></td> <td>15 minute</td> </tr> <tr> <td class=\"text-blue\">Euronext</th> <td><ul> <li>Euronext Paris (PA)</li> <li>Euronext Amsterdam (AS)</li> <li>Euronext Lisbon (LS)</li> <li>Euronext Brussels (BR)</li> <li>Euronext Oslo (OL)</li> <li>Euronext London (LN)</li> <li>Euronext Dublin (IR)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> <tr> <td class=\"text-blue\">Deutsche Börse</th> <td><ul> <li>Frankfurt (F)</li> <li>Xetra (DE)</li> <li>Duesseldorf (DU)</li> <li>Hamburg (HM)</li> <li>Berlin (BE)</li> <li>Hanover (HA)</li> <li>Stoxx (SX)</li> <li>TradeGate (TG)</li> <li>Zertifikate (SC)</li> <li>Index</li> <li>Warrant</li></ul></td> <td>End-of-day</td> </tr> </tbody> </table>
|
4467
4773
|
# @param symbol [String] Symbol.
|
4468
4774
|
# @param date [Date] Date: 2020-04-02.
|
4469
4775
|
# @param limit [Integer] Limit number of ticks returned. Maximum value: <code>25000</code>
|
@@ -4612,8 +4918,86 @@ module FinnhubRuby
|
|
4612
4918
|
return data, status_code, headers
|
4613
4919
|
end
|
4614
4920
|
|
4921
|
+
# H1-B Visa Application
|
4922
|
+
# Get a list of H1-B and Permanent visa applications for companies from the DOL. The data is updated quarterly.
|
4923
|
+
# @param symbol [String] Symbol.
|
4924
|
+
# @param from [Date] From date <code>YYYY-MM-DD</code>. Filter on the <code>beginDate</code> column.
|
4925
|
+
# @param to [Date] To date <code>YYYY-MM-DD</code>. Filter on the <code>beginDate</code> column.
|
4926
|
+
# @param [Hash] opts the optional parameters
|
4927
|
+
# @return [VisaApplicationResult]
|
4928
|
+
def stock_visa_application(symbol, from, to, opts = {})
|
4929
|
+
data, _status_code, _headers = stock_visa_application_with_http_info(symbol, from, to, opts)
|
4930
|
+
data
|
4931
|
+
end
|
4932
|
+
|
4933
|
+
# H1-B Visa Application
|
4934
|
+
# Get a list of H1-B and Permanent visa applications for companies from the DOL. The data is updated quarterly.
|
4935
|
+
# @param symbol [String] Symbol.
|
4936
|
+
# @param from [Date] From date <code>YYYY-MM-DD</code>. Filter on the <code>beginDate</code> column.
|
4937
|
+
# @param to [Date] To date <code>YYYY-MM-DD</code>. Filter on the <code>beginDate</code> column.
|
4938
|
+
# @param [Hash] opts the optional parameters
|
4939
|
+
# @return [Array<(VisaApplicationResult, Integer, Hash)>] VisaApplicationResult data, response status code and response headers
|
4940
|
+
def stock_visa_application_with_http_info(symbol, from, to, opts = {})
|
4941
|
+
if @api_client.config.debugging
|
4942
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.stock_visa_application ...'
|
4943
|
+
end
|
4944
|
+
# verify the required parameter 'symbol' is set
|
4945
|
+
if @api_client.config.client_side_validation && symbol.nil?
|
4946
|
+
fail ArgumentError, "Missing the required parameter 'symbol' when calling DefaultApi.stock_visa_application"
|
4947
|
+
end
|
4948
|
+
# verify the required parameter 'from' is set
|
4949
|
+
if @api_client.config.client_side_validation && from.nil?
|
4950
|
+
fail ArgumentError, "Missing the required parameter 'from' when calling DefaultApi.stock_visa_application"
|
4951
|
+
end
|
4952
|
+
# verify the required parameter 'to' is set
|
4953
|
+
if @api_client.config.client_side_validation && to.nil?
|
4954
|
+
fail ArgumentError, "Missing the required parameter 'to' when calling DefaultApi.stock_visa_application"
|
4955
|
+
end
|
4956
|
+
# resource path
|
4957
|
+
local_var_path = '/stock/visa-application'
|
4958
|
+
|
4959
|
+
# query parameters
|
4960
|
+
query_params = opts[:query_params] || {}
|
4961
|
+
query_params[:'symbol'] = symbol
|
4962
|
+
query_params[:'from'] = from
|
4963
|
+
query_params[:'to'] = to
|
4964
|
+
|
4965
|
+
# header parameters
|
4966
|
+
header_params = opts[:header_params] || {}
|
4967
|
+
# HTTP header 'Accept' (if needed)
|
4968
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
4969
|
+
|
4970
|
+
# form parameters
|
4971
|
+
form_params = opts[:form_params] || {}
|
4972
|
+
|
4973
|
+
# http body (model)
|
4974
|
+
post_body = opts[:debug_body]
|
4975
|
+
|
4976
|
+
# return_type
|
4977
|
+
return_type = opts[:debug_return_type] || 'VisaApplicationResult'
|
4978
|
+
|
4979
|
+
# auth_names
|
4980
|
+
auth_names = opts[:debug_auth_names] || ['api_key']
|
4981
|
+
|
4982
|
+
new_options = opts.merge(
|
4983
|
+
:operation => :"DefaultApi.stock_visa_application",
|
4984
|
+
:header_params => header_params,
|
4985
|
+
:query_params => query_params,
|
4986
|
+
:form_params => form_params,
|
4987
|
+
:body => post_body,
|
4988
|
+
:auth_names => auth_names,
|
4989
|
+
:return_type => return_type
|
4990
|
+
)
|
4991
|
+
|
4992
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
4993
|
+
if @api_client.config.debugging
|
4994
|
+
@api_client.config.logger.debug "API called: DefaultApi#stock_visa_application\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
4995
|
+
end
|
4996
|
+
return data, status_code, headers
|
4997
|
+
end
|
4998
|
+
|
4615
4999
|
# Supply Chain Relationships
|
4616
|
-
# <p>This endpoint provides an overall map of public companies' key customers and suppliers. The data offers a deeper look into a company's supply chain and how products are created. The data will help investors manage risk, limit exposure or generate alpha-generating ideas and trading insights.</p
|
5000
|
+
# <p>This endpoint provides an overall map of public companies' key customers and suppliers. The data offers a deeper look into a company's supply chain and how products are created. The data will help investors manage risk, limit exposure or generate alpha-generating ideas and trading insights.</p>
|
4617
5001
|
# @param symbol [String] Symbol.
|
4618
5002
|
# @param [Hash] opts the optional parameters
|
4619
5003
|
# @return [SupplyChainRelationships]
|
@@ -4623,7 +5007,7 @@ module FinnhubRuby
|
|
4623
5007
|
end
|
4624
5008
|
|
4625
5009
|
# Supply Chain Relationships
|
4626
|
-
# <p>This endpoint provides an overall map of public companies' key customers and suppliers. The data offers a deeper look into a company's supply chain and how products are created. The data will help investors manage risk, limit exposure or generate alpha-generating ideas and trading insights.</p>
|
5010
|
+
# <p>This endpoint provides an overall map of public companies' key customers and suppliers. The data offers a deeper look into a company's supply chain and how products are created. The data will help investors manage risk, limit exposure or generate alpha-generating ideas and trading insights.</p>
|
4627
5011
|
# @param symbol [String] Symbol.
|
4628
5012
|
# @param [Hash] opts the optional parameters
|
4629
5013
|
# @return [Array<(SupplyChainRelationships, Integer, Hash)>] SupplyChainRelationships data, response status code and response headers
|
@@ -4972,7 +5356,7 @@ module FinnhubRuby
|
|
4972
5356
|
end
|
4973
5357
|
|
4974
5358
|
# Earnings Call Transcripts List
|
4975
|
-
# List earnings call transcripts' metadata. This endpoint is available for US, UK and Canadian companies.
|
5359
|
+
# List earnings call transcripts' metadata. This endpoint is available for US, UK, European, Australian and Canadian companies.
|
4976
5360
|
# @param symbol [String] Company symbol: AAPL. Leave empty to list the latest transcripts
|
4977
5361
|
# @param [Hash] opts the optional parameters
|
4978
5362
|
# @return [EarningsCallTranscriptsList]
|
@@ -4982,7 +5366,7 @@ module FinnhubRuby
|
|
4982
5366
|
end
|
4983
5367
|
|
4984
5368
|
# Earnings Call Transcripts List
|
4985
|
-
# List earnings call transcripts' metadata. This endpoint is available for US, UK and Canadian companies.
|
5369
|
+
# List earnings call transcripts' metadata. This endpoint is available for US, UK, European, Australian and Canadian companies.
|
4986
5370
|
# @param symbol [String] Company symbol: AAPL. Leave empty to list the latest transcripts
|
4987
5371
|
# @param [Hash] opts the optional parameters
|
4988
5372
|
# @return [Array<(EarningsCallTranscriptsList, Integer, Hash)>] EarningsCallTranscriptsList data, response status code and response headers
|