# Chatbot lead capture with Dizo

> When a website visitor shares an email in chat, resolve it to a person and company mid-conversation, then route, qualify and book without a long quiz.

**For:** Growth, marketing ops and teams running website chat or an AI chat assistant on their site.

**The problem:** Chatbots either ask a string of qualifying questions that visitors abandon, or treat every visitor the same, so senior buyers wait in the same queue as students and job seekers.

## Workflow
1. **Resolve the email** — As soon as the visitor shares an email, call email to profile server-side. 2 credits only if found. (`POST /v1/people/by-email`, 2 credits)
2. **Add company fit** — Look up the work domain with domain to company for headcount, industry and HQ. 1 credit if found; cache per domain. (`GET /v1/companies/{domain}`, 1 credit)
3. **Handle phone-first chats** — Chats on messaging channels often start with a number. Phone to profile resolves it to a person and company. (`POST /v1/people/by-phone`, 2 credits)
4. **Give the bot its own key** — A dedicated key with an endpoint allow-list, `max_credits_per_request` and a daily cap keeps public traffic inside budget. (`POST /v1/keys`, Free)

```
visitor: "sure, it's maya@ledgerline.io"
POST /v1/people/by-email {"email": "maya@ledgerline.io", "max_credits": 2}
     → seniority "vp", department "sales", company ledgerline.io        (2 credits)
GET  /v1/companies/ledgerline.io?fields=employee_count,industry,hq   (cached: 0 credits)
     → employee_count 420, industry "Financial Services"
bot: fit = ICP && seniority >= director → offer a meeting with the on-call AE
```

## Outcomes
- Shorter chats with fewer qualifying questions
- Senior ICP visitors offered a meeting straight away
- Lead records that arrive in the CRM already enriched
- No charge when a visitor's email cannot be matched

## Example cost
| Step | Quantity | Credits each | Credits |
|---|---|---|---|
| Chat emails resolved (≈55% of 3,000) | 1,650 | 2 | 3,300 |
| Work domains resolved (≈90% of 1,800, cached) | 1,620 | 1 | 1,620 |
| Phone-first chats resolved (≈50% of 200) | 100 | 2 | 200 |
| **Total** | | | **5,120** |

That is $128 at list price or $51 at the highest volume tier.

