# coding: utf-8

"""
    Trackside Software TeamDB API v2.0

    This API enables you to access TeamDB data  # noqa: E501

    OpenAPI spec version: 2.0
    Contact: support@trackside.fr
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


from __future__ import absolute_import

import re  # noqa: F401

# python 2 and python 3 compatibility library
import six

from teamdbapi.api_client import ApiClient


class AssemblyApi(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    Ref: https://github.com/swagger-api/swagger-codegen
    """

    def __init__(self, api_client=None):
        if api_client is None:
            api_client = ApiClient()
        self.api_client = api_client

    def assembly_add_revisions_to_assembly(self, assembly_id, revision_ids, **kwargs):  # noqa: E501
        """[Command] Add a list of revisions to an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to which you want to add the revisions (required)
        :param list[str] revision_ids: A list of unique revision ids you want to add to the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_add_revisions_to_assembly_with_http_info(assembly_id, revision_ids, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_add_revisions_to_assembly_with_http_info(assembly_id, revision_ids, **kwargs)  # noqa: E501
            return data

    def assembly_add_revisions_to_assembly_with_http_info(self, assembly_id, revision_ids, **kwargs):  # noqa: E501
        """[Command] Add a list of revisions to an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to which you want to add the revisions (required)
        :param list[str] revision_ids: A list of unique revision ids you want to add to the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'revision_ids']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_add_revisions_to_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_add_revisions_to_assembly`")  # noqa: E501
        # verify the required parameter 'revision_ids' is set
        if self.api_client.client_side_validation and ('revision_ids' not in params or
                                                       params['revision_ids'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `revision_ids` when calling `assembly_add_revisions_to_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/addrevisions', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_add_tag(self, assembly_id, tag, **kwargs):  # noqa: E501
        """[Command] Add a search tag to an existing assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly unique id (required)
        :param str tag: The tag to add to the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_add_tag_with_http_info(assembly_id, tag, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_add_tag_with_http_info(assembly_id, tag, **kwargs)  # noqa: E501
            return data

    def assembly_add_tag_with_http_info(self, assembly_id, tag, **kwargs):  # noqa: E501
        """[Command] Add a search tag to an existing assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly unique id (required)
        :param str tag: The tag to add to the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'tag']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_add_tag" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_add_tag`")  # noqa: E501
        # verify the required parameter 'tag' is set
        if self.api_client.client_side_validation and ('tag' not in params or
                                                       params['tag'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `tag` when calling `assembly_add_tag`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/addtag', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_assemblies_link_to_run(self, run_id, **kwargs):  # noqa: E501
        """Get all the assemblies link to a run  # noqa: E501

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

        :param async_req bool
        :param str run_id: The run id you want the assemblies linked to (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_assemblies_link_to_run_with_http_info(run_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_assemblies_link_to_run_with_http_info(run_id, **kwargs)  # noqa: E501
            return data

    def assembly_assemblies_link_to_run_with_http_info(self, run_id, **kwargs):  # noqa: E501
        """Get all the assemblies link to a run  # noqa: E501

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

        :param async_req bool
        :param str run_id: The run id you want the assemblies linked to (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['run_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'run_id' in params:
            path_params['runId'] = params['run_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/run/{runId}/assemblies', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='list[Assembly]',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_compare_assemblies(self, assembly_aid, assembly_bid, **kwargs):  # noqa: E501
        """[Command] Compare 2 assemblies  # noqa: E501

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

        :param async_req bool
        :param str assembly_aid: Assembly A unique Id (required)
        :param str assembly_bid: Assembly B unique Id (required)
        :param CompareOptions compare_options: The import options. You can leave options empty.              By defaut, there will be no filter and no file export.              To apply a filter you have to fill ParametersSelectionFilters and ExcludeParametersInSelection.              To export a file you must fill OutPathFilePath. The file extension will be automatically replaced by the good one.              DiffGroup allows you to select the content of the diff file generated. You can choose A or B. By default B is selected.
        :return: list[CompareResultDetail]
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_compare_assemblies_with_http_info(assembly_aid, assembly_bid, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_compare_assemblies_with_http_info(assembly_aid, assembly_bid, **kwargs)  # noqa: E501
            return data

    def assembly_compare_assemblies_with_http_info(self, assembly_aid, assembly_bid, **kwargs):  # noqa: E501
        """[Command] Compare 2 assemblies  # noqa: E501

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

        :param async_req bool
        :param str assembly_aid: Assembly A unique Id (required)
        :param str assembly_bid: Assembly B unique Id (required)
        :param CompareOptions compare_options: The import options. You can leave options empty.              By defaut, there will be no filter and no file export.              To apply a filter you have to fill ParametersSelectionFilters and ExcludeParametersInSelection.              To export a file you must fill OutPathFilePath. The file extension will be automatically replaced by the good one.              DiffGroup allows you to select the content of the diff file generated. You can choose A or B. By default B is selected.
        :return: list[CompareResultDetail]
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_aid', 'assembly_bid', 'compare_options']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_compare_assemblies" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_aid' is set
        if self.api_client.client_side_validation and ('assembly_aid' not in params or
                                                       params['assembly_aid'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_aid` when calling `assembly_compare_assemblies`")  # noqa: E501
        # verify the required parameter 'assembly_bid' is set
        if self.api_client.client_side_validation and ('assembly_bid' not in params or
                                                       params['assembly_bid'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_bid` when calling `assembly_compare_assemblies`")  # noqa: E501

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'assembly_aid' in params:
            query_params.append(('assemblyAId', params['assembly_aid']))  # noqa: E501
        if 'assembly_bid' in params:
            query_params.append(('assemblyBId', params['assembly_bid']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/compare', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='list[CompareResultDetail]',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_create_assembly(self, assembly, **kwargs):  # noqa: E501
        """Create an assembly. The revisions list content will be ignored. You have to call AddRevisionsToAssembly to add revisions to an assembly.  # noqa: E501

        Set Assembly.Id empty (00000000-0000-0000-0000-000000000000) in order to create a new assembly.  # noqa: E501
        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.assembly_create_assembly(assembly, async_req=True)
        >>> result = thread.get()

        :param async_req bool
        :param Assembly assembly: The assembly to create. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_create_assembly_with_http_info(assembly, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_create_assembly_with_http_info(assembly, **kwargs)  # noqa: E501
            return data

    def assembly_create_assembly_with_http_info(self, assembly, **kwargs):  # noqa: E501
        """Create an assembly. The revisions list content will be ignored. You have to call AddRevisionsToAssembly to add revisions to an assembly.  # noqa: E501

        Set Assembly.Id empty (00000000-0000-0000-0000-000000000000) in order to create a new assembly.  # noqa: E501
        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True
        >>> thread = api.assembly_create_assembly_with_http_info(assembly, async_req=True)
        >>> result = thread.get()

        :param async_req bool
        :param Assembly assembly: The assembly to create. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_delete_assembly(self, assembly_id, **kwargs):  # noqa: E501
        """Delete an assembly or group revision corresponding to a given id.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id or group revision you want to delete (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_delete_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_delete_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_delete_assembly_with_http_info(self, assembly_id, **kwargs):  # noqa: E501
        """Delete an assembly or group revision corresponding to a given id.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id or group revision you want to delete (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}', 'DELETE',
            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=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_duplicate_assembly(self, assembly_id, **kwargs):  # noqa: E501
        """Duplicate an existing assembly. Set the flag \"withLogs\" to True to duplicate Logs as well.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to copy. (required)
        :param bool with_logs: Flag indicating if the logs should also be duplicated.
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_duplicate_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_duplicate_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_duplicate_assembly_with_http_info(self, assembly_id, **kwargs):  # noqa: E501
        """Duplicate an existing assembly. Set the flag \"withLogs\" to True to duplicate Logs as well.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to copy. (required)
        :param bool with_logs: Flag indicating if the logs should also be duplicated.
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'with_logs']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []
        if 'with_logs' in params:
            query_params.append(('withLogs', params['with_logs']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/duplicate', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_export_assembly(self, assembly_id, output_file_path, **kwargs):  # noqa: E501
        """[Command] Export an assembly into a file  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id corresponding to the assembly to export. (required)
        :param str output_file_path: The path to the file to create. You have to provide the file extension for example : MyFile.m (required)
        :return: bool
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_export_assembly_with_http_info(assembly_id, output_file_path, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_export_assembly_with_http_info(assembly_id, output_file_path, **kwargs)  # noqa: E501
            return data

    def assembly_export_assembly_with_http_info(self, assembly_id, output_file_path, **kwargs):  # noqa: E501
        """[Command] Export an assembly into a file  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id corresponding to the assembly to export. (required)
        :param str output_file_path: The path to the file to create. You have to provide the file extension for example : MyFile.m (required)
        :return: bool
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'output_file_path']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_export_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_export_assembly`")  # noqa: E501
        # verify the required parameter 'output_file_path' is set
        if self.api_client.client_side_validation and ('output_file_path' not in params or
                                                       params['output_file_path'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `output_file_path` when calling `assembly_export_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []
        if 'output_file_path' in params:
            query_params.append(('outputFilePath', params['output_file_path']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/export', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='bool',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_get_assemblies(self, version_id, **kwargs):  # noqa: E501
        """Get all assemblies for a given version  # noqa: E501

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

        :param async_req bool
        :param str version_id: the version id to wich you want the assemblies. (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_get_assemblies_with_http_info(version_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_get_assemblies_with_http_info(version_id, **kwargs)  # noqa: E501
            return data

    def assembly_get_assemblies_with_http_info(self, version_id, **kwargs):  # noqa: E501
        """Get all assemblies for a given version  # noqa: E501

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

        :param async_req bool
        :param str version_id: the version id to wich you want the assemblies. (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['version_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'version_id' in params:
            path_params['versionId'] = params['version_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/version/{versionId}/assemblies', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='list[Assembly]',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_get_assembly(self, assembly_id, **kwargs):  # noqa: E501
        """Get an assembly for a given id  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: the unique id of the assembly. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_get_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_get_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_get_assembly_with_http_info(self, assembly_id, **kwargs):  # noqa: E501
        """Get an assembly for a given id  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: the unique id of the assembly. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_get_current_assembly(self, **kwargs):  # noqa: E501
        """Get the current selected assembly  # noqa: E501

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

        :param async_req bool
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_get_current_assembly_with_http_info(**kwargs)  # noqa: E501
        else:
            (data) = self.assembly_get_current_assembly_with_http_info(**kwargs)  # noqa: E501
            return data

    def assembly_get_current_assembly_with_http_info(self, **kwargs):  # noqa: E501
        """Get the current selected assembly  # noqa: E501

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

        :param async_req bool
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = []  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_get_current_assembly" % key
                )
            params[key] = val
        del 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(
            ['application/json', 'text/json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/current', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_get_group_revisions_in_assembly_and_group(self, assembly_id, group_id, **kwargs):  # noqa: E501
        """Get a list of group revisions (sub assemblies linked to a group) setted to a given assembly and group  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id to which you search the linked group revisions (required)
        :param str group_id: The unique group id where the group revision are linked (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_get_group_revisions_in_assembly_and_group_with_http_info(assembly_id, group_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_get_group_revisions_in_assembly_and_group_with_http_info(assembly_id, group_id, **kwargs)  # noqa: E501
            return data

    def assembly_get_group_revisions_in_assembly_and_group_with_http_info(self, assembly_id, group_id, **kwargs):  # noqa: E501
        """Get a list of group revisions (sub assemblies linked to a group) setted to a given assembly and group  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id to which you search the linked group revisions (required)
        :param str group_id: The unique group id where the group revision are linked (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'group_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_get_group_revisions_in_assembly_and_group" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_get_group_revisions_in_assembly_and_group`")  # noqa: E501
        # verify the required parameter 'group_id' is set
        if self.api_client.client_side_validation and ('group_id' not in params or
                                                       params['group_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `group_id` when calling `assembly_get_group_revisions_in_assembly_and_group`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501
        if 'group_id' in params:
            path_params['groupId'] = params['group_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/group/{groupId}/revisions', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='list[Assembly]',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_get_group_revisions(self, assembly_id, **kwargs):  # noqa: E501
        """Get a list of group revisions (sub assemblies linked to a group) that are setted to a given assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id to which you search the linked group revisions (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_get_group_revisions_with_http_info(assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_get_group_revisions_with_http_info(assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_get_group_revisions_with_http_info(self, assembly_id, **kwargs):  # noqa: E501
        """Get a list of group revisions (sub assemblies linked to a group) that are setted to a given assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The unique assembly id to which you search the linked group revisions (required)
        :return: list[Assembly]
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/grouprevisions', 'GET',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='list[Assembly]',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_import_assembly(self, **kwargs):  # noqa: E501
        """Create a new assembly by importing a definition file. This will also create the new revisions.  # noqa: E501

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

        :param async_req bool
        :param str version_id: The version id to which the new assembly will belong
        :param str assembly_name: The assembly name to create
        :param str revision_name: The default revision name used to create the new revisions
        :param str file_path: The file path containing the parameters
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_import_assembly_with_http_info(**kwargs)  # noqa: E501
        else:
            (data) = self.assembly_import_assembly_with_http_info(**kwargs)  # noqa: E501
            return data

    def assembly_import_assembly_with_http_info(self, **kwargs):  # noqa: E501
        """Create a new assembly by importing a definition file. This will also create the new revisions.  # noqa: E501

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

        :param async_req bool
        :param str version_id: The version id to which the new assembly will belong
        :param str assembly_name: The assembly name to create
        :param str revision_name: The default revision name used to create the new revisions
        :param str file_path: The file path containing the parameters
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['version_id', 'assembly_name', 'revision_name', 'file_path']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'version_id' in params:
            query_params.append(('versionId', params['version_id']))  # noqa: E501
        if 'assembly_name' in params:
            query_params.append(('assemblyName', params['assembly_name']))  # noqa: E501
        if 'revision_name' in params:
            query_params.append(('revisionName', params['revision_name']))  # noqa: E501
        if 'file_path' in params:
            query_params.append(('filePath', params['file_path']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/import', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_link_run_to_assembly(self, run_id, assembly_id, **kwargs):  # noqa: E501
        """[Command] Link a run to an assembly  # noqa: E501

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

        :param async_req bool
        :param str run_id: The Id of the Run to link (required)
        :param str assembly_id: The Id of the Assembly to link (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_link_run_to_assembly_with_http_info(run_id, assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_link_run_to_assembly_with_http_info(run_id, assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_link_run_to_assembly_with_http_info(self, run_id, assembly_id, **kwargs):  # noqa: E501
        """[Command] Link a run to an assembly  # noqa: E501

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

        :param async_req bool
        :param str run_id: The Id of the Run to link (required)
        :param str assembly_id: The Id of the Assembly to link (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['run_id', 'assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_link_run_to_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'run_id' is set
        if self.api_client.client_side_validation and ('run_id' not in params or
                                                       params['run_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `run_id` when calling `assembly_link_run_to_assembly`")  # noqa: E501
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_link_run_to_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'run_id' in params:
            path_params['runId'] = params['run_id']  # noqa: E501

        query_params = []
        if 'assembly_id' in params:
            query_params.append(('assemblyId', params['assembly_id']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/run/{runId}/linkassembly', '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=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_lock_assembly(self, assembly_id, locked, **kwargs):  # noqa: E501
        """[Command] Lock an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to edit. (required)
        :param bool locked: True to lock the assembly, False to unlock (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_lock_assembly_with_http_info(assembly_id, locked, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_lock_assembly_with_http_info(assembly_id, locked, **kwargs)  # noqa: E501
            return data

    def assembly_lock_assembly_with_http_info(self, assembly_id, locked, **kwargs):  # noqa: E501
        """[Command] Lock an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to edit. (required)
        :param bool locked: True to lock the assembly, False to unlock (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'locked']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_lock_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_lock_assembly`")  # noqa: E501
        # verify the required parameter 'locked' is set
        if self.api_client.client_side_validation and ('locked' not in params or
                                                       params['locked'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `locked` when calling `assembly_lock_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []
        if 'locked' in params:
            query_params.append(('locked', params['locked']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/lock', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_remove_assembly_from_run(self, run_id, assembly_id, **kwargs):  # noqa: E501
        """[Command] Remove an assembly from a run  # noqa: E501

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

        :param async_req bool
        :param str run_id: The Id of the Run to unlink (required)
        :param str assembly_id: The Id of the Assembly to unlink (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_remove_assembly_from_run_with_http_info(run_id, assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_remove_assembly_from_run_with_http_info(run_id, assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_remove_assembly_from_run_with_http_info(self, run_id, assembly_id, **kwargs):  # noqa: E501
        """[Command] Remove an assembly from a run  # noqa: E501

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

        :param async_req bool
        :param str run_id: The Id of the Run to unlink (required)
        :param str assembly_id: The Id of the Assembly to unlink (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['run_id', 'assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_remove_assembly_from_run" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'run_id' is set
        if self.api_client.client_side_validation and ('run_id' not in params or
                                                       params['run_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `run_id` when calling `assembly_remove_assembly_from_run`")  # noqa: E501
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_remove_assembly_from_run`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'run_id' in params:
            path_params['runId'] = params['run_id']  # noqa: E501

        query_params = []
        if 'assembly_id' in params:
            query_params.append(('assemblyId', params['assembly_id']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/run/{runId}/unlinkassembly', '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=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_remove_revisions_from_assembly(self, assembly_id, revision_ids, **kwargs):  # noqa: E501
        """[Command] Remove a list of revisions from an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to which you want to remove the revisions (required)
        :param list[str] revision_ids: A list of unique revision ids to remove from the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_remove_revisions_from_assembly_with_http_info(assembly_id, revision_ids, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_remove_revisions_from_assembly_with_http_info(assembly_id, revision_ids, **kwargs)  # noqa: E501
            return data

    def assembly_remove_revisions_from_assembly_with_http_info(self, assembly_id, revision_ids, **kwargs):  # noqa: E501
        """[Command] Remove a list of revisions from an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to which you want to remove the revisions (required)
        :param list[str] revision_ids: A list of unique revision ids to remove from the assembly (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'revision_ids']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_remove_revisions_from_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_remove_revisions_from_assembly`")  # noqa: E501
        # verify the required parameter 'revision_ids' is set
        if self.api_client.client_side_validation and ('revision_ids' not in params or
                                                       params['revision_ids'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `revision_ids` when calling `assembly_remove_revisions_from_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/removerevisions', 'POST',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_remove_tag(self, assembly_id, tag, **kwargs):  # noqa: E501
        """[Command] Remove a search tag from an existing assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly unique id (required)
        :param str tag: The tag to remove from the assembly (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_remove_tag_with_http_info(assembly_id, tag, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_remove_tag_with_http_info(assembly_id, tag, **kwargs)  # noqa: E501
            return data

    def assembly_remove_tag_with_http_info(self, assembly_id, tag, **kwargs):  # noqa: E501
        """[Command] Remove a search tag from an existing assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly unique id (required)
        :param str tag: The tag to remove from the assembly (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'tag']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_remove_tag" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_remove_tag`")  # noqa: E501
        # verify the required parameter 'tag' is set
        if self.api_client.client_side_validation and ('tag' not in params or
                                                       params['tag'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `tag` when calling `assembly_remove_tag`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []
        if 'tag' in params:
            query_params.append(('tag', params['tag']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}/removetag', '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=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_select_current_assembly(self, assembly_id, **kwargs):  # noqa: E501
        """[Command] Set the current selected assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to select (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_select_current_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_select_current_assembly_with_http_info(assembly_id, **kwargs)  # noqa: E501
            return data

    def assembly_select_current_assembly_with_http_info(self, assembly_id, **kwargs):  # noqa: E501
        """[Command] Set the current selected assembly  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id to select (required)
        :return: None
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

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

        collection_formats = {}

        path_params = {}

        query_params = []
        if 'assembly_id' in params:
            query_params.append(('assemblyId', params['assembly_id']))  # noqa: E501

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/current', '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=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)

    def assembly_update_assembly(self, assembly_id, assembly, **kwargs):  # noqa: E501
        """Update an assembly. The revisions list content will be ignored. You have to call AddRevisionsToAssembly to add revisions to an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id corresponding to the assembly you want to update. (required)
        :param Assembly assembly: The assembly to update. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """
        kwargs['_return_http_data_only'] = True
        if kwargs.get('async_req'):
            return self.assembly_update_assembly_with_http_info(assembly_id, assembly, **kwargs)  # noqa: E501
        else:
            (data) = self.assembly_update_assembly_with_http_info(assembly_id, assembly, **kwargs)  # noqa: E501
            return data

    def assembly_update_assembly_with_http_info(self, assembly_id, assembly, **kwargs):  # noqa: E501
        """Update an assembly. The revisions list content will be ignored. You have to call AddRevisionsToAssembly to add revisions to an assembly.  # noqa: E501

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

        :param async_req bool
        :param str assembly_id: The assembly id corresponding to the assembly you want to update. (required)
        :param Assembly assembly: The assembly to update. (required)
        :return: Assembly
                 If the method is called asynchronously,
                 returns the request thread.
        """

        all_params = ['assembly_id', 'assembly']  # noqa: E501
        all_params.append('async_req')
        all_params.append('_return_http_data_only')
        all_params.append('_preload_content')
        all_params.append('_request_timeout')

        params = locals()
        for key, val in six.iteritems(params['kwargs']):
            if key not in all_params:
                raise TypeError(
                    "Got an unexpected keyword argument '%s'"
                    " to method assembly_update_assembly" % key
                )
            params[key] = val
        del params['kwargs']
        # verify the required parameter 'assembly_id' is set
        if self.api_client.client_side_validation and ('assembly_id' not in params or
                                                       params['assembly_id'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly_id` when calling `assembly_update_assembly`")  # noqa: E501
        # verify the required parameter 'assembly' is set
        if self.api_client.client_side_validation and ('assembly' not in params or
                                                       params['assembly'] is None):  # noqa: E501
            raise ValueError("Missing the required parameter `assembly` when calling `assembly_update_assembly`")  # noqa: E501

        collection_formats = {}

        path_params = {}
        if 'assembly_id' in params:
            path_params['assemblyId'] = params['assembly_id']  # noqa: E501

        query_params = []

        header_params = {}

        form_params = []
        local_var_files = {}

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

        # HTTP header `Content-Type`
        header_params['Content-Type'] = self.api_client.select_header_content_type(  # noqa: E501
            ['application/json-patch+json', 'application/json', 'text/json', 'application/*+json'])  # noqa: E501

        # Authentication setting
        auth_settings = []  # noqa: E501

        return self.api_client.call_api(
            '/teamdbapi/v2.0/assembly/{assemblyId}', 'PUT',
            path_params,
            query_params,
            header_params,
            body=body_params,
            post_params=form_params,
            files=local_var_files,
            response_type='Assembly',  # noqa: E501
            auth_settings=auth_settings,
            async_req=params.get('async_req'),
            _return_http_data_only=params.get('_return_http_data_only'),
            _preload_content=params.get('_preload_content', True),
            _request_timeout=params.get('_request_timeout'),
            collection_formats=collection_formats)
