gophish-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@gophish-mcpshow me all active phishing campaigns"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
๐ฃ GoPhish MCP Server
A complete MCP (Model Context Protocol) server for interacting with all GoPhish API functionalities.
Features โข Installation โข Configuration โข Usage โข Tools
๐ Note: This MCP has been tested and works with GoPhish version 0.11.0. If I receive enough love ๐, I might update it with new capabilities!
โจ Key Features
๐ฏ Complete Campaign Management: Full CRUD + advanced analysis and statistics
๐ฅ Group Management: Manage target user groups with search capabilities
๐ง Email Templates: Create, edit and manage email templates
๐ Landing Pages: Manage landing pages for campaigns
๐ฎ SMTP Profiles: Configure email sending profiles
๐ค User Management: Manage system users and administrators
๐ Analysis and Reports: Detailed statistics, data export and global analysis
๐ Utility Tools: Search, validation, duplication and diagnostics
Related MCP server: MailScript MCP Server
๐ Quick Start
Installation
Clone this repository
git clone <repository-url>
cd gophish-mcpInstall dependencies:
pip install -e .Configuration
Option 1: .env file (Recommended)
Copy the example file:
cp env.example .envEdit
.envwith your credentials:
GOPHISH_URL=https://your-gophish-server:3333
GOPHISH_API_KEY=your-api-key-hereOption 2: Environment variables
export GOPHISH_URL="https://your-gophish-server:3333"
export GOPHISH_API_KEY="your-api-key"๐ป Usage with Claude, Cursor, VSCode, Kiro
Step 1: Configure Credentials (One time only)
Create a .env file in the project directory:
cp env.example .env
# Edit .env with your real credentialsStep 2: Configure MCP Client
Add the server to your MCP configuration (without credentials):
{
"mcpServers": {
"gophish": {
"command": "python",
"args": ["/path/to/your/gophish-mcp/server.py"],
"cwd": "/path/to/your/gophish-mcp",
"disabled": false,
"autoApprove": [
"gophish_get_campaigns",
"gophish_get_campaign",
"gophish_get_active_campaigns",
"gophish_get_completed_campaigns",
"gophish_get_recent_campaigns",
"gophish_get_latest_campaign",
"gophish_get_campaigns_summary",
"gophish_get_campaign_results",
"gophish_get_campaign_summary",
"gophish_get_campaign_analytics",
"gophish_get_global_analytics",
"gophish_get_system_status",
"gophish_search_campaigns",
"gophish_search_groups",
"gophish_search_templates",
"gophish_get_groups",
"gophish_get_templates",
"gophish_get_pages",
"gophish_get_smtp_profiles",
"gophish_get_users",
"gophish_get_campaign_by_status",
"gophish_get_campaign_by_date_range",
"gophish_get_campaign_targets",
"gophish_get_campaign_events"
]
}
}
}Step 3: Restart MCP Client
Restart your MCP client (Claude, Cursor, etc.)
๐ Security Note: Credentials are only configured in the server's
.envfile, not in the client JSON.All tools listed in
autoApproveare read-only according to the API implementation inserver.py. Any create, update or delete operation (gophish_create_*,gophish_update_*,gophish_delete_*) will always require manual approval.
๐ ๏ธ Tool Categories
Category | Description |
๐ READ-ONLY | These tools only read data and are automatically approved by the MCP client |
โ๏ธ WRITE | These tools modify data and require manual approval for security |
๐ Available Tools
๐ฏ Campaigns (Complete Management)
Basic Operations
Tool | Description | Type |
| Get all campaigns | ๐ READ-ONLY |
| Get details of a specific campaign | ๐ READ-ONLY |
| Create new campaign | โ๏ธ WRITE |
| Update existing campaign | โ๏ธ WRITE |
| Delete campaign | โ๏ธ WRITE |
Analysis and Statistics
Tool | Description | Type |
| Get latest campaign with complete statistics | ๐ READ-ONLY |
| Get summary of last N campaigns | ๐ READ-ONLY |
| Get detailed results of a campaign | ๐ READ-ONLY |
| Get summary with statistics of a campaign | ๐ READ-ONLY |
| Get complete analysis of a campaign | ๐ READ-ONLY |
Filters and Search
Tool | Description | Type |
| Get active campaigns | ๐ READ-ONLY |
| Get completed campaigns | ๐ READ-ONLY |
| Filter campaigns by status | ๐ READ-ONLY |
| Get campaigns from last N days | ๐ READ-ONLY |
| Get campaigns in date range | ๐ READ-ONLY |
| Search campaigns by name | ๐ READ-ONLY |
Utilities
Tool | Description | Type |
| Get all targets of a campaign | ๐ READ-ONLY |
| Get events of a campaign | ๐ READ-ONLY |
๐ฅ Groups (Complete Management)
Tool | Description | Type |
| Get all groups | ๐ READ-ONLY |
| Create new group | โ๏ธ WRITE |
| Update existing group | โ๏ธ WRITE |
| Delete group | โ๏ธ WRITE |
| Search groups by name | ๐ READ-ONLY |
๐ง Email Templates (Complete Management)
Tool | Description | Type |
| Get all templates | ๐ READ-ONLY |
| Create new template | โ๏ธ WRITE |
| Update existing template | โ๏ธ WRITE |
| Delete template | โ๏ธ WRITE |
| Search templates by name or subject | ๐ READ-ONLY |
๐ Landing Pages (Complete Management)
Tool | Description | Type |
| Get all pages | ๐ READ-ONLY |
| Create new page | โ๏ธ WRITE |
| Update existing page | โ๏ธ WRITE |
| Delete page | โ๏ธ WRITE |
๐ฎ SMTP Profiles (Complete Management)
Tool | Description | Type |
| Get all SMTP profiles | ๐ READ-ONLY |
| Create new SMTP profile | โ๏ธ WRITE |
| Update existing SMTP profile | โ๏ธ WRITE |
| Delete SMTP profile | โ๏ธ WRITE |
๐ค User Management
Tool | Description | Type |
| Get all users/administrators | ๐ READ-ONLY |
| Create new user | โ๏ธ WRITE |
| Update existing user | โ๏ธ WRITE |
๐ Global Analysis and Reports
Tool | Description | Type |
| Get system status and general statistics | ๐ READ-ONLY |
| Get global analysis of all campaigns | ๐ READ-ONLY |
๐ก Usage Examples
Once configured, you can use commands like:
Basic Management
Show me all GoPhish campaignsCreate a new campaign called "Test Campaign" using template with ID 1Update campaign with ID 5 to change its name to "Updated Campaign"Analysis and Reports
Show me the complete analysis of campaign with ID 3Get global statistics of all campaignsShow me events from campaign 2Search and Filters
Search campaigns containing "phishing" in the nameShow me all active campaignsGet campaigns created in the last 7 daysUser Management
List all system usersCreate a new administrator userAdvanced Search
Search templates containing "urgent" in the subjectFind groups containing "marketing" in the name๐ Security
โ ๏ธ Server disables SSL verification by default for local development
โ Make sure to use HTTPS in production
๐ Keep your API key secure and don't share it
๐ก๏ธ All write operations require valid authentication
๐งช Testing
Run Tests
# Run all tests
python test.py all
# Run read-only tests
python test.py readonly
# Run verbose demo
python test.py demo
# Run comprehensive tests
python test.py comprehensiveTesting Requirements
โ GoPhish server running
โ Valid credentials in
.envโ Dependencies installed:
pip install -e .
See tests/README.md for more details about testing.
๐ ๏ธ Utilities
Utility Scripts
# List campaigns
python utils/list_campaigns.py๐๏ธ Development
For local development:
# Install in development mode
pip install -e .
# Run server directly
python server.py
# Run tests
python test.py all๐ Additional Resources
Architecture Documentation - Learn about the server architecture
Test Results - View comprehensive test results
Made with โค๏ธ for the GoPhish community
โญ Star this repo if you find it useful!
License
This project is licensed under the MIT License. See the LICENSE file for details.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/dan1t0/gophish-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server