UNPKG

sec-edgar-api

Version:

Fetch and parse SEC earnings reports and other filings. Useful for financial analysis.

21 lines (20 loc) 767 B
import type { FactItemExtended, FiscalPeriod, ReportRaw, XMLParams } from '../../../types'; import { GetDocumentXbrlParams } from '../../SecEdgarApi'; import { XbrlParseResult } from '../XBRLParser/XBRLParser'; interface ReportWithPeriod extends ReportRaw { period: number; startDate: string; endDate: string; isCurrentPeriod: boolean; } export interface DocumentXbrlResult extends XbrlParseResult { report: ReportRaw | null; fiscalYear: number; fiscalPeriod: FiscalPeriod; facts: FactItemExtended[]; xml: string; /** Facts grouped into reports by their start and end dates */ periodReports: ReportWithPeriod[]; } export declare function parseXbrl(params: XMLParams & GetDocumentXbrlParams): DocumentXbrlResult; export {};