> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mantle.chat/llms.txt
> Use this file to discover all available pages before exploring further.

# Supabase

> Query data and manage your Supabase project — run SQL, manage auth, deploy edge functions, and control storage from Mantle

Connect Supabase to let selected agents query data and work with projects, users, functions, and storage that your
connected account can access.

***

## What you unlock

<CardGroup cols={2}>
  <Card title="SQL queries" icon="database">
    Execute read and write SQL queries against your Supabase Postgres database through natural language.
  </Card>

  <Card title="Auth management" icon="lock">
    Manage authentication users, SSO providers, and auth configuration without opening the Supabase dashboard.
  </Card>

  <Card title="Edge functions" icon="bolt">
    List, deploy, and invoke edge functions directly from chat or automated agent tasks.
  </Card>

  <Card title="Project control" icon="sliders">
    Manage projects, branches, storage buckets, and database configuration from one place.
  </Card>
</CardGroup>

***

## Connect Supabase

<Steps>
  <Step title="Open Settings → Integrations">
    In any workspace go to **Settings → Integrations** and select **Supabase**.
  </Step>

  <Step title="Authorize with OAuth">
    Click **Connect** and sign in to your Supabase account. Grant Mantle the requested permissions to access your
    projects and data.
  </Step>

  <Step title="Confirm the connection">
    Once authorized, you'll be redirected back to Mantle. The integration status will show as connected.
  </Step>
</Steps>

***

## Agent tools

Add Supabase tools to agents that need them. Their access is limited by the connected account and selected tools.

### Database & SQL

| Tool                | Description                                |
| ------------------- | ------------------------------------------ |
| Run SQL query       | Execute SQL against your Supabase database |
| Run read-only query | Execute a read-only SQL query              |
| List tables         | List all tables in the database            |
| Get table schemas   | Retrieve schema details for tables         |
| Select from table   | Query data from a specific table           |
| Generate types      | Generate TypeScript types from your schema |

### Projects & Branches

| Tool            | Description                                |
| --------------- | ------------------------------------------ |
| List projects   | List all Supabase projects                 |
| Get project     | Retrieve project details and health status |
| Create branch   | Create a database branch for development   |
| List branches   | List all branches for a project            |
| Apply migration | Apply a database migration                 |

### Edge Functions & Storage

| Tool            | Description                             |
| --------------- | --------------------------------------- |
| List functions  | List all edge functions in a project    |
| Deploy function | Deploy or update an edge function       |
| Invoke function | Call an edge function with parameters   |
| List buckets    | List all storage buckets                |
| Manage secrets  | Create, list, or delete project secrets |

***

## Triggers

<Note>
  Automated triggers for Supabase are not yet available. Triggers will be added in a future update — check back soon.
</Note>

***

## Example use cases

<AccordionGroup>
  <Accordion title="Quick data queries from chat">
    Ask "How many active users do we have?" and the agent translates your question into SQL, runs it against your
    Supabase database, and returns the result — no SQL client needed.
  </Accordion>

  <Accordion title="Deploy edge functions from conversations">
    After discussing a new webhook handler in chat, ask your agent to deploy the edge function to Supabase. It handles
    the deployment and confirms the function is live.
  </Accordion>

  <Accordion title="Database branch for feature development">
    Starting a new feature? Ask your agent to create a Supabase branch with the latest schema — it returns the branch
    URL and connection details ready for your development environment.
  </Accordion>
</AccordionGroup>

***

## Troubleshooting

<AccordionGroup>
  <Accordion title="OAuth connection failed">
    Make sure you are signing in with a Supabase account that owns or has access to the projects you want to manage. Try
    disconnecting and reconnecting from **Settings → Integrations → Supabase**.
  </Accordion>

  <Accordion title="SQL queries return errors">
    Check your SQL syntax and ensure the tables and columns referenced exist in your database. Use "List tables" and
    "Get table schemas" to verify the current schema before writing queries.
  </Accordion>

  <Accordion title="Edge function deployment fails">
    Verify the function code compiles and meets Supabase's edge function requirements (Deno runtime). Check that your
    project plan supports the number of edge functions you need.
  </Accordion>

  <Accordion title="Branch creation not available">
    Database branching requires a Supabase Pro plan or higher. Free tier projects do not support branching. Check your
    project's plan in the Supabase dashboard.
  </Accordion>
</AccordionGroup>

***

<Card title="Back to Integrations" icon="plug" href="/integrations/overview">
  View all available integrations
</Card>
