Falah Gate Salieh/Gemini-Email-Subject-Generator-MCP
Built by Metorial, the integration platform for agentic AI.
Falah Gate Salieh/Gemini-Email-Subject-Generator-MCP
Server Summary
Generate email subjects
Send emails with AI-generated subjects
Support HTML and plain text content
Handle image attachments
Provide error handling and status reporting
Customize content with rich formatting
A powerful Model Context Protocol (MCP) server that leverages Google's Gemini Flash 2 AI model to generate engaging email subjects and detailed thinking processes. This tool integrates seamlessly with Claude Desktop to provide intelligent email subject generation and advanced content creation.
send-email
)generate-thinking
)git clone [your-repo-url]
cd gemini-email-subject-generator
npm install
.env
file:GEMINI_API_KEY=your_api_key_here
[email protected]
NODEMAILER_PASSWORD=your_app_password_here
npm run build
%AppData%/Claude/claude_desktop_config.json
:{
"mcpServers": {
"Gemini Email Generator": {
"command": "node",
"args": ["path/to/gemini-email-subject-generator/dist/index.js"],
"cwd": "path/to/gemini-email-subject-generator",
"env": {
"GEMINI_API_KEY": "your_api_key_here",
"NODEMAILER_EMAIL": "[email protected]",
"NODEMAILER_PASSWORD": "your_app_password_here"
}
}
}
}
{
"name": "send-email",
"arguments": {
"to": "[email protected]",
"subjectPrompt": "Create a catchy subject line for a marketing email about our new AI-powered analytics platform",
"text": "Hello! This is the plain text version of our email.",
"html": "Hello!This is the HTML version of our email with an inline image: ",
"images": [
{
"name": "chart.png",
"data": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAA..."
}
]
}
}
Important Note About Email Tool: When you use the
send-email
tool, Claude will display a confirmation message that the email was sent successfully. This confirmation message is NOT the content of the email - it's just feedback to you that the operation succeeded. The actual email sent to the recipient will contain only the content you specified in thetext
andhtml
fields, with the subject generated by Gemini based on your prompt.
{
"name": "generate-thinking",
"arguments": {
"prompt": "Your complex analysis prompt here",
"outputDir": "./custom_output"
}
}
output/
āāā thinking/
āāā gemini_thinking_[timestamp].txt
npm run build
: Compile TypeScript to JavaScriptnpm run start
: Start the MCP servernpm run dev
: Run in development mode with ts-nodeGEMINI_API_KEY
: Your Google Gemini API keyNODEMAILER_EMAIL
: Your email address for sending emailsNODEMAILER_PASSWORD
: Your email app password (for Gmail, use an app password).env
fileAPI Key Error
.env
file existsClaude Desktop Connection
Email Sending Issues
Add DEBUG=true
to your .env
file for verbose logging:
GEMINI_API_KEY=your_key_here
DEBUG=true
interface SendEmailParams {
to: string; // Recipient email address
subjectPrompt: string; // Prompt for generating email subject
text: string; // Plain text version of email
html?: string; // HTML version of email (optional)
images?: { // Optional images to attach
name: string; // Image filename
data: string; // Base64 encoded image data
}[];
}
interface GenerateThinkingParams {
prompt: string; // Analysis prompt
outputDir?: string; // Optional output directory
}
MIT License - See LICENSE file for details