Skip to main content
Glama

MongoDB MCP Server

Official
by mongodb-js
insertMany.test.ts1.57 kB
import { describeAccuracyTests } from "./sdk/describeAccuracyTests.js"; import { Matcher } from "./sdk/matcher.js"; describeAccuracyTests([ { prompt: [ "In my namespace 'mflix.movies', insert 3 documents each with the following fields:", "- id: an incremental number starting from 1", "- name: a string of format 'name<id>'", ].join("\n"), expectedToolCalls: [ { toolName: "insert-many", parameters: { database: "mflix", collection: "movies", documents: [ { id: 1, name: "name1", }, { id: 2, name: "name2", }, { id: 3, name: "name3", }, ], }, }, ], }, { prompt: "Add three empty documents in one go in collection 'movies' inside database 'mflix'", expectedToolCalls: [ { toolName: "insert-many", parameters: { database: "mflix", collection: "movies", documents: [{ _id: Matcher.anyValue }, { _id: Matcher.anyValue }, { _id: Matcher.anyValue }], }, }, ], }, ]);

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/mongodb-js/mongodb-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server