def validate_params(self):
        """To validate parameters of function app."""
        __method_name = inspect.currentframe().f_code.co_name
        required_params = {
            "BaseURL": consts.COFENSE_BASE_URL,
            "AzureClientId": consts.AZURE_CLIENT_ID,
            "AzureClientSecret": "" if consts.AZURE_CLIENT_SECRET is None or consts.AZURE_CLIENT_SECRET == "" else self.f.encrypt(bytes(consts.AZURE_CLIENT_SECRET, 'utf-8')),
            "AzureTenantId": consts.AZURE_TENANT_ID,
            "AzureResourceGroup": consts.AZURE_RESOURCE_GROUP,
            "AzureWorkspaceName": consts.AZURE_WORKSPACE_NAME,
            "AzureSubscriptionId": consts.AZURE_SUBSCRIPTION_ID,
            "ConnectionString": consts.CONNECTION_STRING,
            "Schedule": consts.SCHEDULE,
            "Cofense_username": consts.COFENSE_USERNAME,
            "Cofense_password": "" if consts.COFENSE_PASSWORD is None or consts.COFENSE_PASSWORD == "" else self.f.encrypt(bytes(consts.COFENSE_PASSWORD, 'utf-8')),
            "LogLevel": consts.LOG_LEVEL,
            "WorkspaceID": consts.WORKSPACE_ID,
            "WorkspaceKey": consts.WORKSPACE_KEY,
            "Malware_Table_Name": consts.MALWARE_DATA_TABLE_NAME,
            "Function_App_Name": consts.FUNCTION_APP_NAME,
        }
        applogger.debug(
            "{}(method={}) : Checking if all the environment variables exist or not.".format(
                consts.LOGS_STARTS_WITH, __method_name
            )
        )
        missing_required_field = False
        for label, params in required_params.items():
            if not params or params == "":
                missing_required_field = True
                applogger.error(
                    '{}(method={}) : {} : "{}" field is not set in the environment please set '
                    "the environment variable and run the app.".format(
                        consts.LOGS_STARTS_WITH,
                        __method_name,
                        self.azure_function_name,
                        label,
                    )
                )
        if missing_required_field:
            raise CofenseIntelligenceException(
                "Error Occurred while validating params. Required fields missing."
            )
        if not consts.COFENSE_BASE_URL.startswith("https://"):
            applogger.error(
                '{}(method={}) : {} : "BaseURL" must start with "https://" schema followed '
                'by hostname. BaseURL="{}"'.format(
                    consts.LOGS_STARTS_WITH,
                    __method_name,
                    self.azure_function_name,
                    consts.COFENSE_BASE_URL,
                )
            )
            raise CofenseIntelligenceException(
                "Error Occurred while validating params. Invalid format for BaseURL."
            )
To validate parameters of function app.
Solutions/CofenseIntelligence/Data Connectors/CofenseIntelligenceDataConnector/SharedCode/utils.py