Esempio n. 1
0
    def get_login_page_with_http_info(self, **kwargs):  # noqa: E501
        """get_login_page  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.get_login_page_with_http_info(async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
        ]
        all_params.extend(
            [
                'async_req',
                '_return_http_data_only',
                '_preload_content',
                '_request_timeout'
            ]
        )

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method get_login_page" % key
                )
            local_var_params[key] = val
        del local_var_params['kwargs']

        collection_formats = {}

        path_params = {}

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

        body_params = None
        # HTTP header `Accept`
        header_params['Accept'] = self.api_client.select_header_accept(
            ['text/html'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/libs/granite/core/content/login.html', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='str',  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get('_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 2
0
    def ssl_setup_with_http_info(self, keystore_password, keystore_password_confirm, truststore_password, truststore_password_confirm, https_hostname, https_port, **kwargs):  # noqa: E501
        """ssl_setup  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.ssl_setup_with_http_info(keystore_password, keystore_password_confirm, truststore_password, truststore_password_confirm, https_hostname, https_port, async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param str keystore_password: (required)
        :param str keystore_password_confirm: (required)
        :param str truststore_password: (required)
        :param str truststore_password_confirm: (required)
        :param str https_hostname: (required)
        :param str https_port: (required)
        :param file privatekey_file:
        :param file certificate_file:
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
            'keystore_password',
            'keystore_password_confirm',
            'truststore_password',
            'truststore_password_confirm',
            'https_hostname',
            'https_port',
            'privatekey_file',
            'certificate_file'
        ]
        all_params.extend(
            [
                'async_req',
                '_return_http_data_only',
                '_preload_content',
                '_request_timeout'
            ]
        )

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method ssl_setup" % key
                )
            local_var_params[key] = val
        del local_var_params['kwargs']
        # verify the required parameter 'keystore_password' is set
        if self.api_client.client_side_validation and ('keystore_password' not in local_var_params or  # noqa: E501
                                                        local_var_params['keystore_password'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `keystore_password` when calling `ssl_setup`")  # noqa: E501
        # verify the required parameter 'keystore_password_confirm' is set
        if self.api_client.client_side_validation and ('keystore_password_confirm' not in local_var_params or  # noqa: E501
                                                        local_var_params['keystore_password_confirm'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `keystore_password_confirm` when calling `ssl_setup`")  # noqa: E501
        # verify the required parameter 'truststore_password' is set
        if self.api_client.client_side_validation and ('truststore_password' not in local_var_params or  # noqa: E501
                                                        local_var_params['truststore_password'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `truststore_password` when calling `ssl_setup`")  # noqa: E501
        # verify the required parameter 'truststore_password_confirm' is set
        if self.api_client.client_side_validation and ('truststore_password_confirm' not in local_var_params or  # noqa: E501
                                                        local_var_params['truststore_password_confirm'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `truststore_password_confirm` when calling `ssl_setup`")  # noqa: E501
        # verify the required parameter 'https_hostname' is set
        if self.api_client.client_side_validation and ('https_hostname' not in local_var_params or  # noqa: E501
                                                        local_var_params['https_hostname'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `https_hostname` when calling `ssl_setup`")  # noqa: E501
        # verify the required parameter 'https_port' is set
        if self.api_client.client_side_validation and ('https_port' not in local_var_params or  # noqa: E501
                                                        local_var_params['https_port'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `https_port` when calling `ssl_setup`")  # noqa: E501

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'keystore_password' in local_var_params and local_var_params['keystore_password'] is not None:  # noqa: E501
            query_params.append(('keystorePassword', local_var_params['keystore_password']))  # noqa: E501
        if 'keystore_password_confirm' in local_var_params and local_var_params['keystore_password_confirm'] is not None:  # noqa: E501
            query_params.append(('keystorePasswordConfirm', local_var_params['keystore_password_confirm']))  # noqa: E501
        if 'truststore_password' in local_var_params and local_var_params['truststore_password'] is not None:  # noqa: E501
            query_params.append(('truststorePassword', local_var_params['truststore_password']))  # noqa: E501
        if 'truststore_password_confirm' in local_var_params and local_var_params['truststore_password_confirm'] is not None:  # noqa: E501
            query_params.append(('truststorePasswordConfirm', local_var_params['truststore_password_confirm']))  # noqa: E501
        if 'https_hostname' in local_var_params and local_var_params['https_hostname'] is not None:  # noqa: E501
            query_params.append(('httpsHostname', local_var_params['https_hostname']))  # noqa: E501
        if 'https_port' in local_var_params and local_var_params['https_port'] is not None:  # noqa: E501
            query_params.append(('httpsPort', local_var_params['https_port']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}
        if 'privatekey_file' in local_var_params:
            local_var_files['privatekeyFile'] = local_var_params['privatekey_file']  # noqa: E501
        if 'certificate_file' in local_var_params:
            local_var_files['certificateFile'] = local_var_params['certificate_file']  # noqa: E501

        body_params = None
        # HTTP header `Accept`
        header_params['Accept'] = self.api_client.select_header_accept(
            ['text/plain'])  # noqa: E501

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['multipart/form-data'])  # noqa: E501

        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/libs/granite/security/post/sslSetup.html', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='str',  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get('_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 3
0
    def post_cq_actions_with_http_info(self, authorizable_id, changelog, **kwargs):  # noqa: E501
        """post_cq_actions  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.post_cq_actions_with_http_info(authorizable_id, changelog, async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param str authorizable_id: (required)
        :param str changelog: (required)
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
            'authorizable_id',
            'changelog'
        ]
        all_params.extend(
            [
                'async_req',
                '_return_http_data_only',
                '_preload_content',
                '_request_timeout'
            ]
        )

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method post_cq_actions" % key
                )
            local_var_params[key] = val
        del local_var_params['kwargs']
        # verify the required parameter 'authorizable_id' is set
        if self.api_client.client_side_validation and ('authorizable_id' not in local_var_params or  # noqa: E501
                                                        local_var_params['authorizable_id'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `authorizable_id` when calling `post_cq_actions`")  # noqa: E501
        # verify the required parameter 'changelog' is set
        if self.api_client.client_side_validation and ('changelog' not in local_var_params or  # noqa: E501
                                                        local_var_params['changelog'] is None):  # noqa: E501
            raise ApiValueError("Missing the required parameter `changelog` when calling `post_cq_actions`")  # noqa: E501

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'authorizable_id' in local_var_params and local_var_params['authorizable_id'] is not None:  # noqa: E501
            query_params.append(('authorizableId', local_var_params['authorizable_id']))  # noqa: E501
        if 'changelog' in local_var_params and local_var_params['changelog'] is not None:  # noqa: E501
            query_params.append(('changelog', local_var_params['changelog']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

        body_params = None
        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/.cqactions.html', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type=None,  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get('_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 4
0
    def post_config_aem_password_reset_with_http_info(self, **kwargs):  # noqa: E501
        """post_config_aem_password_reset  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.post_config_aem_password_reset_with_http_info(async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param list[str] pwdreset_authorizables:
        :param str pwdreset_authorizables_type_hint:
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
            'pwdreset_authorizables',
            'pwdreset_authorizables_type_hint'
        ]
        all_params.extend(
            [
                'async_req',
                '_return_http_data_only',
                '_preload_content',
                '_request_timeout'
            ]
        )

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method post_config_aem_password_reset" % key
                )
            local_var_params[key] = val
        del local_var_params['kwargs']

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'pwdreset_authorizables' in local_var_params and local_var_params['pwdreset_authorizables'] is not None:  # noqa: E501
            query_params.append(('pwdreset.authorizables', local_var_params['pwdreset_authorizables']))  # noqa: E501
            collection_formats['pwdreset.authorizables'] = 'multi'  # noqa: E501
        if 'pwdreset_authorizables_type_hint' in local_var_params and local_var_params['pwdreset_authorizables_type_hint'] is not None:  # noqa: E501
            query_params.append(('pwdreset.authorizables@TypeHint', local_var_params['pwdreset_authorizables_type_hint']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

        body_params = None
        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/apps/system/config/com.shinesolutions.aem.passwordreset.Activator', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type=None,  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get('_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 5
0
    def post_set_password_with_http_info(self, old, plain, verify,
                                         **kwargs):  # noqa: E501
        """post_set_password  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.post_set_password_with_http_info(old, plain, verify, async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param str old: (required)
        :param str plain: (required)
        :param str verify: (required)
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = ['old', 'plain', 'verify']
        all_params.extend([
            'async_req', '_return_http_data_only', '_preload_content',
            '_request_timeout'
        ])

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError("Got an unexpected keyword argument '%s'"
                                   " to method post_set_password" % key)
            local_var_params[key] = val
        del local_var_params['kwargs']
        # verify the required parameter 'old' is set
        if self.api_client.client_side_validation and (
                'old' not in local_var_params or  # noqa: E501
                local_var_params['old'] is None):  # noqa: E501
            raise ApiValueError(
                "Missing the required parameter `old` when calling `post_set_password`"
            )  # noqa: E501
        # verify the required parameter 'plain' is set
        if self.api_client.client_side_validation and (
                'plain' not in local_var_params or  # noqa: E501
                local_var_params['plain'] is None):  # noqa: E501
            raise ApiValueError(
                "Missing the required parameter `plain` when calling `post_set_password`"
            )  # noqa: E501
        # verify the required parameter 'verify' is set
        if self.api_client.client_side_validation and (
                'verify' not in local_var_params or  # noqa: E501
                local_var_params['verify'] is None):  # noqa: E501
            raise ApiValueError(
                "Missing the required parameter `verify` when calling `post_set_password`"
            )  # noqa: E501

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'old' in local_var_params and local_var_params[
                'old'] is not None:  # noqa: E501
            query_params.append(('old', local_var_params['old']))  # noqa: E501
        if 'plain' in local_var_params and local_var_params[
                'plain'] is not None:  # noqa: E501
            query_params.append(
                ('plain', local_var_params['plain']))  # noqa: E501
        if 'verify' in local_var_params and local_var_params[
                'verify'] is not None:  # noqa: E501
            query_params.append(
                ('verify', local_var_params['verify']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

        body_params = None
        # HTTP header `Accept`
        header_params['Accept'] = self.api_client.select_header_accept(
            ['text/plain'])  # noqa: E501

        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/crx/explorer/ui/setpassword.jsp',
            'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='str',  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get(
                '_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 6
0
    def post_package_service_json_with_http_info(self, path, cmd,
                                                 **kwargs):  # noqa: E501
        """post_package_service_json  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.post_package_service_json_with_http_info(path, cmd, async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param str path: (required)
        :param str cmd: (required)
        :param str group_name:
        :param str package_name:
        :param str package_version:
        :param str charset_:
        :param bool force:
        :param bool recursive:
        :param file package:
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
            'path', 'cmd', 'group_name', 'package_name', 'package_version',
            'charset_', 'force', 'recursive', 'package'
        ]
        all_params.extend([
            'async_req', '_return_http_data_only', '_preload_content',
            '_request_timeout'
        ])

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError("Got an unexpected keyword argument '%s'"
                                   " to method post_package_service_json" %
                                   key)
            local_var_params[key] = val
        del local_var_params['kwargs']
        # verify the required parameter 'path' is set
        if self.api_client.client_side_validation and (
                'path' not in local_var_params or  # noqa: E501
                local_var_params['path'] is None):  # noqa: E501
            raise ApiValueError(
                "Missing the required parameter `path` when calling `post_package_service_json`"
            )  # noqa: E501
        # verify the required parameter 'cmd' is set
        if self.api_client.client_side_validation and (
                'cmd' not in local_var_params or  # noqa: E501
                local_var_params['cmd'] is None):  # noqa: E501
            raise ApiValueError(
                "Missing the required parameter `cmd` when calling `post_package_service_json`"
            )  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'path' in local_var_params:
            path_params['path'] = local_var_params['path']  # noqa: E501

        query_params = []
        if 'cmd' in local_var_params and local_var_params[
                'cmd'] is not None:  # noqa: E501
            query_params.append(('cmd', local_var_params['cmd']))  # noqa: E501
        if 'group_name' in local_var_params and local_var_params[
                'group_name'] is not None:  # noqa: E501
            query_params.append(
                ('groupName', local_var_params['group_name']))  # noqa: E501
        if 'package_name' in local_var_params and local_var_params[
                'package_name'] is not None:  # noqa: E501
            query_params.append(
                ('packageName',
                 local_var_params['package_name']))  # noqa: E501
        if 'package_version' in local_var_params and local_var_params[
                'package_version'] is not None:  # noqa: E501
            query_params.append(
                ('packageVersion',
                 local_var_params['package_version']))  # noqa: E501
        if 'charset_' in local_var_params and local_var_params[
                'charset_'] is not None:  # noqa: E501
            query_params.append(
                ('_charset_', local_var_params['charset_']))  # noqa: E501
        if 'force' in local_var_params and local_var_params[
                'force'] is not None:  # noqa: E501
            query_params.append(
                ('force', local_var_params['force']))  # noqa: E501
        if 'recursive' in local_var_params and local_var_params[
                'recursive'] is not None:  # noqa: E501
            query_params.append(
                ('recursive', local_var_params['recursive']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}
        if 'package' in local_var_params:
            local_var_files['package'] = local_var_params[
                'package']  # noqa: E501

        body_params = None
        # HTTP header `Accept`
        header_params['Accept'] = self.api_client.select_header_accept(
            ['application/json'])  # noqa: E501

        # HTTP header `Content-Type`
        header_params[
            'Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
                ['multipart/form-data'])  # noqa: E501

        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/crx/packmgr/service/.json/{path}',
            'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='str',  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get(
                '_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 7
0
    def post_saml_configuration_with_http_info(self, **kwargs):  # noqa: E501
        """post_saml_configuration  # noqa: E501

        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.post_saml_configuration_with_http_info(async_req=True)
        >>> result = thread.get()

        :param async_req bool: execute request asynchronously
        :param bool post:
        :param bool apply:
        :param bool delete:
        :param str action:
        :param str location:
        :param list[str] path:
        :param int service_ranking:
        :param str idp_url:
        :param str idp_cert_alias:
        :param bool idp_http_redirect:
        :param str service_provider_entity_id:
        :param str assertion_consumer_service_url:
        :param str sp_private_key_alias:
        :param str key_store_password:
        :param str default_redirect_url:
        :param str user_id_attribute:
        :param bool use_encryption:
        :param bool create_user:
        :param bool add_group_memberships:
        :param str group_membership_attribute:
        :param list[str] default_groups:
        :param str name_id_format:
        :param list[str] synchronize_attributes:
        :param bool handle_logout:
        :param str logout_url:
        :param int clock_tolerance:
        :param str digest_method:
        :param str signature_method:
        :param str user_intermediate_path:
        :param list[str] propertylist:
        :param _return_http_data_only: response data without head status code
                                       and headers
        :param _preload_content: if False, the urllib3.HTTPResponse object will
                                 be returned without reading/decoding response
                                 data. Default is True.
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :return: tuple(SamlConfigurationInfo, status_code(int), headers(HTTPHeaderDict))
                 If the method is called asynchronously,
                 returns the request thread.
        """

        local_var_params = locals()

        all_params = [
            'post',
            'apply',
            'delete',
            'action',
            'location',
            'path',
            'service_ranking',
            'idp_url',
            'idp_cert_alias',
            'idp_http_redirect',
            'service_provider_entity_id',
            'assertion_consumer_service_url',
            'sp_private_key_alias',
            'key_store_password',
            'default_redirect_url',
            'user_id_attribute',
            'use_encryption',
            'create_user',
            'add_group_memberships',
            'group_membership_attribute',
            'default_groups',
            'name_id_format',
            'synchronize_attributes',
            'handle_logout',
            'logout_url',
            'clock_tolerance',
            'digest_method',
            'signature_method',
            'user_intermediate_path',
            'propertylist'
        ]
        all_params.extend(
            [
                'async_req',
                '_return_http_data_only',
                '_preload_content',
                '_request_timeout'
            ]
        )

        for key, val in six.iteritems(local_var_params['kwargs']):
            if key not in all_params:
                raise ApiTypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method post_saml_configuration" % key
                )
            local_var_params[key] = val
        del local_var_params['kwargs']

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'post' in local_var_params and local_var_params['post'] is not None:  # noqa: E501
            query_params.append(('post', local_var_params['post']))  # noqa: E501
        if 'apply' in local_var_params and local_var_params['apply'] is not None:  # noqa: E501
            query_params.append(('apply', local_var_params['apply']))  # noqa: E501
        if 'delete' in local_var_params and local_var_params['delete'] is not None:  # noqa: E501
            query_params.append(('delete', local_var_params['delete']))  # noqa: E501
        if 'action' in local_var_params and local_var_params['action'] is not None:  # noqa: E501
            query_params.append(('action', local_var_params['action']))  # noqa: E501
        if 'location' in local_var_params and local_var_params['location'] is not None:  # noqa: E501
            query_params.append(('$location', local_var_params['location']))  # noqa: E501
        if 'path' in local_var_params and local_var_params['path'] is not None:  # noqa: E501
            query_params.append(('path', local_var_params['path']))  # noqa: E501
            collection_formats['path'] = 'multi'  # noqa: E501
        if 'service_ranking' in local_var_params and local_var_params['service_ranking'] is not None:  # noqa: E501
            query_params.append(('service.ranking', local_var_params['service_ranking']))  # noqa: E501
        if 'idp_url' in local_var_params and local_var_params['idp_url'] is not None:  # noqa: E501
            query_params.append(('idpUrl', local_var_params['idp_url']))  # noqa: E501
        if 'idp_cert_alias' in local_var_params and local_var_params['idp_cert_alias'] is not None:  # noqa: E501
            query_params.append(('idpCertAlias', local_var_params['idp_cert_alias']))  # noqa: E501
        if 'idp_http_redirect' in local_var_params and local_var_params['idp_http_redirect'] is not None:  # noqa: E501
            query_params.append(('idpHttpRedirect', local_var_params['idp_http_redirect']))  # noqa: E501
        if 'service_provider_entity_id' in local_var_params and local_var_params['service_provider_entity_id'] is not None:  # noqa: E501
            query_params.append(('serviceProviderEntityId', local_var_params['service_provider_entity_id']))  # noqa: E501
        if 'assertion_consumer_service_url' in local_var_params and local_var_params['assertion_consumer_service_url'] is not None:  # noqa: E501
            query_params.append(('assertionConsumerServiceURL', local_var_params['assertion_consumer_service_url']))  # noqa: E501
        if 'sp_private_key_alias' in local_var_params and local_var_params['sp_private_key_alias'] is not None:  # noqa: E501
            query_params.append(('spPrivateKeyAlias', local_var_params['sp_private_key_alias']))  # noqa: E501
        if 'key_store_password' in local_var_params and local_var_params['key_store_password'] is not None:  # noqa: E501
            query_params.append(('keyStorePassword', local_var_params['key_store_password']))  # noqa: E501
        if 'default_redirect_url' in local_var_params and local_var_params['default_redirect_url'] is not None:  # noqa: E501
            query_params.append(('defaultRedirectUrl', local_var_params['default_redirect_url']))  # noqa: E501
        if 'user_id_attribute' in local_var_params and local_var_params['user_id_attribute'] is not None:  # noqa: E501
            query_params.append(('userIDAttribute', local_var_params['user_id_attribute']))  # noqa: E501
        if 'use_encryption' in local_var_params and local_var_params['use_encryption'] is not None:  # noqa: E501
            query_params.append(('useEncryption', local_var_params['use_encryption']))  # noqa: E501
        if 'create_user' in local_var_params and local_var_params['create_user'] is not None:  # noqa: E501
            query_params.append(('createUser', local_var_params['create_user']))  # noqa: E501
        if 'add_group_memberships' in local_var_params and local_var_params['add_group_memberships'] is not None:  # noqa: E501
            query_params.append(('addGroupMemberships', local_var_params['add_group_memberships']))  # noqa: E501
        if 'group_membership_attribute' in local_var_params and local_var_params['group_membership_attribute'] is not None:  # noqa: E501
            query_params.append(('groupMembershipAttribute', local_var_params['group_membership_attribute']))  # noqa: E501
        if 'default_groups' in local_var_params and local_var_params['default_groups'] is not None:  # noqa: E501
            query_params.append(('defaultGroups', local_var_params['default_groups']))  # noqa: E501
            collection_formats['defaultGroups'] = 'multi'  # noqa: E501
        if 'name_id_format' in local_var_params and local_var_params['name_id_format'] is not None:  # noqa: E501
            query_params.append(('nameIdFormat', local_var_params['name_id_format']))  # noqa: E501
        if 'synchronize_attributes' in local_var_params and local_var_params['synchronize_attributes'] is not None:  # noqa: E501
            query_params.append(('synchronizeAttributes', local_var_params['synchronize_attributes']))  # noqa: E501
            collection_formats['synchronizeAttributes'] = 'multi'  # noqa: E501
        if 'handle_logout' in local_var_params and local_var_params['handle_logout'] is not None:  # noqa: E501
            query_params.append(('handleLogout', local_var_params['handle_logout']))  # noqa: E501
        if 'logout_url' in local_var_params and local_var_params['logout_url'] is not None:  # noqa: E501
            query_params.append(('logoutUrl', local_var_params['logout_url']))  # noqa: E501
        if 'clock_tolerance' in local_var_params and local_var_params['clock_tolerance'] is not None:  # noqa: E501
            query_params.append(('clockTolerance', local_var_params['clock_tolerance']))  # noqa: E501
        if 'digest_method' in local_var_params and local_var_params['digest_method'] is not None:  # noqa: E501
            query_params.append(('digestMethod', local_var_params['digest_method']))  # noqa: E501
        if 'signature_method' in local_var_params and local_var_params['signature_method'] is not None:  # noqa: E501
            query_params.append(('signatureMethod', local_var_params['signature_method']))  # noqa: E501
        if 'user_intermediate_path' in local_var_params and local_var_params['user_intermediate_path'] is not None:  # noqa: E501
            query_params.append(('userIntermediatePath', local_var_params['user_intermediate_path']))  # noqa: E501
        if 'propertylist' in local_var_params and local_var_params['propertylist'] is not None:  # noqa: E501
            query_params.append(('propertylist', local_var_params['propertylist']))  # noqa: E501
            collection_formats['propertylist'] = 'csv'  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

        body_params = None
        # HTTP header `Accept`
        header_params['Accept'] = self.api_client.select_header_accept(
            ['text/plain'])  # noqa: E501

        # Authentication setting
        auth_settings = ['aemAuth']  # noqa: E501

        return self.api_client.call_api(
            '/system/console/configMgr/com.adobe.granite.auth.saml.SamlAuthenticationHandler', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='SamlConfigurationInfo',  # noqa: E501
            auth_settings=auth_settings,
            async_req=local_var_params.get('async_req'),
            _return_http_data_only=local_var_params.get('_return_http_data_only'),  # noqa: E501
            _preload_content=local_var_params.get('_preload_content', True),
            _request_timeout=local_var_params.get('_request_timeout'),
            collection_formats=collection_formats)
Esempio n. 8
0
    def call_with_http_info(self, **kwargs):

        try:
            index = self.api_client.configuration.server_operation_index.get(
                self.settings['operation_id'],
                self.api_client.configuration.server_index
            ) if kwargs['_host_index'] is None else kwargs['_host_index']
            server_variables = self.api_client.configuration.server_operation_variables.get(
                self.settings['operation_id'],
                self.api_client.configuration.server_variables)
            _host = self.api_client.configuration.get_host_from_settings(
                index,
                variables=server_variables,
                servers=self.settings['servers'])
        except IndexError:
            if self.settings['servers']:
                raise ApiValueError(
                    "Invalid host index. Must be 0 <= index < %s" %
                    len(self.settings['servers']))
            _host = None

        for key, value in kwargs.items():
            if key not in self.params_map['all']:
                raise ApiTypeError("Got an unexpected parameter '%s'"
                                   " to method `%s`" %
                                   (key, self.settings['operation_id']))
            # only throw this nullable ApiValueError if _check_input_type
            # is False, if _check_input_type==True we catch this case
            # in self.__validate_inputs
            if (key not in self.params_map['nullable'] and value is None
                    and kwargs['_check_input_type'] is False):
                raise ApiValueError(
                    "Value may not be None for non-nullable parameter `%s`"
                    " when calling `%s`" %
                    (key, self.settings['operation_id']))

        for key in self.params_map['required']:
            if key not in kwargs.keys():
                raise ApiValueError(
                    "Missing the required parameter `%s` when calling "
                    "`%s`" % (key, self.settings['operation_id']))

        self.__validate_inputs(kwargs)

        params = self.__gather_params(kwargs)

        accept_headers_list = self.headers_map['accept']
        if accept_headers_list:
            params['header']['Accept'] = self.api_client.select_header_accept(
                accept_headers_list)

        content_type_headers_list = self.headers_map['content_type']
        if content_type_headers_list:
            header_list = self.api_client.select_header_content_type(
                content_type_headers_list)
            params['header']['Content-Type'] = header_list

        return self.api_client.call_api(
            self.settings['endpoint_path'],
            self.settings['http_method'],
            params['path'],
            params['query'],
            params['header'],
            body=params['body'],
            post_params=params['form'],
            files=params['file'],
            response_type=self.settings['response_type'],
            auth_settings=self.settings['auth'],
            async_req=kwargs['async_req'],
            _check_type=kwargs['_check_return_type'],
            _return_http_data_only=kwargs['_return_http_data_only'],
            _preload_content=kwargs['_preload_content'],
            _request_timeout=kwargs['_request_timeout'],
            _host=_host,
            collection_formats=params['collection_format'])