--- title: "Verify with AI: check your Userflow.js installation with your AI coding agent" slug: "verify-with-ai" description: "Verify your Userflow.js installation with our AI coding agent, ensuring correct initialization, token usage, and advanced functions without altering your code." tags: ["Codebase Checks", "AI Coding Agent", "Userflow Verification"] updated: 2026-11-02T14:56:42Z published: 2026-11-02T14:56:42Z canonical: "help.userflow.com/verify-with-ai" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.userflow.com/llms.txt > Use this file to discover all available pages before exploring further. # Verify with AI The Userflow Verification Skill checks an existing Userflow.js installation and tells you whether it is correct. Your AI coding agent reads your codebase, reports what it finds with a severity for each issue, and changes nothing until you approve a specific fix. It catches the problems that don't throw an error: identification running on public pages (which inflates your Monthly Active User count), a token that belongs to a different environment, or a second initialization added by mistake. ### Download [](https://cdn.us.document360.io/9697557a-eb5d-476f-9b09-062b0f7bdcbd/Images/Documentation/verify-with-ai(1).md)verify-with-ai15.62 KB[](https://cdn.us.document360.io/9697557a-eb5d-476f-9b09-062b0f7bdcbd/Images/Documentation/verify-with-ai(1).md) ## Before you start You'll need: - An existing Userflow.js installation. If you haven't installed it yet, use [Install with AI](https://help.userflow.com/docs/install-with-ai) instead - An AI coding agent with access to your project files — Claude Code, Cursor, GitHub Copilot, Codex, Windsurf, and others all work - No Userflow MCP server required ## Step 1: Add the verification skill Quickest route—paste this into your agent's chat. Nothing to install: ```plaintext Verify Userflow.js in this project. Use the Userflow verification skill: Read https://raw.githubusercontent.com/userflow/ai-skills-library/refs/heads/main/skills/verify-with-ai/SKILL.md and verify my Userflow.js installation. ``` To add it permanently with the Claude Code plugin or skills.sh, see [Add Userflow coding skills to your agent](https://help.userflow.com/docs/add-userflow-coding-skills-to-your-agent). If you already added the Claude Code plugin for Install with AI, you have this skill too—run `/userflow:verify-with-ai`. ## Step 2: Run the skill Open your coding agent with access to your project and ask it to verify your Userflow installation. The skill finds every place your code touches Userflow — initialization, identification, sign-out, and any advanced functions — then evaluates each against the checklist below and produces a report. It does not edit anything at this stage. ## What the skill checks - **Initialization.** Exactly one `init()` runs per page load, before any other Userflow call, and only in client-side code. - **Token and environment.** The token is real, not a placeholder, and belongs to the environment that build targets rather than being shared across environments or hardcoded in source. - **Identification.** `identify()` runs only after sign-in or sign-up and never on public pages; `identify()` and `identifyAnonymous()` are never both reachable on the same page load; user values are real rather than placeholders. - **Sign-out.** `reset()` is wired so the next user on a shared device doesn't inherit the previous identity. - **Advanced functions.** If your install already uses `group()`, `track()`, or identity verification, they're checked for correct usage — including that no Secret Key appears in frontend code. - **Delivery.** Your Content Security Policy allows Userflow.js, and script-tag installs use the official snippet. The checks that protect your MAU count are treated as the most serious. Anything that lets an unauthenticated visitor be identified is reported as Critical, whether or not your content is otherwise working. ## Step 3: Read the report Every finding cites the file and line it came from, explains the impact, and proposes a fix. Findings are ordered by severity: | Severity | What it means | | --- | --- | | **Critical** | Costs money, corrupts data, or breaks security — for example identifying signed-out visitors, or a token from the wrong environment | | **High** | The install malfunctions for real users — a duplicate `init()`, a missing `reset()`, or Userflow blocked by your CSP | | **Medium** | Works today but will break later — a hardcoded token, or a malformed date attribute | | **Low** | Advisory only, safe to leave as-is | Some checks can't be answered by reading code. Those are listed separately as runtime checks for you to run in a browser — most importantly, loading a public page while signed out and confirming `userflow.isIdentified()` returns `false`. ## Step 4: Apply the fixes you approve The skill asks before it changes anything, one fix at a time. You can accept all of them, some of them, or none — and it re-runs the relevant checks afterwards to confirm each fix landed. If your installation is tangled enough that patching would be riskier than starting over — several conflicting initializations, or npm and script-tag installs both present — the skill will say so and recommend a clean reinstall with [Install with AI](https://help.userflow.com/docs/install-with-ai) instead. ## Troubleshooting **The report says a check "needs a runtime check"** That's expected. Some behaviour can only be confirmed in a running browser, and the skill won't claim to have verified something it couldn't see. Follow the steps it lists and report the results back to it. **It found nothing, but content still isn't showing** A correct installation with non-matching flow targeting conditions is not an installation problem. Check your flow's own audience and page conditions in Userflow. **It recommends a reinstall** Take that seriously. It means the defects overlap enough that fixing them individually risks leaving the install in a half-changed state. **Still stuck** Browse the [Userflow documentation](https://help.userflow.com/), ask your coding agent to explain a specific finding, or contact Userflow support. --- ### FAQ #### Will it change my code? Not without asking. The skill reads and reports first, then applies only the fixes you approve, one at a time. #### Do I need to have used Install with AI first? No. It verifies any Userflow.js installation, however it was originally added — by hand, by a developer, or by the install skill. #### What if Userflow isn't installed at all? The skill will tell you and point you to [Install with AI](https://help.userflow.com/docs/install-with-ai). It won't start installing on its own. #### Will it suggest new attributes or features? No. It reports only what correctness requires. For recommendations on attributes and flow targeting, use [Suggest with AI](https://help.userflow.com/docs/suggest-with-ai). #### **Can I see what the skill actually does?** Yes. Read the full [verify-with-ai](https://github.com/userflow/ai-skills-library/blob/main/skills/verify-with-ai/SKILL.md) skill on GitHub. > **Review any changes before merging.** The skill asks before editing, but the fixes it applies are real code changes. Human oversight is recommended. ## Related - [Install with AI](/install-with-ai.md) - [AI Playbooks and Skills](/ai-skills-library.md) - [Connect Userflow to Claude, ChatGPT, and other AI tools with the Userflow MCP](/mcp.md)