Skip to content

937 - Search Config

Search engine index configuration. This is an example of a MAML document.

maml
{
  engine: "elasticsearch"
  connection: {
    host: "localhost:7700"
    api_key: "nHIKj1XNBzYPRGNC0fyqjzMU9pIjJxiY"
    timeout: 4565
  }

  # Index settings
  index: {
    name: "cappelletti"
    primary_key: "id"
    searchable: [
      "title"
      "description"
      "content"
    ]
    filterable: [
      "category"
      "status"
      "date"
    ]
    sortable: [
      "date"
      "relevance"
    ]
  }

  synonyms: {
    js: [
      "javascript"
      "ecmascript"
    ]
    ts: [
      "typescript"
    ]
  }
}

See Also