scrapercity 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENT_DOCS.txt +12 -17
- package/README.md +1 -1
- package/SKILL.md +0 -1
- package/bin/cli.mjs +0 -35
- package/bin/mcp.mjs +2 -31
- package/lib/client.mjs +6 -2
- package/package.json +1 -1
package/AGENT_DOCS.txt
CHANGED
|
@@ -18,14 +18,6 @@ apollo
|
|
|
18
18
|
Cost: $0.0039/lead | Min 500, max 50000
|
|
19
19
|
DELIVERY: UP TO 4 DAYS. Use webhook, not polling.
|
|
20
20
|
|
|
21
|
-
apollo-filters
|
|
22
|
-
Body: { seniorityLevel, functionDept, companyIndustry, personCountry, personState,
|
|
23
|
-
companyCountry, companyState, companySize, personTitles:[], companyDomains:[],
|
|
24
|
-
companyKeywords:[], personCities:[], companyCities:[], hasPhone, count, fileName }
|
|
25
|
-
At least one filter required.
|
|
26
|
-
Returns: { runId, message }
|
|
27
|
-
Cost: $0.0039/lead | DELIVERY: UP TO 4 DAYS.
|
|
28
|
-
|
|
29
21
|
maps
|
|
30
22
|
Body: { searchStringsArray: ["plumbers"], locationQuery: "Denver, CO", maxCrawledPlacesPerSearch: 500 }
|
|
31
23
|
Returns: { runId, datasetId, priceMicro }
|
|
@@ -157,7 +149,9 @@ GET /api/v1/apollo-status
|
|
|
157
149
|
Returns: { useApify, message } - check if Apollo URL endpoint is available
|
|
158
150
|
|
|
159
151
|
────────────────────────────────────────
|
|
160
|
-
DATABASES (GET, $
|
|
152
|
+
DATABASES (GET, $149+ plans, 100k/day)
|
|
153
|
+
This is the recommended path for filter-based B2B people search (by title,
|
|
154
|
+
industry, location, seniority, etc). Returns instantly from a cached dataset.
|
|
161
155
|
────────────────────────────────────────
|
|
162
156
|
|
|
163
157
|
GET /api/v1/database/leads?title=CTO&country=United States&hasEmail=true&page=1&limit=100
|
|
@@ -184,19 +178,20 @@ ERROR CODES
|
|
|
184
178
|
WORKFLOW EXAMPLES
|
|
185
179
|
────────────────────────────────────────
|
|
186
180
|
|
|
187
|
-
1.
|
|
181
|
+
1. LEAD DATABASE (instant, recommended for B2B people search):
|
|
182
|
+
GET /api/v1/database/leads?title=CTO&industry=computer+software&hasEmail=true&page=1
|
|
183
|
+
Loop pages until page > totalPages.
|
|
184
|
+
This is the supported path for filter-based B2B contact search ($149+ plans).
|
|
185
|
+
|
|
186
|
+
2. MAPS SCRAPE (fast):
|
|
188
187
|
POST /api/v1/scrape/maps → get runId → poll status every 15s → download CSV
|
|
189
188
|
|
|
190
|
-
|
|
189
|
+
3. APOLLO SCRAPE (slow, only when user provides an apollo.io URL):
|
|
191
190
|
POST /api/v1/scrape/apollo → get runId → configure webhook → wait for callback
|
|
192
191
|
Do NOT poll Apollo in a tight loop. Check once per hour at most.
|
|
193
192
|
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
4. LEAD DATABASE (instant):
|
|
198
|
-
GET /api/v1/database/leads?title=CTO&industry=computer+software&hasEmail=true&page=1
|
|
199
|
-
Loop pages until page > totalPages
|
|
193
|
+
4. ENRICH PIPELINE:
|
|
194
|
+
Database/Maps → download CSV → extract emails → POST email-validator → download validated CSV
|
|
200
195
|
|
|
201
196
|
5. LOCAL BUSINESS PIPELINE:
|
|
202
197
|
Yelp/Angi/Maps → download CSV → POST email-finder with names+domains → POST mobile-finder
|
package/README.md
CHANGED
|
@@ -87,7 +87,7 @@ curl -O https://app.scrapercity.com/api/downloads/RUN_ID \
|
|
|
87
87
|
2. **Poll status** (or use webhooks) → wait for `SUCCEEDED`
|
|
88
88
|
3. **Download CSV** → leads with full contact info
|
|
89
89
|
|
|
90
|
-
Apollo scrapes take
|
|
90
|
+
Apollo scrapes take 11-48+ hours. All other scrapers: 1-30 minutes. Store leads are instant.
|
|
91
91
|
|
|
92
92
|
## Authentication
|
|
93
93
|
|
package/SKILL.md
CHANGED
|
@@ -20,7 +20,6 @@ Auth: `Authorization: Bearer $SCRAPERCITY_API_KEY` on all requests.
|
|
|
20
20
|
| Slug | Input | Cost | Speed |
|
|
21
21
|
|------|-------|------|-------|
|
|
22
22
|
| `apollo` | `{url, count, fileName}` | $0.0039/lead | ~4 DAYS (use webhook) |
|
|
23
|
-
| `apollo-filters` | `{seniorityLevel, functionDept, companyIndustry, personCountry, personState, companySize, personTitles[], companyDomains[], count}` | $0.0039/lead | ~4 DAYS |
|
|
24
23
|
| `maps` | `{searchStringsArray:["query"], locationQuery, maxCrawledPlacesPerSearch}` | $0.01/place | 5-30 min |
|
|
25
24
|
| `email-validator` | `{emails:["a@b.com"]}` | $0.0036/email | 1-10 min |
|
|
26
25
|
| `email-finder` | `{contacts:[{first_name,last_name,domain}], autoValidateEmails, autoFindMobiles}` | $0.05/contact | 1-10 min |
|
package/bin/cli.mjs
CHANGED
|
@@ -97,40 +97,6 @@ async function main() {
|
|
|
97
97
|
break
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
// ── Apollo Filters ────────────────────────────────────
|
|
101
|
-
case 'apollo-filters': {
|
|
102
|
-
const filters = {}
|
|
103
|
-
for (const f of ['--seniority', '--function', '--industry', '--country', '--state',
|
|
104
|
-
'--company-country', '--company-state', '--company-size', '--count', '--name', '--has-phone']) {
|
|
105
|
-
const v = flag(f)
|
|
106
|
-
if (v === undefined) continue
|
|
107
|
-
const key = {
|
|
108
|
-
'--seniority': 'seniorityLevel', '--function': 'functionDept',
|
|
109
|
-
'--industry': 'companyIndustry', '--country': 'personCountry',
|
|
110
|
-
'--state': 'personState', '--company-country': 'companyCountry',
|
|
111
|
-
'--company-state': 'companyState', '--company-size': 'companySize',
|
|
112
|
-
'--count': 'count', '--name': 'fileName', '--has-phone': 'hasPhone'
|
|
113
|
-
}[f]
|
|
114
|
-
filters[key] = f === '--has-phone' ? true : (f === '--count' ? +v : v)
|
|
115
|
-
}
|
|
116
|
-
// Array flags
|
|
117
|
-
for (const f of ['--titles', '--domains', '--keywords', '--person-cities', '--company-cities']) {
|
|
118
|
-
const v = flag(f)
|
|
119
|
-
if (!v) continue
|
|
120
|
-
const key = { '--titles': 'personTitles', '--domains': 'companyDomains',
|
|
121
|
-
'--keywords': 'companyKeywords', '--person-cities': 'personCities',
|
|
122
|
-
'--company-cities': 'companyCities' }[f]
|
|
123
|
-
filters[key] = v.split(',').map(s => s.trim())
|
|
124
|
-
}
|
|
125
|
-
if (!Object.keys(filters).length) die('At least one filter required. Example: scrapercity apollo-filters --industry "computer software" --country "United States" --count 1000')
|
|
126
|
-
const r = await sc.apolloFilters(filters)
|
|
127
|
-
console.log(`✓ Apollo filter search started`)
|
|
128
|
-
console.log(` Run ID: ${r.runId}`)
|
|
129
|
-
console.log(` ${r.message || ''}`)
|
|
130
|
-
console.log(` Note: Apollo takes up to 4 days. Set up a webhook to get notified.`)
|
|
131
|
-
break
|
|
132
|
-
}
|
|
133
|
-
|
|
134
100
|
// ── Maps ──────────────────────────────────────────────
|
|
135
101
|
case 'maps': {
|
|
136
102
|
const query = flag('--query') || flag('-q')
|
|
@@ -466,7 +432,6 @@ ScraperCity CLI - B2B lead generation from your terminal
|
|
|
466
432
|
|
|
467
433
|
Scrapers:
|
|
468
434
|
scrapercity apollo <url> [--count N] Apollo scrape (URL-based, ~4 day delivery)
|
|
469
|
-
scrapercity apollo-filters [filters] Apollo scrape (filter-based)
|
|
470
435
|
scrapercity maps -q <query> -l <loc> Google Maps scrape
|
|
471
436
|
scrapercity email-validate <emails> Validate email addresses
|
|
472
437
|
scrapercity email-find --first X --last Y --domain Z Find business emails
|
package/bin/mcp.mjs
CHANGED
|
@@ -31,7 +31,7 @@ const TOOLS = [
|
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
33
|
name: 'scrape_apollo',
|
|
34
|
-
description: 'Scrape leads from Apollo.io using a search URL. IMPORTANT: Apollo delivery takes
|
|
34
|
+
description: 'Scrape leads from Apollo.io using a search URL. IMPORTANT: Apollo delivery takes 11-48+ hours. Use webhooks (configure at app.scrapercity.com/dashboard/webhooks) instead of polling. Returns a runId to check status later.',
|
|
35
35
|
inputSchema: {
|
|
36
36
|
type: 'object',
|
|
37
37
|
properties: {
|
|
@@ -42,31 +42,6 @@ const TOOLS = [
|
|
|
42
42
|
required: ['url']
|
|
43
43
|
}
|
|
44
44
|
},
|
|
45
|
-
{
|
|
46
|
-
name: 'scrape_apollo_filters',
|
|
47
|
-
description: 'Scrape leads from Apollo.io using filter parameters instead of a URL. Same 4-day delivery - use webhooks. At least one filter required.',
|
|
48
|
-
inputSchema: {
|
|
49
|
-
type: 'object',
|
|
50
|
-
properties: {
|
|
51
|
-
seniorityLevel: { type: 'string', description: 'e.g. "director", "vp", "c_suite", "manager", "senior"' },
|
|
52
|
-
functionDept: { type: 'string', description: 'e.g. "sales", "marketing", "engineering", "finance"' },
|
|
53
|
-
companyIndustry: { type: 'string', description: 'e.g. "computer software", "financial services"' },
|
|
54
|
-
personCountry: { type: 'string', description: 'e.g. "United States", "United Kingdom"' },
|
|
55
|
-
personState: { type: 'string', description: 'e.g. "California", "New York"' },
|
|
56
|
-
companyCountry: { type: 'string', description: 'Company HQ country' },
|
|
57
|
-
companyState: { type: 'string', description: 'Company HQ state' },
|
|
58
|
-
companySize: { type: 'string', description: 'e.g. "11-50", "51-200", "201-500", "501-1000", "1001-5000"' },
|
|
59
|
-
personTitles: { type: 'array', items: { type: 'string' }, description: 'Specific job titles to target' },
|
|
60
|
-
companyDomains: { type: 'array', items: { type: 'string' }, description: 'Specific company domains' },
|
|
61
|
-
companyKeywords: { type: 'array', items: { type: 'string' }, description: 'Company description keywords' },
|
|
62
|
-
personCities: { type: 'array', items: { type: 'string' }, description: 'Person city filter' },
|
|
63
|
-
companyCities: { type: 'array', items: { type: 'string' }, description: 'Company city filter' },
|
|
64
|
-
hasPhone: { type: 'boolean', description: 'Only return contacts with phone numbers', default: false },
|
|
65
|
-
count: { type: 'number', description: 'Number of leads (min 500, max 50000)', default: 1000 },
|
|
66
|
-
fileName: { type: 'string', description: 'Export name', default: 'Apollo Export' }
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
},
|
|
70
45
|
{
|
|
71
46
|
name: 'scrape_maps',
|
|
72
47
|
description: 'Scrape businesses from Google Maps. Returns businesses with names, addresses, phone numbers, websites, emails, ratings. Typically completes in 5-30 minutes.',
|
|
@@ -381,11 +356,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
|
381
356
|
break
|
|
382
357
|
case 'scrape_apollo':
|
|
383
358
|
result = await sc.apollo(args.url, args.count || 1000, args.fileName || '')
|
|
384
|
-
result._note = 'Apollo takes
|
|
385
|
-
break
|
|
386
|
-
case 'scrape_apollo_filters':
|
|
387
|
-
result = await sc.apolloFilters(args)
|
|
388
|
-
result._note = 'Apollo takes up to 4 days. Configure webhook at app.scrapercity.com/dashboard/webhooks instead of polling.'
|
|
359
|
+
result._note = 'Apollo takes 11-48+ hours. Configure webhook at app.scrapercity.com/dashboard/webhooks instead of polling.'
|
|
389
360
|
break
|
|
390
361
|
case 'scrape_maps':
|
|
391
362
|
result = await sc.maps(args.query, args.location, args.limit || 500)
|
package/lib/client.mjs
CHANGED
|
@@ -83,8 +83,12 @@ export async function download(runId, outputPath) {
|
|
|
83
83
|
export const apollo = (url, count = 1000, fileName = '') =>
|
|
84
84
|
post('/api/v1/scrape/apollo', { url, count, fileName })
|
|
85
85
|
|
|
86
|
-
|
|
87
|
-
|
|
86
|
+
// apolloFilters was the filter-based Apollo endpoint. It has been retired.
|
|
87
|
+
// For B2B people search by filter, use the Lead Database (GET /api/v1/database/leads,
|
|
88
|
+
// included on the $149/mo plan and above).
|
|
89
|
+
export const apolloFilters = () => {
|
|
90
|
+
throw new Error('apolloFilters is no longer available. Use the Lead Database (GET /api/v1/database/leads) instead - included on the $149/mo plan and above.')
|
|
91
|
+
}
|
|
88
92
|
|
|
89
93
|
export const apolloStatus = () => get('/api/v1/apollo-status')
|
|
90
94
|
|