Logo   espend.de
2026-01-17
MCP Service PHP Generator

Generates Symfony service definitions in YAML or XML format for a given PHP class. This MCP tool analyzes a class constructor to identify dependencies and creates service arguments for explicit wiring.

The tool supports both YAML (default) and XML output formats, with options to use the class name as service ID or generate a short ID.

YAML example:

App\Service\EmailService:
    arguments: ['@mailer', '@logger']

XML example:

<service id="App\Service\EmailService">
    <argument type="service" id="mailer"/>
</service>
Stimulus Controller Completion
StimulusControllerCompletionRegistrar
2026-01-17

Completion UX Html Twig

Auto-completes Stimulus controller names in HTML data-controller attributes and Twig stimulus_controller() function calls. The completion shows all registered Stimulus controllers from the project, including those from Symfony UX packages.

In HTML, normalized names are provided (e.g., symfony--ux-chartjs--chart). In Twig, both normalized names and original module names (e.g., @symfony/ux-chartjs/chart) are supported. Navigation from controller name to the source JavaScript file is also available.

HTML - data-controller attribute:

<div data-controller="symfony--ux-chartjs--chart">
    <canvas data-symfony--ux-chartjs--chart-target="canvas"></canvas>
</div>

Twig - stimulus_controller() function:

{{ stimulus_controller('symfony--ux-chartjs--chart', {
    'data': chartData
}) }}
Symfony Form Type Options MCP Tool
FormTypeOptionsMcpToolset
2026-01-14
MCP Form PHP

Lists all available options for a specific Symfony form type. This MCP tool provides detailed information about option names, their types (DEFAULT, REQUIRED, DEFINED), and the source classes that define them.

The tool accepts a form type name or FQN and returns CSV format with columns: name, type, source.

name,type,source
label,DEFAULT,Symfony\Component\Form\Extension\Core\Type\FormType
required,DEFAULT,Symfony\Component\Form\Extension\Core\Type\FormType
data,DEFAULT,Symfony\Component\Form\Extension\Core\Type\FormType
Symfony Profiler Requests MCP Tool
ProfilerRequestsMcpToolset
2026-01-14
MCP Profiler PHP

Lists the last 10 Symfony profiler requests with detailed information about HTTP requests, controllers, routes, templates, and form types used. This MCP tool provides optional filtering by URL, hash, controller, and route name.

The tool returns CSV format with columns: hash, method, url, statusCode, profilerUrl, controller, route, template, formTypes.

hash,method,url,statusCode,profilerUrl,controller,route,template,formTypes
18e6b8,GET,http://127.0.0.1:8000/user/1,200,_profiler/18e6b8,App\Controller\UserController::show,user_show,user/show.html.twig,
2026-01-11
MCP PHP

Lists all Symfony console commands available in the project. This MCP tool provides access to configured console commands with their class names and file paths.

The tool returns CSV format with columns: name, className, filePath.

name,className,filePath
cache:clear,\App\Command\CacheClearCommand,src/Command/CacheClearCommand.php
doctrine:fixtures:load,\Doctrine\Bundle\FixturesBundle\Command\LoadDataFixturesDoctrineCommand,vendor/doctrine/doctrine-fixtures-bundle/Command/LoadDataFixturesDoctrineCommand.php
Doctrine Entity Fields MCP Tool
DoctrineEntityFieldsMcpToolset
2026-01-11
MCP Doctrine PHP

Lists all fields of a Doctrine entity as CSV. This MCP tool provides detailed field information for a specific entity class including field names, column names, types, and relations.

The tool returns CSV format with columns: name, column, type, relation, relationType.

name,column,type,relation,relationType
id,id,integer,,
username,username,string,,
email,email,string,,
orders,orders,,App\Entity\Order,OneToMany
Doctrine Entities MCP Tool
DoctrineEntityMcpToolset
2026-01-11
MCP Doctrine PHP

Lists all Doctrine ORM entities in the project as CSV. This MCP tool provides access to all configured Doctrine entities with their class names and file paths.

The tool returns CSV format with columns: className, filePath.

className,filePath
App\Entity\User,src/Entity/User.php
App\Entity\Product,src/Entity/Product.php
App\Entity\Order,src/Entity/Order.php
2026-01-11
MCP Form PHP

Lists all Symfony form types configured in the project. This MCP tool provides access to form type aliases, class names, and their file locations.

The tool returns CSV format with columns: name, className, filePath.

name,className,filePath
user,App\Form\UserType,src/Form/UserType.php
email,Symfony\Component\Form\Extension\Core\Type\EmailType,vendor/symfony/form/Extension/Core/Type/EmailType.php
2026-01-11
MCP Routing PHP

Lists Symfony routes with their controller mappings and file paths. This MCP tool provides access to routes configured in the Symfony project with optional filtering by route name or controller.

