FruxonDocs

MongoDB

MongoDB database integration for querying, inserting, updating, and aggregating documents

The MongoDB integration lets your agents query, insert, update, delete, and aggregate documents in MongoDB databases.

Prerequisites

You need:

  • MongoDB connection string — The URI for your MongoDB instance (e.g., mongodb+srv://user:pass@cluster.mongodb.net/). This includes authentication credentials.
  • Database name — The default database your agent will work with.

Setup

  1. Open your agent in Agent Studio
  2. In the Integrations panel, click Add Integration Config
  3. Select MongoDB from the integration list
  4. Give the config a display name (e.g., "MongoDB - Production")
  5. Enter the configuration parameters:
    • Connection String — Your MongoDB URI (stored encrypted)
    • Database — The default database name
  6. Save the agent revision

No separate authentication setup is needed — credentials are embedded in the connection string.

Using in Your Agent

  1. In an Agent Step, attach MongoDB tools from the tools panel
  2. The agent uses your integration config for all MongoDB operations
  3. Tools are referenced as mongodb.find, mongodb.insert_one, etc.

Available Tools

ToolDescriptionAction Type
list_collectionsList all collections in the databaseReadOnly
findQuery documents from a collectionReadOnly
countCount documents matching a filterReadOnly
aggregateRun an aggregation pipelineReadOnly
insert_oneInsert a single documentReversible
insert_manyInsert multiple documentsReversible
update_oneUpdate a single documentReversible
update_manyUpdate multiple documentsReversible
delete_oneDelete a single documentIrreversible
delete_manyDelete multiple documentsIrreversible

On this page