Home / MCP / Freepik MCP Server
Provides access to Freepik stock resources and Mystic AI image generation via an MCP server.
Configuration
View docs{
"mcpServers": {
"freepik": {
"command": "node",
"args": [
"path/to/freepik-mcp/build/index.js"
],
"env": {
"FREEPIK_API_KEY": "YOUR_API_KEY"
}
}
}
}You run a Freepik MCP Server to access Freepik resources and Mystic AI image generation through a single MCP endpoint. This server lets you search assets, view details, download resources, generate images with Mystic AI, and check generation status, all via your MCP client.
Start by adding the Freepik MCP server to your MCP client configuration. You will run the server locally and connect to it through the MCP protocol. The server exposes operations for searching resources, retrieving resource details, downloading resources, generating images with Mystic AI, and checking the status of those generations.
Typical usage patterns include: searching for stock photos or vectors, fetching detailed information about a specific resource, obtaining a download URL for a resource, generating a new image from a text prompt, and polling for the completion status of a Mystic AI generation task. Your MCP client will invoke these endpoints through the server’s exposed toolset.
Prerequisites: Node.js 18 or higher and a Freepik API key.
Step 1: Create a directory for MCP servers and navigate into it.
mkdir mcp-servers
cd mcp-serversStep 2: Clone the Freepik MCP server repository and install dependencies.
git clone https://github.com/MCERQUA/freepik-mcp.git
cd freepik-mcp
npm install
npm run buildStep 3: Configure your Freepik API key and start the server through your MCP setup. The following is a representative MCP configuration you would place in your MCP settings to run the local server.
{
"mcpServers": {
"freepik": {
"command": "node",
"args": ["path/to/freepik-mcp/build/index.js"],
"env": {
"FREEPIK_API_KEY": "your-api-key-here"
},
"disabled": false,
"autoApprove": []
}
}
}Obtain your Freepik API key and ensure it is available to the server at runtime. The API key is passed to the server via the FREEPIK_API_KEY environment variable. Start the server using the command configuration shown above and keep your API key secure.
- Securely manage API keys and rotate them periodically according to your organizational policies. - Ensure access to the local MCP server is restricted to trusted clients. - Monitor logs for API errors and rate limit considerations. - Regularly update dependencies and rebuild the server to incorporate security fixes.
If the server fails to start, check that Node.js 18+ is installed, the Freepik API key is present in the environment, and the build output path matches your configuration. Review logs for authentication errors from Freepik and for any validation issues reported by the MCP client.
Search Freepik resources with filters such as term, limit, order, and content/type/license filters.
Retrieve detailed information for a specific Freepik resource by its ID.
Get a direct download URL for a specific Freepik resource by its ID.
Create a Mystic AI-generated image from a text prompt with options for resolution, aspect ratio, realism, engine, and detailing.
Check the status of an ongoing Mystic AI generation task using its task_id.