drapon
服务介绍
Claude Extension Configuration Tool
This repository is a tool for managing the feature extension settings of the Claude desktop application and Cursor IDE.
Overview
Using a Makefile, this tool automatically generates configuration files (claude_desktop_config.json or config.json) from templates (claude_desktop_config.template.json or cursor_config.template.json) and a .env file, and installs them into the configuration directory of the Claude desktop application or Cursor IDE.
Supported Features
This repository enables the following features in the Claude desktop application and Cursor IDE:
- Brave Search: Web and local search
- Filesystem: Local file operations
- Git: Repository operations
- GitHub: Repository management
- Shell: Command execution
- Puppeteer: Web scraping
- Fetch: HTTP requests
- Claude CLI: Command line integration
- AWS Documentation: Searching AWS-related information
- Supabase: Database integration
- Obsidian: Obsidian note operations
Prerequisites
- Bun is installed
makeis installed on your system- The Claude desktop application or Cursor IDE is installed
- uvx is installed (if using the AWS Documentation feature)
Setup
-
Clone the repository:
bash
git clone https://github.com/yourusername/claude-ts-mcps.git
cd claude-ts-mcps -
Create a .env file:
Create a
.envfile with the following content and set the necessary values.API Keys and Tokens
BRAVE_API_KEY=your_brave_api_key # Brave search API Key
GITHUB_TOKEN=your_github_personal_access_token # GitHub personal access token
SUPABASE_API_KEY=your_supabase_api_key # Supabase API Key
FIGMA_API_KEY=your_figma_api_key # Figma API KeyExecutables Paths
BUN_PATH=/path/to/bun # Full path to bun command (usually /opt/homebrew/bin/bun)
UVX_PATH=/path/to/uvx # Full path to uvx command (usually /usr/local/bin/uvx)
NPX_PATH=/path/to/npx # Full path to npx command
CLAUDE_CLI_PATH=/path/to/claude/cli # Full path to Claude CLIDirectories
HOME_DIR=/your/home/directory # Path to home directory
OBSIDIAN_VAULT_DIR=/path/to/obsidian/vault # Path to Obsidian vault directory
CURSOR_WORKSPACE_PATH=/path/to/workspace # Path to Cursor workspace (for Cursor)Fetch Tool Configuration
CUSTOM_USER_AGENT=Mozilla/5.0 (...) # Custom user agent setting
IGNORE_ROBOTS_TXT=false # Whether to ignore robots.txt -
Install and configure dependencies:
For Claude Desktop:
bashSelectively enable MCP servers (recommended)
make select-mcps
Or, use the traditional automatic setup
make setup
For Cursor IDE:
bashSet up MCP servers for Cursor
./scripts/setup_cursor_mcp.sh
This will perform the following actions:
- Install dependencies in the root directory and
tsdirectory - If using
select-mcps:- You can select which MCP servers to enable
- You can input the required environment variables interactively- The configuration file is generated from the template file (
claude_desktop_config.template.jsonorcursor_config.template.json) and the.envfile.
- Install dependencies in the root directory and
- The generated configuration file is copied to the appropriate configuration directory.
-
Restart the application:
To apply the changes, please restart the Claude Desktop app or Cursor IDE.
Makefile Commands
make allormake: The default target. Runs thesetuptarget.make setup: Installs dependencies, generates the configuration file, and copies it to the Claude Desktop app's configuration directory.make select-mcps: Interactively selects MCP servers for configuration. Also allows setting necessary environment variables.make install: Installs only the dependencies.make clean: Removes the generatedclaude_desktop_config.jsonfile.
Configuration Files
claude_desktop_config.template.json: Template file for feature settings of Claude Desktop.cursor_config.template.json: Template file for feature settings of Cursor IDE..env: File for defining environment variables (not included in the repository).claude_desktop_config.json: Generated configuration file for Claude Desktop (not included in the repository).config.json: Generated configuration file for Cursor IDE (not included in the repository).
Customization
You can customize the settings by modifying the .env file and the template files:
- .env: Define environment-specific values and secrets here.
- Template Files: Modify the feature settings templates as needed.
- Interactive Selection: Use
make select-mcpsto enable only the MCP servers you wish to use.
How to Use Obsidian Features
To use Obsidian features, you need to set OBSIDIAN_VAULT_DIR in the .env file. This feature provides the following tools:
-
write_note: Creates or updates an Obsidian note.
path: Path to the note (.mdextension is optional).content: Content of the note.append: Iftrue, appends to the existing note (optional).
-
delete_note: Deletes an Obsidian note.
path: Path to the note to be deleted.
-
read_notes: Reads multiple notes at once.
paths: Array of paths to the notes to be read.
-
search_notes: Searches for notes by name.
query: Search query (case-insensitive).
Example:
javascript
// Create a note
write_note({"path": "Projects/新しいプロジェクト", "content": "# 新しいプロジェクト\n\nここにプロジェクトの詳細を記述します。"})
// Append to a note
write_note({"path": "Projects/新しいプロジェクト", "content": "## 追加情報\n\nここに追加情報を記述します。", "append": true})
// Search for notes
search_notes({"query": "プロジェクト"})
// Read notes
read_notes({"paths": ["Projects/新しいプロジェクト", "Daily/2025-04-12"]})
// Delete a note
delete_note({"path": "Projects/古いプロジェクト"})
Developing and Extending MCPs
How to add a new MCP to this repository:
-
Create a new server file:
Create a new.tsfile in the/ts/src/directory. You can refer to existing files (e.g.,obsidian.ts). -
Define required schemas:Use Zod to define the schema for input parameters.
typescript
const MyToolArgsSchema = z.object({
param1: z.string().describe("Description for parameter 1"),
param2: z.number().optional().describe("Optional parameter 2"),
});
-
Add Tool Implementation:
Implement the tool's behavior withinserver.setRequestHandler(). -
Add to Configuration Files:
Add the new MCP settings to the template files (claude_desktop_config.template.jsonandcursor_config.template.json).
json
"my-new-tool": {
"command": "{{BUN_PATH}}",
"args": ["run", "{{PROJECT_ROOT}}/ts/src/my-new-tool.ts", "{{SOME_PARAMETER}}"]
}
- Add Environment Variables:
Add any new environment variables to the.envfile as needed, and update the README.
Troubleshooting
- If you encounter issues, check the console output for error messages.
- Ensure that the path in the
.envfile is correct. - Verify that the
buncommand is working properly. - For Obsidian features, make sure
OBSIDIAN_VAULT_DIRis correctly set. - If problems occur during interactive setup, try setting up using the traditional method with
make setup. - If there are issues with Cursor IDE settings, check that the MCP configuration path is correctly specified in the Cursor settings interface.
Development Guidelines
This project uses Bun exclusively as the package manager. Since other package managers like npm or yarn are not supported, please use the bun command for all installations and executions.