The tool returns CSV format with columns: name, controller, path, filePath.

name,controller,path,filePath
app_home,App\Controller\HomeController::index,/,src/Controller/HomeController.php
api_users_list,App\Controller\UserController::list,/api/users,src/Controller/UserController.php
api_users_show,App\Controller\UserController::show,/api/users/{id},src/Controller/UserController.php
2026-01-11
MCP Routing PHP

Matches a plain request URL to Symfony routes using reverse pattern matching. This MCP tool finds routes that could handle a given URL path by matching against route patterns with placeholders.

The tool returns CSV format with columns: name, controller, path, filePath.

name,controller,path,filePath
api_user_show,App\Controller\Api\UserController::show,/api/users/{id},src/Controller/Api/UserController.php
api_user_list,App\Controller\Api\UserController::list,/api/users,src/Controller/Api/UserController.php
2026-01-11
MCP Service PHP

Locates where a Symfony service is defined in configuration files by service name or class name. This MCP tool provides access to service definitions with their file paths and line numbers.

The tool returns CSV format with columns: serviceName, className, filePath, lineNumber.

serviceName,className,filePath,lineNumber
app.service.my_service,\App\Service\MyService,config/services.yaml,15
app.my_service_alias,\App\Service\MyService,config/services.yaml,25
Twig Extensions MCP Tool
TwigExtensionMcpToolset
2026-01-11
MCP Twig PHP

Lists available Twig template extensions for code generation and template assistance. This MCP tool provides unified access to all Twig extensions including filters, functions, tests, and tags.

The tool returns CSV format with columns: extension_type, name, className, methodName, parameters.

extension_type,name,className,methodName,parameters
filter,upper,\Twig\Extension\CoreExtension,upper,"value,encoding"
function,path,\Twig\Extension\AssetExtension,path,"url,name"
filter,date,\Twig\Extension\CoreExtension,date,"date,format"
Empty Table attribute on entities is useless
DoctrineEmptyTableAttributeInspection
2026-01-09
Inspection PHP Paid Doctrine

Reports empty #[ORM\Table] attributes on Doctrine entities. An empty Table attribute (with no arguments) provides no additional configuration beyond the default table name and can be safely removed. The inspection only reports when an Entity attribute is also present on the class.

Before:

use Doctrine\ORM\Mapping as ORM;

#[ORM\Entity]
#[ORM\Table]  class Product
{
    // ...
}

After:

use Doctrine\ORM\Mapping as ORM;

#[ORM\Entity]
class Product
{
    // ...
}

Table attribute is only useful when you need custom configuration:

#[ORM\Entity]
#[ORM\Table(name: 'products', schema: 'app')]
class Product
{
    // ...
}
Use ON instead of WITH for arbitrary joins
DoctrineQueryBuilderJoinWithToOnInspection
2026-01-08
Inspection PHP Paid Doctrine

Reports deprecated WITH usage in Doctrine ORM QueryBuilder join methods and DQL for arbitrary joins. Since Doctrine ORM 3.x, WITH should only be used for association joins (defined relations), while ON should be used for arbitrary joins (joins with entity class and join condition). The inspection only triggers when the Doctrine ORM version has this deprecation.

QueryBuilder - Before (Deprecated):

$qb->join(Partner::class, 'p', Expr\Join::WITH, 'p.id = u.myId');
$qb->leftJoin('App\Entity\Geo', 'g', 'WITH', 'g.id = u.geoId');

QueryBuilder - After (Correct):

$qb->join(Partner::class, 'p', Expr\Join::ON, 'p.id = u.myId');
$qb->leftJoin('App\Entity\Geo', 'g', 'ON', 'g.id = u.geoId');

DQL - Before (Deprecated):

$em->createQuery('SELECT u FROM User u JOIN Banlist b WITH u.email = b.email');
$em->createQuery('SELECT u, p FROM User u JOIN ' . CmsPhonenumber::class . ' p WITH u = p.user');

DQL - After (Correct):

$em->createQuery('SELECT u FROM User u JOIN Banlist b ON u.email = b.email');
$em->createQuery('SELECT u, p FROM User u JOIN ' . CmsPhonenumber::class . ' p ON u = p.user');

Association joins (WITH is still valid):

// No warning - this is an association join (u.orders has a defined relation)
$qb->join('u.orders', 'o', 'WITH', 'o.status = :status');
Doctrine lifecycle callback methods must be public
DoctrineLifecycleMethodVisibilityInspection
2026-01-06
Inspection PHP Doctrine Paid

