- Create a Supabase account and access token
- Quick start: Install a pre-built Supabase toolkit into Powerboards in minutes
- Build and customize: Connect, test, and deploy the Supabase MCP server using the MeshAgent CLI
Supabase Setup (required for both paths)
- Create a Supabase account and a project at https://supabase.com.
- From the Project Settings -> General page you will see the Project ID (also called Project Reference). You will use this value to connect MeshAgent to your Supabase project.
- Create a Supabase access token. Go to Account Settings -> Access Tokens. Generate a new token and set an expiration date for it. Keep this value private.
Note: Each MCP connection is scoped to a single Supabase project. If you need to connect multiple projects, repeat the steps below with a different project reference and toolkit name.
Quickstart: Install via Powerboards
If you want to get up and running without using the MeshAgent CLI, you can install the Supabase toolkit directly into Powerboards.- Click the link below to open the supabase toolkit installer: Install Supabase Toolkit in Powerboards.
- Powerboards will walk you through the setup, you will sign in, create/select a Project, create/select a room, then install the toolkit. You will need to paste in your Supabase Project ID and Supabase Access Token you generated above. Powerboards will automatically store the access token as a secret.
- Next, click the link to install an agent that uses the toolkit: Install Agent that Uses Supabase Toolkit in Powerboards.
- Follow the same process to install the agent.
Build and Customize: CLI Guide
This path walks you through connecting and testing the Supabase MCP server locally, then deploying it as a persistent service. This is useful if you want to customize the toolkit, test changes before deploying, or understand how the pre-built Powerboards template works under the hood.Prerequisites
Before you begin, make sure you have:- The MeshAgent CLI installed (either globally via
brew install meshagentor in a python environment viauv add "meshagent[all]") - Connected to the MeshAgent project you want to work in (run
meshagent setupto authenticate and select your project) - Room admin access to the room you plan to use
- Your Supabase Project Reference and Access Token from the setup step above
api.secrets and api.admin grants. If you’re a room admin or project owner, when you run meshagent setup the CLI mints a participant token for you with those grants automatically. If you do not have a token with these grants ask an admin to do Step 2 for you.
Step 1: Export your credentials
Export your Supabase credentials so the following commands can reference them:bash
Step 2: Store the access token as a room secret
Create a room-scoped secret so the MCP server can authenticate with Supabase. This stores your access token under the secret IDsupabase and makes it available to the supabase identity (this is the identity we’ll use for the toolkit).
bash
Managing secrets for other identities
Managing secrets for other identities
When you create a room secret with 2. Generate the token:Copy the token value, then export it along with your project and room:You can find your project ID by running 4. Unset the environment variables when you’re done — otherwise your CLI will continue executing commands using the token you created:5. Reauthenticate and connect as yourself
--for-identity supabase, that secret belongs to the supabase identity — not to you. Running meshagent room secrets list --room myroom while authenticated as yourself won’t show it.To view or delete secrets for another identity, you need to generate a participant token for that identity and temporarily act as them.1. Create a token request file (e.g. supabase_token.yaml):meshagent project list or from the output of meshagent setup.3. View or delete the secrets:Step 3: Start the MCP Session
This command connects to the Supabase MCP server and exposes it as a toolkit in your room. The{supabase} placeholder in --header-secret resolves to the room secret you created in Step 2 (matching the --secret-id supabase).
The project_ref parameter in the URL determines which Supabase project this toolkit can access. Agents or humans using this toolkit will only be able to interact with that specific project.
bash
bash
myroom, open the menu in the upper left, and select Toolkits. You will see the supabase toolkit and its associated tools.
Step 4: Test with an agent
With the MCP session still running in your first terminal tab, from a second tab in your terminal start a chatbot agent that uses the Supabase toolkit:bash
Note: The --room-rules flag is optional. It creates a file at the specified path that anyone in the room can edit to customize the agent’s rules. This is useful if you want to tweak the agent’s behavior without redeploying it.
Try it out in MeshAgent Studio:
- Enter
myroom - Select the supabase-agent from the participants list
- Ask the agent to perform a task, such as listing tables in your Supabase project.
- Optionally, click the + button and enable Web Search to let the agent look up Supabase documentation on the fly.
Step 5: Deploy the Supabase toolkit as a persistent service
Once you’ve verified everything works locally, you can deploy the Supabase toolkit as a persistent service so the toolkit stays available without a local terminal session. Create a ServiceTemplate configuration file,meshagent.yaml, that defines the service:
bash
Warning: This command will deploy the service, but if the room secret does not exist the container will exit with Secret 'supabase' not found and the toolkit will not register.
After deployment, the Supabase toolkit will be available to any participant or agent in the room without a local MCP session.
To deploy the chatbot that uses the toolkit run:
bash
Publishing to Powerboards
Once you’re happy with your service template, you can make it installable via Powerboards so others can use it without going through the CLI steps.- Push your
meshagent.yamlto a GitHub Gist (or any publicly accessible URL). - Click the Raw button on the gist to get the direct URL to the file.
- Construct the Powerboards install link: https://app.powerboards.com/install?url=YOUR_RAW_URL
Powerboards note: the ServiceTemplate includes asupabase_access_tokenvariable withmeshagent.secret.*annotations. Powerboards uses that to prompt for the token and store the room secret automatically. The CLI ignores those annotations, so you still need to set the room secret yourself before deploying the toolkit that uses the service from the command line.