How to use the paconn.settings.settings.Settings function in paconn

To help you get started, we’ve selected a few paconn examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github microsoft / PowerPlatformConnectors / tools / paconn-cli / paconn / settings / settingsbuilder.py View on Github external
api_properties,
            api_definition,
            icon,
            client_id=None,
            tenant=None,
            authority_url=None,
            resource=None):
        """
        Loads settings into a settings object.
        """

        # Load from settings file if it is available
        if settings_file:
            settings = SettingsSerializer.from_json(settings_file)
        else:
            settings = Settings(
                connector_id=connector_id,
                environment=environment,
                powerapps_url=powerapps_url,
                powerapps_api_version=powerapps_version,
                api_properties=api_properties,
                api_definition=api_definition,
                icon=icon,
                client_id=client_id,
                tenant=tenant,
                authority_url=authority_url,
                resource=resource
            )
        return settings
github microsoft / PowerPlatformConnectors / tools / paconn-cli / paconn / settings / settingsserializer.py View on Github external
def deserialize(settings_dict):
        """
        Deserializes a dictionary to a settings object
        """
        settings = Settings(
            # Connector sepecific settings
            connector_id=settings_dict.get(_CONNECTOR_ID, None),
            environment=settings_dict.get(_ENVIRONMENT, None),

            # Files
            api_properties=settings_dict.get(_API_PROPERTIES, None),
            api_definition=settings_dict.get(_API_DEFINITION, None),
            icon=settings_dict.get(_ICON, None),

            # PowerApps RP settings
            powerapps_url=settings_dict.get(_POWERAPPS_URL, None),
            powerapps_api_version=settings_dict.get(_POWERAPPS_API_VERSION, None),
            # powerapps_base_path IGNORED

            # Flow RP Settings
            flow_url=settings_dict.get(_FLOW_URL, None),
github microsoft / PowerPlatformConnectors / tools / paconn-cli / paconn / settings / settingsbuilder.py View on Github external
def get_authentication_settings(
            settings_file,
            client_id,
            tenant,
            authority_url,
            resource):
        """
        Loads settings into a settings object.
        """

        # Load from settings file if it is available
        if settings_file:
            settings = SettingsSerializer.from_json(settings_file)
        else:
            settings = Settings(
                connector_id=None,
                environment=None,
                powerapps_url=None,
                powerapps_api_version=None,
                api_properties=None,
                api_definition=None,
                icon=None,
                client_id=client_id,
                tenant=tenant,
                authority_url=authority_url,
                resource=resource
            )
        return settings