def extract_ids_and_names_of_tags(self, tags):
        """
        To retrieve ids and names from tags based on the given indicator type.

        Args:
            tags (list): The tags to extract ids and names from.

        Raises:
            TeamCymruScoutException: If an error occurs while extracting tag ids and names.
        """
        __method_name = inspect.currentframe().f_code.co_name
        try:
            ids = []
            names = []
            for item in tags:
                ids.append(item.get("id"))
                names.append(item.get("name", ""))
                tags_children = item.get("children", {})
                if tags_children:
                    child_ids, child_names = self.extract_ids_and_names_of_tags(tags_children)
                    ids.extend(child_ids)
                    names.extend(child_names)
            return ids, names
        except Exception as err:
            applogger.error(self.error_logs.format(self.logs_starts_with, __method_name, err))
            raise TeamCymruScoutException()

        To retrieve ids and names from tags based on the given indicator type.

        Args:
            tags (list): The tags to extract ids and names from.

        Raises:
            TeamCymruScoutException: If an error occurs while extracting tag ids and names.
        
Solutions/Team Cymru Scout/Data Connectors/TeamCymruScout/SharedCode/utils.py