Back to overview
MCP Integration (AI Tools)
Connect AI assistants like Lovable, Cursor or Claude directly to your CMS.
What is MCP?
MCP (Model Context Protocol) is an open standard that lets AI assistants communicate directly with external tools. Instead of copying and pasting, an AI assistant can directly:
• Create and edit pages in your CMS
• Translate content to other languages
• Publish your website
• View bookings and orders
• Retrieve analytics
Think of MCP as a 'remote control' that lets AI tools operate your CMS.
View the full MCP technical documentation at developers.optimocms.com.
Connect MCP to Lovable
Lovable supports custom MCP servers on all paid plans. Follow these steps to connect your Optimocms site:
1. Open your Lovable project
2. Go to Connectors → Chat connectors
3. Click 'New MCP server'
4. Fill in the fields:
• Server name: Optimocms
• Server URL: https://europe-west4-cms-sg.cloudfunctions.net/mcpServer
5. Choose an authentication method:
• Bearer token or API key (recommended): paste your Optimocms API key (starts with omc_)
• No authentication is NOT supported — an API key is always required
6. Click 'Add & authorize'
The MCP server now appears in your list of chat connectors. Lovable's AI assistant can read and edit your CMS directly.
Where do I find my API key?
Go to your Optimocms dashboard → Settings → API Keys. Create a new key and select which permissions Lovable should have (e.g. read pages, create pages, publish).
Tips
- You need a paid Lovable plan (Starter, Launch or Scale) for custom MCP servers.
- Create a separate API key for Lovable with only the permissions you need.
- Use a test site first before connecting Lovable to your production site.
- You can revoke the API key at any time in Settings → API Keys.
Lovable example prompts
After connecting Optimocms to Lovable, you can use natural language prompts. Here are practical examples:
1. Build a landing page
"Create a modern landing page for my bakery with a hero section, opening hours, photo gallery and contact form."
2. Add a page section
"Add a testimonials section to my homepage with 3 customer reviews."
3. Translate content
"Translate all pages of my site to German and French."
4. Create shop products
"Add 5 products to my webshop: sourdough bread (€4.50), croissant (€2.80), baguette (€3.20), cinnamon roll (€3.50) and focaccia (€5.00). Add descriptions and categories."
5. Manage bookings
"Show all bookings for next week and create a new booking for John Smith on Friday at 14:00."
6. View analytics
"Show me visitor statistics for the past 30 days. Which pages have the most traffic?"
7. Improve existing content
"Improve the text on my about page. Make it more professional and add a call-to-action."
8. Publish the website
"Publish my website so the latest changes go live."
All prompts work in any language — Lovable and Optimocms understand English, Dutch, German, French and Spanish.
Lovable troubleshooting
Connection fails?
• Check that your Server URL is exactly: https://europe-west4-cms-sg.cloudfunctions.net/mcpServer
• Verify your API key starts with omc_ and is not expired
• Ensure you selected 'Bearer token or API key' as authentication method
Lovable says 'no tools available'?
• Remove and re-add the MCP server in Lovable
• Verify the API key has at least read permissions
• Wait a few seconds after connecting — Lovable fetches the tool list on first use
Changes not visible on my site?
• Content changes are saved as draft by default. Use the prompt 'Publish my site' or publish manually in the CMS.
Rate limit errors?
• Your plan has a maximum number of API requests per minute. Upgrade your plan or wait a moment before trying again.
Connect MCP to Cursor
Add the following to your Cursor MCP configuration (~/.cursor/mcp.json):
{
"mcpServers": {
"optimocms": {
"url": "https://europe-west4-cms-sg.cloudfunctions.net/mcpServer",
"headers": {
"Authorization": "Bearer omc_your_api_key"
}
}
}
}
After restarting Cursor you can ask questions like 'Show my pages' or 'Publish my site'.
Connect MCP to Claude Desktop
Add the following to your Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"optimocms": {
"url": "https://europe-west4-cms-sg.cloudfunctions.net/mcpServer",
"headers": {
"Authorization": "Bearer omc_your_api_key"
}
}
}
}
Claude can now manage your CMS directly via chat.
Available tools
The following tools are available via MCP:
• list_sites — Show all your websites
• list_pages / get_page — View pages
• create_page / update_page — Create or edit pages
• publish_site — Publish website
• generate_page — AI generates a page from a description
• translate_page — Translate a page
• assist_content — AI improves existing content
• get_analytics — Retrieve visitor statistics
• list_products / create_product — Manage shop products
• list_bookings / create_booking — Manage bookings
• earn_points / list_rewards — Manage loyalty program
View the complete tools overview with all parameters and examples.
Frequently asked questions
Does MCP cost extra?
No, MCP is included in all paid plans (Starter, Professional and Agency). You use the same API key and limits as the REST API.
Can the AI accidentally delete my site?
No. Deletion is not available via MCP. Publishing requires the 'publish' permission on your API key.
Which AI tools work with MCP?
Lovable, Cursor, Claude Desktop, Windsurf, and any tool that supports the MCP protocol.
How do I secure my MCP connection?
Use an API key with minimal permissions. Create a separate key per tool. Revoke the key when you stop using a tool.
Tips
- Start with an API key that only has read permissions. Add write permissions once you are sure the AI works correctly.
- Always test on a test website before using MCP on your production site.