Skip to main content
Glama
aimadesimple

TinyDB Remote MCP

by aimadesimple

TinyDB Remote MCP

A small, practical Model Context Protocol (MCP) server that stores data in TinyDB. It is designed as a learning project for people who want to understand how to build an MCP server and connect it to an MCP client.

The detailed, step-by-step project setup and deployment notes are in NOTES.md.

What this MCP does

The server exposes three tools:

  • insert_data — stores one JSON document in TinyDB.

  • get_all_data — returns every stored document.

  • delete_all_data — removes every stored document.

For example, insert_data accepts:

{
  "data": {
    "name": "Aarav Sharma",
    "email": "aarav.sharma@example.com",
    "role": "admin",
    "active": true
  }
}

Related MCP server: tldraw-mcp

Run locally

This project uses uv to manage dependencies.

uv sync
uv run python tinydb_remote_server.py

The local Streamable HTTP endpoint is:

http://127.0.0.1:10000/mcp

TinyDB creates db.json at runtime. It is local runtime data and is not intended to be committed to version control.

Use the MCP

MCP Inspector

Start the Inspector locally:

npx @modelcontextprotocol/inspector

Select Streamable HTTP and enter either the local endpoint above or your deployed endpoint:

https://<render-service-name>.onrender.com/mcp

You can also list the tools from the command line:

npx @modelcontextprotocol/inspector --cli https://<render-service-name>.onrender.com/mcp --transport http --method tools/list

OpenAI web app

Enable Developer mode in ChatGPT under Settings > Security and login. Then, from Settings > Plugins (or https://chatgpt.com/plugins), create an app using your deployed MCP URL:

https://<render-service-name>.onrender.com/mcp

After it is created, select the app in a ChatGPT project and ask it to insert or retrieve test records.

Codex, Claude web app, and Claude Code

Add the deployed /mcp URL as a Streamable HTTP MCP server in the client’s MCP or connector settings. Once connected, the client can call insert_data, get_all_data, and delete_all_data.

Deployment and security notes

See NOTES.md for the full Render deployment guide. When creating the Render service, add **/*.md as an Ignored Path under Advanced > Build Filters so Markdown-only changes do not trigger a deployment.

This example server is public and unauthenticated. Use test data only, and do not store credentials, personal information, or other sensitive data. On Render’s Free service, the TinyDB data is ephemeral and may be lost after a restart or redeploy.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides long-term memory for chatbots through a TinyDB-backed MCP server. Enables storing, searching, and managing JSON records with schema validation without requiring external databases.
    1
    MIT
  • F
    license
    A
    quality
    D
    maintenance
    Minimal MCP server for editing tldraw .tldr files via JSON manipulation. Headless, no browser needed.
    18
    1
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    A local MCP-style server for managing task records and seeded documents through controlled tool functions, using SQLite and JSON seed data.
    MIT