Class: SecApi::Objects::DataFile

Inherits:
DocumentFormatFile show all
Defined in:
lib/sec_api/objects/data_file.rb

Overview

Represents a data file (XBRL, XML, etc.) within an SEC filing.

DataFile objects inherit from DocumentFormatFile and represent structured data files such as XBRL instance documents, XML schemas, and other machine-readable attachments. All instances are immutable.

DataFile inherits all attributes from DocumentFormatFile:

  • sequence - File sequence number

  • description - File description (optional)

  • type - MIME type or file type

  • url - Direct URL to download the file

  • size - File size in bytes

Examples:

Accessing data files from a filing

filing = client.query.ticker("AAPL").form_type("10-K").search.first
filing.data_files.each do |file|
  puts "#{file.description}: #{file.url}"
end

Finding XBRL instance documents

xbrl_files = filing.data_files.select { |f| f.type.include?("xml") }

See Also:

Method Summary

Methods inherited from DocumentFormatFile

from_api