diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 782121f..f3b7ba9 100755 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -13,6 +13,9 @@ regula/facesdk/webclient/gen/apis/__init__.py regula/facesdk/webclient/gen/configuration.py regula/facesdk/webclient/gen/exceptions.py regula/facesdk/webclient/gen/model/__init__.py +regula/facesdk/webclient/gen/model/add_image_to_person_request.py +regula/facesdk/webclient/gen/model/add_image_to_person_request_image.py +regula/facesdk/webclient/gen/model/add_image_to_person_response.py regula/facesdk/webclient/gen/model/attribute_config.py regula/facesdk/webclient/gen/model/attribute_config_list.py regula/facesdk/webclient/gen/model/crop.py @@ -40,10 +43,10 @@ regula/facesdk/webclient/gen/model/group.py regula/facesdk/webclient/gen/model/group_all_of.py regula/facesdk/webclient/gen/model/group_page.py regula/facesdk/webclient/gen/model/group_page_all_of.py +regula/facesdk/webclient/gen/model/group_response.py regula/facesdk/webclient/gen/model/group_to_create.py regula/facesdk/webclient/gen/model/image.py regula/facesdk/webclient/gen/model/image_fields.py -regula/facesdk/webclient/gen/model/image_fields_image.py regula/facesdk/webclient/gen/model/image_page.py regula/facesdk/webclient/gen/model/image_page_all_of.py regula/facesdk/webclient/gen/model/image_source.py @@ -67,6 +70,7 @@ regula/facesdk/webclient/gen/model/page.py regula/facesdk/webclient/gen/model/person.py regula/facesdk/webclient/gen/model/person_all_of.py regula/facesdk/webclient/gen/model/person_fields.py +regula/facesdk/webclient/gen/model/person_to_update_fields.py regula/facesdk/webclient/gen/model/person_with_images.py regula/facesdk/webclient/gen/model/person_with_images_all_of.py regula/facesdk/webclient/gen/model/persons_page.py diff --git a/regula/facesdk/webclient/gen/api/group_api.py b/regula/facesdk/webclient/gen/api/group_api.py index 9e4907c..dd721e7 100644 --- a/regula/facesdk/webclient/gen/api/group_api.py +++ b/regula/facesdk/webclient/gen/api/group_api.py @@ -312,18 +312,18 @@ def delete_group_with_http_info(self, group_id, **kwargs): # noqa: E501 collection_formats=collection_formats, _request_auth=local_var_params.get('_request_auth')) - def get_all_groups(self, page, size, **kwargs): # noqa: E501 + def get_all_groups(self, **kwargs): # noqa: E501 """Get groups # 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_all_groups(page, size, async_req=True) + >>> thread = api.get_all_groups(async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) + :param page: The page number to get a list of persons or groups. :type page: int - :param size: The page size with a list of persons or groups, items. (required) + :param size: The page size with a list of persons or groups, items. :type size: int :param x_request_id: Request header label. :type x_request_id: str @@ -343,20 +343,20 @@ def get_all_groups(self, page, size, **kwargs): # noqa: E501 :rtype: GroupPage """ kwargs['_return_http_data_only'] = True - return self.get_all_groups_with_http_info(page, size, **kwargs) # noqa: E501 + return self.get_all_groups_with_http_info(**kwargs) # noqa: E501 - def get_all_groups_with_http_info(self, page, size, **kwargs): # noqa: E501 + def get_all_groups_with_http_info(self, **kwargs): # noqa: E501 """Get groups # 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_all_groups_with_http_info(page, size, async_req=True) + >>> thread = api.get_all_groups_with_http_info(async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) + :param page: The page number to get a list of persons or groups. :type page: int - :param size: The page size with a list of persons or groups, items. (required) + :param size: The page size with a list of persons or groups, items. :type size: int :param x_request_id: Request header label. :type x_request_id: str @@ -408,14 +408,6 @@ def get_all_groups_with_http_info(self, page, size, **kwargs): # noqa: E501 ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'page' is set - if self.api_client.client_side_validation and ('page' not in local_var_params or # noqa: E501 - local_var_params['page'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `page` when calling `get_all_groups`") # noqa: E501 - # verify the required parameter 'size' is set - if self.api_client.client_side_validation and ('size' not in local_var_params or # noqa: E501 - local_var_params['size'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `size` when calling `get_all_groups`") # noqa: E501 collection_formats = {} @@ -459,21 +451,21 @@ def get_all_groups_with_http_info(self, page, size, **kwargs): # noqa: E501 collection_formats=collection_formats, _request_auth=local_var_params.get('_request_auth')) - def get_all_persons_by_group_id(self, page, size, group_id, **kwargs): # noqa: E501 + def get_all_persons_by_group_id(self, group_id, **kwargs): # noqa: E501 """Get group persons # 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_all_persons_by_group_id(page, size, group_id, async_req=True) + >>> thread = api.get_all_persons_by_group_id(group_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param group_id: Group ID. (required) :type group_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -492,23 +484,23 @@ def get_all_persons_by_group_id(self, page, size, group_id, **kwargs): # noqa: :rtype: PersonsPage """ kwargs['_return_http_data_only'] = True - return self.get_all_persons_by_group_id_with_http_info(page, size, group_id, **kwargs) # noqa: E501 + return self.get_all_persons_by_group_id_with_http_info(group_id, **kwargs) # noqa: E501 - def get_all_persons_by_group_id_with_http_info(self, page, size, group_id, **kwargs): # noqa: E501 + def get_all_persons_by_group_id_with_http_info(self, group_id, **kwargs): # noqa: E501 """Get group persons # 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_all_persons_by_group_id_with_http_info(page, size, group_id, async_req=True) + >>> thread = api.get_all_persons_by_group_id_with_http_info(group_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param group_id: Group ID. (required) :type group_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -537,9 +529,9 @@ def get_all_persons_by_group_id_with_http_info(self, page, size, group_id, **kwa local_var_params = locals() all_params = [ + 'group_id' 'page' 'size' - 'group_id' 'x_request_id' ] all_params.extend( @@ -560,14 +552,6 @@ def get_all_persons_by_group_id_with_http_info(self, page, size, group_id, **kwa ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'page' is set - if self.api_client.client_side_validation and ('page' not in local_var_params or # noqa: E501 - local_var_params['page'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `page` when calling `get_all_persons_by_group_id`") # noqa: E501 - # verify the required parameter 'size' is set - if self.api_client.client_side_validation and ('size' not in local_var_params or # noqa: E501 - local_var_params['size'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `size` when calling `get_all_persons_by_group_id`") # noqa: E501 # verify the required parameter 'group_id' is set if self.api_client.client_side_validation and ('group_id' not in local_var_params or # noqa: E501 local_var_params['group_id'] is None): # noqa: E501 diff --git a/regula/facesdk/webclient/gen/api/person_api.py b/regula/facesdk/webclient/gen/api/person_api.py index 6b5b2d3..a9a7283 100644 --- a/regula/facesdk/webclient/gen/api/person_api.py +++ b/regula/facesdk/webclient/gen/api/person_api.py @@ -36,19 +36,19 @@ def __init__(self, api_client=None): api_client = ApiClient() self.api_client = api_client - def add_image_to_person(self, person_id, image_fields, **kwargs): # noqa: E501 + def add_image_to_person(self, person_id, add_image_to_person_request, **kwargs): # noqa: E501 """Add person image # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_image_to_person(person_id, image_fields, async_req=True) + >>> thread = api.add_image_to_person(person_id, add_image_to_person_request, async_req=True) >>> result = thread.get() :param person_id: Person ID. (required) :type person_id: str - :param image_fields: Image to add. (required) - :type image_fields: ImageFields + :param add_image_to_person_request: Image to add. (required) + :type add_image_to_person_request: AddImageToPersonRequest :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -64,24 +64,24 @@ def add_image_to_person(self, person_id, image_fields, **kwargs): # noqa: E501 :return: Returns the result object. If the method is called asynchronously, returns the request thread. - :rtype: Image + :rtype: AddImageToPersonResponse """ kwargs['_return_http_data_only'] = True - return self.add_image_to_person_with_http_info(person_id, image_fields, **kwargs) # noqa: E501 + return self.add_image_to_person_with_http_info(person_id, add_image_to_person_request, **kwargs) # noqa: E501 - def add_image_to_person_with_http_info(self, person_id, image_fields, **kwargs): # noqa: E501 + def add_image_to_person_with_http_info(self, person_id, add_image_to_person_request, **kwargs): # noqa: E501 """Add person image # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_image_to_person_with_http_info(person_id, image_fields, async_req=True) + >>> thread = api.add_image_to_person_with_http_info(person_id, add_image_to_person_request, async_req=True) >>> result = thread.get() :param person_id: Person ID. (required) :type person_id: str - :param image_fields: Image to add. (required) - :type image_fields: ImageFields + :param add_image_to_person_request: Image to add. (required) + :type add_image_to_person_request: AddImageToPersonRequest :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -104,14 +104,14 @@ def add_image_to_person_with_http_info(self, person_id, image_fields, **kwargs): :return: Returns the result object. If the method is called asynchronously, returns the request thread. - :rtype: tuple(Image, status_code(int), headers(HTTPHeaderDict)) + :rtype: tuple(AddImageToPersonResponse, status_code(int), headers(HTTPHeaderDict)) """ local_var_params = locals() all_params = [ 'person_id' - 'image_fields' + 'add_image_to_person_request' 'x_request_id' ] all_params.extend( @@ -136,10 +136,10 @@ def add_image_to_person_with_http_info(self, person_id, image_fields, **kwargs): if self.api_client.client_side_validation and ('person_id' not in local_var_params or # noqa: E501 local_var_params['person_id'] is None): # noqa: E501 raise ApiValueError("Missing the required parameter `person_id` when calling `add_image_to_person`") # noqa: E501 - # verify the required parameter 'image_fields' is set - if self.api_client.client_side_validation and ('image_fields' not in local_var_params or # noqa: E501 - local_var_params['image_fields'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `image_fields` when calling `add_image_to_person`") # noqa: E501 + # verify the required parameter 'add_image_to_person_request' is set + if self.api_client.client_side_validation and ('add_image_to_person_request' not in local_var_params or # noqa: E501 + local_var_params['add_image_to_person_request'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `add_image_to_person_request` when calling `add_image_to_person`") # noqa: E501 collection_formats = {} @@ -157,8 +157,8 @@ def add_image_to_person_with_http_info(self, person_id, image_fields, **kwargs): local_var_files = {} body_params = None - if 'image_fields' in local_var_params: - body_params = local_var_params['image_fields'] + if 'add_image_to_person_request' in local_var_params: + body_params = local_var_params['add_image_to_person_request'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json']) # noqa: E501 @@ -178,7 +178,7 @@ def add_image_to_person_with_http_info(self, person_id, image_fields, **kwargs): body=body_params, post_params=form_params, files=local_var_files, - response_type='Image', # noqa: E501 + response_type='AddImageToPersonResponse', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -610,21 +610,21 @@ def delete_person_with_http_info(self, person_id, **kwargs): # noqa: E501 collection_formats=collection_formats, _request_auth=local_var_params.get('_request_auth')) - def get_all_groups_by_person_id(self, page, size, person_id, **kwargs): # noqa: E501 + def get_all_groups_by_person_id(self, person_id, **kwargs): # noqa: E501 """Get person groups # 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_all_groups_by_person_id(page, size, person_id, async_req=True) + >>> thread = api.get_all_groups_by_person_id(person_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param person_id: Person ID. (required) :type person_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -643,23 +643,23 @@ def get_all_groups_by_person_id(self, page, size, person_id, **kwargs): # noqa: :rtype: GroupPage """ kwargs['_return_http_data_only'] = True - return self.get_all_groups_by_person_id_with_http_info(page, size, person_id, **kwargs) # noqa: E501 + return self.get_all_groups_by_person_id_with_http_info(person_id, **kwargs) # noqa: E501 - def get_all_groups_by_person_id_with_http_info(self, page, size, person_id, **kwargs): # noqa: E501 + def get_all_groups_by_person_id_with_http_info(self, person_id, **kwargs): # noqa: E501 """Get person groups # 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_all_groups_by_person_id_with_http_info(page, size, person_id, async_req=True) + >>> thread = api.get_all_groups_by_person_id_with_http_info(person_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param person_id: Person ID. (required) :type person_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -688,9 +688,9 @@ def get_all_groups_by_person_id_with_http_info(self, page, size, person_id, **kw local_var_params = locals() all_params = [ + 'person_id' 'page' 'size' - 'person_id' 'x_request_id' ] all_params.extend( @@ -711,14 +711,6 @@ def get_all_groups_by_person_id_with_http_info(self, page, size, person_id, **kw ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'page' is set - if self.api_client.client_side_validation and ('page' not in local_var_params or # noqa: E501 - local_var_params['page'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `page` when calling `get_all_groups_by_person_id`") # noqa: E501 - # verify the required parameter 'size' is set - if self.api_client.client_side_validation and ('size' not in local_var_params or # noqa: E501 - local_var_params['size'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `size` when calling `get_all_groups_by_person_id`") # noqa: E501 # verify the required parameter 'person_id' is set if self.api_client.client_side_validation and ('person_id' not in local_var_params or # noqa: E501 local_var_params['person_id'] is None): # noqa: E501 @@ -768,21 +760,21 @@ def get_all_groups_by_person_id_with_http_info(self, page, size, person_id, **kw collection_formats=collection_formats, _request_auth=local_var_params.get('_request_auth')) - def get_all_images_by_person_id(self, page, size, person_id, **kwargs): # noqa: E501 + def get_all_images_by_person_id(self, person_id, **kwargs): # noqa: E501 """Get person images # 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_all_images_by_person_id(page, size, person_id, async_req=True) + >>> thread = api.get_all_images_by_person_id(person_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param person_id: Person ID. (required) :type person_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -801,23 +793,23 @@ def get_all_images_by_person_id(self, page, size, person_id, **kwargs): # noqa: :rtype: ImagePage """ kwargs['_return_http_data_only'] = True - return self.get_all_images_by_person_id_with_http_info(page, size, person_id, **kwargs) # noqa: E501 + return self.get_all_images_by_person_id_with_http_info(person_id, **kwargs) # noqa: E501 - def get_all_images_by_person_id_with_http_info(self, page, size, person_id, **kwargs): # noqa: E501 + def get_all_images_by_person_id_with_http_info(self, person_id, **kwargs): # noqa: E501 """Get person images # 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_all_images_by_person_id_with_http_info(page, size, person_id, async_req=True) + >>> thread = api.get_all_images_by_person_id_with_http_info(person_id, async_req=True) >>> result = thread.get() - :param page: The page number to get a list of persons or groups. (required) - :type page: int - :param size: The page size with a list of persons or groups, items. (required) - :type size: int :param person_id: Person ID. (required) :type person_id: str + :param page: The page number to get a list of persons or groups. + :type page: int + :param size: The page size with a list of persons or groups, items. + :type size: int :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -846,9 +838,9 @@ def get_all_images_by_person_id_with_http_info(self, page, size, person_id, **kw local_var_params = locals() all_params = [ + 'person_id' 'page' 'size' - 'person_id' 'x_request_id' ] all_params.extend( @@ -869,14 +861,6 @@ def get_all_images_by_person_id_with_http_info(self, page, size, person_id, **kw ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'page' is set - if self.api_client.client_side_validation and ('page' not in local_var_params or # noqa: E501 - local_var_params['page'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `page` when calling `get_all_images_by_person_id`") # noqa: E501 - # verify the required parameter 'size' is set - if self.api_client.client_side_validation and ('size' not in local_var_params or # noqa: E501 - local_var_params['size'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `size` when calling `get_all_images_by_person_id`") # noqa: E501 # verify the required parameter 'person_id' is set if self.api_client.client_side_validation and ('person_id' not in local_var_params or # noqa: E501 local_var_params['person_id'] is None): # noqa: E501 @@ -1209,19 +1193,19 @@ def get_person_with_http_info(self, person_id, **kwargs): # noqa: E501 collection_formats=collection_formats, _request_auth=local_var_params.get('_request_auth')) - def update_person(self, person_id, person_fields, **kwargs): # noqa: E501 + def update_person(self, person_id, person_to_update_fields, **kwargs): # noqa: E501 """Update person # 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_person(person_id, person_fields, async_req=True) + >>> thread = api.update_person(person_id, person_to_update_fields, async_req=True) >>> result = thread.get() :param person_id: Person ID. (required) :type person_id: str - :param person_fields: Request body for the Person to update. (required) - :type person_fields: PersonFields + :param person_to_update_fields: Request body for the Person to update. (required) + :type person_to_update_fields: PersonToUpdateFields :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -1240,21 +1224,21 @@ def update_person(self, person_id, person_fields, **kwargs): # noqa: E501 :rtype: None """ kwargs['_return_http_data_only'] = True - return self.update_person_with_http_info(person_id, person_fields, **kwargs) # noqa: E501 + return self.update_person_with_http_info(person_id, person_to_update_fields, **kwargs) # noqa: E501 - def update_person_with_http_info(self, person_id, person_fields, **kwargs): # noqa: E501 + def update_person_with_http_info(self, person_id, person_to_update_fields, **kwargs): # noqa: E501 """Update person # 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_person_with_http_info(person_id, person_fields, async_req=True) + >>> thread = api.update_person_with_http_info(person_id, person_to_update_fields, async_req=True) >>> result = thread.get() :param person_id: Person ID. (required) :type person_id: str - :param person_fields: Request body for the Person to update. (required) - :type person_fields: PersonFields + :param person_to_update_fields: Request body for the Person to update. (required) + :type person_to_update_fields: PersonToUpdateFields :param x_request_id: Request header label. :type x_request_id: str :param async_req: Whether to execute the request asynchronously. @@ -1284,7 +1268,7 @@ def update_person_with_http_info(self, person_id, person_fields, **kwargs): # n all_params = [ 'person_id' - 'person_fields' + 'person_to_update_fields' 'x_request_id' ] all_params.extend( @@ -1309,10 +1293,10 @@ def update_person_with_http_info(self, person_id, person_fields, **kwargs): # n if self.api_client.client_side_validation and ('person_id' not in local_var_params or # noqa: E501 local_var_params['person_id'] is None): # noqa: E501 raise ApiValueError("Missing the required parameter `person_id` when calling `update_person`") # noqa: E501 - # verify the required parameter 'person_fields' is set - if self.api_client.client_side_validation and ('person_fields' not in local_var_params or # noqa: E501 - local_var_params['person_fields'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `person_fields` when calling `update_person`") # noqa: E501 + # verify the required parameter 'person_to_update_fields' is set + if self.api_client.client_side_validation and ('person_to_update_fields' not in local_var_params or # noqa: E501 + local_var_params['person_to_update_fields'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `person_to_update_fields` when calling `update_person`") # noqa: E501 collection_formats = {} @@ -1330,8 +1314,8 @@ def update_person_with_http_info(self, person_id, person_fields, **kwargs): # n local_var_files = {} body_params = None - if 'person_fields' in local_var_params: - body_params = local_var_params['person_fields'] + if 'person_to_update_fields' in local_var_params: + body_params = local_var_params['person_to_update_fields'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json']) # noqa: E501 diff --git a/regula/facesdk/webclient/gen/model/add_image_to_person_request.py b/regula/facesdk/webclient/gen/model/add_image_to_person_request.py new file mode 100644 index 0000000..410a653 --- /dev/null +++ b/regula/facesdk/webclient/gen/model/add_image_to_person_request.py @@ -0,0 +1,205 @@ +# coding: utf-8 + +""" + Regula FaceSDK Web API + + [Download OpenAPI specification](https://github.com/regulaforensics/FaceSDK-web-openapi) ### Clients * [JavaScript](https://github.com/regulaforensics/FaceSDK-web-js-client) client for the browser and node.js based on axios * [Java](https://github.com/regulaforensics/FaceSDK-web-java-client) client compatible with jvm and android * [Python](https://github.com/regulaforensics/FaceSDK-web-python-client) 3.5+ client * [C#](https://github.com/regulaforensics/FaceSDK-web-csharp-client) client for .NET & .NET Core # noqa: E501 + + The version of the OpenAPI document: 6.1.0 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from regula.facesdk.webclient.gen.configuration import Configuration + + +class AddImageToPersonRequest(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'tag': 'str', + 'image': 'AddImageToPersonRequestImage', + 'threshold': 'float', + 'limit': 'int', + } + + attribute_map = { + 'tag': 'tag', + 'image': 'image', + 'threshold': 'threshold', + 'limit': 'limit', + } + + def __init__(self, tag=None, image=None, threshold=None, limit=None, local_vars_configuration=None): # noqa: E501 + """AddImageToPersonRequest - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._tag = None + self._image = None + self._threshold = None + self._limit = None + self.discriminator = None + + if tag is not None: + self.tag = tag + self.image = image + if threshold is not None: + self.threshold = threshold + if limit is not None: + self.limit = limit + + @property + def tag(self): + """Gets the tag of this AddImageToPersonRequest. # noqa: E501 + + Session identificator. # noqa: E501 + + :return: The tag of this AddImageToPersonRequest. # noqa: E501 + :rtype: str + """ + return self._tag + + @tag.setter + def tag(self, tag): + """Sets the tag of this AddImageToPersonRequest. + + Session identificator. # noqa: E501 + + :param tag: The tag of this AddImageToPersonRequest. # noqa: E501 + :type tag: str + """ + + self._tag = tag + + @property + def image(self): + """Gets the image of this AddImageToPersonRequest. # noqa: E501 + + + :return: The image of this AddImageToPersonRequest. # noqa: E501 + :rtype: AddImageToPersonRequestImage + """ + return self._image + + @image.setter + def image(self, image): + """Sets the image of this AddImageToPersonRequest. + + + :param image: The image of this AddImageToPersonRequest. # noqa: E501 + :type image: AddImageToPersonRequestImage + """ + if self.local_vars_configuration.client_side_validation and image is None: # noqa: E501 + raise ValueError("Invalid value for `image`, must not be `None`") # noqa: E501 + + self._image = image + + @property + def threshold(self): + """Gets the threshold of this AddImageToPersonRequest. # noqa: E501 + + The similarity threshold. # noqa: E501 + + :return: The threshold of this AddImageToPersonRequest. # noqa: E501 + :rtype: float + """ + return self._threshold + + @threshold.setter + def threshold(self, threshold): + """Sets the threshold of this AddImageToPersonRequest. + + The similarity threshold. # noqa: E501 + + :param threshold: The threshold of this AddImageToPersonRequest. # noqa: E501 + :type threshold: float + """ + + self._threshold = threshold + + @property + def limit(self): + """Gets the limit of this AddImageToPersonRequest. # noqa: E501 + + The maximum number of results to be returned. # noqa: E501 + + :return: The limit of this AddImageToPersonRequest. # noqa: E501 + :rtype: int + """ + return self._limit + + @limit.setter + def limit(self, limit): + """Sets the limit of this AddImageToPersonRequest. + + The maximum number of results to be returned. # noqa: E501 + + :param limit: The limit of this AddImageToPersonRequest. # noqa: E501 + :type limit: int + """ + + self._limit = limit + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, AddImageToPersonRequest): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, AddImageToPersonRequest): + return True + + return self.to_dict() != other.to_dict() diff --git a/regula/facesdk/webclient/gen/model/add_image_to_person_request_image.py b/regula/facesdk/webclient/gen/model/add_image_to_person_request_image.py new file mode 100644 index 0000000..f69fbee --- /dev/null +++ b/regula/facesdk/webclient/gen/model/add_image_to_person_request_image.py @@ -0,0 +1,204 @@ +# coding: utf-8 + +""" + Regula FaceSDK Web API + + [Download OpenAPI specification](https://github.com/regulaforensics/FaceSDK-web-openapi) ### Clients * [JavaScript](https://github.com/regulaforensics/FaceSDK-web-js-client) client for the browser and node.js based on axios * [Java](https://github.com/regulaforensics/FaceSDK-web-java-client) client compatible with jvm and android * [Python](https://github.com/regulaforensics/FaceSDK-web-python-client) 3.5+ client * [C#](https://github.com/regulaforensics/FaceSDK-web-csharp-client) client for .NET & .NET Core # noqa: E501 + + The version of the OpenAPI document: 6.1.0 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from regula.facesdk.webclient.gen.configuration import Configuration + + +class AddImageToPersonRequestImage(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'content_type': 'str', + 'content': 'str', + 'image_url': 'str', + 'resize_options': 'ResizeOptions', + } + + attribute_map = { + 'content_type': 'contentType', + 'content': 'content', + 'image_url': 'imageUrl', + 'resize_options': 'resizeOptions', + } + + def __init__(self, content_type=None, content=None, image_url=None, resize_options=None, local_vars_configuration=None): # noqa: E501 + """AddImageToPersonRequestImage - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._content_type = None + self._content = None + self._image_url = None + self._resize_options = None + self.discriminator = None + + if content_type is not None: + self.content_type = content_type + if content is not None: + self.content = content + if image_url is not None: + self.image_url = image_url + if resize_options is not None: + self.resize_options = resize_options + + @property + def content_type(self): + """Gets the content_type of this AddImageToPersonRequestImage. # noqa: E501 + + Original media type of the uploaded image. # noqa: E501 + + :return: The content_type of this AddImageToPersonRequestImage. # noqa: E501 + :rtype: str + """ + return self._content_type + + @content_type.setter + def content_type(self, content_type): + """Sets the content_type of this AddImageToPersonRequestImage. + + Original media type of the uploaded image. # noqa: E501 + + :param content_type: The content_type of this AddImageToPersonRequestImage. # noqa: E501 + :type content_type: str + """ + + self._content_type = content_type + + @property + def content(self): + """Gets the content of this AddImageToPersonRequestImage. # noqa: E501 + + Base64 encoded image. # noqa: E501 + + :return: The content of this AddImageToPersonRequestImage. # noqa: E501 + :rtype: str + """ + return self._content + + @content.setter + def content(self, content): + """Sets the content of this AddImageToPersonRequestImage. + + Base64 encoded image. # noqa: E501 + + :param content: The content of this AddImageToPersonRequestImage. # noqa: E501 + :type content: str + """ + + self._content = content + + @property + def image_url(self): + """Gets the image_url of this AddImageToPersonRequestImage. # noqa: E501 + + Image URL. # noqa: E501 + + :return: The image_url of this AddImageToPersonRequestImage. # noqa: E501 + :rtype: str + """ + return self._image_url + + @image_url.setter + def image_url(self, image_url): + """Sets the image_url of this AddImageToPersonRequestImage. + + Image URL. # noqa: E501 + + :param image_url: The image_url of this AddImageToPersonRequestImage. # noqa: E501 + :type image_url: str + """ + + self._image_url = image_url + + @property + def resize_options(self): + """Gets the resize_options of this AddImageToPersonRequestImage. # noqa: E501 + + + :return: The resize_options of this AddImageToPersonRequestImage. # noqa: E501 + :rtype: ResizeOptions + """ + return self._resize_options + + @resize_options.setter + def resize_options(self, resize_options): + """Sets the resize_options of this AddImageToPersonRequestImage. + + + :param resize_options: The resize_options of this AddImageToPersonRequestImage. # noqa: E501 + :type resize_options: ResizeOptions + """ + + self._resize_options = resize_options + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, AddImageToPersonRequestImage): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, AddImageToPersonRequestImage): + return True + + return self.to_dict() != other.to_dict() diff --git a/regula/facesdk/webclient/gen/model/add_image_to_person_response.py b/regula/facesdk/webclient/gen/model/add_image_to_person_response.py new file mode 100644 index 0000000..e1ea4fd --- /dev/null +++ b/regula/facesdk/webclient/gen/model/add_image_to_person_response.py @@ -0,0 +1,262 @@ +# coding: utf-8 + +""" + Regula FaceSDK Web API + + [Download OpenAPI specification](https://github.com/regulaforensics/FaceSDK-web-openapi) ### Clients * [JavaScript](https://github.com/regulaforensics/FaceSDK-web-js-client) client for the browser and node.js based on axios * [Java](https://github.com/regulaforensics/FaceSDK-web-java-client) client compatible with jvm and android * [Python](https://github.com/regulaforensics/FaceSDK-web-python-client) 3.5+ client * [C#](https://github.com/regulaforensics/FaceSDK-web-csharp-client) client for .NET & .NET Core # noqa: E501 + + The version of the OpenAPI document: 6.1.0 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from regula.facesdk.webclient.gen.configuration import Configuration + + +class AddImageToPersonResponse(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'id': 'str', + 'content_type': 'str', + 'created_at': 'str', + 'path': 'str', + 'url': 'str', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', + } + + attribute_map = { + 'id': 'id', + 'content_type': 'contentType', + 'created_at': 'createdAt', + 'path': 'path', + 'url': 'url', + 'metadata': 'metadata', + } + + def __init__(self, id=None, content_type=None, created_at=None, path=None, url=None, metadata=None, local_vars_configuration=None): # noqa: E501 + """AddImageToPersonResponse - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._id = None + self._content_type = None + self._created_at = None + self._path = None + self._url = None + self._metadata = None + self.discriminator = None + + if id is not None: + self.id = id + if content_type is not None: + self.content_type = content_type + if created_at is not None: + self.created_at = created_at + if path is not None: + self.path = path + if url is not None: + self.url = url + if metadata is not None: + self.metadata = metadata + + @property + def id(self): + """Gets the id of this AddImageToPersonResponse. # noqa: E501 + + Response image ID. The list is sorted by decreasing ID value. # noqa: E501 + + :return: The id of this AddImageToPersonResponse. # noqa: E501 + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """Sets the id of this AddImageToPersonResponse. + + Response image ID. The list is sorted by decreasing ID value. # noqa: E501 + + :param id: The id of this AddImageToPersonResponse. # noqa: E501 + :type id: str + """ + + self._id = id + + @property + def content_type(self): + """Gets the content_type of this AddImageToPersonResponse. # noqa: E501 + + Original media type of the returned image. # noqa: E501 + + :return: The content_type of this AddImageToPersonResponse. # noqa: E501 + :rtype: str + """ + return self._content_type + + @content_type.setter + def content_type(self, content_type): + """Sets the content_type of this AddImageToPersonResponse. + + Original media type of the returned image. # noqa: E501 + + :param content_type: The content_type of this AddImageToPersonResponse. # noqa: E501 + :type content_type: str + """ + + self._content_type = content_type + + @property + def created_at(self): + """Gets the created_at of this AddImageToPersonResponse. # noqa: E501 + + Returned image creation date. # noqa: E501 + + :return: The created_at of this AddImageToPersonResponse. # noqa: E501 + :rtype: str + """ + return self._created_at + + @created_at.setter + def created_at(self, created_at): + """Sets the created_at of this AddImageToPersonResponse. + + Returned image creation date. # noqa: E501 + + :param created_at: The created_at of this AddImageToPersonResponse. # noqa: E501 + :type created_at: str + """ + + self._created_at = created_at + + @property + def path(self): + """Gets the path of this AddImageToPersonResponse. # noqa: E501 + + Returned image path. # noqa: E501 + + :return: The path of this AddImageToPersonResponse. # noqa: E501 + :rtype: str + """ + return self._path + + @path.setter + def path(self, path): + """Sets the path of this AddImageToPersonResponse. + + Returned image path. # noqa: E501 + + :param path: The path of this AddImageToPersonResponse. # noqa: E501 + :type path: str + """ + + self._path = path + + @property + def url(self): + """Gets the url of this AddImageToPersonResponse. # noqa: E501 + + Returned image URL. # noqa: E501 + + :return: The url of this AddImageToPersonResponse. # noqa: E501 + :rtype: str + """ + return self._url + + @url.setter + def url(self, url): + """Sets the url of this AddImageToPersonResponse. + + Returned image URL. # noqa: E501 + + :param url: The url of this AddImageToPersonResponse. # noqa: E501 + :type url: str + """ + + self._url = url + + @property + def metadata(self): + """Gets the metadata of this AddImageToPersonResponse. # noqa: E501 + + A free-form object containing person's extended attributes. # noqa: E501 + + :return: The metadata of this AddImageToPersonResponse. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this AddImageToPersonResponse. + + A free-form object containing person's extended attributes. # noqa: E501 + + :param metadata: The metadata of this AddImageToPersonResponse. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, AddImageToPersonResponse): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, AddImageToPersonResponse): + return True + + return self.to_dict() != other.to_dict() diff --git a/regula/facesdk/webclient/gen/model/group.py b/regula/facesdk/webclient/gen/model/group.py index c3a995d..85280ce 100644 --- a/regula/facesdk/webclient/gen/model/group.py +++ b/regula/facesdk/webclient/gen/model/group.py @@ -33,7 +33,6 @@ class Group(object): and the value is json key in definition. """ openapi_types = { - 'tag': 'str', 'name': 'str', 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', 'id': 'str', @@ -41,28 +40,24 @@ class Group(object): } attribute_map = { - 'tag': 'tag', 'name': 'name', 'metadata': 'metadata', 'id': 'id', 'created_at': 'createdAt', } - def __init__(self, tag=None, name=None, metadata=None, id=None, created_at=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, name=None, metadata=None, id=None, created_at=None, local_vars_configuration=None): # noqa: E501 """Group - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration - self._tag = None self._name = None self._metadata = None self._id = None self._created_at = None self.discriminator = None - if tag is not None: - self.tag = tag if name is not None: self.name = name if metadata is not None: @@ -72,29 +67,6 @@ def __init__(self, tag=None, name=None, metadata=None, id=None, created_at=None, if created_at is not None: self.created_at = created_at - @property - def tag(self): - """Gets the tag of this Group. # noqa: E501 - - Session identificator. # noqa: E501 - - :return: The tag of this Group. # noqa: E501 - :rtype: str - """ - return self._tag - - @tag.setter - def tag(self, tag): - """Sets the tag of this Group. - - Session identificator. # noqa: E501 - - :param tag: The tag of this Group. # noqa: E501 - :type tag: str - """ - - self._tag = tag - @property def name(self): """Gets the name of this Group. # noqa: E501 diff --git a/regula/facesdk/webclient/gen/model/group_response.py b/regula/facesdk/webclient/gen/model/group_response.py new file mode 100644 index 0000000..77eee22 --- /dev/null +++ b/regula/facesdk/webclient/gen/model/group_response.py @@ -0,0 +1,150 @@ +# coding: utf-8 + +""" + Regula FaceSDK Web API + + [Download OpenAPI specification](https://github.com/regulaforensics/FaceSDK-web-openapi) ### Clients * [JavaScript](https://github.com/regulaforensics/FaceSDK-web-js-client) client for the browser and node.js based on axios * [Java](https://github.com/regulaforensics/FaceSDK-web-java-client) client compatible with jvm and android * [Python](https://github.com/regulaforensics/FaceSDK-web-python-client) 3.5+ client * [C#](https://github.com/regulaforensics/FaceSDK-web-csharp-client) client for .NET & .NET Core # noqa: E501 + + The version of the OpenAPI document: 6.1.0 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from regula.facesdk.webclient.gen.configuration import Configuration + + +class GroupResponse(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'name': 'str', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', + } + + attribute_map = { + 'name': 'name', + 'metadata': 'metadata', + } + + def __init__(self, name=None, metadata=None, local_vars_configuration=None): # noqa: E501 + """GroupResponse - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._name = None + self._metadata = None + self.discriminator = None + + if name is not None: + self.name = name + if metadata is not None: + self.metadata = metadata + + @property + def name(self): + """Gets the name of this GroupResponse. # noqa: E501 + + Group to create name. # noqa: E501 + + :return: The name of this GroupResponse. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this GroupResponse. + + Group to create name. # noqa: E501 + + :param name: The name of this GroupResponse. # noqa: E501 + :type name: str + """ + + self._name = name + + @property + def metadata(self): + """Gets the metadata of this GroupResponse. # noqa: E501 + + A free-form object containing group's extended attributes. # noqa: E501 + + :return: The metadata of this GroupResponse. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this GroupResponse. + + A free-form object containing group's extended attributes. # noqa: E501 + + :param metadata: The metadata of this GroupResponse. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, GroupResponse): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, GroupResponse): + return True + + return self.to_dict() != other.to_dict() diff --git a/regula/facesdk/webclient/gen/model/group_to_create.py b/regula/facesdk/webclient/gen/model/group_to_create.py index 114c035..8d2b546 100644 --- a/regula/facesdk/webclient/gen/model/group_to_create.py +++ b/regula/facesdk/webclient/gen/model/group_to_create.py @@ -57,10 +57,8 @@ def __init__(self, tag=None, name=None, metadata=None, local_vars_configuration= if tag is not None: self.tag = tag - if name is not None: - self.name = name - if metadata is not None: - self.metadata = metadata + self.name = name + self.metadata = metadata @property def tag(self): @@ -105,6 +103,8 @@ def name(self, name): :param name: The name of this GroupToCreate. # noqa: E501 :type name: str """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 self._name = name @@ -128,6 +128,8 @@ def metadata(self, metadata): :param metadata: The metadata of this GroupToCreate. # noqa: E501 :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} """ + if self.local_vars_configuration.client_side_validation and metadata is None: # noqa: E501 + raise ValueError("Invalid value for `metadata`, must not be `None`") # noqa: E501 self._metadata = metadata diff --git a/regula/facesdk/webclient/gen/model/image_fields.py b/regula/facesdk/webclient/gen/model/image_fields.py index 01d75ef..3eead2d 100644 --- a/regula/facesdk/webclient/gen/model/image_fields.py +++ b/regula/facesdk/webclient/gen/model/image_fields.py @@ -34,7 +34,7 @@ class ImageFields(object): """ openapi_types = { 'tag': 'str', - 'image': 'ImageFieldsImage', + 'image': 'AddImageToPersonRequestImage', 'output_image_params': 'OutputImageParams', 'detect_all': 'bool', 'threshold': 'float', @@ -106,7 +106,7 @@ def image(self): :return: The image of this ImageFields. # noqa: E501 - :rtype: ImageFieldsImage + :rtype: AddImageToPersonRequestImage """ return self._image @@ -116,7 +116,7 @@ def image(self, image): :param image: The image of this ImageFields. # noqa: E501 - :type image: ImageFieldsImage + :type image: AddImageToPersonRequestImage """ self._image = image diff --git a/regula/facesdk/webclient/gen/model/match_response.py b/regula/facesdk/webclient/gen/model/match_response.py index 7433990..a6c07b1 100644 --- a/regula/facesdk/webclient/gen/model/match_response.py +++ b/regula/facesdk/webclient/gen/model/match_response.py @@ -36,15 +36,17 @@ class MatchResponse(object): 'code': 'FaceSDKResultCode', 'detections': '[MatchImageDetection]', 'results': '[MatchImageResult]', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', } attribute_map = { 'code': 'code', 'detections': 'detections', 'results': 'results', + 'metadata': 'metadata', } - def __init__(self, code=None, detections=None, results=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, code=None, detections=None, results=None, metadata=None, local_vars_configuration=None): # noqa: E501 """MatchResponse - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -53,6 +55,7 @@ def __init__(self, code=None, detections=None, results=None, local_vars_configur self._code = None self._detections = None self._results = None + self._metadata = None self.discriminator = None self.code = code @@ -60,6 +63,8 @@ def __init__(self, code=None, detections=None, results=None, local_vars_configur self.detections = detections if results is not None: self.results = results + if metadata is not None: + self.metadata = metadata @property def code(self): @@ -130,6 +135,29 @@ def results(self, results): self._results = results + @property + def metadata(self): + """Gets the metadata of this MatchResponse. # noqa: E501 + + A free-form object containing person's extended attributes. # noqa: E501 + + :return: The metadata of this MatchResponse. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this MatchResponse. + + A free-form object containing person's extended attributes. # noqa: E501 + + :param metadata: The metadata of this MatchResponse. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/regula/facesdk/webclient/gen/model/match_response_all_of.py b/regula/facesdk/webclient/gen/model/match_response_all_of.py index b430eb2..8982268 100644 --- a/regula/facesdk/webclient/gen/model/match_response_all_of.py +++ b/regula/facesdk/webclient/gen/model/match_response_all_of.py @@ -35,14 +35,16 @@ class MatchResponseAllOf(object): openapi_types = { 'detections': '[MatchImageDetection]', 'results': '[MatchImageResult]', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', } attribute_map = { 'detections': 'detections', 'results': 'results', + 'metadata': 'metadata', } - def __init__(self, detections=None, results=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, detections=None, results=None, metadata=None, local_vars_configuration=None): # noqa: E501 """MatchResponseAllOf - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -50,12 +52,15 @@ def __init__(self, detections=None, results=None, local_vars_configuration=None) self._detections = None self._results = None + self._metadata = None self.discriminator = None if detections is not None: self.detections = detections if results is not None: self.results = results + if metadata is not None: + self.metadata = metadata @property def detections(self): @@ -103,6 +108,29 @@ def results(self, results): self._results = results + @property + def metadata(self): + """Gets the metadata of this MatchResponseAllOf. # noqa: E501 + + A free-form object containing person's extended attributes. # noqa: E501 + + :return: The metadata of this MatchResponseAllOf. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this MatchResponseAllOf. + + A free-form object containing person's extended attributes. # noqa: E501 + + :param metadata: The metadata of this MatchResponseAllOf. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/regula/facesdk/webclient/gen/model/operation_log.py b/regula/facesdk/webclient/gen/model/operation_log.py index 0f26163..95592ac 100644 --- a/regula/facesdk/webclient/gen/model/operation_log.py +++ b/regula/facesdk/webclient/gen/model/operation_log.py @@ -36,15 +36,17 @@ class OperationLog(object): 'status_code': 'int', 'type': 'str', 'msg': 'str', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', } attribute_map = { 'status_code': 'statusCode', 'type': 'type', 'msg': 'msg', + 'metadata': 'metadata', } - def __init__(self, status_code=None, type=None, msg=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, status_code=None, type=None, msg=None, metadata=None, local_vars_configuration=None): # noqa: E501 """OperationLog - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -53,6 +55,7 @@ def __init__(self, status_code=None, type=None, msg=None, local_vars_configurati self._status_code = None self._type = None self._msg = None + self._metadata = None self.discriminator = None if status_code is not None: @@ -61,6 +64,8 @@ def __init__(self, status_code=None, type=None, msg=None, local_vars_configurati self.type = type if msg is not None: self.msg = msg + if metadata is not None: + self.metadata = metadata @property def status_code(self): @@ -131,6 +136,29 @@ def msg(self, msg): self._msg = msg + @property + def metadata(self): + """Gets the metadata of this OperationLog. # noqa: E501 + + A free-form object containing group's extended attributes. # noqa: E501 + + :return: The metadata of this OperationLog. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this OperationLog. + + A free-form object containing group's extended attributes. # noqa: E501 + + :param metadata: The metadata of this OperationLog. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/regula/facesdk/webclient/gen/model/person.py b/regula/facesdk/webclient/gen/model/person.py index 6284a23..b546379 100644 --- a/regula/facesdk/webclient/gen/model/person.py +++ b/regula/facesdk/webclient/gen/model/person.py @@ -64,8 +64,7 @@ def __init__(self, name=None, metadata=None, groups=None, id=None, created_at=No self._updated_at = None self.discriminator = None - if name is not None: - self.name = name + self.name = name if metadata is not None: self.metadata = metadata if groups is not None: @@ -97,6 +96,8 @@ def name(self, name): :param name: The name of this Person. # noqa: E501 :type name: str """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 self._name = name diff --git a/regula/facesdk/webclient/gen/model/person_fields.py b/regula/facesdk/webclient/gen/model/person_fields.py index d0de851..c460116 100644 --- a/regula/facesdk/webclient/gen/model/person_fields.py +++ b/regula/facesdk/webclient/gen/model/person_fields.py @@ -55,8 +55,7 @@ def __init__(self, name=None, metadata=None, groups=None, local_vars_configurati self._groups = None self.discriminator = None - if name is not None: - self.name = name + self.name = name if metadata is not None: self.metadata = metadata if groups is not None: @@ -82,6 +81,8 @@ def name(self, name): :param name: The name of this PersonFields. # noqa: E501 :type name: str """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 self._name = name diff --git a/regula/facesdk/webclient/gen/model/person_to_update_fields.py b/regula/facesdk/webclient/gen/model/person_to_update_fields.py new file mode 100644 index 0000000..c8bd46a --- /dev/null +++ b/regula/facesdk/webclient/gen/model/person_to_update_fields.py @@ -0,0 +1,178 @@ +# coding: utf-8 + +""" + Regula FaceSDK Web API + + [Download OpenAPI specification](https://github.com/regulaforensics/FaceSDK-web-openapi) ### Clients * [JavaScript](https://github.com/regulaforensics/FaceSDK-web-js-client) client for the browser and node.js based on axios * [Java](https://github.com/regulaforensics/FaceSDK-web-java-client) client compatible with jvm and android * [Python](https://github.com/regulaforensics/FaceSDK-web-python-client) 3.5+ client * [C#](https://github.com/regulaforensics/FaceSDK-web-csharp-client) client for .NET & .NET Core # noqa: E501 + + The version of the OpenAPI document: 6.1.0 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from regula.facesdk.webclient.gen.configuration import Configuration + + +class PersonToUpdateFields(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'name': 'str', + 'metadata': '{str: (bool, date, datetime, dict, float, int, list, str, none_type)}', + 'groups': '[str]', + } + + attribute_map = { + 'name': 'name', + 'metadata': 'metadata', + 'groups': 'groups', + } + + def __init__(self, name=None, metadata=None, groups=None, local_vars_configuration=None): # noqa: E501 + """PersonToUpdateFields - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._name = None + self._metadata = None + self._groups = None + self.discriminator = None + + if name is not None: + self.name = name + if metadata is not None: + self.metadata = metadata + if groups is not None: + self.groups = groups + + @property + def name(self): + """Gets the name of this PersonToUpdateFields. # noqa: E501 + + Person name. # noqa: E501 + + :return: The name of this PersonToUpdateFields. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this PersonToUpdateFields. + + Person name. # noqa: E501 + + :param name: The name of this PersonToUpdateFields. # noqa: E501 + :type name: str + """ + + self._name = name + + @property + def metadata(self): + """Gets the metadata of this PersonToUpdateFields. # noqa: E501 + + A free-form object containing person's extended attributes. # noqa: E501 + + :return: The metadata of this PersonToUpdateFields. # noqa: E501 + :rtype: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + return self._metadata + + @metadata.setter + def metadata(self, metadata): + """Sets the metadata of this PersonToUpdateFields. + + A free-form object containing person's extended attributes. # noqa: E501 + + :param metadata: The metadata of this PersonToUpdateFields. # noqa: E501 + :type metadata: {str: (bool, date, datetime, dict, float, int, list, str, none_type)} + """ + + self._metadata = metadata + + @property + def groups(self): + """Gets the groups of this PersonToUpdateFields. # noqa: E501 + + Groups a person should be placed to. If no group is specified in request, a Default group is created and the person is placed to it. # noqa: E501 + + :return: The groups of this PersonToUpdateFields. # noqa: E501 + :rtype: [str] + """ + return self._groups + + @groups.setter + def groups(self, groups): + """Sets the groups of this PersonToUpdateFields. + + Groups a person should be placed to. If no group is specified in request, a Default group is created and the person is placed to it. # noqa: E501 + + :param groups: The groups of this PersonToUpdateFields. # noqa: E501 + :type groups: [str] + """ + + self._groups = groups + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, PersonToUpdateFields): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, PersonToUpdateFields): + return True + + return self.to_dict() != other.to_dict() diff --git a/regula/facesdk/webclient/gen/model/person_with_images.py b/regula/facesdk/webclient/gen/model/person_with_images.py index 9ff2917..4150f7d 100644 --- a/regula/facesdk/webclient/gen/model/person_with_images.py +++ b/regula/facesdk/webclient/gen/model/person_with_images.py @@ -69,8 +69,7 @@ def __init__(self, images=None, name=None, metadata=None, groups=None, id=None, if images is not None: self.images = images - if name is not None: - self.name = name + self.name = name if metadata is not None: self.metadata = metadata if groups is not None: @@ -123,6 +122,8 @@ def name(self, name): :param name: The name of this PersonWithImages. # noqa: E501 :type name: str """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 self._name = name diff --git a/regula/facesdk/webclient/gen/model/search_person.py b/regula/facesdk/webclient/gen/model/search_person.py index 1464e39..c5670fa 100644 --- a/regula/facesdk/webclient/gen/model/search_person.py +++ b/regula/facesdk/webclient/gen/model/search_person.py @@ -70,8 +70,7 @@ def __init__(self, name=None, metadata=None, groups=None, id=None, created_at=No self._images = None self.discriminator = None - if name is not None: - self.name = name + self.name = name if metadata is not None: self.metadata = metadata if groups is not None: @@ -107,6 +106,8 @@ def name(self, name): :param name: The name of this SearchPerson. # noqa: E501 :type name: str """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 self._name = name diff --git a/regula/facesdk/webclient/gen/model/search_request.py b/regula/facesdk/webclient/gen/model/search_request.py index 02ffa44..ffa0613 100644 --- a/regula/facesdk/webclient/gen/model/search_request.py +++ b/regula/facesdk/webclient/gen/model/search_request.py @@ -36,7 +36,7 @@ class SearchRequest(object): 'create_person': 'SearchParametersCreatePerson', 'group_ids': '[str]', 'tag': 'str', - 'image': 'ImageFieldsImage', + 'image': 'AddImageToPersonRequestImage', 'output_image_params': 'OutputImageParams', 'detect_all': 'bool', 'threshold': 'float', @@ -160,7 +160,7 @@ def image(self): :return: The image of this SearchRequest. # noqa: E501 - :rtype: ImageFieldsImage + :rtype: AddImageToPersonRequestImage """ return self._image @@ -170,7 +170,7 @@ def image(self, image): :param image: The image of this SearchRequest. # noqa: E501 - :type image: ImageFieldsImage + :type image: AddImageToPersonRequestImage """ self._image = image diff --git a/regula/facesdk/webclient/gen/models/__init__.py b/regula/facesdk/webclient/gen/models/__init__.py index e7ca50d..3e2a403 100644 --- a/regula/facesdk/webclient/gen/models/__init__.py +++ b/regula/facesdk/webclient/gen/models/__init__.py @@ -9,6 +9,9 @@ # import sys # sys.setrecursionlimit(n) +from regula.facesdk.webclient.gen.model.add_image_to_person_request import AddImageToPersonRequest +from regula.facesdk.webclient.gen.model.add_image_to_person_request_image import AddImageToPersonRequestImage +from regula.facesdk.webclient.gen.model.add_image_to_person_response import AddImageToPersonResponse from regula.facesdk.webclient.gen.model.attribute_config import AttributeConfig from regula.facesdk.webclient.gen.model.attribute_config_list import AttributeConfigList from regula.facesdk.webclient.gen.model.crop import Crop @@ -36,10 +39,10 @@ from regula.facesdk.webclient.gen.model.group_all_of import GroupAllOf from regula.facesdk.webclient.gen.model.group_page import GroupPage from regula.facesdk.webclient.gen.model.group_page_all_of import GroupPageAllOf +from regula.facesdk.webclient.gen.model.group_response import GroupResponse from regula.facesdk.webclient.gen.model.group_to_create import GroupToCreate from regula.facesdk.webclient.gen.model.image import Image from regula.facesdk.webclient.gen.model.image_fields import ImageFields -from regula.facesdk.webclient.gen.model.image_fields_image import ImageFieldsImage from regula.facesdk.webclient.gen.model.image_page import ImagePage from regula.facesdk.webclient.gen.model.image_page_all_of import ImagePageAllOf from regula.facesdk.webclient.gen.model.image_source import ImageSource @@ -63,6 +66,7 @@ from regula.facesdk.webclient.gen.model.person import Person from regula.facesdk.webclient.gen.model.person_all_of import PersonAllOf from regula.facesdk.webclient.gen.model.person_fields import PersonFields +from regula.facesdk.webclient.gen.model.person_to_update_fields import PersonToUpdateFields from regula.facesdk.webclient.gen.model.person_with_images import PersonWithImages from regula.facesdk.webclient.gen.model.person_with_images_all_of import PersonWithImagesAllOf from regula.facesdk.webclient.gen.model.persons_page import PersonsPage