Android Studio
How to use Publishly from Gemini in Android Studio
Gemini in Android Studio's agent mode can use other tools through the Model Context Protocol. Publishly's MCP server gives it the same Play checks and the same renderer as this website, running on your computer, so your build never leaves it. It needs Node.js 20 or newer, and Chrome for rendering.
Step by step
Start the server
npx @publishly/cli mcp --httpstarts it on this computer and prints a block to paste: apublishlyserver athttp://127.0.0.1:47801/mcp. It keeps running until you stop it.Add it to Android Studio
Open Settings → Tools → AI → MCP Servers (Android Studio → Settings on a Mac), turn on Enable MCP Servers, paste the block and click OK. Type
/mcpin the Gemini chat to see the tools.Ask in agent mode
For example: check
app/build/outputs/bundle/release/app-release.aabfor what Play will object to, or renderMyApp.publishlywith the screenshots inapp/build/outputs/roborazzi, fastlane layout. Give full paths when you can: the server reads relative ones from the folder it runs in.Have it start at login
Android Studio connects only when it starts. Run
npx @publishly/cli mcp --installonce in your project's folder and the server starts at login and keeps running: a LaunchAgent on macOS, a systemd user service on Linux.npx @publishly/cli mcp --uninstallundoes it.Add a token, if you want one
The server listens on 127.0.0.1 only and refuses requests from other websites.
--token s3cretmakes every request carry a secret too, which keeps other programs on the computer out; the printed block includes it.
What the agent can use
check_app: the Play checks on an APK or app bundle, the same as Check app. Nothing is uploaded.project_infoandrender_project: a.publishlydesign saved from the editor, rendered to the same PNGs as Export all.render_videoandvideo_templates: a promo video from screenshots and recordings, with one template or a plan of several shots.whats_new: what changed in Publishly lately.
On Windows
There's no login service on Windows yet: keep npx @publishly/cli mcp --http running in a terminal, or add it to Task Scheduler to start when you log on.
Questions
Android Studio says “Connection refused”
The server wasn't running when Android Studio started, and Studio doesn't try again. Start it with npx @publishly/cli mcp --http, or npx @publishly/cli mcp --install to have it start at login from now on, then untick and tick Enable MCP Servers once.
Does my build leave my computer?
No. The server runs on your computer and reads the file there, the way the website reads it in your browser.
Does it work with other agents?
Yes. claude mcp add publishly -- npx @publishly/cli mcp adds it to Claude Code, which talks to it directly, without --http.
Other guides
Last checked against the app on 2026-10-20.