Typefully
STDIOMCP server for creating and managing Typefully drafts via API integration
MCP server for creating and managing Typefully drafts via API integration
A Model Context Protocol (MCP) server that provides integration with the Typefully API, allowing AI assistants to create and manage drafts on Typefully.
git clone <repository-url> cd typefully-mcp-server
python3 -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -e .
This server supports secure API key storage using macOS Keychain. You have two options:
Store your API key securely in the macOS System keychain:
typefully-mcp-serverapi_keyFor detailed keychain setup instructions, see CURSOR_SETUP.md.
You can set the API key as an environment variable or include it directly in your MCP configuration.
Note: Environment variables take priority over keychain storage for compatibility.
For detailed MCP client setup instructions (Cursor, Claude Desktop, etc.), see CURSOR_SETUP.md.
Basic MCP configuration example:
{ "mcpServers": { "typefully": { "command": "/path/to/your/typefully-mcp-server/venv/bin/python", "args": ["-m", "typefully_mcp_server.server"], "cwd": "/path/to/your/typefully-mcp-server" } } }
Once configured, the MCP server provides the following tools:
Create a new draft in Typefully.
Parameters:
content (required): The content of the draft. Use 4 consecutive newlines to split into multiple tweets.threadify (optional): Automatically split content into multiple tweetsshare (optional): If true, returned payload will include a share_urlschedule_date (optional): ISO formatted date (e.g., "2024-01-15T10:30:00Z") or "next-free-slot"auto_retweet_enabled (optional): Enable AutoRT for this postauto_plug_enabled (optional): Enable AutoPlug for this postExample:
Create a draft with content "Hello from MCP! This is my first automated tweet." and schedule it for next free slot
Get recently scheduled drafts from Typefully.
Parameters:
content_filter (optional): Filter drafts to only include "tweets" or "threads"Example:
Get my scheduled drafts that are threads only
Get recently published drafts from Typefully.
Parameters:
content_filter (optional): Filter drafts to only include "tweets" or "threads"Example:
Show me all my recently published tweets
A test script is included to verify the server functionality:
# Make sure your virtual environment is activated source venv/bin/activate # On Windows: venv\Scripts\activate # Test the API connectivity (requires API key configured) python test_read_api.py
typefully-mcp-server/
├── src/
│   └── typefully_mcp_server/
│       ├── __init__.py
│       ├── server.py      # Main MCP server implementation
│       ├── client.py      # Typefully API client
│       ├── keychain.py    # Secure keychain integration
│       └── types.py       # Type definitions
├── pyproject.toml
├── requirements.txt
├── README.md
└── test_read_api.py       # Test script
# Make sure your virtual environment is activated source venv/bin/activate # On Windows: venv\Scripts\activate # Install development dependencies pip install -e ".[dev]" # Run tests pytest
This MCP server implements a subset of the Typefully API. For more details on the API endpoints and options, refer to the official documentation.
MIT License
Contributions are welcome! Please feel free to submit a Pull Request.