Code Workflows
445 Ergebnisse — ausschließlich quellenverknüpfte n8n-Referenzen
Summarize Zoom meeting recordings in Notion with Smallest.ai and Gemini
Quick Overview This workflow receives Zoom recording webhooks, downloads the meeting recording, transcribes it with Smallest.ai, summarizes it with a Google Gemini-powered AI Agent, and saves the summary and action items as a new page in a Notion database. How it works Receives a POST webhook from Zoom and checks whether the event is Zoom’s endpoint URL validation challenge. For URL validation events, computes the Zoom CRC HMAC SHA-256 token and responds with the plain and encrypted tokens to verify the endpoint. For recording events, immediately acknowledges Zoom with a 200 OK response, then extracts the meeting topic, metadata, and an audio recording download URL from the webhook payload. Downloads the recording file from Zoom using the provided download token for authorization. Sends the downloaded audio to Smallest.ai to generate a full transcription. Uses a LangChain AI Agent with Google Gemini to produce a short meeting summary and a list of action items from the transcript. Creates a new page in a Notion database using the meeting topic as the title and the generated summary as the page content. Setup Create and configure a Zoom Event Notifications webhook (for a recording-c
Answer legal questions with Groq using CanLII and CourtListener
Quick overview This workflow collects a legal question via an n8n form, retrieves supporting authorities from CourtListener or CanLII, and uses a Groq-hosted Llama model to produce an answer grounded only in the retrieved text with verified, non-hallucinated citations. How it works Receives a legal question through an n8n form and captures the selected source database (CourtListener or CanLII) plus optional CanLII database and case IDs. Routes the request to CourtListener full-text search or to CanLII case metadata and citator endpoints based on the selected database. For CourtListener, pulls the top search results and fetches the full text of the top-ranked opinion; for CanLII, loads the selected case and a list of related cases from the CanLII citator. Normalizes the retrieved items into a single numbered “sources” block with excerpts that the model can cite. Sends the question and sources to a Groq Chat Model (Llama 3.3 70B) and parses the response into a structured format containing an answer, a supported flag, and a list of citations. Verifies every cited source index against the retrieved sources, drops any mismatches, and renders an HTML result page showing the answer, verif
Draft grounded Gmail support replies from a Notion KB with Groq and Cohere
Quick Overview This workflow ingests published Notion knowledge base articles into an in-memory vector store using Cohere embeddings, then monitors a support Gmail inbox and uses Groq to draft grounded reply emails based only on retrieved KB sources, saving the result as a Gmail draft for review. How it works Manually runs an ingestion flow that pulls all pages from a Notion database and keeps only articles marked as Published. Fetches each article’s Notion page blocks, assembles them into a single document, splits the text into chunks, and embeds the chunks with Cohere. Clears and loads the resulting embeddings and metadata into an in-memory vector store for retrieval. Triggers when an unread Gmail message arrives matching the support inbox query and normalizes the subject, body, sender, and thread details. Uses Groq to classify the email as a support question, noise, or already resolved, and continues only for real support questions. Embeds the question with Cohere, retrieves and reranks the most relevant KB chunks, and stops if the best match does not meet the configured relevance threshold. Uses Groq to draft a reply using only the retrieved sources and, if an answer is produce
Triage PubMed clinical literature with Gemini and Google Sheets and Docs
Quick overview Automatically retrieve recent PubMed articles, identify the three papers most worth reading first using AI, and generate structured clinical literature triage reports in Google Sheets and Google Docs. How it works Reads the first pending literature request from the Google Sheets "Search Requests" tab. Marks the request as “processing” in Google Sheets and builds the PubMed query parameters (keyword, max results, specialty, clinical question, and output language). Searches PubMed via the NCBI E-utilities API (esearch) and fetches the corresponding article abstracts and metadata as XML (efetch). Parses and normalizes the XML into a structured list of candidate articles including title, abstract, journal, publication year, DOI, and PubMed URL. Sends the aggregated candidate articles to Google Gemini to select and rank the best three papers and generate a structured clinical evaluation for each. Appends the three ranked papers with summaries and triage fields to a Google Sheets “Triage Results” tab. Generates a formatted triage report in Google Docs and updates the original request status to “completed” in Google Sheets. Setup Create a Google Sheets OAuth connection and
Analyse tender PDFs with LlamaParse, Gemini, Supabase and WhatsApp chat
Quick overview This workflow lets you upload a tender/RFT PDF via an n8n form, extracts key fields into Google Sheets using LlamaParse, and makes the document chat-searchable by embedding section chunks with Google Gemini and storing them in Supabase for WhatsApp-based Q&A with Anthropic/DeepSeek. How it works Receives a tender PDF when a user submits the n8n form. Generates a normalized document ID from the uploaded filename and sends the PDF to LlamaParse to parse the full text, split it into predefined tender sections, and extract structured tender metadata. Normalizes the extracted fields, calculates days-until-deadline and a bid score/recommendation, and appends or updates a row in a Google Sheets tender tracker. Combines the parsed full text with the section/page mapping, then carves each section into paragraph-aligned text chunks with page references. Creates an embedding for each chunk using the Google Gemini Embeddings API and inserts the chunk text and vectors into a Supabase table for retrieval. Triggers on an incoming WhatsApp message, embeds the user’s question with Google Gemini, runs a Supabase RPC vector search scoped to a single doc_id, and builds a context payload
Qualify and route free signups with Twain, Claude, Slack, HubSpot and Gmail
Quick overview This workflow receives free-signup events via webhook, enriches the contact with Twain research (and optional Findymail LinkedIn lookup), uses Anthropic Claude to score ICP fit, then routes outcomes to Slack and, for high-fit leads, to HubSpot and Gmail. How it works Receives a POST webhook request for a new signup and authenticates it via a required header. Normalizes the signup fields (uid, email, name, LinkedIn URL) and deduplicates records across runs to avoid reprocessing the same user. If the signup has no LinkedIn URL but has an email, optionally calls Findymail reverse-email lookup to resolve a LinkedIn profile URL and merges it back into the contact. If the lead has neither a work email nor a LinkedIn URL, posts a “skipped” message to Slack and stops. Sends the contact to the Twain Generate/Research API to create research and add the contact to the specified Twain campaign, and posts a Slack alert if the research request fails. If Twain flags a hard disqualification (persona mismatch or incomplete profile), posts a disqualification message to Slack; otherwise, Anthropic Claude evaluates the research against the defined ICP tiers and returns a structured fit
Screen and route candidate CVs with OpenRouter, Google Drive, Sheets, and Gmail
Quick overview This workflow receives candidate CVs via a webhook, extracts text from PDF, DOCX files, looks up the matching job description in Google Sheets, runs a three-agent evaluation using OpenRouter models, then uploads the CV to Google Drive, logs results to Google Sheets, and sends or drafts emails in Gmail. How it works Receives a CV submission via a POST webhook that includes candidate details, an applied job ID, and a CV file. Normalizes the intake data, timestamps the submission, and fetches the matching job description from Google Sheets using the applied job ID. Extracts CV text by either parsing the PDF directly or converting a DOCX/DOC to a Google Doc in Google Drive and exporting it as plain text. Detects whether the CV is Vietnamese or not and uses OpenRouter (Qwen for Vietnamese or Google Gemini for others) to parse the CV into a structured Candidate Profile JSON. Uses OpenRouter (Anthropic Claude Sonnet) to compare the Candidate Profile against the job description, then generates a hiring-manager style review and recommendation based on the ATS evaluation. Uploads the original CV to a recommendation-based Google Drive folder, logs the full screening record (inc
Process prescription orders and refills with Telegram, Google Gemini and Sheets
Quick overview This workflow lets customers order and refill prescriptions via Telegram by extracting medicines from prescription images with Google Gemini, checking and updating inventory in Google Sheets, and sending order summaries and status updates, with delivery updates handled by a webhook and error alerts posted to Slack. How it works Triggers when a Telegram message is received, normalizes it, and routes it based on whether it contains a prescription image/document or the REFILL, STATUS, or CONFIRM command. For prescription images/documents, it downloads the file from Telegram and uses Google Gemini vision to extract medicines, dosages, and quantities from the prescription. It looks up each extracted medicine in a Google Sheets Inventory tab, deducts stock for items that are available, and aggregates the priced order lines. It creates a new pending order in a Google Sheets Orders tab and sends the customer a Telegram order summary with the total and a prompt to reply CONFIRM. For STATUS/REFILL/CONFIRM messages, it reads the relevant order from Google Sheets, sends the current status via Telegram, creates a new pending refill order, or updates the pending order status to co
Manage restaurant orders, upsells, and payments with Telegram, OpenAI, Razorpay, and Google Sheets
Quick overview This workflow runs a Telegram restaurant ordering flow that uses OpenAI to parse orders and suggest an upsell, sends a Razorpay payment link, confirms paid orders via a Razorpay webhook, logs orders and feedback in Google Sheets, notifies the kitchen, sends delivery updates, and posts error alerts to Slack. How it works Receives a customer’s order message in Telegram and sends it to OpenAI to extract items, quantities, subtotal, and a suggested upsell. Replies in Telegram with an order summary and upsell prompt, then waits for the customer to respond. When the customer replies, calculates the final total (including the upsell when accepted) and sends a Razorpay payment link in Telegram. Receives the Razorpay payment.captured webhook, extracts payment details, confirms payment to the customer in Telegram, and posts a kitchen ticket to a dedicated Telegram chat. Appends the paid order to an Orders tab in Google Sheets and calculates ingredient deductions to update the same sheet against the order. Waits through prep and delivery windows and then sends delivery tracking followed by a Telegram feedback request. Captures the customer’s rating in Telegram, calculates loyal
Create daily ClickUp task reports with OpenRouter o3-mini
Quick overview This workflow runs each morning, pulls all tasks from a specified ClickUp list, merges their names and descriptions, and uses an OpenRouter-hosted OpenAI chat model to generate a daily report. It then creates a new ClickUp list for the current run and adds the report as a task. How it works Runs every morning at the configured hour using a schedule trigger. Fetches all tasks from the specified ClickUp list. Merges the retrieved tasks into a single formatted text block for summarization. Checks that task data exists and, if not, creates an error list in ClickUp and stops with an error. Creates a new ClickUp list named with the current date/time to store the report. Sends the merged task text to an AI Agent backed by an OpenRouter (OpenAI) chat model to generate the report content. Creates a ClickUp task named “Report” in the newly created list and stores the AI-generated summary in the task description. Setup Add ClickUp OAuth2 credentials in n8n and select the correct Team/Space/Folder/List details in the ClickUp nodes (including the source list to read from). Add an OpenRouter credential and choose the chat model in the AI Chat Model node. Set the schedule time (hou
Generate SEO-friendly robots.txt with OpenAI and Google Drive
Quick overview This workflow runs manually to check a website’s existing robots.txt, detect the site’s CMS from the homepage HTML using OpenAI, and generate an optimized robots.txt (including the provided sitemap URL) that is saved as a file and uploaded to Google Drive. How it works Starts when you click “Execute workflow” and sets the target website URL and sitemap URL. Requests the site’s existing robots.txt via HTTP and checks whether the response returns status code 200. If robots.txt exists, the workflow stops without making changes. If robots.txt is missing, it fetches the website homepage HTML via HTTP. Sends the HTML to OpenAI to detect the CMS and parses the model output into structured JSON. Uses OpenAI again to generate a production-ready robots.txt tailored to the detected CMS and including the sitemap directive. Converts the generated text into a robots.txt file and uploads it to a chosen folder in Google Drive. Setup Add an OpenAI API credential and ensure the selected chat model is available for both CMS detection and robots.txt generation. Add a Google Drive OAuth2 credential and choose the target Drive and folder for the uploaded robots.txt file. Update the websit
Route patients to the best nearby hospital using Google Maps, GPT-4.1 and Twilio
Quick overview This workflow accepts emergency location requests (or runs on a 5-minute schedule), finds and ranks nearby hospitals/clinics using Google Places, capacity data, and Google Distance Matrix, generates a routing message with OpenAI, sends the recommendation via Twilio SMS, logs the event to Google Sheets, and returns a JSON response. How it works Receives an emergency request via a webhook POST (or runs every 5 minutes on a schedule) and normalizes latitude, longitude, severity, phone number, and a request ID. Validates the GPS coordinates, maps severity to a numeric score, and sets a search radius, returning an error response if the location is invalid. Queries the Google Places API for nearby hospitals and clinics, then merges and deduplicates the results into a single facility list. Looks up each facility’s ED capacity metrics from a capacity API and calculates real-time driving time to each facility with the Google Distance Matrix API. Scores and ranks facilities using a severity-adjusted composite score (travel time, available beds, wait time, and ED diversion penalties) and selects the best match plus two alternatives. Uses OpenAI to generate a calm routing messag
Validate startup ideas and generate business plans with Claude and SendGrid
Quick overview This workflow receives a startup idea via webhook, uses Anthropic Claude to expand it, run market research, competitor analysis, and demand validation, then generates a structured business plan, emails it through SendGrid, logs a summary row to Google Sheets, and returns a JSON response to the webhook caller. How it works Receives a startup idea via an HTTP POST webhook request. Normalizes the submission details (idea, founder, industry, budget) and uses Anthropic Claude to expand the idea into a structured concept with an initial score. Filters out ideas below the viability threshold (ideaScore < 4) to stop low-quality submissions early. Uses Anthropic Claude to produce market sizing and persona research, then parses the results into structured market data. Uses Anthropic Claude to analyze direct and indirect competitors and compute a competitive position score. Uses Anthropic Claude to validate demand signals, risks, and go-to-market recommendations, then calculates a composite score and PROCEED/VALIDATE_FURTHER/PIVOT_OR_ABANDON recommendation. Uses Anthropic Claude to generate a 10-section business plan, appends a tracking row to Google Sheets, emails the report v
Triage Typeform survey feedback with GPT-4o-mini, Slack, Gmail, and Sheets
Quick overview This workflow triggers on new Typeform survey responses, uses OpenAI GPT-4o-mini to classify sentiment and draft reply emails, routes negative feedback through a Slack human-approval loop with revisions, sends emails via Gmail, and logs outcomes to a Google Sheets CRM. How it works Triggers when a new Typeform survey response is submitted. Extracts the respondent’s name, email, rating, and free-text feedback and sends it to OpenAI GPT-4o-mini to classify the response as positive or negative. If the response is negative, OpenAI GPT-4o-mini drafts an empathetic follow-up email, posts a Slack alert to the team, and sends the draft to a Slack review channel that waits for a reply. If the reviewer replies with “approved”, the workflow sends the approved draft to the respondent via Gmail and appends a “Sent” record to Google Sheets. If the reviewer requests changes, OpenAI GPT-4o-mini revises the email based on the Slack feedback and the workflow loops back to Slack for another review. If the response is not negative, OpenAI GPT-4o-mini drafts a thank-you email, sends it automatically via Gmail, and logs the sent email to Google Sheets. Setup Connect credentials for Typefo
Draft personalized cold emails from Google Sheets with Apify and GPT-4o mini
Quick overview This workflow reads pending medical or dental practice leads from Google Sheets, scrapes each practice website with Apify, uses OpenAI (gpt-4o-mini) to identify conversion gaps, and drafts a short personalized cold email, then writes the analysis and draft back to the sheet. How it works Manually starts the workflow and reads leads from a Google Sheets worksheet. Filters the rows to only those with Status set to "pending" and processes them one at a time. Uses Apify Website Content Crawler to scrape up to a few pages of each lead’s WebsiteURL and compiles the extracted text into a trimmed site summary. If enough website text is available, sends it to OpenAI (gpt-4o-mini) to produce a strict-JSON analysis of 2–3 concrete booking/chatbot/after-hours/intake gaps and a best outreach angle. Alternates between “soft” and “direct” framing and asks OpenAI (gpt-4o-mini) to generate a short JSON email draft (subject and body) tailored to the selected gap. Updates the matching row in Google Sheets with ScrapedNotes, WeakPoints, DraftEmail, and sets Status to "drafted", then waits briefly before moving to the next lead. If the scrape returns insufficient content, updates the lea
Send AI market briefings to email and Discord with AlphaAI and GPT-4
Quick Overview This workflow runs every 15 minutes to fetch AlphaAI’s trending market news, filter for new high-relevance, ticker-linked stories, and post them to a Discord channel via webhook as rich embed cards with sentiment and impact details. How it works Runs every 15 minutes on a schedule trigger. Requests the current trending news feed from the AlphaAI API using Bearer authentication. Filters out already-posted articles, keeps only stories with relevance score ≥ 8 and at least one ticker, and formats up to 10 items into Discord embed cards with AlphaAI sentiment, confidence, actionability, and likely price impact. Posts a single Discord webhook message containing a header and the generated embeds, and stores the posted article IDs to prevent duplicates in future runs. Setup Create an AlphaAI API key and add it as an n8n HTTP Bearer Auth credential used by the AlphaAI request. Create a Discord channel webhook and paste its URL into the Discord webhook HTTP request node. Activate the workflow and keep it running on the same n8n instance so its stored posted-article IDs can be reused across executions.
Research Reddit trends and publish LinkedIn posts with Gemini and PostPeer
Quick overview This workflow runs daily, scrapes a selected subreddit with Apify, researches sources via Brave Search and Jina Reader, and uses Eden AI (DeepSeek) plus Google Gemini to draft a LinkedIn post with an image. It logs state in Google Sheets/Drive, sends approval emails, and publishes via PostPeer. How it works Runs daily on a schedule, loads Global Constants, and picks an ACTIVE subreddit row from Google Sheets using a random ID. Scrapes recent posts from that subreddit using an Apify Reddit scraper, then normalizes, scores, and deduplicates candidates. Uses an Eden AI (DeepSeek) agent to vet the candidates and either selects one post idea or stops and records a NO_VIABLE_IDEA entry in Google Sheets and emails the rationale. For a selected idea, a second Eden AI (DeepSeek) agent generates a research brief and up to five Brave Search queries, then Brave Search and Jina Reader collect and extract a small set of non-social sources. A third Eden AI (DeepSeek) agent writes the LinkedIn draft and an accompanying image prompt, then Google Gemini generates the image. Uploads the image to Google Drive, writes the draft and metadata to a Google Sheets post log, and emails a two-s
Triage and retry failed workflow executions with Anthropic, Jira and OpenTelemetry
Quick overview This workflow triggers on n8n execution errors, uses Anthropic (Claude) to classify the failure as transient or logic, and then either retries the failed execution via the n8n API with exponential backoff or creates a Jira issue, while also sending incident telemetry to an OpenTelemetry collector. How it works Triggers automatically when an n8n workflow execution errors. Extracts key telemetry like workflow name, failing node, error message/stack, execution URL, and any detected HTTP status code. Sends the error context to Anthropic (Claude) to return structured JSON with a category, confidence, and remediation guidance. Combines the AI diagnostics with telemetry and tracks a per-incident retry counter (up to three attempts) to decide if the failure is eligible for automated retry. If the error is transient with sufficient confidence and retry budget remains, waits using exponential backoff and calls the n8n API to retry the failed execution, then records the retry outcome. If the error is not retry-eligible (or the retry budget is exhausted), creates a Jira issue with the diagnostics, execution link, and failure details. Posts an OpenTelemetry trace span to your col
Monitor AI search citations and competitors with OpenAI, Google Sheets, and Gmail
Quick overview This workflow runs weekly to test whether fairyfrills.in is cited in OpenAI answers to 15 shopping queries, logs citation details to Google Sheets, and emails a weekly HTML visibility report via Gmail, with optional Slack alerts on workflow errors. How it works Runs once a week on a schedule and generates 15 predefined shopping queries along with the target domain, brand name, and competitor domains. Sends each query to two OpenAI models in parallel: gpt-4o-mini (no browsing) and gpt-4o-search-preview (web search with URLs). Splits the two AI answers into separate items per platform and uses OpenAI to extract citation data (target-domain URLs, competitor citations, citation position, and totals) as structured JSON. Parses the extracted citation JSON, formats key fields (including URL lists, counts, and a response preview), and appends one log row per query and platform to a Google Sheets “Citation Log” sheet. After the final query (ID 15) completes, fetches the logged results from Google Sheets, calculates weekly citation metrics and breakdowns, and generates an HTML report. Sends the weekly citation report email through Gmail to the configured recipient. If any node
Monitor AI brand visibility and GEO gaps with OpenAI, Gmail and Slack
Quick Overview This workflow runs daily to test whether Fairy Frills appears in AI shopping recommendations by querying OpenAI with 10 brand-focused questions (with and without web search), extracting mention and competitor data, generating a GEO gap analysis, and emailing a consolidated HTML report via Gmail. How it works Runs every 24 hours on a schedule. Generates 10 predefined shopping queries for Fairy Frills and includes the brand URL and a competitor list with each query. Sends each query to OpenAI twice in parallel, once to gpt-4o-mini (no search) and once to gpt-4o-search-preview (web search enabled). Combines the two model responses per query and uses OpenAI to extract structured metrics such as whether Fairy Frills is mentioned, mention count and position, competitor mentions, sentiment, and a key snippet. Uses OpenAI again to perform a GEO (Generative Engine Optimization) gap analysis that explains why competitors ranked, why the target brand missed, and which content actions and exact phrases to add. Deduplicates and aggregates insights across all checks, builds an HTML summary, and sends the daily GEO report email via Gmail. Sends a Slack message when the workflow enc
Predict sprint slip risk in Jira with OpenAI via OpenRouter and Slack alerts
Quick Overview This workflow runs on a weekday morning schedule (or manually) to pull the active Jira sprint and its issues, compute sprint health metrics, use an OpenRouter-hosted OpenAI model to assess slip risk, and post a motivating alert to a Slack channel when the sprint is behind. How it works Runs every weekday at 08:00 (or when executed manually). Calls the Jira Software Cloud Agile API to fetch the board’s active sprint and all issues in that sprint, including status, labels, and story points. Calculates sprint timing, completion percentage, slip margin, velocity gap, and a list of potentially blocked issues based on labels or status. Sends the computed metrics to an OpenRouter (OpenAI) chat model to return a structured JSON risk assessment (on_track, at_risk, or critical) with recommendations and tickets to watch. Parses the model output into JSON and merges it with the computed sprint metrics for reporting. If the risk level is not on_track, a second OpenRouter (OpenAI) agent drafts a team-focused status update and posts it to the configured Slack channel. If the risk level is on_track (or parsing fails and defaults to on_track), the workflow ends without posting to Sla
Generate vendor negotiation strategies from pricing data with GPT-4 and SendGrid
Quick overview This workflow ingests vendor pricing via a webhook or a weekly schedule, analyzes variance against historical and market benchmarks, uses OpenAI to draft negotiation strategies for high-priority cases, then emails recommendations through SendGrid and appends the analysis to a Google Sheets tracker. How it works Receives vendor pricing data from a POST webhook endpoint or runs every Monday at 8:00 to process a scheduled input. Normalizes incoming fields (vendor, pricing, benchmarks, volume, currency, renewal date, and notes) into a consistent schema. Calculates price variance versus historical and market benchmarks, estimates potential savings, derives a confidence score, and flags whether the opportunity is high priority. Filters to only high-priority opportunities and waits briefly to help manage API rate limits. Uses OpenAI to generate a structured, under-300-word negotiation strategy including tactics, target and walk-away prices, projected savings range, and risk flags. Formats the AI output into a report, emails it via the SendGrid API, and appends the analyzed record to a Google Sheets tab for tracking. Setup Add an OpenAI API credential for the OpenAI Chat Mod
Generate rich character bibles for writers with GPT-4.1 and Google Sheets
Quick overview This workflow accepts character details via webhook or manual trigger, uses OpenAI to generate psychology, backstory, and emotional arc drafts in parallel, then synthesizes them into a structured “Character Bible” JSON response and optionally appends a log row to Google Sheets. How it works Receives a POST request on an n8n webhook (or runs manually) with character parameters like name, age, archetype, world setting, story role, traits, and constraints. Normalizes the incoming fields, validates the archetype, and derives genre tags from the world setting using Python logic. Sends the enriched character inputs to OpenAI three times in parallel to generate a psychology profile, a backstory, and an emotional arc document. Combines the three AI documents into a single context object and passes it to OpenAI again to synthesize a unified Character Bible with defined sections. Parses the Character Bible into structured JSON fields (identity snapshot, personality core, backstory highlights, emotional arc, voice, and story hooks) and adds metadata like request ID and timestamp. Returns the completed character profile as a JSON webhook response and optionally appends a summary
Audit website SEO with Groq, Google PageSpeed and Google Sheets
Quick overview This workflow audits a submitted website URL by extracting on-page SEO signals from the HTML, pulling Google PageSpeed Insights scores, and using Groq (Llama 3.3 70B) to generate a scored SEO report, then logs the results to Google Sheets and returns the audit via webhook. How it works Receives a POST webhook request containing a JSON body with a target url to audit. Fetches the page HTML for the provided URL and stops with an error response if no HTML is returned. Extracts on-page SEO signals from the HTML (title, meta description/keywords, headings, image alt coverage, links, canonical, robots, viewport, Open Graph/Twitter tags, schema, word count, and language). Calls the Google PageSpeed Insights API for mobile to retrieve performance, accessibility, SEO, and best-practices results. Combines the extracted on-page data with the PageSpeed results and sends it to Groq via a LangChain agent to produce a strict, structured JSON audit with scores, findings, fixes, and top priorities. Parses and validates the AI JSON output, appends/updates the audit record in Google Sheets, and returns the final audit JSON to the webhook caller (or returns a 400 error if parsing fails)