in opensearch-api/lib/opensearch/api/actions/mtermvectors.rb [54:86]
def mtermvectors(arguments = {})
headers = arguments.delete(:headers) || {}
arguments = arguments.clone
ids = arguments.delete(:ids)
_index = arguments.delete(:index)
_type = arguments.delete(:type)
method = if arguments[:body]
OpenSearch::API::HTTP_POST
else
OpenSearch::API::HTTP_GET
end
path = if _index && _type
"#{Utils.__listify(_index)}/#{Utils.__listify(_type)}/_mtermvectors"
elsif _index
"#{Utils.__listify(_index)}/_mtermvectors"
else
"_mtermvectors"
end
params = Utils.__validate_and_extract_params arguments, ParamsRegistry.get(__method__)
if ids
body = { :ids => ids }
else
body = arguments[:body]
end
perform_request(method, path, params, body, headers).body
end