Class: Intrinio::FilingApi

Inherits:
Object
  • Object
show all
Defined in:
lib/intrinio-sdk/api/filing_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ FilingApi

Returns a new instance of FilingApi.



19
20
21
# File 'lib/intrinio-sdk/api/filing_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/intrinio-sdk/api/filing_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#get_all_filings(opts = {}) ⇒ ApiResponseFilings

All Filings Returns pertinent filing reference data for a specific company filing or latest filings for all companies. Useful for tracking the latest filings submitted and updating your database accordingly with the new information.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :company (String)

    Filings for the given `company` identifier (ticker, CIK, LEI, Intrinio ID)

  • :report_type (String)

    Filter by report type. Separate values with commas to return multiple The filing <a href="docs.intrinio.com/documentation/sec_filing_report_types" target="_blank">report types</a>.

  • :start_date (Date)

    Filed on or after the given date

  • :end_date (Date)

    Filed before or after the given date

  • :industry_category (String)

    Return companies in the given industry category

  • :industry_group (String)

    Return companies in the given industry group

  • :thea_enabled (BOOLEAN)

    Return filings that have been read by our Thea NLP and are ready for our answers endpoint

  • :page_size (Integer)

    The number of results to return (default to 100)

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:



36
37
38
39
# File 'lib/intrinio-sdk/api/filing_api.rb', line 36

def get_all_filings(opts = {})
  data, _status_code, _headers = get_all_filings_with_http_info(opts)
  return data
end

#get_all_filings_with_http_info(opts = {}) ⇒ Array<(ApiResponseFilings, Fixnum, Hash)>

All Filings Returns pertinent filing reference data for a specific company filing or latest filings for all companies. Useful for tracking the latest filings submitted and updating your database accordingly with the new information.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :company (String)

    Filings for the given &#x60;company&#x60; identifier (ticker, CIK, LEI, Intrinio ID)

  • :report_type (String)

    Filter by report type. Separate values with commas to return multiple The filing &lt;a href&#x3D;&quot;docs.intrinio.com/documentation/sec_filing_report_types&quot; target&#x3D;&quot;_blank&quot;&gt;report types&lt;/a&gt;.

  • :start_date (Date)

    Filed on or after the given date

  • :end_date (Date)

    Filed before or after the given date

  • :industry_category (String)

    Return companies in the given industry category

  • :industry_group (String)

    Return companies in the given industry group

  • :thea_enabled (BOOLEAN)

    Return filings that have been read by our Thea NLP and are ready for our answers endpoint

  • :page_size (Integer)

    The number of results to return

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:

  • (Array<(ApiResponseFilings, Fixnum, Hash)>)

    ApiResponseFilings data, response status code and response headers



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
# File 'lib/intrinio-sdk/api/filing_api.rb', line 54

