# AI Lead Chatbot

> Convert site visitors into qualified leads with an embeddable AI chatbot, Prisma integration, and security guardrails.

AI Lead Chatbot is a paid AI agent skill on Agensi by Zeeonix Digital, in Sales & Lead Gen. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: $9.99 (one-time purchase)
- Creator: [Zeeonix Digital](https://www.agensi.io/creators/zeeonix-digital)
- Category: [Sales & Lead Gen](https://www.agensi.io/skills/sales-lead-gen)
- Version: 1.0
- Last updated: 2026-11-26
- Security: scan passed (2026-11-26); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/ai-lead-chatbot
- Tags: api, typescript, prisma, react, sales, lead-generation

## About this skill

Static contact forms fail to engage high-intent visitors before they bounce. This skill builds a production-ready AI sales assistant that qualifies leads through conversation and syncs them to your database.

### What it does
- **Multi-provider support** via an LLM adapter for OpenAI, Anthropic, or Gemini.
- **Automated qualification** by extracting name, email, budget, and timeline from chat.
- **Database integration** using Prisma/PostgreSQL to persist sessions and leads.
- **Security guardrails** to prevent prompt injection and keep keys server-side.
- **Lead scoring** that calculates a 0-100 priority score for every captured lead.
- **Accessible UI** featuring a floating React widget with keyboard shortcuts and ARIA support.

### How it works
1. **Initialize the adapter** in `src/lib/ai/provider.ts` using server-side environment variables.
2. **Configure the system prompt** with strict business-only scope and injection defenses.
3. **Deploy the chat route** at `/api/chat` with Zod validation and IP-based rate limiting.
4. **Embed the widget** using `LeadChatWidget.tsx` with quick-reply starter chips.

### Frameworks & tools
Built for TypeScript environments using Prisma ORM, Zod for schema validation, and React for the frontend. Works with any standard LLM provider via a unified adapter pattern.

### Why this beats prompting it yourself
Prompting alone doesn't handle session persistence, rate limiting, or data extraction into a relational database. This skill provides the architectural plumbing required to run a sales bot in production without exposing your API keys or leaking system instructions.

### Use cases
- Qualify inbound agency leads before they book a discovery call.
- Provide 24/7 pricing and feature support for a SaaS landing page.
- Capture visitor intent and store it directly in a custom CRM.
- Reduce form abandonment by offering a conversational alternative.

### Known limitations
Requires an existing Prisma schema or PostgreSQL database for lead storage. Message history is capped at the last 15 turns to maintain performance.

## Requires

- tsc
- Node.js
- typrscript
- prisma

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the AI Lead Chatbot skill from Agensi" and describe your task.
3. Buy it on the listing or let your agent ask you first; your agent then loads it from Agensi when it needs it. Every paid skill has a money-back guarantee: https://www.agensi.io/docs/money-back-guarantee

## Frequently asked questions

### How does the AI Lead Chatbot differ from a standard contact form?

This skill replaces static contact forms with a conversational AI that qualifies leads in real-time, extracts structured data like budget and timeline, and stores it directly in your database.

### Which AI models and providers are supported?

The skill includes a unified LLM adapter, making it compatible with major providers including OpenAI, Anthropic, and Google Gemini via server-side environment variables.

### What exactly is included in the purchase?

You will receive the complete TypeScript source code for the React widget, the server-side API routes with Zod validation, the Prisma integration layer, and the security guardrail configurations.

### Can I sync the captured leads to my existing CRM instead of a database?

Yes, while it is optimized for Prisma and PostgreSQL, the clean architecture allows you to swap the data persistence layer to any CRM or database with minimal effort.

### How does the skill handle security and prompt injection?

The skill features built-in security guardrails and server-side key management to prevent prompt injection attacks and ensure your system instructions remain private.

### What are the prerequisites for getting the chatbot live on my site?

Setting up involves configuring your LLM API key, running your Prisma migrations, and embedding the React widget into your site; full documentation for these steps is provided.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
