# Attributes for Faceting

Child route of the settings route.

The attributes that can be used as facets for faceted search.

Attributes for faceting can also be updated directly through the global settings route along with the other settings.

Learn more about faceted search.

# Get Attributes for Faceting

GET
/indexes/:index_uid/settings/attributes-for-faceting

Get the attributes for faceting of an index.

# Path Variables

Variable Description
index_uid The index UID

# Example

# Response: 200 Ok

List the settings.

["genres", "director"]

# Update Attributes for Faceting

POST
/indexes/:index_uid/settings/attributes-for-faceting

Update the attributes for faceting of an index.

# Path Variables

Variable Description
index_uid The index UID

# Body

An array of strings that contains the attributes to use as facets.

More information about the body.

# Example

# Response: 202 Accepted

{
  "updateId": 1
}

This updateId allows you to track the current update.

# Reset Attributes for Faceting

DELETE
/indexes/:index_uid/settings/attributes-for-faceting

Reset the attributes for faceting of the index to the default value.

# Default value

An empty array ([]).

# Path Variables

Variable Description
index_uid The index UID

# Example

# Response: 202 Accepted

{
  "updateId": 1
}

This updateId allows you to track the current update.

Last Updated: 11/10/2020, 3:09:11 PM