Since Dart 3.12 the SDK ships its own MCP server: dart mcp-server. It gives a coding agent the analyzer, dart fix, dart format, tests, hot reload, the widget inspector and pub.dev search. Our fl_mcp server gives the same agent your translations: list projects, add and translate strings, add languages, pull the ARBs, check the gen-l10n setup.
The two do different jobs and are meant to run side by side. This post shows the setup and the order the agent should use them in.
Setup
dart pub global activate flutter_localisation_cli
claude mcp add dart -- dart mcp-server
claude mcp add flutter-localisation --env FL_API_TOKEN=flk_live_xxx -- fl_mcp
The token comes from the dashboard, under API Keys. Any MCP client works; the JSON form is the same two entries:
{
"mcpServers": {
"dart": { "command": "dart", "args": ["mcp-server"] },
"flutter-localisation": {
"command": "/Users/you/.pub-cache/bin/fl_mcp",
"env": { "FL_API_TOKEN": "flk_live_xxx" }
}
}
}
Use absolute paths in desktop clients, which often start without ~/.pub-cache/bin on the PATH.
No tool name clashes
The Dart server can expose up to 25 tools (analyze_files, run_tests, dart_fix, hot_reload, pub, launch_app and others). fl_mcp has 17 (add_string, import_arb, pull_arbs, check_l10n_setup and others). None share a name, and clients prefix each tool with its server's name anyway.
Adding strings
add_stringfor one key,import_arbfor many. Both preview first and only write withapply: true.pull_arbswrites the regenerated ARBs into your repository.- Regenerate the Dart:
fl syncdoes pull and codegen in one step. analyze_fileson the Dart server confirms the new getters resolve.
Do not let the agent edit the ARB files directly. The backend owns them, and the next pull overwrites a hand edit.
After a Flutter upgrade
Current Flutter refuses synthetic-package: true, needs generate: true in pubspec.yaml, and no longer has package:flutter_gen. The loop is:
check_l10n_setupreports what is wrong. Withapply: trueit fixes all three.flutter gen-l10nregenerates the localizations.analyze_filesconfirms the app is clean.
We ran exactly this on a fresh app broken the way an upgrade breaks it, with both servers connected and nothing else installed. Asked only to fix "AppLocalizations is not found" and confirm with the analyzer, the agent called check_l10n_setup, applied the fix, regenerated, and analyze_files came back with no issues.
Add the skill too
The servers give the agent tools. The flutter-localisation agent skill tells it how to use them: work in bulk, never hand-edit generated files, keep the live update key out of source.
npx skills add tajaouart/flutter_localisation_cli --skill flutter-localisation