alengo/sulu-mcp-server-bundle
Read-only Sulu bundle exposing local template XML via authenticated admin API endpoints for MCP servers. Lists templates by type and returns raw XML. Secured by Sulu admin session plus required Bearer token; disabled if token is empty.
/admin/api/mcp/* or implement a Redis cache layer in the bundle.?format=json query parameter for backward compatibility.config/templates/pages) may not match custom Sulu setups.
template_dirs in configuration.| Risk Area | Assessment | Mitigation Strategy |
|---|---|---|
| Authentication Misconfiguration | Dual auth (session + token) may break if misconfigured (e.g., missing cookies). | Provide integration guides with cURL examples; validate auth flow in CI. |
| Template Path Mismatches | Custom Sulu setups may have non-standard template paths. | Allow full path customization via template_dirs; document default locations. |
| No Caching | High request volumes (e.g., live previews) could overload Sulu’s filesystem. | Recommend external caching (Varnish/Redis) or add a cache layer to the bundle. |
| XML Schema Assumptions | MCP servers must parse Sulu’s XML schema (e.g., <page>, <block>). |
Publish XML schema documentation; provide a JSON conversion endpoint (optional). |
| Token Security | Token rotation requires manual cache clearing. | Automate cache invalidation via Symfony event listener on token change. |
| MCP Protocol Gaps | Assumes MCP server understands Sulu’s XML structure. | Validate MCP server compatibility early; provide schema validation tools. |
404 for missing templates) or generic 403?/admin/api prefix).template_dirs).<page>, <block> tags).| Step | Action | Tools/Dependencies |
|---|---|---|
| 1. Pre-Integration Audit | Verify Sulu template structure (paths, XML schema). | find config/templates -type f |
| 2. Bundle Installation | Add to composer.json; register in config/bundles.php. |
Composer |
| 3. Configuration | Set MCP_SERVER_TOKEN in .env.local; customize template_dirs if needed. |
.env.local, config/packages/... |
| 4. Routing | Import alengo_mcp_server.yaml into Symfony’s routing. |
config/routes/... |
| 5. Security Setup | Test MCP server authentication (Sulu admin session + Bearer token). | Postman/cURL |
| 6. Client Integration | Configure MCP server to call /admin/api/mcp/templates/{type}/{name}. |
MCP server SDK |
| 7. Performance Tuning | Add caching (Varnish/Redis) or optimize template paths. | Symfony Cache, Nginx |
| 8. Monitoring | Set up logging/alerts for API access (e.g., failed auth, high latency). | ELK Stack, Symfony Monolog |
| 9. Documentation | Publish API specs (OpenAPI/Swagger) and MCP server integration guide. | Swagger UI, Markdown |
| 10. Token Rotation | Automate token rotation and cache invalidation (Symfony event listener). | Symfony Console Command |
How can I help you explore Laravel packages today?