## Products used
- [Email to Profile API](https://dizo.ai/products/email-to-profile-api.md)
- [Domain to Company API](https://dizo.ai/products/domain-to-company-api.md)
- [Phone to Profile API](https://dizo.ai/products/phone-to-profile-api.md)

## FAQ
### Should the bot tell visitors what it found?
Usually not. Use the data to choose the next step, such as offering a meeting or a docs link, rather than reciting someone's title back to them.

### Can a public chatbot run up my bill?
Not past the limits you set. Give the bot its own key with an allow-list of the two lookup endpoints, a per-request maximum and a daily cap, and rate-limit per visitor in your own code.

### What if the visitor uses a personal email?
Email to profile accepts personal addresses and returns the employer when it finds the person. When it finds nothing, the lookup is free and the bot falls back to asking.


## The job: treat a chat like the start of a sales conversation

Website chat is often the highest-intent channel a company has. The visitor is on your site, reading your pricing or docs, and has chosen to ask a question. What happens next decides whether that intent becomes a meeting. A senior buyer at a company in your ideal profile should be offered time with a person quickly. A student researching a project should get a helpful answer and a link. Most chat setups cannot tell the two apart without asking.

Chatbot lead capture with Dizo uses the one piece of information visitors routinely share, their email, to answer the qualifying questions in the background. When the visitor types an address, your server resolves it to a person and a company while the conversation continues. By the time the bot writes its next message, it knows whether this is a director at a 400-person fintech or someone with a personal address and no match, and it can choose the next step accordingly.

## Why qualifying questions cost conversations

The traditional fix is a qualification script: company name, company size, role, timeline, budget. Every question is a chance for the visitor to close the window. Busy senior people, the ones you most want to reach, are often the least patient with a quiz. And self-reported answers are uneven. People round company sizes, invent titles to get past a gate, or pick the first option in a dropdown.

Enrichment replaces most of the script with facts. Company size, industry and HQ come from the company profile. Title, seniority and department come from the person profile. The bot only needs to ask what data cannot answer, such as what problem the visitor is trying to solve, which is also the question that leads to a better conversation. The [form enrichment](/use-cases/form-enrichment) use case applies the same idea to web forms.

## Step 1: resolve the email to a person

When the visitor shares an address, call [email to profile](/docs/email-to-profile), `POST /v1/people/by-email`, from your server. It accepts work and personal addresses and returns the person's name, title, seniority, department, location, time in role, and an employer summary with name, domain, employee range and industry. It costs 2 credits only if found. Use `fields` to request only what the bot and your CRM need, and set `max_credits: 2` so the call can never cost more.

Never call Dizo from the browser. Your API key must stay on your server, and the lookup should run in parallel with the bot's reply so the visitor never waits on it. If the result arrives a moment after the bot's next message, the bot can still use it for the message after that.

## Step 2: add company fit

The employer summary from email to profile is often enough to route. When you need more, such as precise headcount, HQ country or funding round, call [domain to company](/docs/domain-to-company), `GET /v1/companies/{domain}`, with a `fields` list. It returns 68 data points and costs 1 credit only if the domain is found. For work addresses where email to profile found nothing, the domain lookup alone still tells you which company the visitor is from.

Cache company results by domain. Chat traffic from a single company often arrives in clusters, such as several colleagues evaluating together, and there is no reason to pay for the same company profile twice in a week.

## Step 3: route inside the conversation

With person and company data in hand, apply simple routing rules in your chat logic. Keep them explicit and few, so marketing and sales can agree on them and so the bot's behaviour is predictable. Write every lookup result to the lead record you create in your CRM, so a rep who picks up the conversation does not have to start from scratch.

For chats on messaging channels that begin with a phone number rather than an email, [phone to profile](/docs/phone-to-profile) does the same job: it resolves a number to a person and company, with line type and a Do Not Call flag, at 2 credits only if found.

- ICP company and director or above: offer a meeting with the on-call rep
- ICP company, individual contributor: answer, then offer a trial or demo video
- Existing customer domain: hand to support or the account manager
- Outside ICP or no match: answer the question and link to docs
- Personal email with no match: ask one question about their company

## The agent version: an AI chat assistant with Dizo tools

If your chat assistant is itself an LLM agent, you can expose Dizo as tools, either through the MCP server or as functions your backend calls. The assistant decides when an email has been shared, calls the lookup, and adapts its reply. This is flexible, but the agent is now spending money in response to anonymous visitors, so the guardrails matter more than usual.

Give the assistant a dedicated key created with `POST /v1/keys`: `data:read` scope only, `allowed_endpoints` limited to email to profile and domain to company, `max_credits_per_request` of 3 and a daily cap sized to your chat volume. Add your own per-visitor rate limit so a single session cannot trigger dozens of lookups. And instruct the assistant not to repeat enriched details back to the visitor. The data is for choosing the next step, not for showing off what you know.

## Cost model with worked numbers

Suppose a hypothetical site has 3,000 chats a month in which the visitor shares an email. At an assumed 55% find rate, email to profile charges 1,650 lookups at 2 credits, or 3,300 credits. Suppose the work emails span 1,800 unique domains and 90% are found: with caching, that is 1,620 credits. Another 200 chats start on a messaging channel with a phone number; at a 50% find rate, phone to profile is 100 lookups at 2 credits, or 200 credits.

The month totals 3,300 + 1,620 + 200 = 5,120 credits. At $0.025 per credit that is $128; from a $500 Builder purchase at $0.021 it is about $107.52. That is around four cents per chat that reaches a lookup at the pay-as-you-go rate. If you want to spend less, skip the domain lookup when the employer summary from email to profile already answers your routing question. Full tiers are on the [pricing page](/pricing).

## Measuring success

Compare chats before and after enrichment on a few numbers: completion rate (chats where the visitor reached a resolution rather than leaving), meetings booked per hundred chats, average number of bot questions per chat, and time from chat start to meeting offer for ICP visitors. Enrichment should cut questions and time-to-offer while holding or improving meeting rate.

Watch routing accuracy too. Ask reps to flag chats that were routed wrongly, and look at whether the rules or the data were the cause. Report records that turn out to be wrong through the feedback endpoint; confirmed reports are refunded and corrected.

## Pitfalls and guardrails

Be transparent. Your privacy notice should say that you enrich contact details shared in chat, and your chat consent text should match your jurisdiction's expectations; this is not legal advice, so check with your own counsel. Avoid creepy behaviour: a bot that opens with the visitor's exact title and employer feels like surveillance, even when the data is accurate. Let the data change the path, not the tone.

Technically, keep the key server-side, validate that the input looks like an email before calling, and fail gracefully. A lookup that times out or misses should leave the bot in its default flow, asking one more question, rather than stalling the chat.

## Variations by team size

A small company with a founder answering chat can skip routing rules entirely: enrich the email and show the result to the founder in the chat console, so they know who they are talking to. Mid-size teams with on-call reps usually route senior ICP visitors to a live person and everyone else to the bot. Larger teams with an AI assistant handle most chats automatically and use enrichment to decide which conversations escalate to a human, and to which team.

Companies with heavy chat traffic from existing customers should check the domain against their customer list before calling Dizo at all. A known customer needs support, not qualification, and skipping the lookup saves credits. Teams selling internationally can route by the HQ country in the company profile, so a visitor from a European subsidiary reaches the team that covers that region rather than whoever is on call for the head office. In every variation the principle is the same: spend a few credits to skip questions the data can answer, and spend the visitor's attention on the questions it cannot.

## Getting started checklist

[Sign up](/signup) for live keys and 250 free credits. Build and test the chat integration against `dz_test_` keys first.

- Create a dedicated key with an allow-list and daily cap
- Call email to profile server-side when an email is shared
- Cache domain to company results by domain
- Write four or five routing rules and agree them with sales
- Log every lookup result to the CRM lead record
- Measure questions per chat and meetings per hundred chats
