Claude prompts

Claude Prompt: Clean and Dedupe a Lead CSV

Paste a messy lead export into Claude. It trims, merges duplicates, and fills missing fields from LeadOcean for the rows worth keeping.

Get your free API key →Free to start. No credit card. 1,000 records to spend whenever you like.

Duplicate rows waste sends and inflate list counts. This prompt cleans the file first, then spends records only on rows that are missing fields. Connect https://api.leadocean.io/mcp first (setup is on the MCP page). It works in any MCP client. For a repeatable pipeline, see how to automate lead enrichment with Claude.

The prompt

text
Here is a lead CSV (name, title, company, domain, email, linkedin_url), up to 25 rows.
1. Clean it: trim spaces, lowercase emails and domains, strip tracking
   parameters from LinkedIn URLs, drop rows with no email and no LinkedIn URL.
2. Dedupe in this order: same email, then same LinkedIn URL, then same
   name plus domain. Keep the row with the most fields filled.
3. Call leadocean_list_enum_values for job_level, job_function,
   employee_range and country. Use the exact strings.
4. Call leadocean_count_leads for US Directors in Advertising & Marketing
   at companies with 51-200 employees. Tell me the count and the filters.
5. For each kept row with a LinkedIn URL and a missing title, company size,
   industry or country, call leadocean_get_lead. Skip rows that are complete.
6. Return the clean table, then a list of removed rows with the reason.
   Tell me how many records the lookups spent.

What it resolves to

FilterValue
jobLevelDirector
jobFunctionAdvertising & Marketing
employeeRange51-200
countryUS

Steps 1 and 2 run inside Claude and cost nothing. The filters are only for sizing your target segment against the list you cleaned.

How many match

30,597 mailable people matched on 2 October 2026. Filters: jobLevel Director, jobFunction Advertising & Marketing, employeeRange 51-200, country US.

Mailable means verified, catch_all_valid or catch_all, the default for leadocean_count_leads. The count is free. If your cleaned file holds far fewer rows than the segment, you have room to add more.

What you get back

Each kept row comes back complete. These are placeholder values, not real records.

TitleCompany sizeIndustryCountryStatus
Director of Marketing51-200Software DevelopmentUSkept, filled
Director, Demand Generation51-200Marketing ServicesUSkept
Director of Marketing51-200Software DevelopmentUSremoved, same email as row 1

Variations

  • Dedupe by domain too: "keep one contact per company domain, the most senior title".
  • Swap step 4 for "Managers in Sales & Business Development in GB" to size a different list.
  • Add "list rows whose email domain differs from the company domain" to catch personal and stale addresses.

Records it spends

The enum lookups and the count are free. leadocean_get_lead costs 1 record per person found, so 25 rows cost up to 25 records. A person we hold nothing for costs nothing. Free gives you 1,000 records one-off with no card. Pro is $499 a month. See pricing.

More prompts live in the prompts hub.

Clean your next lead list before you send

Free to start. No credit card. 1,000 records to spend whenever you like.

Get your free API key →