supabase-mcp icon indicating copy to clipboard operation
supabase-mcp copied to clipboard

feat: add Gemini CLI extension for Supabase

Open jackwotherspoon opened this issue 1 month ago • 9 comments

Hi Gemini CLI team member here 👋

We recently launched Gemini CLI extensions: geminicli.com/extensions

Extensions build on top of MCP, making it better. By providing a custom context file for all users that explains to the agent how to perform complex workflows leveraging the MCP tools, debug common issues, best practices, etc. This vastly improves the agentic capabilities beyond MCP for your users.

We are building a flourishing ecosystem around extensions and want Supabase to be a part of that ecosystem. ⚡

We have a lot planned for extensions and are working to make them easily discoverable for all from within Gemini CLI.

Once this PR is merged and a new Supabase MCP release is done (or existing release is patched to add in new extension files) then Supabase will be available and show up on geminicli.com/extensions.

Improvements

The area I can use some assistance in is making the SUPABASE.md more robust. This context will be loaded automatically for users when they install the Supabase extension. Providing best practices and guidance here will supercharge the extension for users.

Installation

This will be the installation command for users once released:

gemini extensions install https://github.com/supabase-community/supabase-mcp

Once installed, users can run /mcp auth supabase from within Gemini CLI to authenticate the Supabase MCP server.

jackwotherspoon avatar Nov 11 '25 17:11 jackwotherspoon

Thanks for this PR @jackwotherspoon !

How detailed should the SUPABASE.md file be? Would the entire thing be loaded, or is it able to load just the relevant chunks? I found the Flutter example, which is very long and detailed, and the Firebase example, which is super simple and brief.

dshukertjr avatar Nov 12 '25 01:11 dshukertjr

How detailed should the SUPABASE.md file be? Would the entire thing be loaded, or is it able to load just the relevant chunks? I found the Flutter example, which is very long and detailed, and the Firebase example, which is super simple and brief.

Excellent question, I would lean for a middle ground between the two examples. The entire file will be loaded into context so you want to be fairly concise but also provide value.

General best practices for Supabase and troubleshooting etc are great candidates.

@dshukertjr I see that Supabase has some detailed prompts: https://supabase.com/docs/guides/getting-started/ai-prompts

These would be great candidates to be turned into custom commands included in the extension.

Such as a /supabase:create_migration.

Attaching a PR for monday.com extension I did that I think is the best example so far of an extension: https://github.com/mondaycom/mcp/pull/120

jackwotherspoon avatar Nov 12 '25 01:11 jackwotherspoon

@jackwotherspoon Something like what I have right now good?

Also, regarding the commands with the Monday example, I didn't see the commands/monday directory being referenced in the gemini-extension.json file, but do they get automatically picked up by Gemini and will be available like /monday:create-item? In our case, we can just bring over those prompts as toml files inside commands/supabase directory?

dshukertjr avatar Nov 12 '25 03:11 dshukertjr

It would be helpful to write this MCP best practices doc in a way that could be re-used across clients beyond just Gemini CLI. I'm experimenting with a similar steering file for Kiro IDE (see WIP supabase-mcp.md), but there's also Cursor rules, Claude Skills, etc. I figure most IDE clients should follow a consistent overall workflow.

One challenge is that there's different desired workflows when connecting to MCP with our local stack vs hosted platform. For instance, local MCP has fewer tools and the option for agents to operate directly on the supabase/ directory in the codebase. For IDE integrations, a local-first workflow might be preferable, though hosted is simpler to set up. In the case of Kiro, a solution we're considering is two integrations (one for local, one for hosted).

mattrossman avatar Nov 12 '25 17:11 mattrossman

Also, regarding the commands with the Monday example, I didn't see the commands/monday directory being referenced in the gemini-extension.json file, but do they get automatically picked up by Gemini and will be available like /monday:create-item?

Yes commands/supabase folder will get auto-picked up and does not need to be referenced in the JSON.

In our case, we can just bring over those prompts as toml files inside commands/supabase directory?

Yes they should be able to be brought over almost directly as is. 😄

jackwotherspoon avatar Nov 17 '25 13:11 jackwotherspoon

It would be helpful to write this MCP best practices doc in a way that could be re-used across clients beyond just Gemini CLI. I'm experimenting with a similar steering file for Kiro IDE (see WIP supabase-mcp.md), but there's also Cursor rules, Claude Skills, etc. I figure most IDE clients should follow a consistent overall workflow.

You can totally re-use an existing best practices for the markdown file 👍

Doesn't have to be explicitly tailored towards Gemini CLI

jackwotherspoon avatar Nov 19 '25 14:11 jackwotherspoon

Honestly, about the commands feature, the AI prompts here aren't super well-maintained, and I would prefer not to create another location for them to be maintained. I would prefer to maybe start out without the commands and see how it goes, but how does that sound to everyone?

dshukertjr avatar Nov 19 '25 14:11 dshukertjr

Honestly, about the commands feature, the AI prompts here aren't super well-maintained, and I would prefer not to create another location for them to be maintained. I would prefer to maybe start out without the commands and see how it goes, but how does that sound to everyone?

Works for me! You can easily add commands at a later date 👍

jackwotherspoon avatar Nov 19 '25 14:11 jackwotherspoon

@mattrossman , @Rodriguespn, what do you think of the current state of the PR?

dshukertjr avatar Nov 24 '25 08:11 dshukertjr

Hey @jackwotherspoon we're currently working on a similar integration with Kiro: https://github.com/supabase-community/kiro-powers

I anticipate overlap between Gemini's SUPABASE.md and Kiro's steering docs, so I'd like to wrap up the Kiro integration (should be done this week) before transplanting it into this Gemini extension.

mattrossman avatar Dec 02 '25 16:12 mattrossman