"""
    Config API v1

    The `config` service provides basic catalog management operations. It manages all platform resources needed for different kinds of catalogs and operations on them.  # noqa: E501

    The version of the OpenAPI document: 1.1.6
    Generated by: https://openapi-generator.tech
"""


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

from here_data_config_v1_client.api_client import ApiClient, Endpoint as _Endpoint
from here_data_config_v1_client.model_utils import (  # noqa: F401
    check_allowed_values,
    check_validations,
    date,
    datetime,
    file_type,
    none_type,
    validate_and_convert_types
)
from here_data_config_v1_client.model.catalog import Catalog
from here_data_config_v1_client.model.catalog_failure_status import CatalogFailureStatus
from here_data_config_v1_client.model.catalog_pending_status import CatalogPendingStatus
from here_data_config_v1_client.model.catalog_success_status import CatalogSuccessStatus
from here_data_config_v1_client.model.create_catalog import CreateCatalog
from here_data_config_v1_client.model.patch_catalog import PatchCatalog
from here_data_config_v1_client.model.patch_layer import PatchLayer
from here_data_config_v1_client.model.status_link import StatusLink


class ConfigApi(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 __catalog_exists(
            self,
            catalog_hrn,
            **kwargs
        ):
            """Checks the existence of a catalog  # noqa: E501

            Checks whether a catalog with the specified HRN exists.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.catalog_exists(catalog_hrn, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog.

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                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['catalog_hrn'] = \
                catalog_hrn
            return self.call_with_http_info(**kwargs)

        self.catalog_exists = _Endpoint(
            settings={
                'response_type': None,
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}',
                'operation_id': 'catalog_exists',
                'http_method': 'HEAD',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'billing_tag',
                ],
                'required': [
                    'catalog_hrn',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [],
                'content_type': [],
            },
            api_client=api_client,
            callable=__catalog_exists
        )

        def __create_catalog(
            self,
            create_catalog,
            **kwargs
        ):
            """Creates a catalog  # noqa: E501

            Creates a new catalog with the specified layers. The create catalog operation runs asynchronously. Once you've submitted the catalog for creation, you'll receive a randomly generated token that you can use to monitor the status of the operation.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

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

            Args:
                create_catalog (CreateCatalog): A catalog object that contains metadata and layer definitions.

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                StatusLink
                    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['create_catalog'] = \
                create_catalog
            return self.call_with_http_info(**kwargs)

        self.create_catalog = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs',
                'operation_id': 'create_catalog',
                'http_method': 'POST',
                'servers': None,
            },
            params_map={
                'all': [
                    'create_catalog',
                    'billing_tag',
                ],
                'required': [
                    'create_catalog',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'create_catalog':
                        (CreateCatalog,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'create_catalog': 'body',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__create_catalog
        )

        def __delete_catalog(
            self,
            catalog_hrn,
            **kwargs
        ):
            """Deletes a catalog  # noqa: E501

            Deletes a catalog and any layers within that catalog.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.delete_catalog(catalog_hrn, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            return self.call_with_http_info(**kwargs)

        self.delete_catalog = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}',
                'operation_id': 'delete_catalog',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'billing_tag',
                ],
                'required': [
                    'catalog_hrn',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__delete_catalog
        )

        def __delete_layer(
            self,
            catalog_hrn,
            layer_id,
            **kwargs
        ):
            """Delete a layer  # noqa: E501

            Deletes a layer of the catalog if it's of layerType 'index', 'volatile', or 'stream'. Other `layerTypes` are currently not supported.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.delete_layer(catalog_hrn, layer_id, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog
                layer_id (str): The layer ID

            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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            kwargs['layer_id'] = \
                layer_id
            return self.call_with_http_info(**kwargs)

        self.delete_layer = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}/layers/{layerId}',
                'operation_id': 'delete_layer',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'layer_id',
                ],
                'required': [
                    'catalog_hrn',
                    'layer_id',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'layer_id':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'layer_id': 'layerId',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'layer_id': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__delete_layer
        )

        def __disable_automatic_version_deletion(
            self,
            catalog_hrn,
            **kwargs
        ):
            """Disable automatic version deletion  # noqa: E501

            Disable automatic retired versions cleanup.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.disable_automatic_version_deletion(catalog_hrn, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog.

            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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            return self.call_with_http_info(**kwargs)

        self.disable_automatic_version_deletion = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}/automaticVersionDeletion',
                'operation_id': 'disable_automatic_version_deletion',
                'http_method': 'DELETE',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                ],
                'required': [
                    'catalog_hrn',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__disable_automatic_version_deletion
        )

        def __get_catalog(
            self,
            catalog_hrn,
            **kwargs
        ):
            """Gets the details of a catalog  # noqa: E501

            Gets the full catalog configuration for the requested catalog. The catalog configuration contains descriptive and structural information such as layer definitions and layer types.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.get_catalog(catalog_hrn, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                Catalog
                    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['catalog_hrn'] = \
                catalog_hrn
            return self.call_with_http_info(**kwargs)

        self.get_catalog = _Endpoint(
            settings={
                'response_type': (Catalog,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}',
                'operation_id': 'get_catalog',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'billing_tag',
                ],
                'required': [
                    'catalog_hrn',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__get_catalog
        )

        def __get_catalog_status(
            self,
            token,
            **kwargs
        ):
            """Gets the status of a create, update or delete catalog request.  # noqa: E501

            Takes the randomly generated token that you receive when you submit a catalog for creation. You can use it to monitor the status of your 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.get_catalog_status(token, async_req=True)
            >>> result = thread.get()

            Args:
                token (str): The token of catalog creation, modification or deletion task

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                CatalogSuccessStatus
                    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['token'] = \
                token
            return self.call_with_http_info(**kwargs)

        self.get_catalog_status = _Endpoint(
            settings={
                'response_type': (CatalogSuccessStatus,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/status/{token}',
                'operation_id': 'get_catalog_status',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'token',
                    'billing_tag',
                ],
                'required': [
                    'token',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'token':
                        (str,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'token': 'token',
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'token': 'path',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__get_catalog_status
        )

        def __get_catalogs(
            self,
            **kwargs
        ):
            """Gets a list of all catalogs  # noqa: E501

            Lists all catalogs that your account has access to. To get access to a catalog, your administrator must associate this catalog in your HERE platform account. By default, the list provides summary data for each catalog such as the title, the configuration URL, and the resource type.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

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


            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters,   contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [optional]
                verbose (bool): Indicates if the response should contain fully expanded catalog configurations.. [optional] if omitted the server will use the default value of False
                q (str): Works only when the verbose flag is set to true. The result contains only those items which have the given string as a part of the value of one or more searchable fields (substring compare). It will search the following catalog details fields: id, name, summary, description, tags and layer details: id, name, summary, description, tags, schema-hrn. [optional]
                organisation (str): Works only when the verbose flag is set to true. Filters only catalogs (layers) that belong to a specified organisation. You can filter only by catalog (layer) owner organisation ID. If you do not specify an organisation, the search is unfiltered.. [optional]
                organisation_type ([str]): Works only when the verbose flag is set to true. Filters only catalogs that belong to an organisation. If set to ''myOrganisation'', the search is for catalogs (layers) with the same owner organisation ID like the requester''s. If set to ''here'', the search is for catalogs (layers) with the same owner organisation ID is equal to the Here organisation. If set to ''other'', the search is for catalogs (layers) with an owner organisation ID not equal to the requester organisation and not equal to HERE organisation. If you do not specify an organisation, the search is unfiltered.. [optional]
                layer_type ([str]): Works only when the verbose flag is set to true. Comma-separated list of layer types (with OR semantic) to look for in the layer type. Filters only catalogs that contain layers with layer type presented in a given list. If you do not specify a layer type, the search is unfiltered.. [optional]
                region ([str]): Works only when the verbose flag is set to true. Comma-separated list of regions (with OR semantic) to look for in the catalog replication configuration. Filters only catalogs that contain region presented in given list. If you do not specify a region, the search is unfiltered.. [optional]
                schema_hrn (str): Works only when the verbose flag is set to true. Filters only catalogs (layers) by the specified layer schema HRN. You can only filter by layer schema. If you do not specify a schema, the search is unfiltered.. [optional]
                resource_type (str): Works only when the verbose flag is set to true. Specifies other filters behavior. If set to 'catalog', this applies other filters to search catalogs (and layers inside). If set to 'layer', this applies other filters to search layers. The returned json structure is the same for both cases (list of catalogs with list of layers inside each catalog).. [optional] if omitted the server will use the default value of "catalog"
                coverage ([str]): Works only when the verbose flag is set to true. Comma-separated list of countries (with OR semantic) to look for in the catalog (layer) coverage. Only catalogs (layers) covering specified countries will be returned. This filed is case-insensitive. If you do not specify coverage, the search includes all countries.. [optional]
                access ([str]): Works only when the verbose flag is set to true. Comma-separated list of access types (with OR semantic) to filter result. If set to 'default', the response includes catalogs the user has read or manage access to. If set to 'create', the response includes catalogs the user has created and which match the `owner.creator` field, if set to 'manage', the response includes catalogs the user has manage access to. If set to 'orgAdmin', the response includes catalogs the `OrgAdmin` user have access to.. [optional]
                marketplace_ready (bool): Indicates if the response should contain only Marketplace-ready catalogs. If this flag is set to true, the service will return only catalogs with the `marketplaceReady` element set to true.. [optional] if omitted the server will use the default value of False
                limit (int): Works only when the verbose flag is set to true. When specified, result element count will be limited to this value. Minimum: 1.. [optional]
                sort_by (str): Works only when the verbose flag is set to true. Specifies sort field. If set to 'name', the response contains catalogs sorted by catalog name. If set to 'created', the the response contains catalogs sortedby catalog create time. Layers inside a catalog are always sorted by layer name. If you do not specify a `sortBy`, the response contains catalogs sorted by 'name'.. [optional] if omitted the server will use the default value of "name"
                sort_order (str): Works only when the verbose flag is set to true. Specifies the sort order. If set to 'asc', the sort order is ascending. If set to 'desc', the sort order is descending. If you do not specify `sortOrder`, the sort order is ascending.. [optional] if omitted the server will use the default value of "asc"
                linkable (bool): Indicates if the response should only return the list of linkable catalogs.  Note: - If set to 'true' and the access token has a project scope, then the response will include the catalogs   that are available to the caller to link to the project in the token's project scope and HERE public catalogs. - If set to 'true' and the access token has no scope, then the response will include all HERE public catalogs only.\" . [optional] if omitted the server will use the default value of False
                _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:
                object
                    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.get_catalogs = _Endpoint(
            settings={
                'response_type': (object,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs',
                'operation_id': 'get_catalogs',
                'http_method': 'GET',
                'servers': None,
            },
            params_map={
                'all': [
                    'billing_tag',
                    'verbose',
                    'q',
                    'organisation',
                    'organisation_type',
                    'layer_type',
                    'region',
                    'schema_hrn',
                    'resource_type',
                    'coverage',
                    'access',
                    'marketplace_ready',
                    'limit',
                    'sort_by',
                    'sort_order',
                    'linkable',
                ],
                'required': [],
                'nullable': [
                ],
                'enum': [
                    'organisation_type',
                    'layer_type',
                    'region',
                    'resource_type',
                    'access',
                    'sort_by',
                    'sort_order',
                ],
                'validation': [
                    'limit',
                ]
            },
            root_map={
                'validations': {
                    ('limit',): {

                        'inclusive_minimum': 1,
                    },
                },
                'allowed_values': {
                    ('organisation_type',): {

                        "MYORGANISATION": "myOrganisation",
                        "HERE": "here",
                        "OTHER": "other"
                    },
                    ('layer_type',): {

                        "VERSIONED": "versioned",
                        "STREAM": "stream",
                        "VOLATILE": "volatile",
                        "INDEX": "index",
                        "OBJECTSTORE": "objectstore",
                        "INTERACTIVEMAPS": "interactivemaps"
                    },
                    ('region',): {

                        "EU-IRELAND": "eu-ireland",
                        "US-OREGON": "us-oregon",
                        "CN-NINGXIA": "cn-ningxia"
                    },
                    ('resource_type',): {

                        "CATALOG": "catalog",
                        "LAYER": "layer"
                    },
                    ('access',): {

                        "DEFAULT": "default",
                        "CREATE": "create",
                        "MANAGE": "manage",
                        "ORGADMIN": "orgAdmin"
                    },
                    ('sort_by',): {

                        "NAME": "name",
                        "CREATED": "created"
                    },
                    ('sort_order',): {

                        "ASC": "asc",
                        "DESC": "desc"
                    },
                },
                'openapi_types': {
                    'billing_tag':
                        (str,),
                    'verbose':
                        (bool,),
                    'q':
                        (str,),
                    'organisation':
                        (str,),
                    'organisation_type':
                        ([str],),
                    'layer_type':
                        ([str],),
                    'region':
                        ([str],),
                    'schema_hrn':
                        (str,),
                    'resource_type':
                        (str,),
                    'coverage':
                        ([str],),
                    'access':
                        ([str],),
                    'marketplace_ready':
                        (bool,),
                    'limit':
                        (int,),
                    'sort_by':
                        (str,),
                    'sort_order':
                        (str,),
                    'linkable':
                        (bool,),
                },
                'attribute_map': {
                    'billing_tag': 'billingTag',
                    'verbose': 'verbose',
                    'q': 'q',
                    'organisation': 'organisation',
                    'organisation_type': 'organisationType',
                    'layer_type': 'layerType',
                    'region': 'region',
                    'schema_hrn': 'schemaHrn',
                    'resource_type': 'resourceType',
                    'coverage': 'coverage',
                    'access': 'access',
                    'marketplace_ready': 'marketplaceReady',
                    'limit': 'limit',
                    'sort_by': 'sortBy',
                    'sort_order': 'sortOrder',
                    'linkable': 'linkable',
                },
                'location_map': {
                    'billing_tag': 'query',
                    'verbose': 'query',
                    'q': 'query',
                    'organisation': 'query',
                    'organisation_type': 'query',
                    'layer_type': 'query',
                    'region': 'query',
                    'schema_hrn': 'query',
                    'resource_type': 'query',
                    'coverage': 'query',
                    'access': 'query',
                    'marketplace_ready': 'query',
                    'limit': 'query',
                    'sort_by': 'query',
                    'sort_order': 'query',
                    'linkable': 'query',
                },
                'collection_format_map': {
                    'organisation_type': 'multi',
                    'layer_type': 'multi',
                    'region': 'multi',
                    'coverage': 'multi',
                    'access': 'multi',
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [],
            },
            api_client=api_client,
            callable=__get_catalogs
        )

        def __patch_catalog(
            self,
            catalog_hrn,
            patch_catalog,
            **kwargs
        ):
            """Modify a catalog  # noqa: E501

            Modify some fields of the catalog. The existing HTTP PUT method only allows a complete replacement of a catalog configuration, HTTP PATCH method is used to modify some fields of existing catalog configuration. All fields are optional. Specify field value to modify it, not specified fields are ignored. To remove the field value use the null value. For more information, see RFC 7396 - JSON Merge Patch.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.patch_catalog(catalog_hrn, patch_catalog, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog
                patch_catalog (PatchCatalog): A catalog object that contains modification of catalog configuration

            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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            kwargs['patch_catalog'] = \
                patch_catalog
            return self.call_with_http_info(**kwargs)

        self.patch_catalog = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}',
                'operation_id': 'patch_catalog',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'patch_catalog',
                ],
                'required': [
                    'catalog_hrn',
                    'patch_catalog',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'patch_catalog':
                        (PatchCatalog,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'patch_catalog': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/merge-patch+json'
                ]
            },
            api_client=api_client,
            callable=__patch_catalog
        )

        def __patch_layer(
            self,
            catalog_hrn,
            layer_id,
            patch_layer,
            **kwargs
        ):
            """Modify a catalog layer  # noqa: E501

            Modify some fields of the catalog layer. HTTP PATCH method is used to modify some fields of existing layer configuration. All fields are optional. Specify field value to modify it, not specified fields are ignored. To remove the field value use the null value. For more information see RFC 7396 - JSON Merge Patch.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.patch_layer(catalog_hrn, layer_id, patch_layer, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog
                layer_id (str): The layer ID
                patch_layer (PatchLayer): A layer object that contains modification of layer configuration

            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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            kwargs['layer_id'] = \
                layer_id
            kwargs['patch_layer'] = \
                patch_layer
            return self.call_with_http_info(**kwargs)

        self.patch_layer = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}/layers/{layerId}',
                'operation_id': 'patch_layer',
                'http_method': 'PATCH',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'layer_id',
                    'patch_layer',
                ],
                'required': [
                    'catalog_hrn',
                    'layer_id',
                    'patch_layer',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'layer_id':
                        (str,),
                    'patch_layer':
                        (PatchLayer,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'layer_id': 'layerId',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'layer_id': 'path',
                    'patch_layer': 'body',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/merge-patch+json'
                ]
            },
            api_client=api_client,
            callable=__patch_layer
        )

        def __update_catalog(
            self,
            catalog_hrn,
            create_catalog,
            **kwargs
        ):
            """Updates a catalog  # noqa: E501

            Updates any descriptive and structural information in the catalog. To update a catalog, send a new version of your catalog configuration with the updated data and any required fields.  # noqa: E501
            This method makes a synchronous HTTP request by default. To make an
            asynchronous HTTP request, please pass async_req=True

            >>> thread = api.update_catalog(catalog_hrn, create_catalog, async_req=True)
            >>> result = thread.get()

            Args:
                catalog_hrn (str): The HERE Resource Name (HRN) of the catalog
                create_catalog (CreateCatalog): A catalog object that contains metadata and layer definitions.

            Keyword Args:
                billing_tag (str): The `billingTag` parameter is an optional free-form tag that you can use to group billing records together. If supplied, it must be between 4 - 16 characters, contain only alpha/numeric ASCII characters  [A-Za-z0-9]. Grouping billing records by billing tag will be available in future releases.. [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:
                StatusLink
                    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['catalog_hrn'] = \
                catalog_hrn
            kwargs['create_catalog'] = \
                create_catalog
            return self.call_with_http_info(**kwargs)

        self.update_catalog = _Endpoint(
            settings={
                'response_type': (StatusLink,),
                'auth': [
                    'Bearer'
                ],
                'endpoint_path': '/catalogs/{catalogHrn}',
                'operation_id': 'update_catalog',
                'http_method': 'PUT',
                'servers': None,
            },
            params_map={
                'all': [
                    'catalog_hrn',
                    'create_catalog',
                    'billing_tag',
                ],
                'required': [
                    'catalog_hrn',
                    'create_catalog',
                ],
                'nullable': [
                ],
                'enum': [
                ],
                'validation': [
                ]
            },
            root_map={
                'validations': {
                },
                'allowed_values': {
                },
                'openapi_types': {
                    'catalog_hrn':
                        (str,),
                    'create_catalog':
                        (CreateCatalog,),
                    'billing_tag':
                        (str,),
                },
                'attribute_map': {
                    'catalog_hrn': 'catalogHrn',
                    'billing_tag': 'billingTag',
                },
                'location_map': {
                    'catalog_hrn': 'path',
                    'create_catalog': 'body',
                    'billing_tag': 'query',
                },
                'collection_format_map': {
                }
            },
            headers_map={
                'accept': [
                    'application/json'
                ],
                'content_type': [
                    'application/json'
                ]
            },
            api_client=api_client,
            callable=__update_catalog
        )
