Plain text for machines. The same content is at https://mcp.modelfy.ai/llms.txt
# For AI agents and developers
The MCP server serves its own documentation, in Markdown written for models. Point your agent there.
- llms.txt https://mcp.modelfy.ai/llms.txt
The index for agents: what the server does and where each page is.
- llms-full.txt https://mcp.modelfy.ai/llms-full.txt
Every documentation page in one file.
- Documentation https://mcp.modelfy.ai/docs
Every page also as Markdown: add .md to its URL.
- GitHub repository https://github.com/brookmind/modelfy-mcp
The server's source code (MIT), the Claude Code plugin and the docs.
## Documentation pages
Connected agents also read the docs with the get_docs tool, or as MCP resources at modelfy://docs/<page>. The server sends its own instructions on connect, tailored to the kind of connection, and every error carries a stable code, a next_step the agent can act on and a docs_url.
## The endpoint
https://mcp.modelfy.ai/mcp, Streamable HTTP. Sign-in with OAuth 2.1 (dynamic client registration, client ID metadata documents, PKCE) for chat assistants, or Authorization: Bearer mfy_live_… for bots and code.
## Ways to sign in
Most people only need the first one.
-
1. Sign in with Modelfy (OAuth) (Recommended)
Your assistant opens the Modelfy website: you sign in once and allow it. Nothing to copy and you are not asked again; the connection only ends after 90 days without use. You see every connected assistant in your account, under AI assistants and API keys, and can disconnect any of them.
-
2. Free sandbox key
Try it without an account: a free test key, valid for 30 days. Everything works with sample photos and nothing is spent.
-
3. Device login
For coding agents and bots: the agent shows you a link and a code, you approve in the browser and choose a test key or a live key with a budget. Nobody copies a key.
-
4. API key by hand
In your Modelfy account: AI assistants and API keys, Create key. Pick test or live; a live key gets a budget per photo session and per day. The key is shown once. You can have up to 20 keys and revoke any of them, and anything using it stops at once.
## Try it in ten seconds
Get a free sandbox key with no account and use it as the Bearer token in any MCP client. The catalog is real, everything else is canned, the photos are samples marked SANDBOX and nothing is spent. Limits: 5 keys per hour per address, 60 calls per minute per key.
curl -X POST https://mcp.modelfy.ai/sandbox/keys
By default a sandbox key launches without asking anyone. To try the spending rules your agent will really have, ask for a key that acts as a person ("person": generate_photos needs user_confirmed: true) or as a bot ("bot": the default budget of a live key):
curl -X POST https://mcp.modelfy.ai/sandbox/keys \
-H "Content-Type: application/json" \
-d '{"acts_as": "person"}'
No store to test with? The demo product page has image links that work with add_product_photos.
## A real key without copying it: device login
For an agent in a terminal or on a server (RFC 8628). Start with the name the person will see:
curl -X POST https://mcp.modelfy.ai/device/code \
-H "Content-Type: application/json" \
-d '{"client_name": "Store bot"}'
Show the person verification_uri_complete and the code. Then poll POST /device/token with the device_code every interval seconds until it returns the key, and store it as a secret. Every answer is in Keys and sign-in.
## Your own agent or bot
Any MCP SDK works. TypeScript, with @modelcontextprotocol/client:
import {
Client,
StreamableHTTPClientTransport,
} from "@modelcontextprotocol/client";
const client = new Client({ name: "store-bot", version: "1.0.0" });
await client.connect(
new StreamableHTTPClientTransport(new URL("https://mcp.modelfy.ai/mcp"), {
requestInit: {
headers: { Authorization: `Bearer ${process.env.MODELFY_API_KEY}` },
},
}),
);
const account = await client.callTool({ name: "get_account", arguments: {} });
Read client.getInstructions() once: the server sends its workflow and spending rules there. The Anthropic Messages API, the OpenAI Responses API and the xAI API can also connect to the server for you; examples in Connect your agent.
## The tools
| Tool | What it does | Spends credits |
| get_account | Balance, plan, price per photo; for live keys, the budget and today's spend | Free |
| list_modelslist_backgroundsget_photo_options | The catalog: people, places, formats, shot types | Free |
| add_product_photos | Product photos from public image links | Free |
| create_upload_sessionget_uploaded_photos | Photos from code (presigned PUT) or from a page a person opens | Free |
| plan_photos | Plans a session and returns its exact price and a quote_id | Free |
| generate_photos | Launches the planned session (needs the quote) | Spends credits |
| get_photo_session | Progress and finished photos; can wait until done | Free |
| list_recent_photoscancel_photo_session | Recent photos; stop a session (unstarted photos are refunded) | Refunds |
| get_docs | The documentation, by topic | Free |