Quick Overview This workflow ingests marketing touch events, stores them in Supabase, stitches identities by shared email, and calculates first-touch, last-touch, linear, and time-decay multi-touch attribution credit per channel, outputting a side-by-side model comparison. How it works Runs when triggered manually (or can be adapted to receive real touch events via a webhook). Loads configuration such as the channel list and the time-decay half-life window. Generates a batch of synthetic multi-touch customer journeys for the demo run. Writes all touch events to a Supabase table via the Supabase REST API. Reloads the stored touches from Supabase and merges visitors into a single identity when they share an email address. Computes revenue-weighted channel credit across converting journeys using first-touch, last-touch, linear, and time-decay attribution models. Prints a formatted comparison table of channel credit across the four models. Setup Create a Supabase project and table (for example, mta_touches) to store touch events, matching the fields used in the workflow (visitor_id, email, channel, ts, is_conversion, revenue).
Tags
Related workflows
See all Supabase→Send DocuSign envelopes with Supabase contract data
Quick overview This workflow is triggered by another n8n workflow, fetches an assessment record from Supabase, generates an HTML contract, and sends it as a DocuSign envelope using JWT authentication in either production or sandbox based on the recipient email, then writes the envelope ID and status back to Supabase. How it works Receives an execution request from another workflow with an assessment ID (and optional contract title). Retrieves the matching assessment record from the Supabase assessments table. Generates a styled contract HTML document from the assessment data and Base64-encodes it for DocuSign. Chooses the DocuSign sandbox or production path based on whether the contact email contains a specific marker string. Calls a Supabase Edge Function to create a DocuSign JWT assertion, exchanges it for a DocuSign access token, and creates a “sent” envelope with two signers and anchor-based signature tabs. Updates the Supabase assessment record with the DocuSign envelopeId and sets the contract status to envelope_sent. Setup Create and connect Supabase credentials in n8n, and update the Supabase project URL for the Edge Function endpoint (/functions/v1/docusign-sign-jwt). Conf
Monitor brand visibility in AI search with ChatGPT, Perplexity, Gemini, Claude, and Supabase
Quick Overview This workflow asks buyer-intent questions to ChatGPT Search (OpenAI), Perplexity, Google Gemini Search, and Anthropic Claude, scores whether your brand is cited or mentioned in each answer, logs every check to Supabase, and outputs an overall and per-engine visibility scorecard. How it works Starts when you run the workflow manually. Sets your brand name/domain and a list of buyer questions, then creates one item per question. Sends each question to Anthropic Claude, OpenAI Chat Completions (gpt-4o-search-preview), Perplexity (sonar), and Google Gemini with Google Search enabled. Parses each engine’s response to detect whether your brand domain is cited or your brand name is mentioned, and assigns a score (1 for cited, 0.5 for mentioned, 0 for absent). Writes each scored check (brand, engine, question, score, cited, mentioned) as a row into a Supabase table. Aggregates the results into a per-engine percentage and an overall panel score, then prints a console scorecard with top “not cited” targets. Setup Add environment variables in n8n for ANTHROPIC_API_KEY, OPENAI_API_KEY, PERPLEXITY_API_KEY, and GEMINI_API_KEY. Create a Supabase table named ai_visibility_log with c
Better Oauth2.0 workflow for Pipedrive CRM with Supabase
This workflow provides an OAuth 2.0 auth token refresh process for better control. Developers can utilize it as an alternative to n8n's built-in OAuth flow to achieve improved control and visibility. In this template, I've used Pipedrive API, but users can apply it with any app that requires the authorization_code for token access. This resolves the issue of manually refreshing the OAuth 2.0 token when it expires, or when n8n's native OAuth stops working. What you need to replicate this Your database with a pre-existing table for storing authentication tokens and associated information. I'm using Supabase in this example, but you can also employ a self-hosted MySQL. Here's a quick video on setting up the Supabase table. Create a client app for your chosen application that you want to access via the API. After duplicating the template: a. Add credentials to your database and connect the DB nodes in all 3 workflows. Enable/Publish the first workflow, "1. Generate and Save Pipedrive tokens to Database." Open your client app and follow the Pipedrive instructions to authenticate. Click on Install and test. This will save your initial refresh token and access token to the database. Pleas