MCPcopy
hub / github.com/mongodb/node-mongodb-native / createSearchIndex

Method createSearchIndex

src/collection.ts:1265–1268  ·  view source on GitHub ↗

* Creates a single search index for the collection. * * @param description - The index description for the new search index. * @returns A promise that resolves to the name of the new search index. * * @remarks Only available when used against a 7.0+ Atlas cluster.

(description: SearchIndexDescription)

Source from the content-addressed store, hash-verified

1263 * @remarks Only available when used against a 7.0+ Atlas cluster.
1264 */
1265 async createSearchIndex(description: SearchIndexDescription): Promise<string> {
1266 const [index] = await this.createSearchIndexes([description]);
1267 return index;
1268 }
1269
1270 /**
1271 * Creates multiple search indexes for the current collection.

Calls 1

createSearchIndexesMethod · 0.95

Tested by

no test coverage detected