Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.sequenzy.com/llms.txt

Use this file to discover all available pages before exploring further.

Connect your Supabase database to automatically sync users to Sequenzy. When users are added to your database, they become subscribers instantly.

What is Supabase?

Supabase is an open-source Firebase alternative that provides a PostgreSQL database, authentication, real-time subscriptions, and more. Many SaaS applications use Supabase as their backend.

Connecting Supabase

Step 1: Generate a Webhook Secret

  1. Go to Settings → Integrations in Sequenzy
  2. Click Connect next to Supabase
  3. Click Generate Secret to create a secure webhook secret
  4. Copy the generated secret — you’ll need it in the next step
Generate webhook secret in Sequenzy

Step 2: Create Database Webhook in Supabase

  1. Go to your Supabase Dashboard
  2. Navigate to DatabaseWebhooks
  3. Click Create a new hook
  4. Configure the webhook:
    • Name: sequenzy-user-sync (or any name you prefer)
    • Table: Select your users table (e.g., users or profiles)
    • Events: Select INSERT, UPDATE, and DELETE
    • Type: HTTP Request
    • Method: POST
    • URL: Paste your Sequenzy webhook URL (shown in the modal)
  5. Add an HTTP header for authentication:
    • Header name: x-webhook-secret
    • Header value: Paste the secret you generated in Step 1
  6. Click Create webhook
Create webhook in Supabase dashboard
The x-webhook-secret header is required to verify that webhooks are coming from your Supabase project. Make sure the value matches exactly what you entered in Sequenzy.

Step 3: Save the Connection

  1. Return to Sequenzy’s Supabase connection modal
  2. Click Save Connection
That’s it! Your Supabase users will now sync automatically to Sequenzy.

Route Supabase Auth and Security Emails Through Sequenzy SMTP

The database webhook above handles subscriber sync. Supabase Auth emails are a separate path. If you want Supabase invites, magic links, password resets, and security notifications to send through Sequenzy too, configure Supabase to use Sequenzy SMTP and point each Supabase email template at a Sequenzy transactional email.

Step 4: Configure Supabase SMTP

  1. Create a Sequenzy API key in Settings → API Keys
  2. In Supabase, go to Authentication → Emails → SMTP Settings
  3. Enable custom SMTP and use:
SettingValue
Hostsmtp.sequenzy.com
Port587
Usernameapi
PasswordYour Sequenzy API key
Use a sender address that belongs to a verified Sequenzy sending domain. Supabase still needs a sender configured, even when Sequenzy renders the final template.

Step 5: Point Supabase Email Templates at Sequenzy Transactionals

If your workspace does not have a verified sender profile yet, Sequenzy automatically provisions a shared-domain sender and assigns it to the default Supabase templates. In Sequenzy, open the Supabase integration modal and click Create default Supabase auth templates. This provisions the standard transactional emails for:
  • supabase-confirm-signup
  • supabase-invite
  • supabase-magic-link
  • supabase-password-reset
  • supabase-email-change
  • supabase-password-changed
  • supabase-phone-changed
  • supabase-identity-linked
  • supabase-identity-unlinked
  • supabase-mfa-enrolled
  • supabase-mfa-removed
Then replace the Supabase message body with a JSON payload that references the matching Sequenzy slug. You can reference the Sequenzy email by slug or transactionalId. variables and dataVariables are both supported. Example for a Magic Link template:
{
  "slug": "supabase-magic-link",
  "dataVariables": {
    "confirmation_url": "{{ .ConfirmationURL }}",
    "token": "{{ .Token }}",
    "token_hash": "{{ .TokenHash }}",
    "redirect_to": "{{ .RedirectTo }}",
    "site_url": "{{ .SiteURL }}",
    "email": "{{ .Email }}"
  }
}
Example for an Email Changed notification:
{
  "slug": "supabase-email-change",
  "dataVariables": {
    "email": "{{ .Email }}",
    "old_email": "{{ .OldEmail }}",
    "new_email": "{{ .NewEmail }}"
  }
}

Suggested Variable Mapping

