def get_breaches_data_into_sentinel(self) -> None:
        """Fetch breaches data for all companies or specified companies and post it to Sentinel."""
        if not self.check_env_var:
            raise BitSightException(
                "{} {} Some Environment variables are not set hence exiting the app.".format(
                    self.logs_starts_with, consts.BREACHES_FUNC_NAME
                )
            )

        applogger.info(
            "{} {} Fetching companies from companies table.".format(
                self.logs_starts_with, consts.BREACHES_FUNC_NAME
            )
        )
        logs_data, flag = get_logs_data()
        if not flag:
            applogger.info(
                "{} {} Companies are not available yet.".format(
                    self.logs_starts_with, consts.BREACHES_FUNC_NAME
                )
            )
            return

        applogger.info(
            "{} {} Fetched companies from companies table.".format(
                self.logs_starts_with, consts.BREACHES_FUNC_NAME
            )
        )
        logs_data = sorted(logs_data, key=lambda x: x["name_s"])
        company_names = [data["name_s"] for data in logs_data]

        if consts.COMPANIES.strip().lower() == "all":
            self.get_all_companies_breaches_details(company_names, logs_data)
        else:
            self.get_specific_company_breaches_details(company_names, logs_data)
Fetch breaches data for all companies or specified companies and post it to Sentinel.
Solutions/BitSight/Data Connectors/BitSightDataConnector/BreachesDetails/bitsight_breaches.py