@@ -2846,6 +2846,103 @@ def generate_data_key_with_http_info(self, body, **kwargs): # noqa: E501
28462846 _request_timeout = params .get ('_request_timeout' ),
28472847 collection_formats = collection_formats )
28482848
2849+ def generate_mac (self , body , ** kwargs ): # noqa: E501
2850+ """generate_mac # noqa: E501
2851+
2852+ This method makes a synchronous HTTP request by default. To make an
2853+ asynchronous HTTP request, please pass async_req=True
2854+ >>> thread = api.generate_mac(body, async_req=True)
2855+ >>> result = thread.get()
2856+
2857+ :param async_req bool
2858+ :param GenerateMacRequest body: (required)
2859+ :return: GenerateMacResponse
2860+ If the method is called asynchronously,
2861+ returns the request thread.
2862+ """
2863+ kwargs ['_return_http_data_only' ] = True
2864+ if kwargs .get ('async_req' ):
2865+ return self .generate_mac_with_http_info (body , ** kwargs ) # noqa: E501
2866+ else :
2867+ (data ) = self .generate_mac_with_http_info (body , ** kwargs ) # noqa: E501
2868+ return data
2869+
2870+ def generate_mac_with_http_info (self , body , ** kwargs ): # noqa: E501
2871+ """generate_mac # noqa: E501
2872+
2873+ This method makes a synchronous HTTP request by default. To make an
2874+ asynchronous HTTP request, please pass async_req=True
2875+ >>> thread = api.generate_mac_with_http_info(body, async_req=True)
2876+ >>> result = thread.get()
2877+
2878+ :param async_req bool
2879+ :param GenerateMacRequest body: (required)
2880+ :return: GenerateMacResponse
2881+ If the method is called asynchronously,
2882+ returns the request thread.
2883+ """
2884+
2885+ all_params = ['body' ] # noqa: E501
2886+ all_params .append ('async_req' )
2887+ all_params .append ('_return_http_data_only' )
2888+ all_params .append ('_preload_content' )
2889+ all_params .append ('_request_timeout' )
2890+
2891+ params = locals ()
2892+ for key , val in six .iteritems (params ['kwargs' ]):
2893+ if key not in all_params :
2894+ raise TypeError (
2895+ "Got an unexpected keyword argument '%s'"
2896+ " to method generate_mac" % key
2897+ )
2898+ params [key ] = val
2899+ del params ['kwargs' ]
2900+ # verify the required parameter 'body' is set
2901+ if self .api_client .client_side_validation and ('body' not in params or
2902+ params ['body' ] is None ): # noqa: E501
2903+ raise ValueError ("Missing the required parameter `body` when calling `generate_mac`" ) # noqa: E501
2904+
2905+ collection_formats = {}
2906+
2907+ path_params = {}
2908+
2909+ query_params = []
2910+
2911+ header_params = {}
2912+
2913+ form_params = []
2914+ local_var_files = {}
2915+
2916+ body_params = None
2917+ if 'body' in params :
2918+ body_params = params ['body' ]
2919+ # HTTP header `Accept`
2920+ header_params ['Accept' ] = self .api_client .select_header_accept (
2921+ ['application/json' ]) # noqa: E501
2922+
2923+ # HTTP header `Content-Type`
2924+ header_params ['Content-Type' ] = self .api_client .select_header_content_type ( # noqa: E501
2925+ ['application/json' ]) # noqa: E501
2926+
2927+ # Authentication setting
2928+ auth_settings = ['volcengineSign' ] # noqa: E501
2929+
2930+ return self .api_client .call_api (
2931+ '/GenerateMac/2021-02-18/kms/post/application_json/' , 'POST' ,
2932+ path_params ,
2933+ query_params ,
2934+ header_params ,
2935+ body = body_params ,
2936+ post_params = form_params ,
2937+ files = local_var_files ,
2938+ response_type = 'GenerateMacResponse' , # noqa: E501
2939+ auth_settings = auth_settings ,
2940+ async_req = params .get ('async_req' ),
2941+ _return_http_data_only = params .get ('_return_http_data_only' ),
2942+ _preload_content = params .get ('_preload_content' , True ),
2943+ _request_timeout = params .get ('_request_timeout' ),
2944+ collection_formats = collection_formats )
2945+
28492946 def get_parameters_for_import (self , body , ** kwargs ): # noqa: E501
28502947 """get_parameters_for_import # noqa: E501
28512948
@@ -4300,3 +4397,100 @@ def update_secret_rotation_policy_with_http_info(self, body, **kwargs): # noqa:
43004397 _preload_content = params .get ('_preload_content' , True ),
43014398 _request_timeout = params .get ('_request_timeout' ),
43024399 collection_formats = collection_formats )
4400+
4401+ def verify_mac (self , body , ** kwargs ): # noqa: E501
4402+ """verify_mac # noqa: E501
4403+
4404+ This method makes a synchronous HTTP request by default. To make an
4405+ asynchronous HTTP request, please pass async_req=True
4406+ >>> thread = api.verify_mac(body, async_req=True)
4407+ >>> result = thread.get()
4408+
4409+ :param async_req bool
4410+ :param VerifyMacRequest body: (required)
4411+ :return: VerifyMacResponse
4412+ If the method is called asynchronously,
4413+ returns the request thread.
4414+ """
4415+ kwargs ['_return_http_data_only' ] = True
4416+ if kwargs .get ('async_req' ):
4417+ return self .verify_mac_with_http_info (body , ** kwargs ) # noqa: E501
4418+ else :
4419+ (data ) = self .verify_mac_with_http_info (body , ** kwargs ) # noqa: E501
4420+ return data
4421+
4422+ def verify_mac_with_http_info (self , body , ** kwargs ): # noqa: E501
4423+ """verify_mac # noqa: E501
4424+
4425+ This method makes a synchronous HTTP request by default. To make an
4426+ asynchronous HTTP request, please pass async_req=True
4427+ >>> thread = api.verify_mac_with_http_info(body, async_req=True)
4428+ >>> result = thread.get()
4429+
4430+ :param async_req bool
4431+ :param VerifyMacRequest body: (required)
4432+ :return: VerifyMacResponse
4433+ If the method is called asynchronously,
4434+ returns the request thread.
4435+ """
4436+
4437+ all_params = ['body' ] # noqa: E501
4438+ all_params .append ('async_req' )
4439+ all_params .append ('_return_http_data_only' )
4440+ all_params .append ('_preload_content' )
4441+ all_params .append ('_request_timeout' )
4442+
4443+ params = locals ()
4444+ for key , val in six .iteritems (params ['kwargs' ]):
4445+ if key not in all_params :
4446+ raise TypeError (
4447+ "Got an unexpected keyword argument '%s'"
4448+ " to method verify_mac" % key
4449+ )
4450+ params [key ] = val
4451+ del params ['kwargs' ]
4452+ # verify the required parameter 'body' is set
4453+ if self .api_client .client_side_validation and ('body' not in params or
4454+ params ['body' ] is None ): # noqa: E501
4455+ raise ValueError ("Missing the required parameter `body` when calling `verify_mac`" ) # noqa: E501
4456+
4457+ collection_formats = {}
4458+
4459+ path_params = {}
4460+
4461+ query_params = []
4462+
4463+ header_params = {}
4464+
4465+ form_params = []
4466+ local_var_files = {}
4467+
4468+ body_params = None
4469+ if 'body' in params :
4470+ body_params = params ['body' ]
4471+ # HTTP header `Accept`
4472+ header_params ['Accept' ] = self .api_client .select_header_accept (
4473+ ['application/json' ]) # noqa: E501
4474+
4475+ # HTTP header `Content-Type`
4476+ header_params ['Content-Type' ] = self .api_client .select_header_content_type ( # noqa: E501
4477+ ['application/json' ]) # noqa: E501
4478+
4479+ # Authentication setting
4480+ auth_settings = ['volcengineSign' ] # noqa: E501
4481+
4482+ return self .api_client .call_api (
4483+ '/VerifyMac/2021-02-18/kms/post/application_json/' , 'POST' ,
4484+ path_params ,
4485+ query_params ,
4486+ header_params ,
4487+ body = body_params ,
4488+ post_params = form_params ,
4489+ files = local_var_files ,
4490+ response_type = 'VerifyMacResponse' , # noqa: E501
4491+ auth_settings = auth_settings ,
4492+ async_req = params .get ('async_req' ),
4493+ _return_http_data_only = params .get ('_return_http_data_only' ),
4494+ _preload_content = params .get ('_preload_content' , True ),
4495+ _request_timeout = params .get ('_request_timeout' ),
4496+ collection_formats = collection_formats )
0 commit comments