list_api_routesLABSCO SUMMARY
Validation rules are the part an agent otherwise gets wrong every time.
A route list tells you the endpoint exists; the form request tells you what it will actually reject, and that is where generated client code and generated tests fall over. Parsing those rules — with the authorisation logic beside them — means the agent knows the contract rather than guessing it from a controller signature. The single-call whole-endpoint view is the one to use in practice: it saves the four round trips you would otherwise spend assembling the same picture.
What it is
A package you add to a Laravel application so an agent can ask the codebase what its API actually is, rather than inferring it from source.
What you get
- Route discovery, filterable by path, method, domain, with vendor routes excluded
- Controller inspection, down to file paths and line numbers
- Validation analysis — the form request rules, custom messages and authorisation logic
- Response schema analysis over return types, resources and model attributes
- One call that returns everything about a single endpoint
- Routes and controllers also reachable as addressable resources
Requirements
PHP 8.2 or higher and Laravel 12.x, installed with composer. MIT licensed.
Setup effort
One command — composer require 0xmergen/lmad
USE CASES
Understanding an endpoint
Route, controller, validation and response shape in one call.
Generating a client that works
The real validation rules, not the inferred ones.
Finding the code
Controller methods with file paths and line numbers.
5 tools
Listed in project docs. Your client may show a different list.
get_route_detailsget_request_rulesget_response_schemaanalyze_endpointBEFORE YOU INSTALL
What to know first
Tools you get
5 tools named in the project's documentation.
Requires
- PHP 8.2 or later
- Laravel 12.x
- laravel/mcp 0.5.x
Where it runs
All 5 documented setups run the server on your machine.
INSTALLATION
Connect your client
Server setup
composer require 0xmergen/lmadMCP Clients
Claude Desktop — stdio, Claude Code — stdio
{
"mcpServers": {
"lmad": {
"command": "php",
"args": [
"<YOUR_PATH_TO_LMAD_PROJECT_ARTISAN>",
"mcp:serve",
"--server=lmad"
],
"env": {
"APP_ENV": "local"
}
}
}
}Claude Code — HTTP
{
"mcpServers": {
"lmad": {
"type": "http",
"url": "http://localhost:8000/mcp/lmad"
}
}
}Cline — stdio
{
"mcpServers": {
"lmad": {
"command": "php",
"args": [
"<YOUR_LARAVEL_ROOT>/artisan",
"mcp:serve",
"--server=lmad"
],
"env": {
"APP_ENV": "local",
"LARAVEL_ROOT": "<YOUR_LARAVEL_ROOT>"
}
}
}
}Cline — HTTP
{
"mcpServers": {
"lmad": {
"type": "streamableHttp",
"url": "http://localhost:8000/mcp/lmad",
"headers": {
"Accept": "application/json"
}
}
}
}