Skip to content

Supabase Connector

The Supabase connector integrates with your Supabase project using the Management API and service role key, providing 10 live tools for database tables, authentication, storage, and RPC functions.

Authentication

Provide your Supabase project URL and service role key:

json
{
  "name": "Production Supabase",
  "source_type": "supabase",
  "config": {
    "project_url": "https://abcdefghijklmnop.supabase.co",
    "service_role_key": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
    "project_ref": "abcdefghijklmnop"
  }
}

Finding Your Credentials

  1. Go to your Supabase dashboard at app.supabase.com
  2. Select your project
  3. Navigate to Settings > API
  4. Copy the Project URL and service_role key (under "Project API keys")

WARNING

The service_role key bypasses Row Level Security (RLS). Never expose it in client-side code. Agentcy stores it encrypted and uses it only for server-side API calls.

Live Tools (10)

ToolDescriptionArguments
supabase_list_tablesList all tables with row counts and column infoschema?
supabase_describe_tableGet columns, types, constraints, and RLS policies for a tabletable, schema?
supabase_query_tableExecute a read-only SQL query via the Supabase SQL editor APIquery, limit?
supabase_list_auth_usersList auth users with metadata, providers, and last sign-inpage?, per_page?
supabase_insert_rowInsert a row into a tabletable, data, schema?
supabase_update_rowsUpdate rows in a table matching a filtertable, filter, data, schema?
supabase_delete_rowsDelete rows from a table matching a filtertable, filter, schema?
supabase_list_storage_bucketsList storage buckets with size, public flag, and file limits--
supabase_list_functionsList Edge Functions with status and deployment info--
supabase_call_rpcCall a database RPC functionfunction_name, params?

Example: Agent Using Supabase Tools

User: "How many users signed up in the last 7 days and what providers are they using?"

Agent: Let me check the auth users.
→ Calls supabase_list_auth_users(per_page: 100)
→ Filters for users created in the last 7 days
→ Reports: "42 new users in the last 7 days:
   - 28 via email/password
   - 11 via Google OAuth
   - 3 via GitHub OAuth
   Highest signup day was Tuesday with 12 signups."

ETL Ingestion

Nodes Created

Node LabelPropertiesSource
SupabaseTablename, schema, row_count, rls_enabled, column_countTables API
SupabaseColumnname, data_type, nullable, default_value, is_primary_keyTables API
SupabaseBucketname, public, file_size_limit, allowed_mime_types, created_atStorage API
SupabaseUserid, email, provider, confirmed_at, last_sign_in, roleAuth API
SupabaseFunctionname, slug, status, version, created_at, updated_atFunctions API
RLSPolicyname, table, command, definition, check_expressionTables API

Relationships Created

RelationshipFromTo
HAS_COLUMNSupabaseTableSupabaseColumn
HAS_POLICYSupabaseTableRLSPolicy
REFERENCESSupabaseTableSupabaseTable (foreign keys)
UPLOADS_TOSupabaseUserSupabaseBucket
INVOKESSupabaseFunctionSupabaseTable

Graph Queries

cypher
-- Find tables without RLS policies
MATCH (t:SupabaseTable)
WHERE t.rls_enabled = false
RETURN t.name, t.row_count

-- Map foreign key relationships
MATCH (t1:SupabaseTable)-[:REFERENCES]->(t2:SupabaseTable)
RETURN t1.name, t2.name

-- Find users by auth provider
MATCH (u:SupabaseUser)
RETURN u.provider, count(u) AS user_count
ORDER BY user_count DESC

Configuration Reference

FieldTypeDefaultDescription
project_urlstringrequiredSupabase project URL
service_role_keystringrequiredService role API key
project_refstring--Project reference ID (for Management API)
schemastringpublicSchema to scope tools and ingestion to
sync_tablesbooltrueInclude tables and columns
sync_authbooltrueInclude auth users
sync_storagebooltrueInclude storage buckets
sync_functionsbooltrueInclude Edge Functions
sync_rlsbooltrueInclude RLS policies
max_query_rowsint1000Maximum rows returned by supabase_query_table
query_timeout_secsint30Query execution timeout

Troubleshooting

ErrorCauseFix
401 UnauthorizedInvalid service role keyVerify the key in project settings
403 ForbiddenKey type is anon not service_roleUse the service_role key, not the anon key
404 Project not foundIncorrect project URLVerify the project URL in your dashboard
Connection refusedProject is pausedResume the project from the Supabase dashboard
Rate limitedToo many API requestsUpgrade your Supabase plan or reduce sync frequency

Built by AgentcyLabs. For in-house deployment or Agentcy Cloud (PaaS) access, visit agentcylabs.com.