> ## Documentation Index
> Fetch the complete documentation index at: https://docs.enterspeed.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Intro

An index schema defines the structure of a Query index as well as the mapping of the items that goes into the index which are queryable from the [Query API](/api-reference/query).

```js title="JavaScript index schema example" theme={null}
/** @type {Enterspeed.IndexSchema} */
export default {
  triggers: function(context) {
    context.triggers('pim', ['product'])
  },
  index: {
    fields {
        sku: { type: "keyword" }, 
        title: { type: "text" }, 
        description: { type: "text" },
        isActive: { type: "boolean" }
      }
  },
  properties: function (sourceEntity) {
    return {
        sku: sourceEntity.properties.sku, 
        title: sourceEntity.properties.title, 
        description: sourceEntity.properties.description,
        isActive: sourceEntity.properties.isActive
      }
  }
}
```
