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

[source, js]
----
const response = await client.search({
  index: "place",
  pretty: "true",
  suggest: {
    place_suggestion: {
      prefix: "tim",
      completion: {
        field: "suggest",
        size: 10,
        contexts: {
          location: [
            {
              lat: 43.6624803,
              lon: -79.3863353,
              precision: 2,
            },
            {
              context: {
                lat: 43.6624803,
                lon: -79.3863353,
              },
              boost: 2,
            },
          ],
        },
      },
    },
  },
});
console.log(response);
----
