Exemple #1
0
    def search_company_filings_by_cik(self, cik, filing_type, filing_subtype, no_of_entries, filing_date_before,
                                      filing_pattern, filing_rsrc_cache):
        # TODO: build dynamic from file
        filing_types = ["425", "8-K", "10-K", "10-Q"]
        filing_subtypes = ["EX-1", "EX-2", "EX-3", "EX-4", "EX-5", "EX-6", "EX-7", "EX-8", "EX-9", "EX-10", "EX-11",
                           "EX-12", "EX-13", "EX-14", "EX-15", "EX-16", "EX-17", "EX-18", "EX-19", "EX-20", "EX-21",
                           "EX-22", "EX-23", "EX-24", "EX-25", "EX-25", "AEX-26", "EX-28", "EX-29", "EX-31", "EX-32",
                           "EX-33", "EX-34", "EX-35", "EX-99"]

        if filing_type in filing_types:
            if filing_subtype in filing_subtypes or \
                    re.match(r'EX-\d\d\.*', filing_subtype, re.IGNORECASE) or \
                    filing_subtype in filing_types :

                edgar = Edgar()
                self.alogger.debug("Getting company registration from endpoint")
                company_name = edgar.get_company_name_by_cik(cik=cik)
                self.search_company(company_name, cik,
                                    filing_type, filing_subtype,
                                    no_of_entries, filing_date_before, filing_pattern, filing_rsrc_cache)
            else:
                print("{} not a recognized filing subtype.".format(filing_subtype))
                print("Supported filing subtypes:")
                for filing_subtype in filing_subtypes:
                    print(filing_subtype)
        else:
            print("{} not a recognized filing type.".format(filing_type))
            print("Supported filing types:")
            for filing_type in filing_types:
                print(filing_type)
Exemple #2
0
from edgar import Edgar
edgar = Edgar()
possible_companies = edgar.find_company_name("microsoft corp")
print(possible_companies)
# edgar.download_index("/home/sroot/kaizha/temp/", 2020, skip_all_present_except_last=Tr
print(edgar.get_company_name_by_cik("0000789019"))