younifyd
Menu

Mtermvectors (GET /{index}/_mtermvectors)

Mtermvectors

GET/{index}/_mtermvectors

Use it in a workflow

  1. Add a step and choose the OpenSearch connector.
  2. Pick the Mtermvectors (GET /{index}/_mtermvectors) action (under core).
  3. Fill in the fields below, then reference the result from later steps as {{mtermvectorsGetIndexMtermvectors.response.data}}.

Request

Path parameters

indexstringrequired

The name of the index that contains the document.

Query parameters

field_statisticsboolean

If `true`, the response includes the document count, sum of document frequencies, and sum of total term frequencies.

Default true

fieldsoneOf

A comma-separated list or a wildcard expression specifying the fields to include in the statistics. Used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters.

idsarray<string>

A comma-separated list of documents IDs. You must provide either the `docs` field in the request body or specify `ids` as a query parameter or in the request body.

offsetsboolean

If `true`, the response includes term offsets.

Default true

payloadsboolean

If `true`, the response includes term payloads.

Default true

positionsboolean

If `true`, the response includes term positions.

Default true

preferencestring

Specifies the node or shard on which the operation should be performed. See [preference query parameter]({{site.url}}{{site.baseurl}}/api-reference/search-apis/search/#the-preference-query-parameter) for a list of available options. By default the requests are routed randomly to available shard copies (primary or replica), with no guarantee of consistency across repeated queries.

realtimeboolean

If `true`, the request is real time as opposed to near real time.

Default true

routingoneOf

A custom value used to route operations to a specific shard.

term_statisticsboolean

If `true`, the response includes term frequency and document frequency.

Default false

versioninteger (int64)

If `true`, returns the document version as part of a hit.

version_typeoneOf

The specific version type.

prettyboolean

Whether to pretty-format the returned JSON response.

Default false

humanboolean

Whether to return human-readable values for statistics.

Default false

error_traceboolean

Whether to include the stack trace of returned errors.

Default false

sourcestring

The URL-encoded request definition. Useful for libraries that do not accept a request body for non-POST requests.

filter_pathoneOf

A comma-separated list of filters used to filter the response. Use wildcards to match any field or part of a field's name. To exclude fields, use `-`.

Response

Returns 200 with an object. Read it in later steps with {{mtermvectorsGetIndexMtermvectors.response.data.<field>}}.

docsarray<object>
_idstringrequired

The unique identifier for a resource.

_indexstringrequired
_versioninteger (int64)
tookinteger (int64)
foundboolean
term_vectorsobject
errorobject7 fields
_typestring

The type of document or resource.

json
{
  "docs": [
    {
      "_id": "string",
      "_index": "string",
      "_version": 0,
      "took": 0,
      "found": false,
      "term_vectors": {},
      "error": {
        "type": "string",
        "reason": "string",
        "stack_trace": "string",
        "caused_by": {},
        "root_cause": [
          {}
        ],
        "suppressed": [
          {}
        ],
        "header": {}
      },
      "_type": "string"
    }
  ]
}

Need more? See the OpenSearch guide for connection setup and behaviour shared by every action.

Mtermvectors (GET /{index}/_mtermvectors) — OpenSearch — Documentation