The Glif MCP Server provides a way to run AI workflows from glif.app using the Model Context Protocol (MCP). It allows you to execute glifs, manage bots, and access glif metadata through an MCP server compatible with Claude Desktop and other MCP clients.
~/Library/Application Support/Claude/claude_desktop_config.json
):{
"mcpServers": {
"glif": {
"command": "npx",
"args": ["-y", "@glifxyz/glif-mcp-server@latest"],
"env": {
"GLIF_API_TOKEN": "your-token-here"
}
}
}
}
git clone https://github.com/glifxyz/glif-mcp-server
cd glif-mcp-server
npm install
npm run build
{
"mcpServers": {
"glif": {
"command": "node",
"args": ["/path/to/glif-mcp/build/index.js"],
"env": {
"GLIF_API_TOKEN": "your-token-here"
}
}
}
}
{
"mcpServers": {
"glif": {
"command": "node",
"args": ["/path/to/glif-mcp/build/index.js"],
"env": {
"GLIF_API_TOKEN": "your-token-here",
"GLIF_IDS": "cm2v9aiga00008vfqdiximl2m,cm2v98jk6000r11afslqvooil,cm2v9rp66000bat9wr606qq6o",
"IGNORE_SAVED_GLIFS": true
}
}
}
}
To automatically install via Smithery:
npx -y @smithery/cli install @glifxyz/glif-mcp-server --client claude
You can convert specific glifs into standalone tools for easier access. Here's an example workflow:
Find interesting glifs:
What are some cool new glifs?
(This will trigger a list_featured_glifs
tool call)
Save a glif as a custom tool:
I like the 1970s sci-fi book cover generator, make that into a tool called "scifi_book_image"
(This will trigger a save_glif_as_tool
call with appropriate parameters)
Use your new tool directly:
Make sci-fi book image of a robot uprising
Note: Claude Desktop requires a restart to load new tool definitions, while some other clients may reload automatically.
glif://{id}
- Access glif metadataglifRun://{id}
- Get run detailsglifUser://{id}
- Access user profile informationThe server is subject to the same usage limits as regular user accounts. You can purchase additional credits at glif.app/pricing if needed.
To add this MCP server to Claude Code, run this command in your terminal:
claude mcp add-json "glif" '{"command":"npx","args":["-y","@glifxyz/glif-mcp-server@latest"],"env":{"GLIF_API_TOKEN":"your-token-here"}}'
See the official Claude Code MCP documentation for more details.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"glif": {
"command": "npx",
"args": [
"-y",
"@glifxyz/glif-mcp-server@latest"
],
"env": {
"GLIF_API_TOKEN": "your-token-here"
}
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.
To add this MCP server to Claude Desktop:
1. Find your configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%\Claude\claude_desktop_config.json
~/.config/Claude/claude_desktop_config.json
2. Add this to your configuration file:
{
"mcpServers": {
"glif": {
"command": "npx",
"args": [
"-y",
"@glifxyz/glif-mcp-server@latest"
],
"env": {
"GLIF_API_TOKEN": "your-token-here"
}
}
}
}
3. Restart Claude Desktop for the changes to take effect