# coding: utf-8

"""
    Stencila Hub API

    ## Authentication  Many endpoints in the Stencila Hub API require an authentication token. These tokens carry many privileges, so be sure to keep them secure. Do not place your tokens in publicly accessible areas such as client-side code. The API is only served over HTTPS to avoid exposing tokens and other data on the network.  To obtain a token, [`POST /api/tokens`](#operations-tokens-tokens_create) with either a `username` and `password` pair, or an [OpenID Connect](https://openid.net/connect/) token. Then use the token in the `Authorization` header of subsequent requests with the prefix `Token` e.g.      curl -H \"Authorization: Token 48866b1e38a2e9db0baada2140b2327937f4a3636dd5f2dfd8c212341c88d34\" https://hub.stenci.la/api/projects/  Alternatively, you can use `Basic` authentication with the token used as the username and no password. This can be more convenient when using command line tools such as [cURL](https://curl.haxx.se/) e.g.      curl -u 48866b1e38a2e9db0baada2140b2327937f4a3636dd5f2dfd8c212341c88d34: https://hub.stenci.la/api/projects/  Or, the less ubiquitous, but more accessible [httpie](https://httpie.org/):      http --auth 48866b1e38a2e9db0baada2140b2327937f4a3636dd5f2dfd8c212341c88d34: https://hub.stenci.la/api/projects/  In both examples above, the trailing colon is not required but avoids being asked for a password.  ## Versioning  The Stencila Hub is released using semantic versioning. The current version is available from the [`GET /api/status`](/api/status) endpoint. Please see the [Github release page](https://github.com/stencila/hub/releases) and the [changelog](https://github.com/stencila/hub/blob/master/CHANGELOG.md) for details on each release. We currently do not provide versioning of the API but plan to do so soon (probably by using a `Accept: application/vnd.stencila.hub+json;version=1.0` request header). If you are using, or interested in using, the API please contact us and we may be able to expedite this.   # noqa: E501

    The version of the OpenAPI document: v1
    Contact: hello@stenci.la
    Generated by: https://openapi-generator.tech
"""


import re  # noqa: F401
import sys  # noqa: F401

from stencila.hub.api_client import ApiClient, Endpoint
from stencila.hub.model_utils import (  # noqa: F401
    check_allowed_values,
    check_validations,
    date,
    datetime,
    file_type,
    none_type,
    validate_and_convert_types
)
from stencila.hub.model.file import File
from stencila.hub.model.inline_response20010 import InlineResponse20010
from stencila.hub.model.inline_response20011 import InlineResponse20011
from stencila.hub.model.inline_response20012 import InlineResponse20012
from stencila.hub.model.inline_response20013 import InlineResponse20013
from stencila.hub.model.inline_response20014 import InlineResponse20014
from stencila.hub.model.inline_response20015 import InlineResponse20015
from stencila.hub.model.job_create import JobCreate
from stencila.hub.model.job_retrieve import JobRetrieve
from stencila.hub.model.project_agent import ProjectAgent
from stencila.hub.model.project_agent_create import ProjectAgentCreate
from stencila.hub.model.project_agent_update import ProjectAgentUpdate
from stencila.hub.model.project_create import ProjectCreate
from stencila.hub.model.project_list import ProjectList
from stencila.hub.model.project_retrieve import ProjectRetrieve
from stencila.hub.model.project_update import ProjectUpdate
from stencila.hub.model.snapshot import Snapshot
from stencila.hub.model.source_polymorphic import SourcePolymorphic


