> For the complete documentation index, see [llms.txt](https://docs.tonic.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tonic.ai/app/setting-up-your-database/mongodb.md).

# MongoDB

MongoDB is an open source NoSQL database. MongoDB does not store data in tables according to a rigid schema. Instead, MongoDB stores data in documents that have a flexible schema or no schema at all.

Tonic Structural can work with MongoDB data that is either hosted on Atlas or is self-hosted.

You can also use the MongoDB data connector to connect to an Amazon DocumentDB database.

## General data connector information <a href="#mongodb-general-info" id="mongodb-general-info"></a>

<table data-view="cards"><thead><tr><th></th><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>System requirements</strong></td><td>Supported versions of MongoDB for Structural.</td><td></td><td><a href="https://docs.tonic.ai/app/setting-up-your-database/mongodb/mongodb-system-requirements.md">System requirements for MongoDB</a></td></tr><tr><td><strong>Structural differences and limitations</strong></td><td>Features that are unavailable or work differently in MongoDB workspaces.</td><td></td><td><a href="https://docs.tonic.ai/app/setting-up-your-database/mongodb/mongodb-tonic-differences.md">Structural differences and limitations with MongoDB</a></td></tr><tr><td><strong>Configure workspace data connections</strong></td><td>Data connection settings for MongoDB workspaces.</td><td></td><td><a href="https://docs.tonic.ai/app/setting-up-your-database/mongodb/mongodb-workspace-data-connections.md">Configuring MongoDB workspace data connections</a></td></tr><tr><td><strong>Other MongoDB hints and tips</strong></td><td>Other tips for working with MongoDB in Structural.</td><td></td><td><a href="https://docs.tonic.ai/app/setting-up-your-database/mongodb/mongodb-hints-tips.md">Other MongoDB hints and tips</a></td></tr></tbody></table>

## Configuring generators for MongoDB collection fields <a href="#mongodb-generator-config" id="mongodb-generator-config"></a>

For MongoDB, **Database View** and **Table View** are replaced with **Collection View**.

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>Scan collections</strong><br><br>The collection scan identifies the collections and fields in the database.</td><td><a href="https://docs.tonic.ai/app/generation/working-with-document-based-data/mongodb-collection-scans.md">Performing scans on collections</a></td></tr><tr><td><strong>Use Collection View</strong><br><br>Use <strong>Collection View</strong> to assign generators to collection fields.</td><td><a href="https://docs.tonic.ai/app/generation/working-with-document-based-data/mongodb-collection-view.md">Using Collection View</a></td></tr><tr><td><strong>Assign generators to path expressions</strong><br><br>Assign a generator to all of the fields that match a JSONPath expression.</td><td><a href="https://docs.tonic.ai/app/generation/working-with-document-based-data/document-path-expressions.md">Assigning generators to path expressions</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.tonic.ai/app/setting-up-your-database/mongodb.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