Reports methods with Doctrine lifecycle callback attributes that are not public. Doctrine lifecycle callback methods (like #[PostLoad], #[PrePersist], etc.) must be public to work correctly.

Instead of:

#[PostLoad]
private function afterLoad(): void
{
    // ...
}

Use:

#[PostLoad]
public function afterLoad(): void
{
    // ...
}
Entity class must have #[HasLifecycleCallbacks] attribute
DoctrineLifecycleMissingCallbacksAttributeInspection
2026-01-06
Inspection PHP Doctrine Paid

Reports entity classes using Doctrine lifecycle callback attributes (like #[PostLoad], #[PrePersist], etc.) without the #[HasLifecycleCallbacks] attribute. Doctrine requires this attribute on the entity class to enable lifecycle callbacks.

Instead of:

class User
{
    #[PostLoad]
    public function afterLoad(): void
    {
        // ...
    }
}

Use:

#[HasLifecycleCallbacks]
class User
{
    #[PostLoad]
    public function afterLoad(): void
    {
        // ...
    }
}
Symfony Console Command Completion in Terminal
CommandNameTerminalCompletionContributor
2025-12-11

Other Terminal Completion

Provides intelligent code completion for Symfony console commands directly in the integrated terminal. When typing bin/console or console commands, the plugin automatically suggests available commands, and for command options after the command name.

Supports completion for:

  • Command names: bin/console cac<Tab> → suggests cache:clear, cache:pool:clear, etc.
  • Command options: bin/console app:greet Fabien -<Tab> → suggests available options like --help, --quiet, -v, etc.
  • Option shortcuts and long forms are both supported

bin/console NAME
Migrate Twig Extension to PHP attributes
TwigExtensionToAttributeIntention
2025-12-10
Intention PHP Twig Attribute

Migrates Twig Extension from getFilters(), getFunctions(), and getTests() methods to PHP attributes.

Before:

<?php

namespace App\Twig;

use Twig\Extension\AbstractExtension;
use Twig\TwigFilter;
use Twig\TwigFunction;
use Twig\TwigTest;
use Twig\Environment;

class MyExtension extends AbstractExtension
{
    public function getFilters()
    {
        return [
            new TwigFilter('filter_name', [$this, 'filterMethod'], ['needs_environment' => true]),
        ];
    }

    public function getFunctions()
    {
        return [
            new TwigFunction('function_name', [$this, 'functionMethod'], [
                'needs_environment' => true,
                'needs_context' => true,
                'is_safe' => ['html']
            ]),
        ];
    }

    public function getTests()
    {
        return [
            new TwigTest('test_name', [$this, 'testMethod']),
        ];
    }

    public function filterMethod(Environment $env, $value)
    {
        return $value;
    }

    public function functionMethod(Environment $env, $context, $value)
    {
        return $value;
    }

    public function testMethod($value)
    {
        return $value;
    }
}

After:

<?php

namespace App\Twig;

use Twig\Attribute\AsTwigFilter;
use Twig\Attribute\AsTwigFunction;
use Twig\Attribute\AsTwigTest;
use Twig\Environment;

class MyExtension
{
    #[AsTwigFilter('filter_name', needsEnvironment: true)]
    public function filterMethod(Environment $env, $value)
    {
        return $value;
    }

    #[AsTwigFunction('function_name', needsEnvironment: true, needsContext: true, isSafe: ['html'])]
    public function functionMethod(Environment $env, $context, $value)
    {
        return $value;
    }

    #[AsTwigTest('test_name')]
    public function testMethod($value)
    {
        return $value;
    }
}
QueryBuilder array arguments deprecated (Doctrine DBAL 2.11+)
DoctrineQueryBuilderArrayDeprecationInspection
2025-12-09
Inspection PHP Doctrine Paid

Reports deprecated array usage in Doctrine DBAL QueryBuilder methods (select(), addSelect(), groupBy(), addGroupBy()). In Doctrine DBAL 2.11+, these methods no longer accept arrays and require individual arguments.

Instead of:

$qb->select(['u.id', 'p.id']);
$qb->addSelect(['u.name', 'p.name']);
$qb->groupBy(['u.category']);
$qb->addGroupBy(['u.status']);

Use:

$qb->select('u.id', 'p.id');
$qb->addSelect('u.name', 'p.name');
$qb->groupBy('u.category');
$qb->addGroupBy('u.status');
Add parameter to route action method
RouteActionParameterIntention
2025-12-04
Intention PHP

Adds a parameter (e.g., Request) to a Symfony route action method. Available when the cursor is inside a public method that has a Route attribute or annotation, or inside an __invoke method where the class has a Route attribute or annotation.

Before:

<?php
use Symfony\Component\Routing\Attribute\Route;

class MyController
{
    #[Route('/hello')]
    public function index(): Response
    {
    }
}

After:

<?php
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Attribute\Route;

class MyController
{
    #[Route('/hello')]
    public function index(Request $request): Response
    {
    }
}