def get_all_filings_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_all_filings ..."
  end
  if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 10000
    fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling FilingApi.get_all_filings, must be smaller than or equal to 10000.'
  end

  # resource path
  local_var_path = "/filings"

  # query parameters
  query_params = {}
  query_params[:'company'] = opts[:'company'] if !opts[:'company'].nil?
  query_params[:'report_type'] = opts[:'report_type'] if !opts[:'report_type'].nil?
  query_params[:'start_date'] = opts[:'start_date'] if !opts[:'start_date'].nil?
  query_params[:'end_date'] = opts[:'end_date'] if !opts[:'end_date'].nil?
  query_params[:'industry_category'] = opts[:'industry_category'] if !opts[:'industry_category'].nil?
  query_params[:'industry_group'] = opts[:'industry_group'] if !opts[:'industry_group'].nil?
  query_params[:'thea_enabled'] = opts[:'thea_enabled'] if !opts[:'thea_enabled'].nil?
  query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
  query_params[:'next_page'] = opts[:'next_page'] if !opts[:'next_page'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ApiResponseFilings')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_all_filings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_all_notes(opts = {}) ⇒ ApiResponseFilingNotes

All Filing Notes Returns a list of the latest XBRL filing note sections from the SEC 10-K and 10-Q statements. The returned Intrinio XBRL filing note ID can then be utilized with the “Filing Note by ID” endpoint to retrieve the contents of the note in HTML or text format.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :company (String)

    A Company identifier (Ticker, CIK, LEI, Intrinio ID)

  • :report_type (String)

    Notes contained in filings that match the given &lt;a href&#x3D;&quot;docs.intrinio.com/documentation/sec_filing_report_types&quot; target&#x3D;&quot;_blank&quot;&gt;report type&lt;/a&gt;

  • :filing_start_date (Date)

    Limit search to filings on or after this date

  • :filing_end_date (Date)

    Limit search to filings on or before this date

  • :period_ended_start_date (Date)

    Limit search to filings with a period end date on or after this date

  • :period_ended_end_date (Date)

    Limit search to filings with a period end date on or before this date

  • :page_size (Integer)

    The number of results to return (default to 100)

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:



113
114
115
116
# File 'lib/intrinio-sdk/api/filing_api.rb', line 113

def get_all_notes(opts = {})
  data, _status_code, _headers = get_all_notes_with_http_info(opts)
  return data
end

#get_all_notes_with_http_info(opts = {}) ⇒ Array<(ApiResponseFilingNotes, Fixnum, Hash)>

All Filing Notes Returns a list of the latest XBRL filing note sections from the SEC 10-K and 10-Q statements. The returned Intrinio XBRL filing note ID can then be utilized with the “Filing Note by ID” endpoint to retrieve the contents of the note in HTML or text format.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :company (String)

    A Company identifier (Ticker, CIK, LEI, Intrinio ID)

  • :report_type (String)

    Notes contained in filings that match the given &lt;a href&#x3D;&quot;docs.intrinio.com/documentation/sec_filing_report_types&quot; target&#x3D;&quot;_blank&quot;&gt;report type&lt;/a&gt;

  • :filing_start_date (Date)

    Limit search to filings on or after this date

  • :filing_end_date (Date)

    Limit search to filings on or before this date

  • :period_ended_start_date (Date)

    Limit search to filings with a period end date on or after this date

  • :period_ended_end_date (Date)

    Limit search to filings with a period end date on or before this date

  • :page_size (Integer)

    The number of results to return

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:

  • (Array<(ApiResponseFilingNotes, Fixnum, Hash)>)

    ApiResponseFilingNotes data, response status code and response headers



130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
# File 'lib/intrinio-sdk/api/filing_api.rb', line 130

def get_all_notes_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_all_notes ..."
  end
  if @api_client.config.client_side_validation && opts[:'report_type'] && !['10-Q', '10-K'].include?(opts[:'report_type'])
    fail ArgumentError, 'invalid value for "report_type", must be one of 10-Q, 10-K'
  end
  if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 10000
    fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling FilingApi.get_all_notes, must be smaller than or equal to 10000.'
  end

  # resource path
  local_var_path = "/filings/notes"

  # query parameters
  query_params = {}
  query_params[:'company'] = opts[:'company'] if !opts[:'company'].nil?
  query_params[:'report_type'] = opts[:'report_type'] if !opts[:'report_type'].nil?
  query_params[:'filing_start_date'] = opts[:'filing_start_date'] if !opts[:'filing_start_date'].nil?
  query_params[:'filing_end_date'] = opts[:'filing_end_date'] if !opts[:'filing_end_date'].nil?
  query_params[:'period_ended_start_date'] = opts[:'period_ended_start_date'] if !opts[:'period_ended_start_date'].nil?
  query_params[:'period_ended_end_date'] = opts[:'period_ended_end_date'] if !opts[:'period_ended_end_date'].nil?
  query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
  query_params[:'next_page'] = opts[:'next_page'] if !opts[:'next_page'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ApiResponseFilingNotes')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_all_notes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_filing_answers(identifier, query, opts = {}) ⇒ ApiResponseFilingAnswers

Filing Answers

Parameters:

  • identifier

    A Filing identifier

  • query

    The query to ask the Thea API

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



185
186
187
188
# File 'lib/intrinio-sdk/api/filing_api.rb', line 185

def get_filing_answers(identifier, query, opts = {})
  data, _status_code, _headers = get_filing_answers_with_http_info(identifier, query, opts)
  return data
end

#get_filing_answers_with_http_info(identifier, query, opts = {}) ⇒ Array<(ApiResponseFilingAnswers, Fixnum, Hash)>

Filing Answers

Parameters:

  • identifier

    A Filing identifier

  • query

    The query to ask the Thea API

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(ApiResponseFilingAnswers, Fixnum, Hash)>)

    ApiResponseFilingAnswers data, response status code and response headers



196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
# File 'lib/intrinio-sdk/api/filing_api.rb', line 196

def get_filing_answers_with_http_info(identifier, query, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_filing_answers ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_filing_answers"
  end
  # verify the required parameter 'query' is set
  if @api_client.config.client_side_validation && query.nil?
    fail ArgumentError, "Missing the required parameter 'query' when calling FilingApi.get_filing_answers"
  end
  # resource path
  local_var_path = "/filings/{identifier}/answers".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}
  query_params[:'query'] = query

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ApiResponseFilingAnswers')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_filing_answers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_filing_by_id(id, opts = {}) ⇒ Filing

Lookup Filing Returns the Filing with the given ‘identifier`

Parameters:

  • id

    The Intrinio ID of the Filing

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



244
245
246
247
# File 'lib/intrinio-sdk/api/filing_api.rb', line 244

def get_filing_by_id(id, opts = {})
  data, _status_code, _headers = get_filing_by_id_with_http_info(id, opts)
  return data
end

#get_filing_by_id_with_http_info(id, opts = {}) ⇒ Array<(Filing, Fixnum, Hash)>

Lookup Filing Returns the Filing with the given &#x60;identifier&#x60;

Parameters:

  • id

    The Intrinio ID of the Filing

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Filing, Fixnum, Hash)>)

    Filing data, response status code and response headers



254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
# File 'lib/intrinio-sdk/api/filing_api.rb', line 254

def get_filing_by_id_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_filing_by_id ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling FilingApi.get_filing_by_id"
  end
  # resource path
  local_var_path = "/filings/{id}".sub('{' + 'id' + '}', id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Filing')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_filing_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_filing_fundamentals(identifier, opts = {}) ⇒ ApiResponseFilingFundamentals

All Fundamentals by Filing Returns a list of fundamentals with unique fundamental IDs associated with a particular ‘Intrinio Filing ID` (if applicable) that have been updated or created as a result of a company`s latest SEC filing. Useful to ensure your database is up to date with the latest fundamentals.

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :statement_code (String)

    Filters fundamentals by statement code

  • :type (String)

    Filters fundamentals by type

  • :fiscal_year (Integer)

    Filters fundamentals by fiscal year

  • :fiscal_period (String)

    Filters fundamentals by fiscal period

  • :start_date (Date)

    Returns fundamentals on or after the given date

  • :end_date (Date)

    Returns fundamentals on or before the given date

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:



304
305
306
307
# File 'lib/intrinio-sdk/api/filing_api.rb', line 304

def get_filing_fundamentals(identifier, opts = {})
  data, _status_code, _headers = get_filing_fundamentals_with_http_info(identifier, opts)
  return data
end

#get_filing_fundamentals_with_http_info(identifier, opts = {}) ⇒ Array<(ApiResponseFilingFundamentals, Fixnum, Hash)>

All Fundamentals by Filing Returns a list of fundamentals with unique fundamental IDs associated with a particular &#x60;Intrinio Filing ID&#x60; (if applicable) that have been updated or created as a result of a company&#x60;s latest SEC filing. Useful to ensure your database is up to date with the latest fundamentals.

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :statement_code (String)

    Filters fundamentals by statement code

  • :type (String)

    Filters fundamentals by type

  • :fiscal_year (Integer)

    Filters fundamentals by fiscal year

  • :fiscal_period (String)

    Filters fundamentals by fiscal period

  • :start_date (Date)

    Returns fundamentals on or after the given date

  • :end_date (Date)

    Returns fundamentals on or before the given date

  • :next_page (String)

    Gets the next page of data from a previous API call

Returns:



321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
# File 'lib/intrinio-sdk/api/filing_api.rb', line 321

def get_filing_fundamentals_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_filing_fundamentals ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_filing_fundamentals"
  end
  if @api_client.config.client_side_validation && opts[:'statement_code'] && !['income_statement', 'balance_sheet_statement', 'cash_flow_statement', 'calculations'].include?(opts[:'statement_code'])
    fail ArgumentError, 'invalid value for "statement_code", must be one of income_statement, balance_sheet_statement, cash_flow_statement, calculations'
  end
  if @api_client.config.client_side_validation && opts[:'type'] && !['QTR', 'YTD', 'FY', 'TTM'].include?(opts[:'type'])
    fail ArgumentError, 'invalid value for "type", must be one of QTR, YTD, FY, TTM'
  end
  if @api_client.config.client_side_validation && opts[:'fiscal_period'] && !['FY', 'Q1', 'Q2', 'Q3', 'Q4', 'Q2YTD', 'Q3YTD', 'Q1TTM', 'Q2TTM', 'Q3TTM'].include?(opts[:'fiscal_period'])
    fail ArgumentError, 'invalid value for "fiscal_period", must be one of FY, Q1, Q2, Q3, Q4, Q2YTD, Q3YTD, Q1TTM, Q2TTM, Q3TTM'
  end
  # resource path
  local_var_path = "/filings/{identifier}/fundamentals".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}
  query_params[:'statement_code'] = opts[:'statement_code'] if !opts[:'statement_code'].nil?
  query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
  query_params[:'fiscal_year'] = opts[:'fiscal_year'] if !opts[:'fiscal_year'].nil?
  query_params[:'fiscal_period'] = opts[:'fiscal_period'] if !opts[:'fiscal_period'].nil?
  query_params[:'start_date'] = opts[:'start_date'] if !opts[:'start_date'].nil?
  query_params[:'end_date'] = opts[:'end_date'] if !opts[:'end_date'].nil?
  query_params[:'next_page'] = opts[:'next_page'] if !opts[:'next_page'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ApiResponseFilingFundamentals')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_filing_fundamentals\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_filing_html(identifier, opts = {}) ⇒ String

Filing Html Returns a SEC filing in HTML Format for a specified filing ID.

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (String)


380
381
382
383
# File 'lib/intrinio-sdk/api/filing_api.rb', line 380

def get_filing_html(identifier, opts = {})
  data, _status_code, _headers = get_filing_html_with_http_info(identifier, opts)
  return data
end

#get_filing_html_with_http_info(identifier, opts = {}) ⇒ Array<(String, Fixnum, Hash)>

Filing Html Returns a SEC filing in HTML Format for a specified filing ID.

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(String, Fixnum, Hash)>)

    String data, response status code and response headers



390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
# File 'lib/intrinio-sdk/api/filing_api.rb', line 390

def get_filing_html_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_filing_html ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_filing_html"
  end
  # resource path
  local_var_path = "/filings/{identifier}/html".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['text/html'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'String')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_filing_html\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_filing_text(identifier, opts = {}) ⇒ String

Filing Text

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (String)


433
434
435
436
# File 'lib/intrinio-sdk/api/filing_api.rb', line 433

def get_filing_text(identifier, opts = {})
  data, _status_code, _headers = get_filing_text_with_http_info(identifier, opts)
  return data
end

#get_filing_text_with_http_info(identifier, opts = {}) ⇒ Array<(String, Fixnum, Hash)>

Filing Text

Parameters:

  • identifier

    A Filing identifier

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(String, Fixnum, Hash)>)

    String data, response status code and response headers



443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
# File 'lib/intrinio-sdk/api/filing_api.rb', line 443

def get_filing_text_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_filing_text ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_filing_text"
  end
  # resource path
  local_var_path = "/filings/{identifier}/text".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['text/plain; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'String')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_filing_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_note(identifier, opts = {}) ⇒ FilingNote

Filing Note by ID Returns the XBRL filing note contents in HTML or text format for a specified Intrinio XBRL filing note ID.

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :content_format (String)

    Returns content in html (as filed) or plain text (default to text)

Returns:



487
488
489
490
# File 'lib/intrinio-sdk/api/filing_api.rb', line 487

def get_note(identifier, opts = {})
  data, _status_code, _headers = get_note_with_http_info(identifier, opts)
  return data
end

#get_note_html(identifier, opts = {}) ⇒ String

Filing Note HTML

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (String)


545
546
547
548
# File 'lib/intrinio-sdk/api/filing_api.rb', line 545

def get_note_html(identifier, opts = {})
  data, _status_code, _headers = get_note_html_with_http_info(identifier, opts)
  return data
end

#get_note_html_with_http_info(identifier, opts = {}) ⇒ Array<(String, Fixnum, Hash)>

Filing Note HTML

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(String, Fixnum, Hash)>)

    String data, response status code and response headers



555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
# File 'lib/intrinio-sdk/api/filing_api.rb', line 555

def get_note_html_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_note_html ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_note_html"
  end
  # resource path
  local_var_path = "/filings/notes/{identifier}/html".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['text/plain; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'String')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_note_html\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_note_text(identifier, opts = {}) ⇒ String

Filing Note Text

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (String)


598
599
600
601
# File 'lib/intrinio-sdk/api/filing_api.rb', line 598

def get_note_text(identifier, opts = {})
  data, _status_code, _headers = get_note_text_with_http_info(identifier, opts)
  return data
end

#get_note_text_with_http_info(identifier, opts = {}) ⇒ Array<(String, Fixnum, Hash)>

Filing Note Text

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(String, Fixnum, Hash)>)

    String data, response status code and response headers



608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
# File 'lib/intrinio-sdk/api/filing_api.rb', line 608

def get_note_text_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_note_text ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_note_text"
  end
  # resource path
  local_var_path = "/filings/notes/{identifier}/text".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['text/plain; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'String')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_note_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_note_with_http_info(identifier, opts = {}) ⇒ Array<(FilingNote, Fixnum, Hash)>

Filing Note by ID Returns the XBRL filing note contents in HTML or text format for a specified Intrinio XBRL filing note ID.

Parameters:

  • identifier

    The Intrinio ID of the filing note

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :content_format (String)

    Returns content in html (as filed) or plain text

Returns:

  • (Array<(FilingNote, Fixnum, Hash)>)

    FilingNote data, response status code and response headers



498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
# File 'lib/intrinio-sdk/api/filing_api.rb', line 498

def get_note_with_http_info(identifier, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.get_note ..."
  end
  # verify the required parameter 'identifier' is set
  if @api_client.config.client_side_validation && identifier.nil?
    fail ArgumentError, "Missing the required parameter 'identifier' when calling FilingApi.get_note"
  end
  if @api_client.config.client_side_validation && opts[:'content_format'] && !['text', 'html'].include?(opts[:'content_format'])
    fail ArgumentError, 'invalid value for "content_format", must be one of text, html'
  end
  # resource path
  local_var_path = "/filings/notes/{identifier}".sub('{' + 'identifier' + '}', identifier.to_s)

  # query parameters
  query_params = {}
  query_params[:'content_format'] = opts[:'content_format'] if !opts[:'content_format'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'FilingNote')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#get_note\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#search_notes(query, opts = {}) ⇒ ApiResponseFilingNotesSearch

Search Filing Notes Search the XBRL note database and return a list of XBRL note sections containing text from the text query parameter passed through.

Parameters:

  • query

    Search for notes that contain all or parts of this text

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filing_start_date (Date)

    Limit search to filings on or after this date

  • :filing_end_date (Date)

    Limit search to filings on or before this date

  • :page_size (Integer)

    The number of results to return (default to 100)

Returns:



654
655
656
657
# File 'lib/intrinio-sdk/api/filing_api.rb', line 654

def search_notes(query, opts = {})
  data, _status_code, _headers = search_notes_with_http_info(query, opts)
  return data
end

#search_notes_with_http_info(query, opts = {}) ⇒ Array<(ApiResponseFilingNotesSearch, Fixnum, Hash)>

Search Filing Notes Search the XBRL note database and return a list of XBRL note sections containing text from the text query parameter passed through.

Parameters:

  • query

    Search for notes that contain all or parts of this text

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filing_start_date (Date)

    Limit search to filings on or after this date

  • :filing_end_date (Date)

    Limit search to filings on or before this date

  • :page_size (Integer)

    The number of results to return

Returns:



667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
# File 'lib/intrinio-sdk/api/filing_api.rb', line 667

def search_notes_with_http_info(query, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: FilingApi.search_notes ..."
  end
  # verify the required parameter 'query' is set
  if @api_client.config.client_side_validation && query.nil?
    fail ArgumentError, "Missing the required parameter 'query' when calling FilingApi.search_notes"
  end
  if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 10000
    fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling FilingApi.search_notes, must be smaller than or equal to 10000.'
  end

  # resource path
  local_var_path = "/filings/notes/search"

  # query parameters
  query_params = {}
  query_params[:'query'] = query
  query_params[:'filing_start_date'] = opts[:'filing_start_date'] if !opts[:'filing_start_date'].nil?
  query_params[:'filing_end_date'] = opts[:'filing_end_date'] if !opts[:'filing_end_date'].nil?
  query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['ApiKeyAuth']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ApiResponseFilingNotesSearch')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: FilingApi#search_notes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end