class ProjectsApi(object):
    """NOTE: This class is auto generated by OpenAPI Generator
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

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

        def __projects_agents_create(
            self,
            project,
            data,
            **kwargs
        ):
            """Create an object.  # noqa: E501

            Returns data for the new object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_agents_create(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (ProjectAgentCreate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectAgentCreate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_agents_create = Endpoint(
            settings={
                'response_type': (ProjectAgentCreate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/agents/',
                'operation_id': 'projects_agents_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (ProjectAgentCreate,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_agents_create
        )

        def __projects_agents_delete(
            self,
            agent,
            project,
            **kwargs
        ):
            """Destroy an object.  # noqa: E501

            Returns an empty response.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_agents_delete(agent, project, async_req=True)
            >>> result = thread.get()

            Args:
                agent (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                None
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['agent'] = \
                agent
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_agents_delete = Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/agents/{agent}/',
                'operation_id': 'projects_agents_delete',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'agent',
                    'project',
                ],
                'required': [
                    'agent',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'agent':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'agent': 'agent',
                    'project': 'project',
                },
                'location_map': {
                    'agent': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_agents_delete
        )

        def __projects_agents_list(
            self,
            project,
            **kwargs
        ):
            """List objects.  # noqa: E501

            Returns a list of objects.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_agents_list(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20011
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_agents_list = Endpoint(
            settings={
                'response_type': (InlineResponse20011,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/agents/',
                'operation_id': 'projects_agents_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'limit',
                    'offset',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                },
                'attribute_map': {
                    'project': 'project',
                    'limit': 'limit',
                    'offset': 'offset',
                },
                'location_map': {
                    'project': 'path',
                    'limit': 'query',
                    'offset': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_agents_list
        )

        def __projects_agents_partial_update(
            self,
            agent,
            project,
            data,
            **kwargs
        ):
            """Update an object.  # noqa: E501

            Returns data for the updated object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_agents_partial_update(agent, project, data, async_req=True)
            >>> result = thread.get()

            Args:
                agent (str):
                project (str):
                data (ProjectAgentUpdate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectAgentUpdate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['agent'] = \
                agent
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_agents_partial_update = Endpoint(
            settings={
                'response_type': (ProjectAgentUpdate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/agents/{agent}/',
                'operation_id': 'projects_agents_partial_update',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'agent',
                    'project',
                    'data',
                ],
                'required': [
                    'agent',
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'agent':
                        (str,),
                    'project':
                        (str,),
                    'data':
                        (ProjectAgentUpdate,),
                },
                'attribute_map': {
                    'agent': 'agent',
                    'project': 'project',
                },
                'location_map': {
                    'agent': 'path',
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_agents_partial_update
        )

        def __projects_agents_read(
            self,
            agent,
            project,
            **kwargs
        ):
            """Retrieve an object.  # noqa: E501

            Returns data for the object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_agents_read(agent, project, async_req=True)
            >>> result = thread.get()

            Args:
                agent (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectAgent
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['agent'] = \
                agent
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_agents_read = Endpoint(
            settings={
                'response_type': (ProjectAgent,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/agents/{agent}/',
                'operation_id': 'projects_agents_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'agent',
                    'project',
                ],
                'required': [
                    'agent',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'agent':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'agent': 'agent',
                    'project': 'project',
                },
                'location_map': {
                    'agent': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_agents_read
        )

        def __projects_convert(
            self,
            file,
            project,
            data,
            **kwargs
        ):
            """Convert a file to another format.  # noqa: E501

            Confirms that the destination path and other options are correct, creates a job and redirects to it.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_convert(file, project, data, async_req=True)
            >>> result = thread.get()

            Args:
                file (str):
                project (str):
                data (File):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                File
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['file'] = \
                file
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_convert = Endpoint(
            settings={
                'response_type': (File,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/files/{file}!convert',
                'operation_id': 'projects_convert',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'file',
                    'project',
                    'data',
                ],
                'required': [
                    'file',
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'file':
                        (str,),
                    'project':
                        (str,),
                    'data':
                        (File,),
                },
                'attribute_map': {
                    'file': 'file',
                    'project': 'project',
                },
                'location_map': {
                    'file': 'path',
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_convert
        )

        def __projects_create(
            self,
            data,
            **kwargs
        ):
            """Create a project.  # noqa: E501

            Receives details of the project. Returns details of the new project.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_create(data, async_req=True)
            >>> result = thread.get()

            Args:
                data (ProjectCreate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectCreate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_create = Endpoint(
            settings={
                'response_type': (ProjectCreate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/',
                'operation_id': 'projects_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'data',
                ],
                'required': [
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'data':
                        (ProjectCreate,),
                },
                'attribute_map': {
                },
                'location_map': {
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_create
        )

        def __projects_delete(
            self,
            project,
            **kwargs
        ):
            """Destroy a project.  # noqa: E501

            Returns an empty response on success.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_delete(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                None
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_delete = Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/',
                'operation_id': 'projects_delete',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_delete
        )

        def __projects_files_delete(
            self,
            file,
            project,
            **kwargs
        ):
            """Destroy an object.  # noqa: E501

            Returns an empty response.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_files_delete(file, project, async_req=True)
            >>> result = thread.get()

            Args:
                file (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                None
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['file'] = \
                file
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_files_delete = Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/files/{file}',
                'operation_id': 'projects_files_delete',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'file',
                    'project',
                ],
                'required': [
                    'file',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'file':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'file': 'file',
                    'project': 'project',
                },
                'location_map': {
                    'file': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_files_delete
        )

        def __projects_files_list(
            self,
            project,
            **kwargs
        ):
            """List objects.  # noqa: E501

            Returns a list of objects.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_files_list(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20012
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_files_list = Endpoint(
            settings={
                'response_type': (InlineResponse20012,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/files/',
                'operation_id': 'projects_files_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'limit',
                    'offset',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                },
                'attribute_map': {
                    'project': 'project',
                    'limit': 'limit',
                    'offset': 'offset',
                },
                'location_map': {
                    'project': 'path',
                    'limit': 'query',
                    'offset': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_files_list
        )

        def __projects_files_read(
            self,
            file,
            project,
            **kwargs
        ):
            """Retrieve an object.  # noqa: E501

            Returns data for the object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_files_read(file, project, async_req=True)
            >>> result = thread.get()

            Args:
                file (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                File
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['file'] = \
                file
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_files_read = Endpoint(
            settings={
                'response_type': (File,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/files/{file}',
                'operation_id': 'projects_files_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'file',
                    'project',
                ],
                'required': [
                    'file',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'file':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'file': 'file',
                    'project': 'project',
                },
                'location_map': {
                    'file': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_files_read
        )

        def __projects_history(
            self,
            file,
            project,
            **kwargs
        ):
            """Get the a file's history.  # noqa: E501

            Returns a paginated history of the 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.projects_history(file, project, async_req=True)
            >>> result = thread.get()

            Args:
                file (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                File
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['file'] = \
                file
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_history = Endpoint(
            settings={
                'response_type': (File,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/files/{file}!history',
                'operation_id': 'projects_history',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'file',
                    'project',
                ],
                'required': [
                    'file',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'file':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'file': 'file',
                    'project': 'project',
                },
                'location_map': {
                    'file': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_history
        )

        def __projects_jobs_cancel(
            self,
            job,
            project,
            data,
            **kwargs
        ):
            """Cancel a job.  # noqa: E501

            If the job is cancellable, it will be cancelled and it's status set to `REVOKED`.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_cancel(job, project, data, async_req=True)
            >>> result = thread.get()

            Args:
                job (str):
                project (str):
                data (JobRetrieve):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['job'] = \
                job
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_cancel = Endpoint(
            settings={
                'response_type': (JobRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/{job}/cancel/',
                'operation_id': 'projects_jobs_cancel',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'job',
                    'project',
                    'data',
                ],
                'required': [
                    'job',
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'job':
                        (str,),
                    'project':
                        (str,),
                    'data':
                        (JobRetrieve,),
                },
                'attribute_map': {
                    'job': 'job',
                    'project': 'project',
                },
                'location_map': {
                    'job': 'path',
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_jobs_cancel
        )

        def __projects_jobs_connect_create(
            self,
            job,
            path,
            project,
            data,
            **kwargs
        ):
            """Connect to a job.  # noqa: E501

            Redirects to the internal URL so that users can connect to the job and run methods inside of it.  This request it proxied through the `router`. This view first checks that the user has permission to edit the job.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_connect_create(job, path, project, data, async_req=True)
            >>> result = thread.get()

            Args:
                job (str):
                path (str):
                project (str):
                data (JobRetrieve):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['job'] = \
                job
            kwargs['path'] = \
                path
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_connect_create = Endpoint(
            settings={
                'response_type': (JobRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/{job}/connect/{path}/',
                'operation_id': 'projects_jobs_connect_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'job',
                    'path',
                    'project',
                    'data',
                ],
                'required': [
                    'job',
                    'path',
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'job':
                        (str,),
                    'path':
                        (str,),
                    'project':
                        (str,),
                    'data':
                        (JobRetrieve,),
                },
                'attribute_map': {
                    'job': 'job',
                    'path': 'path',
                    'project': 'project',
                },
                'location_map': {
                    'job': 'path',
                    'path': 'path',
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_jobs_connect_create
        )

        def __projects_jobs_connect_read(
            self,
            job,
            path,
            project,
            **kwargs
        ):
            """Connect to a job.  # noqa: E501

            Redirects to the internal URL so that users can connect to the job and run methods inside of it.  This request it proxied through the `router`. This view first checks that the user has permission to edit the job.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_connect_read(job, path, project, async_req=True)
            >>> result = thread.get()

            Args:
                job (str):
                path (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['job'] = \
                job
            kwargs['path'] = \
                path
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_connect_read = Endpoint(
            settings={
                'response_type': (JobRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/{job}/connect/{path}/',
                'operation_id': 'projects_jobs_connect_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'job',
                    'path',
                    'project',
                ],
                'required': [
                    'job',
                    'path',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'job':
                        (str,),
                    'path':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'job': 'job',
                    'path': 'path',
                    'project': 'project',
                },
                'location_map': {
                    'job': 'path',
                    'path': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_jobs_connect_read
        )

        def __projects_jobs_create(
            self,
            project,
            data,
            **kwargs
        ):
            """Create an object.  # noqa: E501

            Returns data for the new object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_create(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (JobCreate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobCreate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_create = Endpoint(
            settings={
                'response_type': (JobCreate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/',
                'operation_id': 'projects_jobs_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (JobCreate,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_jobs_create
        )

        def __projects_jobs_execute(
            self,
            project,
            data,
            **kwargs
        ):
            """Create an execute job.  # noqa: E501

            Receives the `node` to execute as the request body. Returns the executed `node`.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_execute(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (JobCreate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobCreate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_execute = Endpoint(
            settings={
                'response_type': (JobCreate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/execute/',
                'operation_id': 'projects_jobs_execute',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (JobCreate,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_jobs_execute
        )

        def __projects_jobs_list(
            self,
            project,
            **kwargs
        ):
            """List objects.  # noqa: E501

            Returns a list of objects.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_list(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20013
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_list = Endpoint(
            settings={
                'response_type': (InlineResponse20013,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/',
                'operation_id': 'projects_jobs_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'limit',
                    'offset',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                },
                'attribute_map': {
                    'project': 'project',
                    'limit': 'limit',
                    'offset': 'offset',
                },
                'location_map': {
                    'project': 'path',
                    'limit': 'query',
                    'offset': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_jobs_list
        )

        def __projects_jobs_partial_update(
            self,
            job,
            project,
            data,
            **kwargs
        ):
            """Update an object.  # noqa: E501

            Returns data for the updated object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_partial_update(job, project, data, async_req=True)
            >>> result = thread.get()

            Args:
                job (str):
                project (str):
                data (JobRetrieve):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['job'] = \
                job
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_partial_update = Endpoint(
            settings={
                'response_type': (JobRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/{job}/',
                'operation_id': 'projects_jobs_partial_update',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'job',
                    'project',
                    'data',
                ],
                'required': [
                    'job',
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'job':
                        (str,),
                    'project':
                        (str,),
                    'data':
                        (JobRetrieve,),
                },
                'attribute_map': {
                    'job': 'job',
                    'project': 'project',
                },
                'location_map': {
                    'job': 'path',
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_jobs_partial_update
        )

        def __projects_jobs_read(
            self,
            job,
            project,
            **kwargs
        ):
            """Retrieve an object.  # noqa: E501

            Returns data for the object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_jobs_read(job, project, async_req=True)
            >>> result = thread.get()

            Args:
                job (str):
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                JobRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['job'] = \
                job
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_jobs_read = Endpoint(
            settings={
                'response_type': (JobRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/jobs/{job}/',
                'operation_id': 'projects_jobs_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'job',
                    'project',
                ],
                'required': [
                    'job',
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'job':
                        (str,),
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'job': 'job',
                    'project': 'project',
                },
                'location_map': {
                    'job': 'path',
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_jobs_read
        )

        def __projects_list(
            self,
            **kwargs
        ):
            """List projects.  # noqa: E501

            Returns a list of projects that are accessible to the user, including those that are public and those that the user is a member of (i.e. has a project role for).  The returned list can be filtered using query parameters, `account`, `role`, `public`, `search`, `source`. The `role` filter applies to the currently authenticated user, and as such has no effected for unauthenticated requests. Roles can be specified as a comma separated list e.g. `role=author,manager,owner` or using to the `+` operator to indicate the minimum required role e.g. `role=author+` (equivalent to the previous example).  For example, to list all projects for which the authenticated user is a member and which uses a particular Google Doc as a source:      GET /projects?role=member&source=gdoc://1BW6MubIyDirCGW9Wq-tSqCma8pioxBI6VpeLyXn5mZA  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_list(async_req=True)
            >>> result = thread.get()


            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                account (int): The integer of the id of the account that the project belongs to.. [optional]
                role (str): The role that the currently authenticated user has on the project e.g. \&quot;editor\&quot;, \&quot;owner\&quot; (for any role, use \&quot;member\&quot;). [optional]
                public (bool): Whether or not the project is public.. [optional]
                search (str): A string to search for in the project &#x60;name&#x60;, &#x60;title&#x60; or &#x60;description&#x60;.. [optional]
                source (str): The address of a project source e.g. &#x60;github://&lt;org&gt;/&lt;repo&gt;&#x60;, &#x60;gdoc://&lt;id&gt;&#x60;.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20010
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            return self.call_with_http_info(**kwargs)

        self.projects_list = Endpoint(
            settings={
                'response_type': (InlineResponse20010,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/',
                'operation_id': 'projects_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'limit',
                    'offset',
                    'account',
                    'role',
                    'public',
                    'search',
                    'source',
                ],
                'required': [],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                    'account':
                        (int,),
                    'role':
                        (str,),
                    'public':
                        (bool,),
                    'search':
                        (str,),
                    'source':
                        (str,),
                },
                'attribute_map': {
                    'limit': 'limit',
                    'offset': 'offset',
                    'account': 'account',
                    'role': 'role',
                    'public': 'public',
                    'search': 'search',
                    'source': 'source',
                },
                'location_map': {
                    'limit': 'query',
                    'offset': 'query',
                    'account': 'query',
                    'role': 'query',
                    'public': 'query',
                    'search': 'query',
                    'source': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_list
        )

        def __projects_partial_update(
            self,
            project,
            data,
            **kwargs
        ):
            """Update a project.  # noqa: E501

            Receives details of the project. Returns updated details of the project.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_partial_update(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (ProjectUpdate):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectUpdate
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_partial_update = Endpoint(
            settings={
                'response_type': (ProjectUpdate,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/',
                'operation_id': 'projects_partial_update',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (ProjectUpdate,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_partial_update
        )

        def __projects_pull(
            self,
            project,
            data,
            **kwargs
        ):
            """Pull the project.  # noqa: E501

            Creates a pull job and redirects to it.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_pull(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (ProjectList):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectList
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_pull = Endpoint(
            settings={
                'response_type': (ProjectList,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/pull/',
                'operation_id': 'projects_pull',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (ProjectList,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_pull
        )

        def __projects_read(
            self,
            project,
            **kwargs
        ):
            """Retrieve a project.  # noqa: E501

            Returns details of the project.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_read(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectRetrieve
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_read = Endpoint(
            settings={
                'response_type': (ProjectRetrieve,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/',
                'operation_id': 'projects_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_read
        )

        def __projects_session(
            self,
            project,
            data,
            **kwargs
        ):
            """Get a session for the project.  # noqa: E501

            If the user has already created, or is connected to, a `session` job for this project, and that job is still running, then returns that job. Otherwise, creates a new session.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_session(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (ProjectList):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                ProjectList
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_session = Endpoint(
            settings={
                'response_type': (ProjectList,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/session/',
                'operation_id': 'projects_session',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (ProjectList,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_session
        )

        def __projects_snapshots_archive(
            self,
            project,
            snapshot,
            **kwargs
        ):
            """Retrieve an archive for a project snapshot.  # noqa: E501

            The user should have read access to the project. Returns a redirect to the URL of the archive.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_archive(project, snapshot, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                snapshot (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                Snapshot
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['snapshot'] = \
                snapshot
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_archive = Endpoint(
            settings={
                'response_type': (Snapshot,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/{snapshot}/archive/',
                'operation_id': 'projects_snapshots_archive',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'snapshot',
                ],
                'required': [
                    'project',
                    'snapshot',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'snapshot':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'snapshot': 'snapshot',
                },
                'location_map': {
                    'project': 'path',
                    'snapshot': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_snapshots_archive
        )

        def __projects_snapshots_create(
            self,
            project,
            data,
            **kwargs
        ):
            """Create an object.  # noqa: E501

            Returns data for the new object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_create(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (Snapshot):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                Snapshot
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_create = Endpoint(
            settings={
                'response_type': (Snapshot,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/',
                'operation_id': 'projects_snapshots_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (Snapshot,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_snapshots_create
        )

        def __projects_snapshots_delete(
            self,
            project,
            snapshot,
            **kwargs
        ):
            """Destroy an object.  # noqa: E501

            Returns an empty response.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_delete(project, snapshot, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                snapshot (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                None
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['snapshot'] = \
                snapshot
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_delete = Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/{snapshot}/',
                'operation_id': 'projects_snapshots_delete',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'snapshot',
                ],
                'required': [
                    'project',
                    'snapshot',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'snapshot':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'snapshot': 'snapshot',
                },
                'location_map': {
                    'project': 'path',
                    'snapshot': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_snapshots_delete
        )

        def __projects_snapshots_files(
            self,
            path,
            project,
            snapshot,
            **kwargs
        ):
            """Retrieve a file within a snapshot of the project.  # noqa: E501

            For `index.html` will add necessary headers and if necessary inject content required to connect to a session. For other files redirects to the URL for the file (which may be in a remote storage bucket for example).  For security reasons, this function will be deprecated in favour of getting content from the account subdomain.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_files(path, project, snapshot, async_req=True)
            >>> result = thread.get()

            Args:
                path (str):
                project (str):
                snapshot (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                Snapshot
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['path'] = \
                path
            kwargs['project'] = \
                project
            kwargs['snapshot'] = \
                snapshot
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_files = Endpoint(
            settings={
                'response_type': (Snapshot,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/{snapshot}/files/{path}/',
                'operation_id': 'projects_snapshots_files',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'path',
                    'project',
                    'snapshot',
                ],
                'required': [
                    'path',
                    'project',
                    'snapshot',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'path':
                        (str,),
                    'project':
                        (str,),
                    'snapshot':
                        (str,),
                },
                'attribute_map': {
                    'path': 'path',
                    'project': 'project',
                    'snapshot': 'snapshot',
                },
                'location_map': {
                    'path': 'path',
                    'project': 'path',
                    'snapshot': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_snapshots_files
        )

        def __projects_snapshots_list(
            self,
            project,
            **kwargs
        ):
            """List objects.  # noqa: E501

            Returns a list of objects.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_list(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20014
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_list = Endpoint(
            settings={
                'response_type': (InlineResponse20014,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/',
                'operation_id': 'projects_snapshots_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'limit',
                    'offset',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                },
                'attribute_map': {
                    'project': 'project',
                    'limit': 'limit',
                    'offset': 'offset',
                },
                'location_map': {
                    'project': 'path',
                    'limit': 'query',
                    'offset': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_snapshots_list
        )

        def __projects_snapshots_read(
            self,
            project,
            snapshot,
            **kwargs
        ):
            """Retrieve an object.  # noqa: E501

            Returns data for the object.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_read(project, snapshot, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                snapshot (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                Snapshot
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['snapshot'] = \
                snapshot
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_read = Endpoint(
            settings={
                'response_type': (Snapshot,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/{snapshot}/',
                'operation_id': 'projects_snapshots_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'snapshot',
                ],
                'required': [
                    'project',
                    'snapshot',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'snapshot':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'snapshot': 'snapshot',
                },
                'location_map': {
                    'project': 'path',
                    'snapshot': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_snapshots_read
        )

        def __projects_snapshots_session(
            self,
            project,
            snapshot,
            data,
            **kwargs
        ):
            """Get a session for the snapshot.  # noqa: E501

            If the user has already created, or is connected to, a `session` job for this snapshot, and that job is still running, then returns that job. Otherwise, creates a new session.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_snapshots_session(project, snapshot, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                snapshot (str):
                data (Snapshot):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                Snapshot
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['snapshot'] = \
                snapshot
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_snapshots_session = Endpoint(
            settings={
                'response_type': (Snapshot,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/snapshots/{snapshot}/session/',
                'operation_id': 'projects_snapshots_session',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'snapshot',
                    'data',
                ],
                'required': [
                    'project',
                    'snapshot',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'snapshot':
                        (str,),
                    'data':
                        (Snapshot,),
                },
                'attribute_map': {
                    'project': 'project',
                    'snapshot': 'snapshot',
                },
                'location_map': {
                    'project': 'path',
                    'snapshot': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_snapshots_session
        )

        def __projects_sources_create(
            self,
            project,
            data,
            **kwargs
        ):
            """Create a project source.  # noqa: E501

            Receives details of the source. This should include the `type` of source, a string matching one of the implemented source classes e.g. `ElifeSource`, `GoogleDocsSource`, `GithubSource` as well as the destination `path`, and other type specific properties. See https://github.com/stencila/hub/blob/master/manager/projects/models/sources.py.  For example, to create a new source for a Google Doc:  ```json {     \"type\": \"GoogleDocsSource\",     \"path\": \"report.gdoc\",     \"docId\": \"1BW6MubIyDirCGW9Wq-tSqCma8pioxBI6VpeLyXn5mZA\" } ```  Alternatively, if the request includes a `url`, then the type will be inferred from the URL, falling back to a `UrlSource`. For example, the create the above Google Doc:  ```json {     \"url\": \"https://docs.google.com/document/u/1/d/1BW6MubIyDirCGW9Wq-tSqCma8pioxBI6VpeLyXn5mZA/edit\"     \"path\": \"report.gdoc\", } ```  Returns details of the new source.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_create(project, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_create = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/',
                'operation_id': 'projects_sources_create',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'data',
                ],
                'required': [
                    'project',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                },
                'location_map': {
                    'project': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_create
        )

        def __projects_sources_delete(
            self,
            project,
            source,
            **kwargs
        ):
            """Destroy a project source.  # noqa: E501

            Removes the source from the project. Returns an empty response on success.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_delete(project, source, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                None
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            return self.call_with_http_info(**kwargs)

        self.projects_sources_delete = Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/',
                'operation_id': 'projects_sources_delete',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                ],
                'required': [
                    'project',
                    'source',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_sources_delete
        )

        def __projects_sources_event(
            self,
            project,
            source,
            data,
            **kwargs
        ):
            """Receive an event notification for a project source.  # noqa: E501

            Receives event data from a source provider (e.g. Github, Google) and forward's it on to the source's event handler. Returns an empty response.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_event(project, source, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_event = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/event/',
                'operation_id': 'projects_sources_event',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                    'data',
                ],
                'required': [
                    'project',
                    'source',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_event
        )

        def __projects_sources_list(
            self,
            project,
            **kwargs
        ):
            """List a project's sources.  # noqa: E501

            Returns a list of sources in the project. The returned list can be filtered using the query parameter, `search` which matches against the source's `path` string.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_list(project, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):

            Keyword Args:
                limit (int): Number of results to return per page.. [optional]
                offset (int): The initial index from which to return the results.. [optional]
                search (str): A string to search for in the source&#39;s &#x60;path&#x60;.. [optional]
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                InlineResponse20015
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            return self.call_with_http_info(**kwargs)

        self.projects_sources_list = Endpoint(
            settings={
                'response_type': (InlineResponse20015,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/',
                'operation_id': 'projects_sources_list',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'limit',
                    'offset',
                    'search',
                ],
                'required': [
                    'project',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'limit':
                        (int,),
                    'offset':
                        (int,),
                    'search':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'limit': 'limit',
                    'offset': 'offset',
                    'search': 'search',
                },
                'location_map': {
                    'project': 'path',
                    'limit': 'query',
                    'offset': 'query',
                    'search': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_sources_list
        )

        def __projects_sources_open(
            self,
            path,
            project,
            source,
            **kwargs
        ):
            """Open a project source, or a file within it.  # noqa: E501

            Returns a redirect response to an external URL.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_open(path, project, source, async_req=True)
            >>> result = thread.get()

            Args:
                path (str):
                project (str):
                source (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['path'] = \
                path
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            return self.call_with_http_info(**kwargs)

        self.projects_sources_open = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/open/{path}/',
                'operation_id': 'projects_sources_open',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'path',
                    'project',
                    'source',
                ],
                'required': [
                    'path',
                    'project',
                    'source',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'path':
                        (str,),
                    'project':
                        (str,),
                    'source':
                        (str,),
                },
                'attribute_map': {
                    'path': 'path',
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'path': 'path',
                    'project': 'path',
                    'source': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_sources_open
        )

        def __projects_sources_partial_update(
            self,
            project,
            source,
            data,
            **kwargs
        ):
            """Update a project source.  # noqa: E501

            Receives details of the source. Returns updated details of the source.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_partial_update(project, source, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_partial_update = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/',
                'operation_id': 'projects_sources_partial_update',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                    'data',
                ],
                'required': [
                    'project',
                    'source',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_partial_update
        )

        def __projects_sources_pull(
            self,
            project,
            source,
            data,
            **kwargs
        ):
            """Pull a project source.  # noqa: E501

            Creates a pull job and redirects to it.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_pull(project, source, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_pull = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/pull/',
                'operation_id': 'projects_sources_pull',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                    'data',
                ],
                'required': [
                    'project',
                    'source',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_pull
        )

        def __projects_sources_read(
            self,
            project,
            source,
            **kwargs
        ):
            """Retrieve a project source.  # noqa: E501

            Returns details of the source.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_read(project, source, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            return self.call_with_http_info(**kwargs)

        self.projects_sources_read = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/',
                'operation_id': 'projects_sources_read',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                ],
                'required': [
                    'project',
                    'source',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__projects_sources_read
        )

        def __projects_sources_unwatch(
            self,
            project,
            source,
            data,
            **kwargs
        ):
            """Unwatch a project source.  # noqa: E501

            Removes any subscription to listen to events for the source. Returns an empty response on success (including if the source was not being watched before the request).  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_unwatch(project, source, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_unwatch = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/unwatch/',
                'operation_id': 'projects_sources_unwatch',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                    'data',
                ],
                'required': [
                    'project',
                    'source',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_unwatch
        )

        def __projects_sources_watch(
            self,
            project,
            source,
            data,
            **kwargs
        ):
            """Watch a project source.  # noqa: E501

            Creates a subscription to listen to events for the source. Returns an empty response on success. Returns a 405 if the source type does not support watches.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.projects_sources_watch(project, source, data, async_req=True)
            >>> result = thread.get()

            Args:
                project (str):
                source (str):
                data (SourcePolymorphic):

            Keyword Args:
                _return_http_data_only (bool): response data without head status
                    code and headers. Default is True.
                _preload_content (bool): if False, the urllib3.HTTPResponse object
                    will be returned without reading/decoding response data.
                    Default is True.
                _request_timeout (float/tuple): timeout setting for this request. If one
                    number provided, it will be total request timeout. It can also
                    be a pair (tuple) of (connection, read) timeouts.
                    Default is None.
                _check_input_type (bool): specifies if type checking
                    should be done one the data sent to the server.
                    Default is True.
                _check_return_type (bool): specifies if type checking
                    should be done one the data received from the server.
                    Default is True.
                _host_index (int/None): specifies the index of the server
                    that we want to use.
                    Default is read from the configuration.
                async_req (bool): execute request asynchronously

            Returns:
                SourcePolymorphic
                    If the method is called asynchronously, returns the request
                    thread.
            """
            kwargs['async_req'] = kwargs.get(
                'async_req', False
            )
            kwargs['_return_http_data_only'] = kwargs.get(
                '_return_http_data_only', True
            )
            kwargs['_preload_content'] = kwargs.get(
                '_preload_content', True
            )
            kwargs['_request_timeout'] = kwargs.get(
                '_request_timeout', None
            )
            kwargs['_check_input_type'] = kwargs.get(
                '_check_input_type', True
            )
            kwargs['_check_return_type'] = kwargs.get(
                '_check_return_type', True
            )
            kwargs['_host_index'] = kwargs.get('_host_index')
            kwargs['project'] = \
                project
            kwargs['source'] = \
                source
            kwargs['data'] = \
                data
            return self.call_with_http_info(**kwargs)

        self.projects_sources_watch = Endpoint(
            settings={
                'response_type': (SourcePolymorphic,),
                'auth': [
                    'Token'
                ],
                'endpoint_path': '/projects/{project}/sources/{source}/watch/',
                'operation_id': 'projects_sources_watch',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'project',
                    'source',
                    'data',
                ],
                'required': [
                    'project',
                    'source',
                    'data',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'project':
                        (str,),
                    'source':
                        (str,),
                    'data':
                        (SourcePolymorphic,),
                },
                'attribute_map': {
                    'project': 'project',
                    'source': 'source',
                },
                'location_map': {
                    'project': 'path',
                    'source': 'path',
                    'data': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__projects_sources_watch
        )
