← All articles

FLUX API and MCP: how to add image generation to your

A glowing stream of particles forming a picture

FLUX is an image generation model. NeuralSpace offers the following models: FLUX 2 Pro. They all run through a single public API, and there is a ready MCP server for AI agents. The key is issued on the API keys page.

What FLUX can do

FLUX 2 Pro generates images from a text description with high quality and detail. It supports 1K and 2K resolutions. The model renders textures, light and composition well, suiting illustrations, concepts and ad materials.

API endpoint

Send a request to POST /v1/images/generations. Example: {"model": "flux-2-pro", "prompt": "a landscape at sunset", "resolution": "2K"}. Authorization uses an API key in the x-api-key header. Available model ids: flux-2-pro.

A glowing stream of light particles

MCP tools

The NeuralSpace MCP server is available at POST /mcp (Streamable HTTP). To work with FLUX, an agent uses the tools: generate_image, list_models, get_balance. This lets Claude Code, Cursor and other MCP clients use the site models directly.

How to connect

Sign up on NeuralSpace, open the API keys page and create an nsk-… key. Then pass it in the request header or in your MCP client settings. Full documentation is on the the /v1/docs page.

FAQ

Which resolutions are available?

1K and 2K.

What is the model good for?

For illustrations, concepts and ad materials with high detail.

What format is the request?

POST /v1/images/generations with model and prompt fields.