class AvalaraSdk::EInvoicing::AvalaraSdk::EInvoicing::V1::TaxIdentifiersApi
def validate_tax_identifier_with_http_info(request_parameters)
-
(Array<(TaxIdentifierResponse, Integer, Hash)>)- TaxIdentifierResponse data, response status code and response headers
Parameters:
-
x_correlation_id(String) -- The caller can use this as an identifier to use as a correlation id to trace the call. -
x_avalara_client(String) -- You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a \"Fingerprint\". -
tax_identifier_request(TaxIdentifierRequest) -- -
avalara_version(String) -- The HTTP Header meant to specify the version of the API intended to be used.
def validate_tax_identifier_with_http_info(request_parameters) # OAuth2 Scopes required_scopes = '' # Request Parameters avalara_version = request_parameters.get_avalara_version() tax_identifier_request = request_parameters.get_tax_identifier_request() x_avalara_client = request_parameters.get_x_avalara_client() x_correlation_id = request_parameters.get_x_correlation_id() # verify the required parameter 'avalara_version' is set if @api_client.config.client_side_validation && avalara_version.nil? fail ArgumentError, "Missing the required parameter 'avalara_version' when calling TaxIdentifiersApi.validate_tax_identifier" end # verify the required parameter 'tax_identifier_request' is set if @api_client.config.client_side_validation && tax_identifier_request.nil? fail ArgumentError, "Missing the required parameter 'tax_identifier_request' when calling TaxIdentifiersApi.validate_tax_identifier" end # resource path local_var_path = '/einvoicing/tax-identifiers/validate' # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end if !avalara_version.nil? header_params[:'avalara-version'] = avalara_version end if !x_avalara_client.nil? header_params[:'X-Avalara-Client'] = x_avalara_client end if !x_correlation_id.nil? header_params[:'X-Correlation-ID'] = x_correlation_id end # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(tax_identifier_request) || {} # return_type return_type = 'TaxIdentifierResponse' # auth_names auth_names = ['Bearer'] @api_client.apply_auth_to_request!(header_params, auth_names, required_scopes) new_options = { :operation => :"TaxIdentifiersApi.validate_tax_identifier", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type } response = @api_client.call_api(:POST, local_var_path, new_options, required_scopes, false, :EInvoicing) if new_options[:return_type] data = deserialize(response, new_options[:return_type]) else data = nil end return data, response.code, response.headers end