Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"name": "perplexity",
"owner": {
"name": "Perplexity AI",
"email": "support@perplexity.ai",
"url": "https://www.perplexity.ai"
},
"metadata": {
"description": "Official Perplexity AI plugins for Claude Code, providing real-time web search, reasoning, and research capabilities through Sonar models and the Search API",
"version": "1.0.0"
},
"plugins": [
{
"name": "perplexity-mcp-server",
"source": "./plugins/perplexity-mcp-server",
"description": "Official MCP server for Perplexity API Platform providing AI assistants with real-time web search, reasoning, and research capabilities through Sonar models and the Search API.",
"version": "0.2.2",
"author": {
"name": "Perplexity AI",
"url": "https://www.perplexity.ai"
},
"keywords": ["ai", "perplexity", "mcp", "modelcontextprotocol", "search", "reasoning", "research", "sonar"],
"category": "ai-tools",
"license": "MIT",
"homepage": "https://docs.perplexity.ai/guides/mcp-server",
"repository": "https://github.com/perplexityai/modelcontextprotocol",
"strict": false
}
]
}
23 changes: 20 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,25 @@ Advanced reasoning and problem-solving using the `sonar-reasoning-pro` model. Pe
2. Set it as an environment variable: `PERPLEXITY_API_KEY=your_key_here`
3. (Optional) Set a timeout for requests: `PERPLEXITY_TIMEOUT_MS=600000`. The default is 5 minutes.

### Claude Code
### Claude Code Plugin (Recommended)

**Easy Installation via Plugin Marketplace:**

1. Add the Perplexity marketplace:
```bash
/plugin marketplace add perplexityai/modelcontextprotocol
```

2. Install the plugin:
```bash
/plugin install perplexity-mcp-server@perplexity
```

3. Configure your API key when prompted.

This method provides automatic updates and easier management through Claude Code's plugin system.

**Manual MCP Configuration:**

Run in your terminal:

Expand Down Expand Up @@ -115,5 +133,4 @@ npx @perplexity-ai/mcp-server

For support, visit [community.perplexity.ai](https://community.perplexity.ai) or [file an issue](https://github.com/perplexityai/modelcontextprotocol/issues).

---

---
23 changes: 23 additions & 0 deletions plugins/perplexity-mcp-server/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "perplexity-mcp-server",
"version": "0.2.2",
"description": "Official MCP server for Perplexity API Platform providing AI assistants with real-time web search, reasoning, and research capabilities through Sonar models and the Search API.",
"author": {
"name": "Perplexity AI",
"url": "https://www.perplexity.ai"
},
"homepage": "https://docs.perplexity.ai/guides/mcp-server",
"repository": "https://github.com/perplexityai/modelcontextprotocol",
"license": "MIT",
"keywords": ["ai", "perplexity", "mcp", "modelcontextprotocol", "search", "reasoning", "research", "sonar"],
"category": "ai-tools",
"mcpServers": "./.mcp.json",
"engines": {
"node": ">=18"
},
"dependencies": {
"@modelcontextprotocol/sdk": "^1.0.1",
"axios": "^1.6.2",
"dotenv": "^16.3.1"
}
}
12 changes: 12 additions & 0 deletions plugins/perplexity-mcp-server/.mcp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"mcpServers": {
"perplexity": {
"command": "npx",
"args": ["-y", "@perplexity-ai/mcp-server"],
"env": {
"PERPLEXITY_API_KEY": "",
"PERPLEXITY_TIMEOUT_MS": "300000"
}
}
}
}
65 changes: 65 additions & 0 deletions plugins/perplexity-mcp-server/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Perplexity MCP Server Plugin

Official Claude Code plugin for the Perplexity MCP Server, providing AI assistants with real-time web search, reasoning, and research capabilities through Sonar models and the Search API.

## Features

- **perplexity_search**: Direct web search using the Perplexity Search API with ranked results and metadata
- **perplexity_ask**: General-purpose conversational AI with real-time web search using the `sonar-pro` model
- **perplexity_research**: Deep, comprehensive research using the `sonar-deep-research` model
- **perplexity_reason**: Advanced reasoning and problem-solving using the `sonar-reasoning-pro` model

## Installation

### Prerequisites

1. Get your Perplexity API Key from the [API Portal](https://www.perplexity.ai/account/api/group)
2. Have Claude Code installed and running

### Quick Install

1. Add the Perplexity marketplace to Claude Code:
```
/plugin marketplace add perplexityai/modelcontextprotocol
```

2. Install the plugin:
```
/plugin install perplexity-mcp-server@perplexity
```

3. Configure your API key when prompted, or set it manually in your Claude Code settings.

### Manual Configuration

If you need to set your API key manually:

1. Open Claude Code settings
2. Navigate to MCP Servers
3. Find the "perplexity" server configuration
4. Set the `PERPLEXITY_API_KEY` environment variable to your API key
5. Optionally adjust `PERPLEXITY_TIMEOUT_MS` (default: 300000ms = 5 minutes)

## Usage

Once installed, you can use the Perplexity tools in your conversations with Claude:

- Ask questions that require current information
- Request research on specific topics
- Ask for reasoning through complex problems
- Search for specific information on the web

Claude will automatically use the appropriate Perplexity tool based on your request.

## Troubleshooting

- **API Key Issues**: Ensure `PERPLEXITY_API_KEY` is set correctly in your MCP server configuration
- **Connection Errors**: Check your internet connection and API key validity
- **Timeout Errors**: For very long research queries, increase `PERPLEXITY_TIMEOUT_MS` value

## Support

For support:
- Visit [community.perplexity.ai](https://community.perplexity.ai)
- [File an issue](https://github.com/perplexityai/modelcontextprotocol/issues) on GitHub
- Check the [official documentation](https://docs.perplexity.ai/guides/mcp-server)