https://github.com/bart6114/my-bear-mcp-server
https://github.com/bart6114/my-bear-mcp-server
Last synced: 22 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/bart6114/my-bear-mcp-server
- Owner: bart6114
- License: mit
- Created: 2025-03-13T13:49:21.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2025-03-14T08:11:11.000Z (about 1 month ago)
- Last Synced: 2025-03-14T08:37:11.532Z (about 1 month ago)
- Language: JavaScript
- Size: 32.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-mcp-servers - BearMCP - Provides read-only access to Bear notes for AI assistants via the Model Context Protocol (MCP) (Table of Contents / Other Tools and Integrations)
- awesome-mcp-servers - BearMCP - Provides read-only access to Bear notes for AI assistants via the Model Context Protocol (MCP) (Table of Contents / Other Tools and Integrations)
README
# Bear MCP Server
A Model Context Protocol (MCP) server that allows AI assistants like Claude to read notes from the [Bear](https://bear.app/) note-taking app. This implementation connects directly to the Bear SQLite database in a read-only mode, ensuring your notes remain safe and unmodified.
[](https://github.com/bart6114/my-bear-mcp-server)
[](https://bear.app)
[](https://claude.ai)
[](https://www.typescriptlang.org/)
[](https://opensource.org/licenses/MIT)## Quick Start
### Option 1: Install from GitHub (Recommended)
```bash
npx github:bart6114/my-bear-mcp-server
```That's it! The server will start running and connect to your Bear database.
### Option 2: Clone and Run Locally
```bash
# Clone the repository
git clone https://github.com/bart6114/my-bear-mcp-server.git
cd my-bear-mcp-server# Install dependencies
npm install# Build and run
npm run build
npm start
```## Prerequisites
- macOS with Bear app installed
- Node.js 18 or higher## Configuration
### For Claude Desktop App
Add this to your configuration file at `~/Library/Application Support/Claude/claude_desktop_config.json`:
```json
{
"mcpServers": {
"bear": {
"command": "npx",
"args": ["github:bart6114/my-bear-mcp-server"],
"env": {},
"disabled": false,
"autoApprove": []
}
}
}
```### For Claude VS Code Extension
Add this to your configuration file at `~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json`:
```json
{
"mcpServers": {
"bear": {
"command": "npx",
"args": ["github:bart6114/my-bear-mcp-server"],
"env": {},
"disabled": false,
"autoApprove": []
}
}
}
```## Available Tools
The Bear MCP server provides these read-only tools (all operations are non-destructive and cannot modify your Bear database):
### open_note
Open a note by title or ID.
### search_notes
Search for notes by term or tag.
### get_tags
Get all tags in Bear.
### open_tag
Show all notes with a specific tag.
## Example Usage
Here are examples of how to interact with the Bear MCP tools through AI assistants:
### Searching for Notes
Ask your AI assistant to search for notes containing specific terms:
```
Can you find all my notes about "project management"?
```### Opening a Specific Note
Ask your AI assistant to retrieve a specific note by title:
```
Show me my note titled "Meeting Notes - March 2025"
```### Viewing Tags
Ask your AI assistant to list all your Bear tags:
```
What tags do I have in my Bear notes?
```### Finding Notes with a Specific Tag
Ask your AI assistant to show notes with a particular tag:
```
Show me all notes with the #work tag
```## Advanced Options
If your Bear database is in a non-standard location:
```bash
npx github:bart6114/my-bear-mcp-server --db-path /path/to/your/database.sqlite
```## Technical Details
### Read-Only Implementation
This MCP server connects to your Bear SQLite database using a strict read-only connection. This is enforced at the database driver level:
```typescript
// From src/bear-db.ts
this.db = new Database(dbPath, { readonly: true });
```This ensures that:
- No write operations can be performed on your database
- Your notes and tags cannot be modified, deleted, or corrupted
- The database connection will fail if write permissions are attemptedAll operations performed by this server are SELECT queries that only retrieve data without modifying it.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.