- Explore MCP Servers
- fal_api_mcp_server
Fal Api Mcp Server
What is Fal Api Mcp Server
fal_api_mcp_server is a Model Context Protocol (MCP) server that enables image generation using fal.ai’s FLUX.1 Pro model.
Use cases
Use cases include generating artwork based on user descriptions, creating marketing visuals, developing assets for video games, and producing images for social media content.
How to use
To use fal_api_mcp_server, you need to set up an API key from fal.ai and provide it as an environment variable. Then, you can call the ‘generate_image’ tool with required and optional parameters to generate images based on text prompts.
Key features
Key features include image generation from text prompts, customizable image size, the ability to generate multiple images, safety checker options, and support for different output formats (jpeg or png).
Where to use
fal_api_mcp_server can be used in various fields such as digital art creation, content generation for marketing, game development, and any application requiring automated image generation.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Fal Api Mcp Server
fal_api_mcp_server is a Model Context Protocol (MCP) server that enables image generation using fal.ai’s FLUX.1 Pro model.
Use cases
Use cases include generating artwork based on user descriptions, creating marketing visuals, developing assets for video games, and producing images for social media content.
How to use
To use fal_api_mcp_server, you need to set up an API key from fal.ai and provide it as an environment variable. Then, you can call the ‘generate_image’ tool with required and optional parameters to generate images based on text prompts.
Key features
Key features include image generation from text prompts, customizable image size, the ability to generate multiple images, safety checker options, and support for different output formats (jpeg or png).
Where to use
fal_api_mcp_server can be used in various fields such as digital art creation, content generation for marketing, game development, and any application requiring automated image generation.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
fal-api-mcp-server
A Model Context Protocol (MCP) server that provides image generation capabilities using fal.ai’s FLUX.1 Pro model.
Components
Resources
This server does not provide any persistent resources as fal.ai is primarily a stateless model execution service.
Tools
The server implements one tool:
- generate_image: Generates images based on text prompts using fal.ai FLUX.1 Pro
- Required parameters:
prompt: The text prompt to generate the image from
- Optional parameters:
image_size: The desired image size (default: “landscape_4_3”)- Options: “square_hd”, “square”, “portrait_4_3”, “portrait_16_9”, “landscape_4_3”, “landscape_16_9”
num_images: The number of images to generate (default: 1)enable_safety_checker: Enable the safety checker (default: true)safety_tolerance: Safety tolerance level 1-6, higher is more permissive (default: “2”)output_format: Output image format, “jpeg” or “png” (default: “jpeg”)
- Required parameters:
Configuration
This server requires a fal.ai API key to function properly. You can obtain an API key by signing up at fal.ai.
The API key should be provided as an environment variable:
FAL_KEY=your_fal_ai_api_key
You can set this environment variable in your shell, or create a .env file in the same directory as the server with the above content.
Demo
https://github.com/user-attachments/assets/564a0fc3-9204-4399-b1ea-ab6a5c9f2d84
Quickstart
Install
Claude Desktop
On MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%/Claude/claude_desktop_config.json
Development/Unpublished Servers Configuration
Published Servers Configuration
Usage
Once the server is configured and running, you can use it with Claude to generate images. Example prompts:
- “Generate an image of a mountain landscape at sunset”
- “Create a portrait of a cyberpunk character with neon lights”
- “Show me a futuristic cityscape with flying cars”
Claude will use the fal.ai FLUX.1 Pro model to generate the requested images.
Development
Building and Publishing
To prepare the package for distribution:
- Sync dependencies and update lockfile:
uv sync
- Build package distributions:
uv build
This will create source and wheel distributions in the dist/ directory.
- Publish to PyPI:
uv publish
Note: You’ll need to set PyPI credentials via environment variables or command flags:
- Token:
--tokenorUV_PUBLISH_TOKEN - Or username/password:
--username/UV_PUBLISH_USERNAMEand--password/UV_PUBLISH_PASSWORD
Debugging
Since MCP servers run over stdio, debugging can be challenging. For the best debugging
experience, we strongly recommend using the MCP Inspector.
You can launch the MCP Inspector via npm with this command:
npx @modelcontextprotocol/inspector uv --directory /path/to/fal-api-mcp-server run fal-api-mcp-server
Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










