// This file is autogenerated, DO NOT EDIT
// Use `node scripts/generate-docs-examples.js` to generate the docs examples

[source, js]
----
const response = await client.indices.create({
  index: "ngram_custom_example",
  settings: {
    index: {
      max_ngram_diff: 2,
    },
    analysis: {
      analyzer: {
        default: {
          tokenizer: "whitespace",
          filter: ["3_5_grams"],
        },
      },
      filter: {
        "3_5_grams": {
          type: "ngram",
          min_gram: 3,
          max_gram: 5,
        },
      },
    },
  },
});
console.log(response);
----
