orangeslice 2.1.2 → 2.1.4-beta.0
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/README.md +15 -3
- package/dist/api.js +1 -1
- package/dist/cli.js +102 -22
- package/dist/ctx.d.ts +62 -0
- package/dist/ctx.js +101 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3 -1
- package/docs/integrations/hubspot/getList.md +52 -0
- package/docs/integrations/hubspot/index.md +5 -1
- package/docs/lookalike-search/index.md +154 -0
- package/docs/prospecting/index.md +77 -67
- package/docs/prospecting/linkedin_data/QUICK_REF.md +3 -1
- package/docs/prospecting/linkedin_data/index.md +33 -12
- package/docs/services/builtWith/index.md +6 -6
- package/docs/services/builtWith/lookupDomain.ts +1 -1
- package/docs/services/builtWith/relationships.ts +1 -1
- package/docs/services/builtWith/searchByTech.ts +1 -1
- package/docs/services/company/getEmployeesFromLinkedin.md +26 -12
- package/docs/services/company/linkedin/enrich.md +2 -0
- package/docs/services/company/linkedin/search.md +4 -2
- package/docs/services/company/revenue.md +74 -0
- package/docs/services/ctx/index.md +68 -0
- package/docs/services/googleMaps/scrape.ts +1 -1
- package/docs/services/index.md +1 -0
- package/docs/services/ocean/search/companies.ts +130 -0
- package/docs/services/ocean/search/people.ts +120 -0
- package/docs/services/person/contact/get.ts +2 -2
- package/docs/services/person/linkedin/findUrl.md +2 -2
- package/docs/services/person/linkedin/search.md +4 -2
- package/package.json +1 -1
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Search LinkedIn B2B database for companies by domain, slug, or ID lookup
|
|
2
|
+
description: Search LinkedIn B2B database for companies by domain, slug, or ID lookup. NOT for prospecting — use web search for discovery.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
# Company LinkedIn Search
|
|
6
6
|
|
|
7
7
|
**Credits: 1/result (per-result). Reserves based on query `LIMIT`.**
|
|
8
8
|
|
|
9
|
-
>
|
|
9
|
+
> **🚫 PROSPECTING CHECK:** Are you using this to **discover new companies**? This service is almost never the right choice for prospecting. Use `services.web.search` with `site:linkedin.com/company` patterns for discovery. The only prospecting exception is **trivially simple indexed-column filters** (e.g. `industry_code = 4 AND country_code = 'US'`). Any query with keywords, descriptions, company names, ILIKE, or semantic matching = web search.
|
|
10
|
+
|
|
11
|
+
> Only fast indexed queries are allowed (under 3 seconds, max 2-table joins). Everything else falls back to `services.web.search`. **You MUST read `services/web/search` before using web search.**
|
|
10
12
|
|
|
11
13
|
> **IMPORTANT:** These tables (`linkedin_company`, `linkedin_crunchbase_funding`, etc.) are in an **EXTERNAL B2B database** -- NOT accessible via `ctx.sql()`.
|
|
12
14
|
>
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# Get Company Revenue
|
|
2
|
+
|
|
3
|
+
Get company revenue, employee count, and firmographic data from a company domain.
|
|
4
|
+
|
|
5
|
+
**Credits: 2 (standard). Charged only if a valid result is returned.**
|
|
6
|
+
|
|
7
|
+
## Input Parameters
|
|
8
|
+
|
|
9
|
+
| Parameter | Type | Required | Description |
|
|
10
|
+
| --------- | -------- | -------- | ------------------------------------------------------------------------- |
|
|
11
|
+
| `domain` | `string` | Yes | Company website domain (e.g., `stripe.com`, `https://www.salesforce.com`) |
|
|
12
|
+
|
|
13
|
+
Accepts any format: bare domain (`stripe.com`), with www (`www.stripe.com`), or full URL (`https://www.stripe.com/about`). The domain is automatically normalized.
|
|
14
|
+
|
|
15
|
+
## Output
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
{
|
|
19
|
+
revenue: number | null; // USD (e.g., 5100000000 for $5.1B). Ranges averaged.
|
|
20
|
+
employees: number | null; // Count (e.g., 750 for "501-1,000"). Ranges averaged.
|
|
21
|
+
headquarters: string | null; // e.g., "San Francisco, California, United States"
|
|
22
|
+
industry: string | null; // e.g., "Business Intelligence (BI) Software, Software"
|
|
23
|
+
website: string | null; // e.g., "www.stripe.com"
|
|
24
|
+
funding: number | null; // USD (e.g., 8700000000 for $8.7B)
|
|
25
|
+
description: string | null; // Company description paragraph
|
|
26
|
+
sourceUrl: string | null; // The data source URL
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Examples
|
|
31
|
+
|
|
32
|
+
### Basic Revenue Lookup
|
|
33
|
+
|
|
34
|
+
```typescript
|
|
35
|
+
const companyData = await services.company.revenue({
|
|
36
|
+
domain: row.domain
|
|
37
|
+
});
|
|
38
|
+
return companyData.revenue; // 5100000000
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### Extract Multiple Fields
|
|
42
|
+
|
|
43
|
+
```typescript
|
|
44
|
+
const companyData = await services.company.revenue({
|
|
45
|
+
domain: row.website
|
|
46
|
+
});
|
|
47
|
+
return {
|
|
48
|
+
revenue: companyData.revenue,
|
|
49
|
+
employees: companyData.employees,
|
|
50
|
+
industry: companyData.industry,
|
|
51
|
+
hq: companyData.headquarters
|
|
52
|
+
};
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### Filter by Revenue Size
|
|
56
|
+
|
|
57
|
+
```typescript
|
|
58
|
+
const companyData = await services.company.revenue({
|
|
59
|
+
domain: row.domain
|
|
60
|
+
});
|
|
61
|
+
if (companyData.revenue && companyData.revenue > 1_000_000_000) {
|
|
62
|
+
return "Enterprise";
|
|
63
|
+
} else if (companyData.revenue && companyData.revenue > 100_000_000) {
|
|
64
|
+
return "Mid-Market";
|
|
65
|
+
}
|
|
66
|
+
return "SMB";
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
## Key Rules
|
|
70
|
+
|
|
71
|
+
1. **Domain input only** — pass the company's website domain. URLs, bare domains, and www-prefixed domains all work.
|
|
72
|
+
2. **Numbers are parsed** — revenue, employees, and funding are returned as numbers (not formatted strings). Ranges are averaged.
|
|
73
|
+
3. **All fields nullable** — if the data source doesn't list a field (e.g., funding for a bootstrapped company), it returns `null`.
|
|
74
|
+
4. **Handles normalization** — `https://www.stripe.com/about`, `www.stripe.com`, and `stripe.com` all resolve to the same company.
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Spreadsheet management — create spreadsheets, run SQL, add rows
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
# ctx — Spreadsheet Context API
|
|
6
|
+
|
|
7
|
+
Manage Orange Slice spreadsheets programmatically. Create spreadsheets, add sheets and columns via SQL, query data, insert rows.
|
|
8
|
+
|
|
9
|
+
## Quick start
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
import { ctx } from "orangeslice";
|
|
13
|
+
|
|
14
|
+
// Create a spreadsheet
|
|
15
|
+
const ss = await ctx.createSpreadsheet({ name: "Leads" });
|
|
16
|
+
|
|
17
|
+
// Create a sheet with columns
|
|
18
|
+
await ctx.sql(ss.id, "CREATE TABLE contacts (name, email, website)");
|
|
19
|
+
|
|
20
|
+
// Insert data
|
|
21
|
+
await ctx.sql(ss.id, "INSERT INTO contacts (name, email) VALUES ('Acme', 'hi@acme.com')");
|
|
22
|
+
|
|
23
|
+
// Query data
|
|
24
|
+
const result = await ctx.sql(ss.id, "SELECT * FROM contacts WHERE name = 'Acme'");
|
|
25
|
+
console.log(result.rows);
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Methods
|
|
29
|
+
|
|
30
|
+
### Top-level
|
|
31
|
+
|
|
32
|
+
- **`ctx.createSpreadsheet({ name })`** — Create a new spreadsheet. The scope (personal vs org) is determined by the API key. Returns `{ id, name }`.
|
|
33
|
+
- **`ctx.listSpreadsheets()`** — List spreadsheets visible to the API key's scope. Returns `{ spreadsheets: [...] }`.
|
|
34
|
+
- **`ctx.deleteSpreadsheet(spreadsheetId)`** — Soft-delete a spreadsheet (must be within the API key's scope).
|
|
35
|
+
- **`ctx.sql(spreadsheetId, sql)`** — Execute EAV-SQL against a spreadsheet within the API key's scope (see SQL reference below).
|
|
36
|
+
|
|
37
|
+
### Bound spreadsheet
|
|
38
|
+
|
|
39
|
+
Call `ctx.spreadsheet(id)` to get a handle bound to a specific spreadsheet:
|
|
40
|
+
|
|
41
|
+
```typescript
|
|
42
|
+
const ss = ctx.spreadsheet("uuid-here");
|
|
43
|
+
await ss.sql("SELECT * FROM contacts");
|
|
44
|
+
await ss.sheet("contacts").addRow({ name: "Corp", email: "corp@example.com" });
|
|
45
|
+
await ss.sheet("contacts").addRows([
|
|
46
|
+
{ name: "Foo", email: "foo@example.com" },
|
|
47
|
+
{ name: "Bar", email: "bar@example.com" }
|
|
48
|
+
]);
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
- **`ss.sql(sql)`** — Execute EAV-SQL (same as `ctx.sql` but without needing to pass spreadsheetId).
|
|
52
|
+
- **`ss.sheet(name).addRow(row)`** — Insert a single row into the named sheet.
|
|
53
|
+
- **`ss.sheet(name).addRows(rows)`** — Insert multiple rows.
|
|
54
|
+
|
|
55
|
+
## EAV-SQL Reference
|
|
56
|
+
|
|
57
|
+
The `sql` method supports a subset of SQL mapped to Orange Slice's EAV storage:
|
|
58
|
+
|
|
59
|
+
| Statement | Example | Description |
|
|
60
|
+
| -------------- | ---------------------------------------------------------- | -------------------------------- |
|
|
61
|
+
| `CREATE TABLE` | `CREATE TABLE leads (name, email, website)` | Creates a new sheet with columns |
|
|
62
|
+
| `SELECT` | `SELECT name, email FROM leads WHERE email LIKE '%@acme%'` | Query rows |
|
|
63
|
+
| `INSERT INTO` | `INSERT INTO leads (name) VALUES ('Acme')` | Add rows |
|
|
64
|
+
| `ALTER TABLE` | `ALTER TABLE leads ADD COLUMN phone` | Add/rename/drop columns |
|
|
65
|
+
| `DELETE FROM` | `DELETE FROM leads WHERE email IS NULL` | Delete rows |
|
|
66
|
+
| `DROP TABLE` | `DROP TABLE leads` | Delete a sheet |
|
|
67
|
+
|
|
68
|
+
> **Note:** `RUN` commands are not supported via the API.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Credits:
|
|
1
|
+
/** Credits: 10/result (per-result). Reserves up to `limit` or `maxCrawledPlacesPerSearch` (default 100). Settles actual count. */
|
|
2
2
|
|
|
3
3
|
interface GoogleMapsScraperInput {
|
|
4
4
|
/** Array of search terms to find places (e.g., ['grocery store', 'pizza restaurant']) */
|
package/docs/services/index.md
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
- **ctx**: Spreadsheet management — create spreadsheets, run SQL, add sheets/columns/rows programmatically.
|
|
1
2
|
- **ai**: AI helpers (summaries, classifications, scoring).
|
|
2
3
|
- **apify**: Run any of 10,000+ Apify actors for web scraping, social media, e-commerce, and more.
|
|
3
4
|
- **browser**: Kernel browser automation - spin up cloud browsers, execute Playwright code, take screenshots. **Use this for scraping structured lists of repeated data** (e.g., product listings, search results, table rows) where you know the DOM structure. Also ideal for **intercepting network requests** to discover underlying APIs, then paginate those APIs directly in your code (faster & cheaper than clicking through pages). Perfect for JS-heavy sites that don't work with simple HTTP scraping.
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
interface OceanCompaniesFilters {
|
|
2
|
+
/** Array of domains to find lookalike companies for (e.g., ["stripe.com", "shopify.com"]) */
|
|
3
|
+
lookalikeDomains?: string[];
|
|
4
|
+
/** Minimum similarity score (0-1) for lookalike matching */
|
|
5
|
+
minScore?: number;
|
|
6
|
+
/** Company size ranges to filter by */
|
|
7
|
+
companySizes?: Array<"0-1" | "2-10" | "11-50" | "51-200" | "201-500" | "501-1000" | "1001-5000" | "5001-10000" | "10001+">;
|
|
8
|
+
/** Two-letter country codes to filter by (e.g., ["us", "gb"]) */
|
|
9
|
+
countries?: string[];
|
|
10
|
+
/** Industry categories to filter by */
|
|
11
|
+
industries?: string[];
|
|
12
|
+
/** Technology names to filter by (e.g., ["React", "Salesforce"]) */
|
|
13
|
+
technologies?: string[];
|
|
14
|
+
/** Technology category names to filter by */
|
|
15
|
+
technologyCategories?: string[];
|
|
16
|
+
/** Keywords to search for */
|
|
17
|
+
keywords?: string[];
|
|
18
|
+
/** Revenue ranges to filter by (e.g., ["0-1M", "1M-10M"]) */
|
|
19
|
+
revenueRanges?: string[];
|
|
20
|
+
/** Filter for e-commerce companies */
|
|
21
|
+
ecommerce?: boolean;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
interface OceanCompanyResult {
|
|
25
|
+
/** Company domain */
|
|
26
|
+
domain: string;
|
|
27
|
+
/** Company name */
|
|
28
|
+
name?: string;
|
|
29
|
+
/** Legal company name */
|
|
30
|
+
legalName?: string;
|
|
31
|
+
/** Company description */
|
|
32
|
+
description?: string;
|
|
33
|
+
/** Two-letter country codes where the company operates */
|
|
34
|
+
countries?: string[];
|
|
35
|
+
/** Primary country code */
|
|
36
|
+
primaryCountry?: string;
|
|
37
|
+
/** Company size range (e.g., "51-200") */
|
|
38
|
+
companySize?: string;
|
|
39
|
+
/** Industry categories */
|
|
40
|
+
industryCategories?: string[];
|
|
41
|
+
/** Industries */
|
|
42
|
+
industries?: string[];
|
|
43
|
+
/** LinkedIn industry classification */
|
|
44
|
+
linkedinIndustry?: string;
|
|
45
|
+
/** Whether the company is an e-commerce business */
|
|
46
|
+
ecommerce?: boolean;
|
|
47
|
+
/** Company keywords */
|
|
48
|
+
keywords?: string[];
|
|
49
|
+
/** Ocean.io employee count estimate */
|
|
50
|
+
employeeCountOcean?: number;
|
|
51
|
+
/** LinkedIn employee count */
|
|
52
|
+
employeeCountLinkedin?: number;
|
|
53
|
+
/** Revenue range (e.g., "1M-10M") */
|
|
54
|
+
revenue?: string;
|
|
55
|
+
/** Year founded */
|
|
56
|
+
yearFounded?: number;
|
|
57
|
+
/** Company email addresses */
|
|
58
|
+
emails?: string[];
|
|
59
|
+
/** Phone numbers with country and primary flag */
|
|
60
|
+
phones?: Array<{ country?: string; number: string; primary?: boolean }>;
|
|
61
|
+
/** Company logo URL */
|
|
62
|
+
logo?: string;
|
|
63
|
+
/** Technologies used */
|
|
64
|
+
technologies?: string[];
|
|
65
|
+
/** Technology categories */
|
|
66
|
+
technologyCategories?: string[];
|
|
67
|
+
/** Company website root URL */
|
|
68
|
+
rootUrl?: string;
|
|
69
|
+
/** Social media profiles */
|
|
70
|
+
medias?: Record<string, { url?: string; handle?: string; name?: string }>;
|
|
71
|
+
/** Office locations */
|
|
72
|
+
locations?: Array<{
|
|
73
|
+
primary?: boolean;
|
|
74
|
+
latitude?: number;
|
|
75
|
+
longitude?: number;
|
|
76
|
+
country?: string;
|
|
77
|
+
locality?: string;
|
|
78
|
+
region?: string;
|
|
79
|
+
postalCode?: string;
|
|
80
|
+
streetAddress?: string;
|
|
81
|
+
state?: string;
|
|
82
|
+
}>;
|
|
83
|
+
/** Department sizes */
|
|
84
|
+
departmentSizes?: Array<{ department: string; size: number }>;
|
|
85
|
+
/** Headcount growth metrics */
|
|
86
|
+
headcountGrowth?: {
|
|
87
|
+
threeMonths?: number;
|
|
88
|
+
threeMonthsPercentage?: number;
|
|
89
|
+
sixMonths?: number;
|
|
90
|
+
sixMonthsPercentage?: number;
|
|
91
|
+
twelveMonths?: number;
|
|
92
|
+
twelveMonthsPercentage?: number;
|
|
93
|
+
};
|
|
94
|
+
/** Last update timestamp */
|
|
95
|
+
updatedAt?: string;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* Search for lookalike companies using Ocean.io.
|
|
100
|
+
* Provide seed domains via companiesFilters.lookalikeDomains to find similar companies.
|
|
101
|
+
* Filter by size, country, industry, technology, revenue, and more.
|
|
102
|
+
* Returns up to `size` companies per call (default 10). Use `searchAfter` for pagination.
|
|
103
|
+
*/
|
|
104
|
+
type companies = (params: {
|
|
105
|
+
/** Filters for company search (lookalike domains, size, country, industry, etc.) */
|
|
106
|
+
companiesFilters?: OceanCompaniesFilters;
|
|
107
|
+
/** Number of results to return (default 10, max 100) */
|
|
108
|
+
size?: number;
|
|
109
|
+
/** Pagination offset (use searchAfter for cursor-based pagination instead) */
|
|
110
|
+
from?: number;
|
|
111
|
+
/** Cursor token from a previous response for efficient pagination */
|
|
112
|
+
searchAfter?: string;
|
|
113
|
+
/** Domains to always include in results */
|
|
114
|
+
includeDomains?: string[];
|
|
115
|
+
/** Domains to exclude from results */
|
|
116
|
+
excludeDomains?: string[];
|
|
117
|
+
}) => Promise<{
|
|
118
|
+
/** Total matching companies */
|
|
119
|
+
total: number;
|
|
120
|
+
/** Cursor for next page (pass as searchAfter) */
|
|
121
|
+
searchAfter?: string;
|
|
122
|
+
/** Matched companies with relevance scores */
|
|
123
|
+
companies: Array<{
|
|
124
|
+
company: OceanCompanyResult;
|
|
125
|
+
/** Relevance grade (A = best match) */
|
|
126
|
+
relevance?: string;
|
|
127
|
+
}>;
|
|
128
|
+
/** Domains that were redirected to canonical domains */
|
|
129
|
+
redirectMap?: Record<string, string>;
|
|
130
|
+
}>;
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
interface OceanCompaniesFilters {
|
|
2
|
+
/** Array of domains to find lookalike companies for (e.g., ["stripe.com", "shopify.com"]) */
|
|
3
|
+
lookalikeDomains?: string[];
|
|
4
|
+
/** Minimum similarity score (0-1) for lookalike matching */
|
|
5
|
+
minScore?: number;
|
|
6
|
+
/** Company size ranges to filter by */
|
|
7
|
+
companySizes?: Array<"0-1" | "2-10" | "11-50" | "51-200" | "201-500" | "501-1000" | "1001-5000" | "5001-10000" | "10001+">;
|
|
8
|
+
/** Two-letter country codes to filter by (e.g., ["us", "gb"]) */
|
|
9
|
+
countries?: string[];
|
|
10
|
+
/** Industry categories to filter by */
|
|
11
|
+
industries?: string[];
|
|
12
|
+
/** Technology names to filter by (e.g., ["React", "Salesforce"]) */
|
|
13
|
+
technologies?: string[];
|
|
14
|
+
/** Technology category names to filter by */
|
|
15
|
+
technologyCategories?: string[];
|
|
16
|
+
/** Keywords to search for */
|
|
17
|
+
keywords?: string[];
|
|
18
|
+
/** Revenue ranges to filter by (e.g., ["0-1M", "1M-10M"]) */
|
|
19
|
+
revenueRanges?: string[];
|
|
20
|
+
/** Filter for e-commerce companies */
|
|
21
|
+
ecommerce?: boolean;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
interface OceanPeopleFilters {
|
|
25
|
+
/** Seniority levels to filter by (e.g., ["C-Level", "VP", "Director", "Manager"]) */
|
|
26
|
+
seniorities?: string[];
|
|
27
|
+
/** Departments to filter by (e.g., ["Engineering", "Sales", "Marketing"]) */
|
|
28
|
+
departments?: string[];
|
|
29
|
+
/** Job title keywords to search for */
|
|
30
|
+
jobTitleKeywords?: string[];
|
|
31
|
+
/** Two-letter country codes to filter by */
|
|
32
|
+
countries?: string[];
|
|
33
|
+
/** Array of Ocean.io people IDs to find lookalikes for */
|
|
34
|
+
lookalikePeopleIds?: string[];
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
interface OceanPersonResult {
|
|
38
|
+
/** Ocean.io person ID */
|
|
39
|
+
id: string;
|
|
40
|
+
/** Company domain */
|
|
41
|
+
domain?: string;
|
|
42
|
+
/** Full name */
|
|
43
|
+
name?: string;
|
|
44
|
+
/** First name */
|
|
45
|
+
firstName?: string;
|
|
46
|
+
/** Last name */
|
|
47
|
+
lastName?: string;
|
|
48
|
+
/** Two-letter country code */
|
|
49
|
+
country?: string;
|
|
50
|
+
/** State/region */
|
|
51
|
+
state?: string;
|
|
52
|
+
/** Location string */
|
|
53
|
+
location?: string;
|
|
54
|
+
/** LinkedIn profile URL */
|
|
55
|
+
linkedinUrl?: string;
|
|
56
|
+
/** Seniority levels (e.g., ["C-Level", "Manager"]) */
|
|
57
|
+
seniorities?: string[];
|
|
58
|
+
/** Departments (e.g., ["Engineering", "Management"]) */
|
|
59
|
+
departments?: string[];
|
|
60
|
+
/** Profile photo URL */
|
|
61
|
+
photo?: string;
|
|
62
|
+
/** Job title in original language */
|
|
63
|
+
jobTitle?: string;
|
|
64
|
+
/** Job title translated to English */
|
|
65
|
+
jobTitleEnglish?: string;
|
|
66
|
+
/** Current job description */
|
|
67
|
+
currentJobDescription?: string;
|
|
68
|
+
/** Work experience history */
|
|
69
|
+
experiences?: Array<{
|
|
70
|
+
dateFrom?: string;
|
|
71
|
+
dateTo?: string;
|
|
72
|
+
description?: string;
|
|
73
|
+
domain?: string;
|
|
74
|
+
jobTitle?: string;
|
|
75
|
+
}>;
|
|
76
|
+
/** Profile summary */
|
|
77
|
+
summary?: string;
|
|
78
|
+
/** Skills */
|
|
79
|
+
skills?: string[];
|
|
80
|
+
/** Phone numbers with verification status */
|
|
81
|
+
phone?: { numbers?: string[]; status?: string };
|
|
82
|
+
/** Email with verification status */
|
|
83
|
+
email?: { address?: string; status?: string };
|
|
84
|
+
/** Last update timestamp */
|
|
85
|
+
updatedAt?: string;
|
|
86
|
+
/** Company info snapshot */
|
|
87
|
+
company?: { companySize?: string; logo?: string; name?: string };
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Search for people at companies using Ocean.io.
|
|
92
|
+
* Combine companiesFilters (to target companies) with peopleFilters (to target roles/departments).
|
|
93
|
+
* Can request verified emails and phone numbers via enableEmailSearch / enablePhoneSearch.
|
|
94
|
+
* Returns up to `size` people per call (default 10). Use `searchAfter` for pagination.
|
|
95
|
+
*/
|
|
96
|
+
type people = (params: {
|
|
97
|
+
/** Filters to target companies (lookalike domains, size, country, etc.) */
|
|
98
|
+
companiesFilters?: OceanCompaniesFilters;
|
|
99
|
+
/** Filters to target people (seniority, department, title keywords, etc.) */
|
|
100
|
+
peopleFilters?: OceanPeopleFilters;
|
|
101
|
+
/** Number of results to return (default 10, max 100) */
|
|
102
|
+
size?: number;
|
|
103
|
+
/** Pagination offset */
|
|
104
|
+
from?: number;
|
|
105
|
+
/** Cursor token from a previous response for efficient pagination */
|
|
106
|
+
searchAfter?: string;
|
|
107
|
+
/** Request verified email addresses (uses additional credits) */
|
|
108
|
+
enableEmailSearch?: boolean;
|
|
109
|
+
/** Request verified phone numbers (uses additional credits) */
|
|
110
|
+
enablePhoneSearch?: boolean;
|
|
111
|
+
}) => Promise<{
|
|
112
|
+
/** Total matching people */
|
|
113
|
+
total: number;
|
|
114
|
+
/** Cursor for next page (pass as searchAfter) */
|
|
115
|
+
searchAfter?: string;
|
|
116
|
+
/** Matched people */
|
|
117
|
+
people: OceanPersonResult[];
|
|
118
|
+
/** Domains that were redirected to canonical domains */
|
|
119
|
+
redirectMap?: Record<string, string>;
|
|
120
|
+
}>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/** Credits: up to 275 (custom). Email+Phone=275, Phone=250, Email=25. 0 if not found. */
|
|
2
2
|
|
|
3
3
|
interface ContactInfoResponse {
|
|
4
|
-
/** The work emails of the person */
|
|
4
|
+
/** The work emails of the person. All emails are pre-filtered for deliverability — only verified deliverable addresses are returned. */
|
|
5
5
|
work_emails: string[];
|
|
6
6
|
/** The work phone numbers of the person */
|
|
7
7
|
work_phones: string[];
|
|
8
|
-
/** The personal emails of the person */
|
|
8
|
+
/** The personal emails of the person. All emails are pre-filtered for deliverability — only verified deliverable addresses are returned. */
|
|
9
9
|
personal_emails: string[];
|
|
10
10
|
/** The personal phone numbers of the person */
|
|
11
11
|
personal_phones: string[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/\*_ Credits: 2
|
|
1
|
+
/\*_ Credits: 2 for the name + company search path, or 50 when reverse-email lookup is used. Charged only if a valid URL is returned. _/
|
|
2
2
|
|
|
3
3
|
/\*\*
|
|
4
4
|
|
|
@@ -15,6 +15,6 @@
|
|
|
15
15
|
keyword?: string;
|
|
16
16
|
/\*_ Location string (e.g., city, state, country) to narrow search results _/
|
|
17
17
|
location?: string;
|
|
18
|
-
/\*_ Email address. If provided,
|
|
18
|
+
/\*_ Email address. If provided, the service tries name + company search first when possible, then falls back to reverse-email lookup. _/
|
|
19
19
|
email?: string;
|
|
20
20
|
}) => Promise<string | undefined>;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Search LinkedIn B2B database for people by company ID or slug lookup
|
|
2
|
+
description: Search LinkedIn B2B database for people by company ID or slug lookup. NOT for prospecting — use web search for discovery.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
# Person LinkedIn Search
|
|
6
6
|
|
|
7
7
|
**Credits: 1/result (per-result). Reserves based on query `LIMIT`.**
|
|
8
8
|
|
|
9
|
-
>
|
|
9
|
+
> **🚫 PROSPECTING CHECK:** Are you using this to **discover new people**? This service is almost never the right choice for finding people you don't already have identifiers for. Use `services.web.search` with `site:linkedin.com/in` patterns for discovery. This service is meant for: looking up a person by slug, or listing employees at a single company you already have the ID for.
|
|
10
|
+
|
|
11
|
+
> Only fast indexed queries are allowed (under 3 seconds, max 2-table joins). Everything else falls back to `services.web.search`. **You MUST read `services/web/search` before using web search.**
|
|
10
12
|
|
|
11
13
|
> **IMPORTANT:** These tables (`linkedin_profile`, `linkedin_profile_position3`, etc.) are in an **EXTERNAL B2B database** -- NOT accessible via `ctx.sql()`.
|
|
12
14
|
>
|