Skip to content

Conversation

@jackwotherspoon
Copy link

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.

@dshukertjr
Copy link
Member

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.

@jackwotherspoon
Copy link
Author

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: mondaycom/mcp#120

@dshukertjr
Copy link
Member

@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?

SUPABASE.md Outdated
Comment on lines 12 to 16
- Use read-only mode (`?read_only=true`) to prevent accidental writes
- Scope to specific projects (`?project_ref=<project-ref>`) to limit access
- Limit tool access with feature groups (`?features=docs%2Caccount%2Cdatabase%2Cdebugging%2Cdevelopment`)
- Available groups: `account`, `docs`, `database`, `debugging`, `development`, `functions`, `storage`, `branching`
- Avoid connecting to production databases even in read-only mode
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are these thing things users add to the MCP url?

i.e. https://mcp.supabase.com/mcp?read_only=true

Because users when they install the extension will get the MCP server config of the extension json automatically (they can not configure it per say).

So a quick question:

I assume the same read-only and project specific stuff can also be configured via auth scopes during the oauth flow?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume the same read-only and project specific stuff can also be configured via auth scopes during the oauth flow?

Not currently, it requests all possible scopes. The only way to configure these options right now is through the URL.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jackwotherspoon In that case, would it be better to just omit this whole section as it's beyond what Gemini can do for the user?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I would probably omit for now. I'll think of some better ways we can enhance extensions framework to allow URL query params better in the future.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

@mattrossman
Copy link
Contributor

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).

@jackwotherspoon
Copy link
Author

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
Copy link
Author

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

@dshukertjr
Copy link
Member

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?

@jackwotherspoon
Copy link
Author

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 jackwotherspoon marked this pull request as ready for review November 19, 2025 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants