Files
davidandClaude Opus 5.5 82d569da9c Phase 2 part 5: find people and verify emails with Hunter.io
Review gets Find people (Domain Search by the departments, seniority and
count set in Settings → Lead sources), Find their email (Email Finder for
a named person at a company), and Verify (one, or every unchecked address
in New). Every call is kept in enrich_runs (schema 9) with its result and
credits, and shown on the card. Nothing runs on a schedule. Sources are
shown by name (Hunter.io, origami.chat, explee.com).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 05:53:52 -07:00

56 lines
3.5 KiB
HTML

{{define "content"}}{{template "settings-start" .}}{{with .Data}}
<h2>Lead sources</h2>
<p class="lede">The prospecting tools you test buying signals in. Supermarket only reads from them: campaigns and their numbers, who was contacted, who replied, who was interested and who unsubscribed. It never starts, changes or sends anything there. Results appear on <a href="/signals">Signals</a>.</p>
<form method="post" action="/settings/sources" autocomplete="off">
{{range .Sources}}
<section class="card">
<h3>{{.Name}}</h3>
{{template "key-field" (dict "F" .Key "Set" .Set)}}
{{if eq .ID "origami"}}
<label>Project <span class="muted small">(optional)</span> <input name="origami_project" value="{{$.Data.Project}}" placeholder="a project ID, to read only that project">
<span class="help">If your organization has projects, the ID of the one to read. Leave empty to read the whole organization.</span></label>
{{end}}
{{if .Set}}
<button type="button" class="secondary small" hx-post="/settings/sources/test/{{.ID}}" hx-target="#test-{{.ID}}" hx-indicator="#testing-{{.ID}}">Test</button>
<span id="testing-{{.ID}}" class="htmx-indicator">Checking…</span>
<div id="test-{{.ID}}"></div>
{{end}}
</section>
{{end}}
{{with .Hunter}}
<h2 id="hunter">Enrichment</h2>
<section class="card">
<h3>Hunter.io</h3>
<p class="small">Finds the people in the roles you sell to at a prospect's website domain, the work address of a person whose name you know, and whether an address receives mail. You start each search from <a href="/prospects">Review</a>; nothing runs on its own. A search costs a credit when it finds someone, a verification half a credit.{{if ne .Used "0"}} Used in the last 30 days: <strong>{{.Used}}</strong> credits.{{end}}</p>
{{template "key-field" (dict "F" .Key "Set" .Set)}}
<fieldset>
<legend>Whom to look for at a company</legend>
<p class="help">Departments (none ticked: all of them)</p>
<div class="check-grid">{{$set := .Settings}}{{range .Departments}}<label class="check"><input type="checkbox" name="hunter_department" value="{{.ID}}" {{if has $set.Departments .ID}}checked{{end}}> {{.Label}}</label>{{end}}</div>
<p class="help">Seniority (none ticked: any)</p>
<div class="check-grid">{{range .Seniorities}}<label class="check"><input type="checkbox" name="hunter_seniority" value="{{.ID}}" {{if has $set.Seniority .ID}}checked{{end}}> {{.Label}}</label>{{end}}</div>
<label>At most
<select name="hunter_per_company">{{range .PerCompany}}<option value="{{.}}" {{if eq . $set.PerCompany}}selected{{end}}>{{.}} people a company</option>{{end}}</select>
<span class="help">Hunter.io's free plan returns at most 10 a search.</span>
</label>
</fieldset>
{{if .Set}}
<button type="button" class="secondary small" hx-post="/settings/sources/test/hunter" hx-target="#test-hunter" hx-indicator="#testing-hunter">Test</button>
<span id="testing-hunter" class="htmx-indicator">Checking…</span>
<div id="test-hunter"></div>
{{end}}
</section>
{{end}}
<div class="actions"><button type="submit">Save</button></div>
</form>
{{end}}{{template "settings-end"}}{{end}}
{{define "test-result"}}
{{with .Error}}<p class="error">{{.}}</p>{{end}}
{{with .OK}}<p class="ok">{{.}}</p>{{end}}
{{with .Sample}}<details><summary>What the API sends</summary>
<p class="help">origami.chat doesn't document its responses, so Supermarket looks fields up by the names its docs use. If an import misses replies or contacts, this shows the real names.</p>
<pre class="sample">{{.}}</pre></details>{{end}}
{{end}}