Supabase template variableSuggested Sequenzy merge tag
{{ .ConfirmationURL }}{{confirmation_url}}
{{ .Token }}{{token}}
{{ .TokenHash }}{{token_hash}}
{{ .RedirectTo }}{{redirect_to}}
{{ .SiteURL }}{{site_url}}
{{ .Email }}{{email}}
{{ .NewEmail }}{{new_email}}
{{ .OldEmail }}{{old_email}}
{{ .Phone }}{{phone}}
{{ .OldPhone }}{{old_phone}}
{{ .Provider }}{{provider}}
{{ .FactorType }}{{factor_type}}
  • Keep the database webhook integration enabled for subscriber sync
  • Use Sequenzy SMTP for Supabase Auth email delivery
  • Create one Sequenzy transactional email per Supabase template type
  • Use clear slugs like supabase-invite, supabase-magic-link, and supabase-password-reset

What Gets Synced

Sequenzy automatically maps common database columns to subscriber attributes:

Email Detection

Sequenzy looks for email in these columns (in order):
  • email
  • email_address
  • user_email
  • contact_email

User ID Detection

User ID is extracted from:
  • id
  • user_id
  • uid
  • uuid

Synced Attributes

Database ColumnSubscriber Attribute
first_namefirstName
last_namelastName
full_namefullName
avatar_urlavatarUrl
phonephone
Any other columnStored as custom attribute
Sensitive columns like password, password_hash, and encrypted_password are automatically excluded.

Tracked Events

Database EventSequenzy Event
INSERTcontact.subscribed
UPDATEAttributes updated (no event)
DELETEcontact.unsubscribed

Using with Automations

Welcome Sequence for New Users

  1. Go to AutomationsCreate New
  2. Set trigger to Event Receivedcontact.subscribed
  3. Add your welcome email sequence
  4. Activate the automation
Every new row in your users table will trigger the welcome sequence.

Custom Attributes

Any column in your users table becomes available for segmentation and personalization:
-- Your users table might have:
CREATE TABLE users (
  id UUID PRIMARY KEY,
  email TEXT,
  first_name TEXT,
  plan TEXT,          -- becomes {{ plan }}
  company_name TEXT,  -- becomes {{ company_name }}
  created_at TIMESTAMP
);
Use these in emails:
Hi {{firstName}},

Thanks for signing up for the {{plan}} plan!

Database Schema Recommendations

For best results, include these columns in your users table:
-- Recommended columns
email TEXT NOT NULL,        -- Required for subscriber creation
first_name TEXT,            -- Maps to firstName
last_name TEXT,             -- Maps to lastName
-- Optional but useful
avatar_url TEXT,            -- Profile picture
phone TEXT,                 -- Phone number
plan TEXT,                  -- Subscription plan
created_at TIMESTAMP        -- For tracking

User Lifecycle

Supabase EventSequenzy Action
Row insertedSubscriber created, contact.subscribed triggered
Row updatedSubscriber attributes updated
Row deletedSubscriber unsubscribed
When you delete a user from your database, they’re automatically unsubscribed in Sequenzy.

Troubleshooting

Users Not Syncing

  1. Verify the webhook URL is correct in Supabase
  2. Check that the x-webhook-secret header matches the secret in Sequenzy
  3. Ensure all events (INSERT, UPDATE, DELETE) are selected
  4. Check Supabase’s webhook logs for failed deliveries

Missing Email

If users are inserted without an email column value, Sequenzy cannot create a subscriber. Ensure your users table has a valid email.

Wrong Columns Mapping

Sequenzy looks for standard column names. If your schema uses different names:
  • email_address → works (detected automatically)
  • customer_email → works (detected automatically)
  • e_mail → won’t be detected as email
Consider using standard column names or storing data in the expected format.

Signature Verification Failed

  1. Verify the x-webhook-secret header value in Supabase matches exactly what you entered in Sequenzy
  2. Secrets are case-sensitive
  3. Try generating a new secret and updating both Supabase and Sequenzy

FAQ

Use whichever table contains your user data. This is typically users, profiles, or auth.users. If you’re using Supabase Auth, you might want to create a trigger to sync to a profiles table with the columns you need.
No, only new inserts after connecting will create subscribers. For existing users, you can export them as CSV and import into Sequenzy.
You can create multiple webhooks for different tables. Each will sync to the same subscriber list, matched by email.
Yes, Supabase integration is included at no extra cost.