text: # coding: utf-8
  
  """
      Cloudbreak API
  
      Cloudbreak is a powerful left surf that breaks over a coral reef, a mile off southwest the island of Tavarua, Fiji. Cloudbreak is a cloud agnostic Hadoop as a Service API. Abstracts the provisioning and ease management and monitoring of on-demand clusters. SequenceIQ's Cloudbreak is a RESTful application development platform with the goal of helping developers to build solutions for deploying Hadoop YARN clusters in different environments. Once it is deployed in your favourite servlet container it exposes a REST API allowing to span up Hadoop clusters of arbitary sizes and cloud providers. Provisioning Hadoop has never been easier. Cloudbreak is built on the foundation of cloud providers API (Amazon AWS, Microsoft Azure, Google Cloud Platform, Openstack), Apache Ambari, Docker lightweight containers, Swarm and Consul. For further product documentation follow the link: <a href=\"http://hortonworks.com/apache/cloudbreak/\">http://hortonworks.com/apache/cloudbreak/</a>
  
      OpenAPI spec version: 2.7.1
      
      Generated by: https://github.com/swagger-api/swagger-codegen.git
  """
  
  
  from __future__ import absolute_import
  
  import sys
  import os
  import re
  
  # python 2 and python 3 compatibility library
  from six import iteritems
  
  from ..configuration import Configuration
  from ..api_client import ApiClient
  
  
  class V1imagecatalogsApi(object):
      """
      NOTE: This class is auto generated by the swagger code generator program.
      Do not edit the class manually.
      Ref: https://github.com/swagger-api/swagger-codegen
      """
  
      def __init__(self, api_client=None):
          config = Configuration()
          if api_client:
              self.api_client = api_client
          else:
              if not config.api_client:
                  config.api_client = ApiClient()
              self.api_client = config.api_client
  
      def delete_public_image_catalog_by_name(self, name, **kwargs):
          """
          delete public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.delete_public_image_catalog_by_name(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: None
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.delete_public_image_catalog_by_name_with_http_info(name, **kwargs)
          else:
              (data) = self.delete_public_image_catalog_by_name_with_http_info(name, **kwargs)
              return data
  
      def delete_public_image_catalog_by_name_with_http_info(self, name, **kwargs):
          """
          delete public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.delete_public_image_catalog_by_name_with_http_info(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: None
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['name']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method delete_public_image_catalog_by_name" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'name' is set
          if ('name' not in params) or (params['name'] is None):
              raise ValueError("Missing the required parameter `name` when calling `delete_public_image_catalog_by_name`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'name' in params:
              path_params['name'] = params['name']
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account/{name}', 'DELETE',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type=None,
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def get_image_catalog_request_from_name(self, name, **kwargs):
          """
          retrieve imagecatalog request by imagecatalog name
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_image_catalog_request_from_name(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: ImageCatalogRequest
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.get_image_catalog_request_from_name_with_http_info(name, **kwargs)
          else:
              (data) = self.get_image_catalog_request_from_name_with_http_info(name, **kwargs)
              return data
  
      def get_image_catalog_request_from_name_with_http_info(self, name, **kwargs):
          """
          retrieve imagecatalog request by imagecatalog name
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_image_catalog_request_from_name_with_http_info(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: ImageCatalogRequest
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['name']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method get_image_catalog_request_from_name" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'name' is set
          if ('name' not in params) or (params['name'] is None):
              raise ValueError("Missing the required parameter `name` when calling `get_image_catalog_request_from_name`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'name' in params:
              path_params['name'] = params['name']
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/{name}/request', 'GET',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogRequest',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def get_images_by_provider(self, platform, **kwargs):
          """
          determines available images for the Cloudbreak version by the given provider and default image catalog url
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_images_by_provider(platform, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str platform: (required)
          :return: ImagesResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.get_images_by_provider_with_http_info(platform, **kwargs)
          else:
              (data) = self.get_images_by_provider_with_http_info(platform, **kwargs)
              return data
  
      def get_images_by_provider_with_http_info(self, platform, **kwargs):
          """
          determines available images for the Cloudbreak version by the given provider and default image catalog url
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_images_by_provider_with_http_info(platform, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str platform: (required)
          :return: ImagesResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['platform']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method get_images_by_provider" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'platform' is set
          if ('platform' not in params) or (params['platform'] is None):
              raise ValueError("Missing the required parameter `platform` when calling `get_images_by_provider`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'platform' in params:
              path_params['platform'] = params['platform']
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/{platform}', 'GET',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImagesResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def get_public_image_catalogs_by_name(self, name, **kwargs):
          """
          get custom image catalog by name
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_public_image_catalogs_by_name(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :param bool with_images:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.get_public_image_catalogs_by_name_with_http_info(name, **kwargs)
          else:
              (data) = self.get_public_image_catalogs_by_name_with_http_info(name, **kwargs)
              return data
  
      def get_public_image_catalogs_by_name_with_http_info(self, name, **kwargs):
          """
          get custom image catalog by name
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_public_image_catalogs_by_name_with_http_info(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :param bool with_images:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['name', 'with_images']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method get_public_image_catalogs_by_name" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'name' is set
          if ('name' not in params) or (params['name'] is None):
              raise ValueError("Missing the required parameter `name` when calling `get_public_image_catalogs_by_name`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'name' in params:
              path_params['name'] = params['name']
  
          query_params = []
          if 'with_images' in params:
              query_params.append(('withImages', params['with_images']))
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account/{name}', 'GET',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def get_public_images_by_provider_and_custom_image_catalog(self, name, platform, **kwargs):
          """
          determines available images for the Cloudbreak version by the given provider and given image catalog url
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_public_images_by_provider_and_custom_image_catalog(name, platform, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :param str platform: (required)
          :return: ImagesResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.get_public_images_by_provider_and_custom_image_catalog_with_http_info(name, platform, **kwargs)
          else:
              (data) = self.get_public_images_by_provider_and_custom_image_catalog_with_http_info(name, platform, **kwargs)
              return data
  
      def get_public_images_by_provider_and_custom_image_catalog_with_http_info(self, name, platform, **kwargs):
          """
          determines available images for the Cloudbreak version by the given provider and given image catalog url
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_public_images_by_provider_and_custom_image_catalog_with_http_info(name, platform, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :param str platform: (required)
          :return: ImagesResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['name', 'platform']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method get_public_images_by_provider_and_custom_image_catalog" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'name' is set
          if ('name' not in params) or (params['name'] is None):
              raise ValueError("Missing the required parameter `name` when calling `get_public_images_by_provider_and_custom_image_catalog`")
          # verify the required parameter 'platform' is set
          if ('platform' not in params) or (params['platform'] is None):
              raise ValueError("Missing the required parameter `platform` when calling `get_public_images_by_provider_and_custom_image_catalog`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'name' in params:
              path_params['name'] = params['name']
          if 'platform' in params:
              path_params['platform'] = params['platform']
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account/{name}/{platform}', 'GET',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImagesResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def get_publics_image_catalogs(self, **kwargs):
          """
          list available custom image catalogs as public resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_publics_image_catalogs(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :return: list[ImageCatalogResponse]
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.get_publics_image_catalogs_with_http_info(**kwargs)
          else:
              (data) = self.get_publics_image_catalogs_with_http_info(**kwargs)
              return data
  
      def get_publics_image_catalogs_with_http_info(self, **kwargs):
          """
          list available custom image catalogs as public resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.get_publics_image_catalogs_with_http_info(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :return: list[ImageCatalogResponse]
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = []
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method get_publics_image_catalogs" % key
                  )
              params[key] = val
          del params['kwargs']
  
          collection_formats = {}
  
          path_params = {}
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account', 'GET',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='list[ImageCatalogResponse]',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def post_private_image_catalog(self, **kwargs):
          """
          create Image Catalog as private resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.post_private_image_catalog(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param ImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.post_private_image_catalog_with_http_info(**kwargs)
          else:
              (data) = self.post_private_image_catalog_with_http_info(**kwargs)
              return data
  
      def post_private_image_catalog_with_http_info(self, **kwargs):
          """
          create Image Catalog as private resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.post_private_image_catalog_with_http_info(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param ImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['body']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method post_private_image_catalog" % key
                  )
              params[key] = val
          del params['kwargs']
  
  
          collection_formats = {}
  
          path_params = {}
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          if 'body' in params:
              body_params = params['body']
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/user', 'POST',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def post_public_image_catalog(self, **kwargs):
          """
          create Image Catalog as public resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.post_public_image_catalog(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param ImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.post_public_image_catalog_with_http_info(**kwargs)
          else:
              (data) = self.post_public_image_catalog_with_http_info(**kwargs)
              return data
  
      def post_public_image_catalog_with_http_info(self, **kwargs):
          """
          create Image Catalog as public resources
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.post_public_image_catalog_with_http_info(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param ImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['body']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method post_public_image_catalog" % key
                  )
              params[key] = val
          del params['kwargs']
  
  
          collection_formats = {}
  
          path_params = {}
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          if 'body' in params:
              body_params = params['body']
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account', 'POST',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def put_public_image_catalog(self, **kwargs):
          """
          update public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.put_public_image_catalog(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param UpdateImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.put_public_image_catalog_with_http_info(**kwargs)
          else:
              (data) = self.put_public_image_catalog_with_http_info(**kwargs)
              return data
  
      def put_public_image_catalog_with_http_info(self, **kwargs):
          """
          update public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.put_public_image_catalog_with_http_info(callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param UpdateImageCatalogRequest body:
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['body']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method put_public_image_catalog" % key
                  )
              params[key] = val
          del params['kwargs']
  
  
          collection_formats = {}
  
          path_params = {}
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          if 'body' in params:
              body_params = params['body']
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/account', 'PUT',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  
      def put_set_default_image_catalog_by_name(self, name, **kwargs):
          """
          update public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.put_set_default_image_catalog_by_name(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
          kwargs['_return_http_data_only'] = True
          if kwargs.get('callback'):
              return self.put_set_default_image_catalog_by_name_with_http_info(name, **kwargs)
          else:
              (data) = self.put_set_default_image_catalog_by_name_with_http_info(name, **kwargs)
              return data
  
      def put_set_default_image_catalog_by_name_with_http_info(self, name, **kwargs):
          """
          update public (owned) or private Image Catalog by id
          Provides an interface to determine available Virtual Machine images for the given version of Cloudbreak.
          This method makes a synchronous HTTP request by default. To make an
          asynchronous HTTP request, please define a `callback` function
          to be invoked when receiving the response.
          >>> def callback_function(response):
          >>>     pprint(response)
          >>>
          >>> thread = api.put_set_default_image_catalog_by_name_with_http_info(name, callback=callback_function)
  
          :param callback function: The callback function
              for asynchronous request. (optional)
          :param str name: (required)
          :return: ImageCatalogResponse
                   If the method is called asynchronously,
                   returns the request thread.
          """
  
          all_params = ['name']
          all_params.append('callback')
          all_params.append('_return_http_data_only')
          all_params.append('_preload_content')
          all_params.append('_request_timeout')
  
          params = locals()
          for key, val in iteritems(params['kwargs']):
              if key not in all_params:
                  raise TypeError(
                      "Got an unexpected keyword argument '%s'"
                      " to method put_set_default_image_catalog_by_name" % key
                  )
              params[key] = val
          del params['kwargs']
          # verify the required parameter 'name' is set
          if ('name' not in params) or (params['name'] is None):
              raise ValueError("Missing the required parameter `name` when calling `put_set_default_image_catalog_by_name`")
  
  
          collection_formats = {}
  
          path_params = {}
          if 'name' in params:
              path_params['name'] = params['name']
  
          query_params = []
  
          header_params = {}
  
          form_params = []
          local_var_files = {}
  
          body_params = None
          # HTTP header `Accept`
          header_params['Accept'] = self.api_client.\
              select_header_accept(['application/json'])
  
          # HTTP header `Content-Type`
          header_params['Content-Type'] = self.api_client.\
              select_header_content_type(['application/json'])
  
          # Authentication setting
          auth_settings = ['tokenAuth']
  
          return self.api_client.call_api('/v1/imagecatalogs/setdefault/{name}', 'PUT',
                                          path_params,
                                          query_params,
                                          header_params,
                                          body=body_params,
                                          post_params=form_params,
                                          files=local_var_files,
                                          response_type='ImageCatalogResponse',
                                          auth_settings=auth_settings,
                                          callback=params.get('callback'),
                                          _return_http_data_only=params.get('_return_http_data_only'),
                                          _preload_content=params.get('_preload_content', True),
                                          _request_timeout=params.get('_request_timeout'),
                                          collection_formats=collection_formats)
  