@coldiq/mcp 0.3.24 → 0.3.27
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/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/dist/tools/call-endpoint.d.ts +22 -0
- package/dist/tools/call-endpoint.d.ts.map +1 -0
- package/dist/tools/call-endpoint.js +27 -0
- package/dist/tools/call-endpoint.js.map +1 -0
- package/dist/tools/enrich-person.d.ts.map +1 -1
- package/dist/tools/enrich-person.js +4 -1
- package/dist/tools/enrich-person.js.map +1 -1
- package/dist/tools/find-emails-bulk.d.ts.map +1 -1
- package/dist/tools/find-emails-bulk.js +5 -1
- package/dist/tools/find-emails-bulk.js.map +1 -1
- package/dist/tools/find-emails.d.ts.map +1 -1
- package/dist/tools/find-emails.js +4 -1
- package/dist/tools/find-emails.js.map +1 -1
- package/dist/tools/find-people.d.ts.map +1 -1
- package/dist/tools/find-people.js +1 -0
- package/dist/tools/find-people.js.map +1 -1
- package/dist/tools/get-bulk-job.d.ts.map +1 -1
- package/dist/tools/get-bulk-job.js +7 -4
- package/dist/tools/get-bulk-job.js.map +1 -1
- package/dist/tools/get-endpoint-details.d.ts +21 -0
- package/dist/tools/get-endpoint-details.d.ts.map +1 -0
- package/dist/tools/get-endpoint-details.js +21 -0
- package/dist/tools/get-endpoint-details.js.map +1 -0
- package/dist/tools/search-endpoints.d.ts +21 -0
- package/dist/tools/search-endpoints.d.ts.map +1 -0
- package/dist/tools/search-endpoints.js +31 -0
- package/dist/tools/search-endpoints.js.map +1 -0
- package/dist/tools/verify-emails-bulk.d.ts.map +1 -1
- package/dist/tools/verify-emails-bulk.js +5 -0
- package/dist/tools/verify-emails-bulk.js.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +7 -0
- package/src/tools/call-endpoint.ts +31 -0
- package/src/tools/enrich-person.ts +4 -1
- package/src/tools/find-emails-bulk.ts +5 -1
- package/src/tools/find-emails.ts +4 -1
- package/src/tools/find-people.ts +1 -0
- package/src/tools/get-bulk-job.ts +7 -4
- package/src/tools/get-endpoint-details.ts +25 -0
- package/src/tools/search-endpoints.ts +35 -0
- package/src/tools/verify-emails-bulk.ts +5 -0
- package/tests/tools/call-endpoint.test.ts +41 -0
- package/tests/tools/get-endpoint-details.test.ts +37 -0
- package/tests/tools/search-endpoints.test.ts +37 -0
package/dist/index.js
CHANGED
|
@@ -14,6 +14,9 @@ import { enrichPersonBulkName, enrichPersonBulkDescription, enrichPersonBulkSche
|
|
|
14
14
|
import { enrichCompanyBulkName, enrichCompanyBulkDescription, enrichCompanyBulkSchema, enrichCompanyBulkHandler } from './tools/enrich-company-bulk.js';
|
|
15
15
|
import { findPhoneBulkName, findPhoneBulkDescription, findPhoneBulkSchema, findPhoneBulkHandler } from './tools/find-phone-bulk.js';
|
|
16
16
|
import { getBulkJobName, getBulkJobDescription, getBulkJobSchema, getBulkJobHandler } from './tools/get-bulk-job.js';
|
|
17
|
+
import { searchEndpointsName, searchEndpointsDescription, searchEndpointsSchema, searchEndpointsHandler } from './tools/search-endpoints.js';
|
|
18
|
+
import { getEndpointDetailsName, getEndpointDetailsDescription, getEndpointDetailsSchema, getEndpointDetailsHandler } from './tools/get-endpoint-details.js';
|
|
19
|
+
import { callEndpointName, callEndpointDescription, callEndpointSchema, callEndpointHandler } from './tools/call-endpoint.js';
|
|
17
20
|
import { findPhoneName, findPhoneDescription, findPhoneSchema, findPhoneHandler, } from './tools/find-phone.js';
|
|
18
21
|
import { enrichCompanyName, enrichCompanyDescription, enrichCompanySchema, enrichCompanyHandler, } from './tools/enrich-company.js';
|
|
19
22
|
import { searchWebName, searchWebDescription, searchWebSchema, searchWebHandler, } from './tools/search-web.js';
|
|
@@ -80,6 +83,10 @@ server.tool(listSkillsName, listSkillsDescription, listSkillsSchema, listSkillsH
|
|
|
80
83
|
server.tool(loadSkillName, loadSkillDescription, loadSkillSchema, loadSkillHandler);
|
|
81
84
|
server.tool(extractPostEngagementName, extractPostEngagementDescription, extractPostEngagementSchema, extractPostEngagementHandler);
|
|
82
85
|
server.tool(getPlaceReviewsName, getPlaceReviewsDescription, getPlaceReviewsSchema, getPlaceReviewsHandler);
|
|
86
|
+
// Generic endpoint discovery + invoke: reach any integrated provider without a dedicated tool.
|
|
87
|
+
server.tool(searchEndpointsName, searchEndpointsDescription, searchEndpointsSchema, searchEndpointsHandler);
|
|
88
|
+
server.tool(getEndpointDetailsName, getEndpointDetailsDescription, getEndpointDetailsSchema, getEndpointDetailsHandler);
|
|
89
|
+
server.tool(callEndpointName, callEndpointDescription, callEndpointSchema, callEndpointHandler);
|
|
83
90
|
// Connect via stdio transport
|
|
84
91
|
const transport = new StdioServerTransport();
|
|
85
92
|
await server.connect(transport);
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAA;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAA;AAChF,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,OAAO,EACL,mBAAmB,EACnB,0BAA0B,EAC1B,qBAAqB,EACrB,sBAAsB,GACvB,MAAM,6BAA6B,CAAA;AAEpC,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,wBAAwB,CAAA;AAE/B,OAAO,EACL,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,gBAAgB,GACjB,MAAM,uBAAuB,CAAA;AAE9B,OAAO,EACL,gBAAgB,EAChB,uBAAuB,EACvB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,0BAA0B,CAAA;AAEjC,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,wBAAwB,CAAA;AAE/B,OAAO,EACL,eAAe,EACf,sBAAsB,EACtB,iBAAiB,E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AAE/F,8BAA8B;AAC9B,MAAM,SAAS,GAAG,IAAI,oBAAoB,EAAE,CAAA;AAC5C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAA"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const callEndpointName = "call_endpoint";
|
|
3
|
+
export declare const callEndpointDescription: string;
|
|
4
|
+
export declare const callEndpointSchema: {
|
|
5
|
+
api: z.ZodString;
|
|
6
|
+
path: z.ZodString;
|
|
7
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
8
|
+
};
|
|
9
|
+
export declare function callEndpointHandler(input: Record<string, unknown>): Promise<{
|
|
10
|
+
content: {
|
|
11
|
+
type: "text";
|
|
12
|
+
text: string;
|
|
13
|
+
}[];
|
|
14
|
+
isError: boolean;
|
|
15
|
+
} | {
|
|
16
|
+
content: {
|
|
17
|
+
type: "text";
|
|
18
|
+
text: string;
|
|
19
|
+
}[];
|
|
20
|
+
isError?: undefined;
|
|
21
|
+
}>;
|
|
22
|
+
//# sourceMappingURL=call-endpoint.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"call-endpoint.d.ts","sourceRoot":"","sources":["../../src/tools/call-endpoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,gBAAgB,kBAAkB,CAAA;AAE/C,eAAO,MAAM,uBAAuB,QAKgB,CAAA;AAEpD,eAAO,MAAM,kBAAkB;;;;CAO9B,CAAA;AAED,wBAAsB,mBAAmB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;GASvE"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { callApi } from '../client.js';
|
|
3
|
+
export const callEndpointName = 'call_endpoint';
|
|
4
|
+
export const callEndpointDescription = 'Call any ColdIQ marketplace endpoint directly with provider-native parameters — the generic invoke for ' +
|
|
5
|
+
'providers/capabilities without a dedicated tool. Get the `api`, `path`, and required params from ' +
|
|
6
|
+
'get_endpoint_details first. Returns the provider response verbatim ({ ok, status, data }). ' +
|
|
7
|
+
'PAID: this bills exactly like calling the endpoint directly (same credit cost + upstream call), so only ' +
|
|
8
|
+
'invoke it to perform the action, not to explore.';
|
|
9
|
+
export const callEndpointSchema = {
|
|
10
|
+
api: z.string().describe('Provider key from search_endpoints / get_endpoint_details, e.g. "coldiq".'),
|
|
11
|
+
path: z.string().describe('Endpoint path without the /v1 prefix, e.g. "/coldiq/prospect/people/filter".'),
|
|
12
|
+
params: z
|
|
13
|
+
.record(z.unknown())
|
|
14
|
+
.optional()
|
|
15
|
+
.describe('Provider-native request params (request body fields, plus any path/query params), as shown in get_endpoint_details.'),
|
|
16
|
+
};
|
|
17
|
+
export async function callEndpointHandler(input) {
|
|
18
|
+
const res = await callApi('POST', '/endpoints/use', { api: input.api, path: input.path, params: input.params });
|
|
19
|
+
if (!res.ok) {
|
|
20
|
+
return {
|
|
21
|
+
content: [{ type: 'text', text: JSON.stringify({ error: 'Endpoint call failed', status: res.status, data: res.data }) }],
|
|
22
|
+
isError: true,
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
return { content: [{ type: 'text', text: JSON.stringify(res.data) }] };
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=call-endpoint.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"call-endpoint.js","sourceRoot":"","sources":["../../src/tools/call-endpoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,gBAAgB,GAAG,eAAe,CAAA;AAE/C,MAAM,CAAC,MAAM,uBAAuB,GAClC,yGAAyG;IACzG,mGAAmG;IACn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C,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,gBAAgB,kBAAkB,CAAA;AAE/C,eAAO,MAAM,uBAAuB,
|
|
1
|
+
{"version":3,"file":"enrich-person.d.ts","sourceRoot":"","sources":["../../src/tools/enrich-person.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,gBAAgB,kBAAkB,CAAA;AAE/C,eAAO,MAAM,uBAAuB,QAOiI,CAAA;AAErK,eAAO,MAAM,kBAAkB;;;;;;;;;CAS9B,CAAA;AAED,wBAAsB,mBAAmB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;GAEvE"}
|
|
@@ -5,7 +5,10 @@ export const enrichPersonName = 'enrich_person';
|
|
|
5
5
|
export const enrichPersonDescription = "Look up a person's LinkedIn profile and professional details. " +
|
|
6
6
|
'Accepts either an email address (reverse lookup) or name + company (profile enrichment). ' +
|
|
7
7
|
'Returns LinkedIn URL, headline, location, current role, and profile data. ' +
|
|
8
|
-
'ColdIQ automatically picks the best provider based on which input fields are present — pass use_providers only if you need a specific tool.'
|
|
8
|
+
'ColdIQ automatically picks the best provider based on which input fields are present — pass use_providers only if you need a specific tool. ' +
|
|
9
|
+
'CHECK the response `_meta` before trusting a reverse-email match: `_meta.match_confidence` (0–1, when the provider gives a score) ' +
|
|
10
|
+
'and `_meta.input_match` (true = the record carries the exact queried email; false = the person\'s email is on a DIFFERENT domain, a strong ' +
|
|
11
|
+
'wrong-person signal; absent = same domain but a different mailbox, or no email to confirm against). A low/false signal means verify the identity before using it.';
|
|
9
12
|
export const enrichPersonSchema = {
|
|
10
13
|
email: z.string().email().optional().describe('Email address for reverse lookup — identify the person behind the email'),
|
|
11
14
|
first_name: z.string().optional().describe("Person's first name (use with last_name + company_name or domain)"),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"enrich-person.js","sourceRoot":"","sources":["../../src/tools/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AC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kEAAkE,CAAC;IAC1G,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,mGAAmG,CAAC;IACvJ,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,uCAAuC,CAAC;IAC9E,aAAa,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,gLAAgL,yBAAyB,CAAC,eAAe,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,qEAAqE,CAAC;CACnW,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,mBAAmB,CAAC,KAA8B;IACtE,OAAO,QAAQ,CAAC,gBAAgB,EAAE,KAAK,CAAC,CAAA;AAC1C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-emails-bulk.d.ts","sourceRoot":"","sources":["../../src/tools/find-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,kBAAkB,qBAAqB,CAAA;AAEpD,eAAO,MAAM,yBAAyB,
|
|
1
|
+
{"version":3,"file":"find-emails-bulk.d.ts","sourceRoot":"","sources":["../../src/tools/find-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,kBAAkB,qBAAqB,CAAA;AAEpD,eAAO,MAAM,yBAAyB,QAQY,CAAA;AAElD,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;CAehC,CAAA;AAED,wBAAsB,qBAAqB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;GAGzE"}
|
|
@@ -4,7 +4,11 @@ export const findEmailsBulkName = 'find_emails_bulk';
|
|
|
4
4
|
export const findEmailsBulkDescription = 'Find professional emails for up to 5,000 people in one ASYNC job. Returns a job_id immediately — this does NOT return emails inline. ' +
|
|
5
5
|
'Poll get_bulk_job(job_id) until status is "done" (usually minutes), then read the found/not_found summary and page through rows. ' +
|
|
6
6
|
'Each person should have first_name + last_name + domain (people missing those come back as not_found and are not charged). ' +
|
|
7
|
-
'Charged only per found email.
|
|
7
|
+
'Charged only per found email. A "found" row means an email was LOCATED, not verified deliverable: each row\'s ' +
|
|
8
|
+
'result carries a `confidence` (high/medium/low/unknown) — treat medium/low/unknown as unverified guesses and run ' +
|
|
9
|
+
'verify_emails_bulk before sending, or you risk bounces. The 202 response includes `credits_reserved` (worst-case hold, ' +
|
|
10
|
+
'settled to actual on completion) and a `low_balance_warning` when your balance is running low. For 50 or fewer people that ' +
|
|
11
|
+
'you want back inline, use find_emails instead.';
|
|
8
12
|
export const findEmailsBulkSchema = {
|
|
9
13
|
people: z
|
|
10
14
|
.array(z.object({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-emails-bulk.js","sourceRoot":"","sources":["../../src/tools/find-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,kBAAkB,GAAG,kBAAkB,CAAA;AAEpD,MAAM,CAAC,MAAM,yBAAyB,GACpC,uIAAuI;IACvI,mIAAmI;IACnI,6HAA6H;IAC7H,
|
|
1
|
+
{"version":3,"file":"find-emails-bulk.js","sourceRoot":"","sources":["../../src/tools/find-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,kBAAkB,GAAG,kBAAkB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AAE,OAAO,EAAE,CAAC,GAAG,CAAC,EAAE,EAAE,CAAA;AACnG,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-emails.d.ts","sourceRoot":"","sources":["../../src/tools/find-emails.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,cAAc,gBAAgB,CAAA;AAE3C,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"find-emails.d.ts","sourceRoot":"","sources":["../../src/tools/find-emails.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,cAAc,gBAAgB,CAAA;AAE3C,eAAO,MAAM,qBAAqB,QAUyB,CAAA;AAE3D,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;CAe5B,CAAA;AASD,KAAK,UAAU,GAAG;IAAE,OAAO,EAAE,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,CAAA;AAMlF,wBAAsB,iBAAiB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC,CA0C3F"}
|
|
@@ -8,7 +8,10 @@ export const findEmailsDescription = 'Find professional emails for multiple peop
|
|
|
8
8
|
'Each person needs a unique id to match results back. ' +
|
|
9
9
|
'Always pass first_name, last_name, and domain — they are the primary enrichment signal. ' +
|
|
10
10
|
'Also pass linkedin_url when available, but never rely on it alone as some providers cannot resolve vanity URLs. ' +
|
|
11
|
-
'ColdIQ automatically picks the best waterfall — pass use_providers only if you need specific tools.'
|
|
11
|
+
'ColdIQ automatically picks the best waterfall — pass use_providers only if you need specific tools. ' +
|
|
12
|
+
'A returned email means one was LOCATED, not verified deliverable: each result carries a `confidence` ' +
|
|
13
|
+
'(high/medium/low/unknown) — treat medium/low/unknown as unverified guesses and run verify_email / ' +
|
|
14
|
+
'verify_emails_bulk before sending, or you risk bounces.';
|
|
12
15
|
export const findEmailsSchema = {
|
|
13
16
|
people: z
|
|
14
17
|
.array(z.object({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-emails.js","sourceRoot":"","sources":["../../src/tools/find-emails.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAC5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAA;AAErE,MAAM,CAAC,MAAM,cAAc,GAAG,aAAa,CAAA;AAE3C,MAAM,CAAC,MAAM,qBAAqB,GAChC,6DAA6D;IAC7D,mEAAmE;IACnE,0EAA0E;IAC1E,uDAAuD;IACvD,0FAA0F;IAC1F,kHAAkH;IAClH,
|
|
1
|
+
{"version":3,"file":"find-emails.js","sourceRoot":"","sources":["../../src/tools/find-emails.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAC5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAA;AAErE,MAAM,CAAC,MAAM,cAAc,GAAG,aAAa,CAAA;AAE3C,MAAM,CAAC,MAAM,qBAAqB,GAChC,6DAA6D;IAC7D,mEAAmE;IACnE,0EAA0E;IAC1E,uDAAuD;IACvD,0FAA0F;IAC1F,kHAAkH;IAClH,sGAAsG;IACtG,uGAAuG;IACvG,oGAAoG;IACpG,yDAAyD,CAAA;AAE3D,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,MAAM,EAAE,CAAC;SACN,KAAK,CACJ,CAAC,CAAC,MAAM,CAAC;QACP,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC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EAAE,EAAE,IAAI,CAAC,CAAA;QAC5D,CAAC;QACD,MAAM,CAAC,IAAI,CAAC,GAAG,OAAO,CAAC,CAAA;QAEvB,+EAA+E;QAC/E,iDAAiD;QACjD,IAAI,GAAG,CAAC,OAAO;YAAE,OAAO,UAAU,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,IAAI,CAAC,CAAA;IAC/D,CAAC;IAED,OAAO,UAAU,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,KAAK,CAAC,CAAA;AAC/C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-people.d.ts","sourceRoot":"","sources":["../../src/tools/find-people.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,cAAc,gBAAgB,CAAA;AAE3C,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"find-people.d.ts","sourceRoot":"","sources":["../../src/tools/find-people.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,cAAc,gBAAgB,CAAA;AAE3C,eAAO,MAAM,qBAAqB,QAYiJ,CAAA;AAEnL,eAAO,MAAM,gBAAgB;;;;;;;;;;;;CAY5B,CAAA;AAED,wBAAsB,iBAAiB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;GAErE"}
|
|
@@ -4,6 +4,7 @@ import { getProvidersForCapability } from '../utils/provider-resolver.js';
|
|
|
4
4
|
export const findPeopleName = 'find_people';
|
|
5
5
|
export const findPeopleDescription = 'Find people at specific companies by job title. ' +
|
|
6
6
|
'CRITICAL: pass ALL companies in ONE call — never loop one call per company. Each call runs a ~90s async job, so looping N companies costs ~N×90s while one batched call stays ~90s total for the same data. ' +
|
|
7
|
+
'PRACTICAL LIMIT: the search fans out one sub-job per company under a ~85s edge budget, so ≈2–3 companies complete per call; with more companies the call may return PARTIAL results — check `_meta.partial` / `_meta.companies_complete` / `_meta.companies_total` and re-run the unfinished companies in a follow-up call. For large multi-company lists, split into batches of ~2–3 companies. ' +
|
|
7
8
|
'Set limit = (desired results per company) × (number of companies). ' +
|
|
8
9
|
'Use this — never search_web — to find contacts, executives, or LinkedIn profiles at known companies. ' +
|
|
9
10
|
'Do not fall back to search_web when results look uncertain or LinkedIn URLs seem wrong — trust what this tool returns. ' +
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-people.js","sourceRoot":"","sources":["../../src/tools/find-people.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAC5C,OAAO,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAA;AAEzE,MAAM,CAAC,MAAM,cAAc,GAAG,aAAa,CAAA;AAE3C,MAAM,CAAC,MAAM,qBAAqB,GAChC,kDAAkD;IAClD,8MAA8M;IAC9M,qEAAqE;IACrE,uGAAuG;IACvG,yHAAyH;IACzH,uIAAuI;IACvI,iQAAiQ;IACjQ,6FAA6F;IAC7F,uHAAuH;IACvH,oMAAoM;IACpM,iLAAiL,CAAA;AAEnL,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,qBAAqB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,gHAAgH,CAAC;IAChL,eAAe,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kHAAkH,CAAC;IAC5K,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,iDAAiD,CAAC;IACtG,WAAW,EAAE,CAA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QAAQ,EAAE,CAAC,QAAQ,CAAC,wDAAwD,CAAC;IAC3G,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,6OAA6O,CAAC;IACrS,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,iJAAiJ,CAAC;IACzM,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,QAAQ,CAAC,2bAA2b,CAAC;IAC/f,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,4UAA4U,CAAC;IACrX,aAAa,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,gLAAgL,yBAAyB,CAAC,aAAa,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,qEAAqE,CAAC;CACjW,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,KAA8B;IACpE,OAAO,QAAQ,CAAC,gBAAgB,EAAE,KAAK,CAAC,CAAA;AAC1C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-bulk-job.d.ts","sourceRoot":"","sources":["../../src/tools/get-bulk-job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,cAAc,iBAAiB,CAAA;AAE5C,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"get-bulk-job.d.ts","sourceRoot":"","sources":["../../src/tools/get-bulk-job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,cAAc,iBAAiB,CAAA;AAE5C,eAAO,MAAM,qBAAqB,QAQsB,CAAA;AAExD,eAAO,MAAM,gBAAgB;;;;CAI5B,CAAA;AAED,wBAAsB,iBAAiB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;GAIrE"}
|
|
@@ -2,10 +2,13 @@ import { z } from 'zod';
|
|
|
2
2
|
import { callApi } from '../client.js';
|
|
3
3
|
export const getBulkJobName = 'get_bulk_job';
|
|
4
4
|
export const getBulkJobDescription = 'Poll any async bulk job (verify_emails_bulk, find_emails_bulk, enrich_person_bulk, enrich_company_bulk, find_phone_bulk). ' +
|
|
5
|
-
'Returns { status, items_total, items_processed, summary, page }. Poll until status is "done" (or "timed_out").
|
|
6
|
-
'per-verdict counts for totals — do NOT expect all rows inline: rows come one page at a time (default 100).
|
|
7
|
-
'
|
|
8
|
-
'
|
|
5
|
+
'Returns { status, items_total, items_processed, summary, coverage, credits_reserved, credits_charged, page }. Poll until status is "done" (or "timed_out"). ' +
|
|
6
|
+
'Use the `summary` per-verdict counts for totals — do NOT expect all rows inline: rows come one page at a time (default 100). ' +
|
|
7
|
+
'The `coverage` block {conclusive, skipped, unverifiable, failed, pending} tells you how much was truly resolved: `skipped` rows (per-row ' +
|
|
8
|
+
'`result.reason` chunk_failed/not_returned/timed_out) were never conclusively checked and are safe to re-submit; `failed` is a hard error (retry unlikely to help). ' +
|
|
9
|
+
'`credits_charged` (null until settled) is the actual spend; `credits_reserved` is the worst-case hold. Each row echoes its submitted `input`, ' +
|
|
10
|
+
'so you can map verdicts back to your submissions without tracking order. To page, OMIT cursor for the first page, then call again with ' +
|
|
11
|
+
'cursor = page.next_cursor until next_cursor is null.';
|
|
9
12
|
export const getBulkJobSchema = {
|
|
10
13
|
job_id: z.number().int().describe('The job_id returned by a *_bulk submit tool.'),
|
|
11
14
|
cursor: z.number().int().optional().describe('Pagination cursor from the previous page.next_cursor. Omit for the first page (an inclusive start row index — cursor=0 returns the first row, so never pass a negative or "offset" value).'),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-bulk-job.js","sourceRoot":"","sources":["../../src/tools/get-bulk-job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,cAAc,GAAG,cAAc,CAAA;AAE5C,MAAM,CAAC,MAAM,qBAAqB,GAChC,4HAA4H;IAC5H,
|
|
1
|
+
{"version":3,"file":"get-bulk-job.js","sourceRoot":"","sources":["../../src/tools/get-bulk-job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,cAAc,GAAG,cAAc,CAAA;AAE5C,MAAM,CAAC,MAAM,qBAAqB,GAChC,4HAA4H;IAC5H,8JAA8J;IAC9J,+HAA+H;IAC/H,2IAA2I;IAC3I,qKAAqK;IACrK,gJAAgJ;IAChJ,yIAAyI;IACzI,sDAAsD,CAAA;AAExD,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,8CAA8C,CAAC;IACjF,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,4LAA4L,CAAC;IAC1O,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wCAAwC,CAAC;CACvG,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,KAA8B;IACpE,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,CAAA;IACjC,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,MAAM,EAAE,SAAS,MAAM,UAAU,EAAE,IAAI,CAAC,CAAA;IAClE,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,EAAE,EAAE,CAAA;AACnG,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const getEndpointDetailsName = "get_endpoint_details";
|
|
3
|
+
export declare const getEndpointDetailsDescription: string;
|
|
4
|
+
export declare const getEndpointDetailsSchema: {
|
|
5
|
+
api: z.ZodString;
|
|
6
|
+
path: z.ZodString;
|
|
7
|
+
};
|
|
8
|
+
export declare function getEndpointDetailsHandler(input: Record<string, unknown>): Promise<{
|
|
9
|
+
content: {
|
|
10
|
+
type: "text";
|
|
11
|
+
text: string;
|
|
12
|
+
}[];
|
|
13
|
+
isError: boolean;
|
|
14
|
+
} | {
|
|
15
|
+
content: {
|
|
16
|
+
type: "text";
|
|
17
|
+
text: string;
|
|
18
|
+
}[];
|
|
19
|
+
isError?: undefined;
|
|
20
|
+
}>;
|
|
21
|
+
//# sourceMappingURL=get-endpoint-details.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-endpoint-details.d.ts","sourceRoot":"","sources":["../../src/tools/get-endpoint-details.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,sBAAsB,yBAAyB,CAAA;AAE5D,eAAO,MAAM,6BAA6B,QAGV,CAAA;AAEhC,eAAO,MAAM,wBAAwB;;;CAGpC,CAAA;AAED,wBAAsB,yBAAyB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;GAS7E"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { callApi } from '../client.js';
|
|
3
|
+
export const getEndpointDetailsName = 'get_endpoint_details';
|
|
4
|
+
export const getEndpointDetailsDescription = 'Get the real request schema, parameters, a ready-to-run request example, and price for one ColdIQ endpoint ' +
|
|
5
|
+
'(from search_endpoints). Read the example before calling — it shows the exact provider-native params ' +
|
|
6
|
+
'call_endpoint expects. FREE.';
|
|
7
|
+
export const getEndpointDetailsSchema = {
|
|
8
|
+
api: z.string().describe('Provider key from search_endpoints, e.g. "coldiq" (Lima Data), "apollo", or "pdl".'),
|
|
9
|
+
path: z.string().describe('Endpoint path without the /v1 prefix, e.g. "/coldiq/prospect/people/filter".'),
|
|
10
|
+
};
|
|
11
|
+
export async function getEndpointDetailsHandler(input) {
|
|
12
|
+
const res = await callApi('POST', '/endpoints/details', { api: input.api, path: input.path });
|
|
13
|
+
if (!res.ok) {
|
|
14
|
+
return {
|
|
15
|
+
content: [{ type: 'text', text: JSON.stringify({ error: 'Endpoint not found or details unavailable', status: res.status, data: res.data }) }],
|
|
16
|
+
isError: true,
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
return { content: [{ type: 'text', text: JSON.stringify(res.data) }] };
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=get-endpoint-details.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-endpoint-details.js","sourceRoot":"","sources":["../../src/tools/get-endpoint-details.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,sBAAsB,GAAG,sBAAsB,CAAA;AAE5D,MAAM,CAAC,MAAM,6BAA6B,GACxC,6GAA6G;IAC7G,uGAAuG;IACvG,8BAA8B,CAAA;AAEhC,MAAM,CAAC,MAAM,wBAAwB,GAAG;IACtC,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,oFAAoF,CAAC;IAC9G,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,8EAA8E,CAAC;CAC1G,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,yBAAyB,CAAC,KAA8B;IAC5E,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,MAAM,EAAE,oBAAoB,EAAE,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,CAAC,CAAA;IAC7F,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC;QACZ,OAAO;YACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,2CAA2C,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC;YACtJ,OAAO,EAAE,IAAI;SACd,CAAA;IACH,CAAC;IACD,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;AACjF,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const searchEndpointsName = "search_endpoints";
|
|
3
|
+
export declare const searchEndpointsDescription: string;
|
|
4
|
+
export declare const searchEndpointsSchema: {
|
|
5
|
+
prompt: z.ZodString;
|
|
6
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
7
|
+
};
|
|
8
|
+
export declare function searchEndpointsHandler(input: Record<string, unknown>): Promise<{
|
|
9
|
+
content: {
|
|
10
|
+
type: "text";
|
|
11
|
+
text: string;
|
|
12
|
+
}[];
|
|
13
|
+
isError: boolean;
|
|
14
|
+
} | {
|
|
15
|
+
content: {
|
|
16
|
+
type: "text";
|
|
17
|
+
text: string;
|
|
18
|
+
}[];
|
|
19
|
+
isError?: undefined;
|
|
20
|
+
}>;
|
|
21
|
+
//# sourceMappingURL=search-endpoints.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-endpoints.d.ts","sourceRoot":"","sources":["../../src/tools/search-endpoints.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,mBAAmB,qBAAqB,CAAA;AAErD,eAAO,MAAM,0BAA0B,QAKmC,CAAA;AAE1E,eAAO,MAAM,qBAAqB;;;CAWjC,CAAA;AAED,wBAAsB,sBAAsB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;;GAS1E"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { callApi } from '../client.js';
|
|
3
|
+
export const searchEndpointsName = 'search_endpoints';
|
|
4
|
+
export const searchEndpointsDescription = 'Discover ColdIQ marketplace API endpoints by natural-language intent — the way to reach ANY integrated ' +
|
|
5
|
+
'provider, including ones without a dedicated tool. Returns matching endpoints grouped by provider, each with ' +
|
|
6
|
+
'its `api`, `path`, summary, and price. Use this when a request names a specific provider (e.g. "find people ' +
|
|
7
|
+
'by title from Lima Data") or needs a capability the fixed tools don\'t cover. Typical flow: search_endpoints → ' +
|
|
8
|
+
'get_endpoint_details (read the request example) → call_endpoint. FREE.';
|
|
9
|
+
export const searchEndpointsSchema = {
|
|
10
|
+
prompt: z
|
|
11
|
+
.string()
|
|
12
|
+
.describe('Natural-language description of the data or capability needed, e.g. "find people by job title" or "Lima Data prospect people".'),
|
|
13
|
+
limit: z
|
|
14
|
+
.number()
|
|
15
|
+
.int()
|
|
16
|
+
.min(1)
|
|
17
|
+
.max(100)
|
|
18
|
+
.optional()
|
|
19
|
+
.describe('Maximum number of endpoints to return (default 10).'),
|
|
20
|
+
};
|
|
21
|
+
export async function searchEndpointsHandler(input) {
|
|
22
|
+
const res = await callApi('POST', '/endpoints/search', { prompt: input.prompt, limit: input.limit });
|
|
23
|
+
if (!res.ok) {
|
|
24
|
+
return {
|
|
25
|
+
content: [{ type: 'text', text: JSON.stringify({ error: 'Endpoint search failed', status: res.status, data: res.data }) }],
|
|
26
|
+
isError: true,
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
return { content: [{ type: 'text', text: JSON.stringify(res.data) }] };
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=search-endpoints.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-endpoints.js","sourceRoot":"","sources":["../../src/tools/search-endpoints.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,mBAAmB,GAAG,kBAAkB,CAAA;AAErD,MAAM,CAAC,MAAM,0BAA0B,GACrC,yGAAyG;IACzG,+GAA+G;IAC/G,8GAA8G;IAC9G,iHAAiH;IACjH,wEAAwE,CAAA;AAE1E,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,MAAM,EAAE,CAAC;SACN,MAAM,EAAE;SACR,QAAQ,CAAC,gIAAgI,CAAC;IAC7I,KAAK,EAAE,CAAC;SACL,MAAM,EAAE;SACR,GAAG,EAAE;SACL,GAAG,CAAC,CAAC,CAAC;SACN,GAAG,CAAC,GAAG,CAAC;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,qDAAqD,CAAC;CACnE,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,sBAAsB,CAAC,KAA8B;IACzE,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,MAAM,EAAE,mBAAmB,EAAE,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAA;IACpG,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC;QACZ,OAAO;YACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,wBAAwB,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC;YACnI,OAAO,EAAE,IAAI;SACd,CAAA;IACH,CAAC;IACD,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;AACjF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verify-emails-bulk.d.ts","sourceRoot":"","sources":["../../src/tools/verify-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,oBAAoB,uBAAuB,CAAA;AAExD,eAAO,MAAM,2BAA2B,
|
|
1
|
+
{"version":3,"file":"verify-emails-bulk.d.ts","sourceRoot":"","sources":["../../src/tools/verify-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,oBAAoB,uBAAuB,CAAA;AAExD,eAAO,MAAM,2BAA2B,QASQ,CAAA;AAEhD,eAAO,MAAM,sBAAsB;;;CAGlC,CAAA;AAED,wBAAsB,uBAAuB,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;GAG3E"}
|
|
@@ -4,6 +4,11 @@ export const verifyEmailsBulkName = 'verify_emails_bulk';
|
|
|
4
4
|
export const verifyEmailsBulkDescription = 'Verify up to 5,000 emails in one ASYNC job. Returns a job_id immediately — this does NOT return verdicts inline. ' +
|
|
5
5
|
'Poll get_bulk_job(job_id) until status is "done" (usually minutes), then read the per-verdict summary counts and page through rows. ' +
|
|
6
6
|
'Charged only per conclusively-verified email (deliverable/catch-all addresses are sendable; unverifiable rows are free). ' +
|
|
7
|
+
'IMPORTANT: an "unknown" verdict is NOT always "genuinely unverifiable". Use the response `coverage` block ' +
|
|
8
|
+
'{conclusive, skipped, unverifiable, pending} and each row\'s `result.reason`: a reason of chunk_failed/not_returned/timed_out ' +
|
|
9
|
+
'means the address was SKIPPED (rate-limited / never checked) and is safe to re-submit — do not discard those contacts; ' +
|
|
10
|
+
'only `provider_indeterminate` (or no reason) is a real "couldn\'t determine". ' +
|
|
11
|
+
'The 202 response includes `credits_reserved` (worst-case hold, settled to actual on completion) and a `low_balance_warning` when low. ' +
|
|
7
12
|
'For a single email use verify_email instead.';
|
|
8
13
|
export const verifyEmailsBulkSchema = {
|
|
9
14
|
emails: z.array(z.string()).min(1).max(5000).describe('Emails to verify (1–5000). Invalid/duplicate entries are dropped server-side.'),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verify-emails-bulk.js","sourceRoot":"","sources":["../../src/tools/verify-emails-bulk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,CAAC,MAAM,oBAAoB,GAAG,oBAAoB,CAAA;AAExD,MAAM,CAAC,MAAM,2BAA2B,GACtC,mHAAmH;IACnH,sIAAsI;IACtI,2HAA2H;IAC3H,8CAA8C,CAAA;AAEhD,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,MAAM,EAAE,CAAC,CAAC,KAA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C,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,mDAAmD,CAAC;CACjG,CAAA;AAED,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAAC,KAA8B;IAC1E,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,MAAM,EAAE,2BAA2B,EAAE,KAAK,CAAC,CAAA;IACrE,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,EAAE,EAAE,CAAA;AACnG,CAAC"}
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -52,6 +52,9 @@ import { enrichPersonBulkName, enrichPersonBulkDescription, enrichPersonBulkSche
|
|
|
52
52
|
import { enrichCompanyBulkName, enrichCompanyBulkDescription, enrichCompanyBulkSchema, enrichCompanyBulkHandler } from './tools/enrich-company-bulk.js'
|
|
53
53
|
import { findPhoneBulkName, findPhoneBulkDescription, findPhoneBulkSchema, findPhoneBulkHandler } from './tools/find-phone-bulk.js'
|
|
54
54
|
import { getBulkJobName, getBulkJobDescription, getBulkJobSchema, getBulkJobHandler } from './tools/get-bulk-job.js'
|
|
55
|
+
import { searchEndpointsName, searchEndpointsDescription, searchEndpointsSchema, searchEndpointsHandler } from './tools/search-endpoints.js'
|
|
56
|
+
import { getEndpointDetailsName, getEndpointDetailsDescription, getEndpointDetailsSchema, getEndpointDetailsHandler } from './tools/get-endpoint-details.js'
|
|
57
|
+
import { callEndpointName, callEndpointDescription, callEndpointSchema, callEndpointHandler } from './tools/call-endpoint.js'
|
|
55
58
|
|
|
56
59
|
import {
|
|
57
60
|
findPhoneName,
|
|
@@ -232,6 +235,10 @@ server.tool(listSkillsName, listSkillsDescription, listSkillsSchema, listSkillsH
|
|
|
232
235
|
server.tool(loadSkillName, loadSkillDescription, loadSkillSchema, loadSkillHandler)
|
|
233
236
|
server.tool(extractPostEngagementName, extractPostEngagementDescription, extractPostEngagementSchema, extractPostEngagementHandler)
|
|
234
237
|
server.tool(getPlaceReviewsName, getPlaceReviewsDescription, getPlaceReviewsSchema, getPlaceReviewsHandler)
|
|
238
|
+
// Generic endpoint discovery + invoke: reach any integrated provider without a dedicated tool.
|
|
239
|
+
server.tool(searchEndpointsName, searchEndpointsDescription, searchEndpointsSchema, searchEndpointsHandler)
|
|
240
|
+
server.tool(getEndpointDetailsName, getEndpointDetailsDescription, getEndpointDetailsSchema, getEndpointDetailsHandler)
|
|
241
|
+
server.tool(callEndpointName, callEndpointDescription, callEndpointSchema, callEndpointHandler)
|
|
235
242
|
|
|
236
243
|
// Connect via stdio transport
|
|
237
244
|
const transport = new StdioServerTransport()
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { z } from 'zod'
|
|
2
|
+
import { callApi } from '../client.js'
|
|
3
|
+
|
|
4
|
+
export const callEndpointName = 'call_endpoint'
|
|
5
|
+
|
|
6
|
+
export const callEndpointDescription =
|
|
7
|
+
'Call any ColdIQ marketplace endpoint directly with provider-native parameters — the generic invoke for ' +
|
|
8
|
+
'providers/capabilities without a dedicated tool. Get the `api`, `path`, and required params from ' +
|
|
9
|
+
'get_endpoint_details first. Returns the provider response verbatim ({ ok, status, data }). ' +
|
|
10
|
+
'PAID: this bills exactly like calling the endpoint directly (same credit cost + upstream call), so only ' +
|
|
11
|
+
'invoke it to perform the action, not to explore.'
|
|
12
|
+
|
|
13
|
+
export const callEndpointSchema = {
|
|
14
|
+
api: z.string().describe('Provider key from search_endpoints / get_endpoint_details, e.g. "coldiq".'),
|
|
15
|
+
path: z.string().describe('Endpoint path without the /v1 prefix, e.g. "/coldiq/prospect/people/filter".'),
|
|
16
|
+
params: z
|
|
17
|
+
.record(z.unknown())
|
|
18
|
+
.optional()
|
|
19
|
+
.describe('Provider-native request params (request body fields, plus any path/query params), as shown in get_endpoint_details.'),
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export async function callEndpointHandler(input: Record<string, unknown>) {
|
|
23
|
+
const res = await callApi('POST', '/endpoints/use', { api: input.api, path: input.path, params: input.params })
|
|
24
|
+
if (!res.ok) {
|
|
25
|
+
return {
|
|
26
|
+
content: [{ type: 'text' as const, text: JSON.stringify({ error: 'Endpoint call failed', status: res.status, data: res.data }) }],
|
|
27
|
+
isError: true,
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return { content: [{ type: 'text' as const, text: JSON.stringify(res.data) }] }
|
|
31
|
+
}
|
|
@@ -8,7 +8,10 @@ export const enrichPersonDescription =
|
|
|
8
8
|
"Look up a person's LinkedIn profile and professional details. " +
|
|
9
9
|
'Accepts either an email address (reverse lookup) or name + company (profile enrichment). ' +
|
|
10
10
|
'Returns LinkedIn URL, headline, location, current role, and profile data. ' +
|
|
11
|
-
'ColdIQ automatically picks the best provider based on which input fields are present — pass use_providers only if you need a specific tool.'
|
|
11
|
+
'ColdIQ automatically picks the best provider based on which input fields are present — pass use_providers only if you need a specific tool. ' +
|
|
12
|
+
'CHECK the response `_meta` before trusting a reverse-email match: `_meta.match_confidence` (0–1, when the provider gives a score) ' +
|
|
13
|
+
'and `_meta.input_match` (true = the record carries the exact queried email; false = the person\'s email is on a DIFFERENT domain, a strong ' +
|
|
14
|
+
'wrong-person signal; absent = same domain but a different mailbox, or no email to confirm against). A low/false signal means verify the identity before using it.'
|
|
12
15
|
|
|
13
16
|
export const enrichPersonSchema = {
|
|
14
17
|
email: z.string().email().optional().describe('Email address for reverse lookup — identify the person behind the email'),
|
|
@@ -7,7 +7,11 @@ export const findEmailsBulkDescription =
|
|
|
7
7
|
'Find professional emails for up to 5,000 people in one ASYNC job. Returns a job_id immediately — this does NOT return emails inline. ' +
|
|
8
8
|
'Poll get_bulk_job(job_id) until status is "done" (usually minutes), then read the found/not_found summary and page through rows. ' +
|
|
9
9
|
'Each person should have first_name + last_name + domain (people missing those come back as not_found and are not charged). ' +
|
|
10
|
-
'Charged only per found email.
|
|
10
|
+
'Charged only per found email. A "found" row means an email was LOCATED, not verified deliverable: each row\'s ' +
|
|
11
|
+
'result carries a `confidence` (high/medium/low/unknown) — treat medium/low/unknown as unverified guesses and run ' +
|
|
12
|
+
'verify_emails_bulk before sending, or you risk bounces. The 202 response includes `credits_reserved` (worst-case hold, ' +
|
|
13
|
+
'settled to actual on completion) and a `low_balance_warning` when your balance is running low. For 50 or fewer people that ' +
|
|
14
|
+
'you want back inline, use find_emails instead.'
|
|
11
15
|
|
|
12
16
|
export const findEmailsBulkSchema = {
|
|
13
17
|
people: z
|
package/src/tools/find-emails.ts
CHANGED
|
@@ -11,7 +11,10 @@ export const findEmailsDescription =
|
|
|
11
11
|
'Each person needs a unique id to match results back. ' +
|
|
12
12
|
'Always pass first_name, last_name, and domain — they are the primary enrichment signal. ' +
|
|
13
13
|
'Also pass linkedin_url when available, but never rely on it alone as some providers cannot resolve vanity URLs. ' +
|
|
14
|
-
'ColdIQ automatically picks the best waterfall — pass use_providers only if you need specific tools.'
|
|
14
|
+
'ColdIQ automatically picks the best waterfall — pass use_providers only if you need specific tools. ' +
|
|
15
|
+
'A returned email means one was LOCATED, not verified deliverable: each result carries a `confidence` ' +
|
|
16
|
+
'(high/medium/low/unknown) — treat medium/low/unknown as unverified guesses and run verify_email / ' +
|
|
17
|
+
'verify_emails_bulk before sending, or you risk bounces.'
|
|
15
18
|
|
|
16
19
|
export const findEmailsSchema = {
|
|
17
20
|
people: z
|
package/src/tools/find-people.ts
CHANGED
|
@@ -7,6 +7,7 @@ export const findPeopleName = 'find_people'
|
|
|
7
7
|
export const findPeopleDescription =
|
|
8
8
|
'Find people at specific companies by job title. ' +
|
|
9
9
|
'CRITICAL: pass ALL companies in ONE call — never loop one call per company. Each call runs a ~90s async job, so looping N companies costs ~N×90s while one batched call stays ~90s total for the same data. ' +
|
|
10
|
+
'PRACTICAL LIMIT: the search fans out one sub-job per company under a ~85s edge budget, so ≈2–3 companies complete per call; with more companies the call may return PARTIAL results — check `_meta.partial` / `_meta.companies_complete` / `_meta.companies_total` and re-run the unfinished companies in a follow-up call. For large multi-company lists, split into batches of ~2–3 companies. ' +
|
|
10
11
|
'Set limit = (desired results per company) × (number of companies). ' +
|
|
11
12
|
'Use this — never search_web — to find contacts, executives, or LinkedIn profiles at known companies. ' +
|
|
12
13
|
'Do not fall back to search_web when results look uncertain or LinkedIn URLs seem wrong — trust what this tool returns. ' +
|
|
@@ -5,10 +5,13 @@ export const getBulkJobName = 'get_bulk_job'
|
|
|
5
5
|
|
|
6
6
|
export const getBulkJobDescription =
|
|
7
7
|
'Poll any async bulk job (verify_emails_bulk, find_emails_bulk, enrich_person_bulk, enrich_company_bulk, find_phone_bulk). ' +
|
|
8
|
-
'Returns { status, items_total, items_processed, summary, page }. Poll until status is "done" (or "timed_out").
|
|
9
|
-
'per-verdict counts for totals — do NOT expect all rows inline: rows come one page at a time (default 100).
|
|
10
|
-
'
|
|
11
|
-
'
|
|
8
|
+
'Returns { status, items_total, items_processed, summary, coverage, credits_reserved, credits_charged, page }. Poll until status is "done" (or "timed_out"). ' +
|
|
9
|
+
'Use the `summary` per-verdict counts for totals — do NOT expect all rows inline: rows come one page at a time (default 100). ' +
|
|
10
|
+
'The `coverage` block {conclusive, skipped, unverifiable, failed, pending} tells you how much was truly resolved: `skipped` rows (per-row ' +
|
|
11
|
+
'`result.reason` chunk_failed/not_returned/timed_out) were never conclusively checked and are safe to re-submit; `failed` is a hard error (retry unlikely to help). ' +
|
|
12
|
+
'`credits_charged` (null until settled) is the actual spend; `credits_reserved` is the worst-case hold. Each row echoes its submitted `input`, ' +
|
|
13
|
+
'so you can map verdicts back to your submissions without tracking order. To page, OMIT cursor for the first page, then call again with ' +
|
|
14
|
+
'cursor = page.next_cursor until next_cursor is null.'
|
|
12
15
|
|
|
13
16
|
export const getBulkJobSchema = {
|
|
14
17
|
job_id: z.number().int().describe('The job_id returned by a *_bulk submit tool.'),
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { z } from 'zod'
|
|
2
|
+
import { callApi } from '../client.js'
|
|
3
|
+
|
|
4
|
+
export const getEndpointDetailsName = 'get_endpoint_details'
|
|
5
|
+
|
|
6
|
+
export const getEndpointDetailsDescription =
|
|
7
|
+
'Get the real request schema, parameters, a ready-to-run request example, and price for one ColdIQ endpoint ' +
|
|
8
|
+
'(from search_endpoints). Read the example before calling — it shows the exact provider-native params ' +
|
|
9
|
+
'call_endpoint expects. FREE.'
|
|
10
|
+
|
|
11
|
+
export const getEndpointDetailsSchema = {
|
|
12
|
+
api: z.string().describe('Provider key from search_endpoints, e.g. "coldiq" (Lima Data), "apollo", or "pdl".'),
|
|
13
|
+
path: z.string().describe('Endpoint path without the /v1 prefix, e.g. "/coldiq/prospect/people/filter".'),
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export async function getEndpointDetailsHandler(input: Record<string, unknown>) {
|
|
17
|
+
const res = await callApi('POST', '/endpoints/details', { api: input.api, path: input.path })
|
|
18
|
+
if (!res.ok) {
|
|
19
|
+
return {
|
|
20
|
+
content: [{ type: 'text' as const, text: JSON.stringify({ error: 'Endpoint not found or details unavailable', status: res.status, data: res.data }) }],
|
|
21
|
+
isError: true,
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
return { content: [{ type: 'text' as const, text: JSON.stringify(res.data) }] }
|
|
25
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { z } from 'zod'
|
|
2
|
+
import { callApi } from '../client.js'
|
|
3
|
+
|
|
4
|
+
export const searchEndpointsName = 'search_endpoints'
|
|
5
|
+
|
|
6
|
+
export const searchEndpointsDescription =
|
|
7
|
+
'Discover ColdIQ marketplace API endpoints by natural-language intent — the way to reach ANY integrated ' +
|
|
8
|
+
'provider, including ones without a dedicated tool. Returns matching endpoints grouped by provider, each with ' +
|
|
9
|
+
'its `api`, `path`, summary, and price. Use this when a request names a specific provider (e.g. "find people ' +
|
|
10
|
+
'by title from Lima Data") or needs a capability the fixed tools don\'t cover. Typical flow: search_endpoints → ' +
|
|
11
|
+
'get_endpoint_details (read the request example) → call_endpoint. FREE.'
|
|
12
|
+
|
|
13
|
+
export const searchEndpointsSchema = {
|
|
14
|
+
prompt: z
|
|
15
|
+
.string()
|
|
16
|
+
.describe('Natural-language description of the data or capability needed, e.g. "find people by job title" or "Lima Data prospect people".'),
|
|
17
|
+
limit: z
|
|
18
|
+
.number()
|
|
19
|
+
.int()
|
|
20
|
+
.min(1)
|
|
21
|
+
.max(100)
|
|
22
|
+
.optional()
|
|
23
|
+
.describe('Maximum number of endpoints to return (default 10).'),
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export async function searchEndpointsHandler(input: Record<string, unknown>) {
|
|
27
|
+
const res = await callApi('POST', '/endpoints/search', { prompt: input.prompt, limit: input.limit })
|
|
28
|
+
if (!res.ok) {
|
|
29
|
+
return {
|
|
30
|
+
content: [{ type: 'text' as const, text: JSON.stringify({ error: 'Endpoint search failed', status: res.status, data: res.data }) }],
|
|
31
|
+
isError: true,
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
return { content: [{ type: 'text' as const, text: JSON.stringify(res.data) }] }
|
|
35
|
+
}
|
|
@@ -7,6 +7,11 @@ export const verifyEmailsBulkDescription =
|
|
|
7
7
|
'Verify up to 5,000 emails in one ASYNC job. Returns a job_id immediately — this does NOT return verdicts inline. ' +
|
|
8
8
|
'Poll get_bulk_job(job_id) until status is "done" (usually minutes), then read the per-verdict summary counts and page through rows. ' +
|
|
9
9
|
'Charged only per conclusively-verified email (deliverable/catch-all addresses are sendable; unverifiable rows are free). ' +
|
|
10
|
+
'IMPORTANT: an "unknown" verdict is NOT always "genuinely unverifiable". Use the response `coverage` block ' +
|
|
11
|
+
'{conclusive, skipped, unverifiable, pending} and each row\'s `result.reason`: a reason of chunk_failed/not_returned/timed_out ' +
|
|
12
|
+
'means the address was SKIPPED (rate-limited / never checked) and is safe to re-submit — do not discard those contacts; ' +
|
|
13
|
+
'only `provider_indeterminate` (or no reason) is a real "couldn\'t determine". ' +
|
|
14
|
+
'The 202 response includes `credits_reserved` (worst-case hold, settled to actual on completion) and a `low_balance_warning` when low. ' +
|
|
10
15
|
'For a single email use verify_email instead.'
|
|
11
16
|
|
|
12
17
|
export const verifyEmailsBulkSchema = {
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest'
|
|
2
|
+
import { initClient } from '../../src/client.js'
|
|
3
|
+
import { callEndpointHandler } from '../../src/tools/call-endpoint.js'
|
|
4
|
+
|
|
5
|
+
describe('call_endpoint handler', () => {
|
|
6
|
+
const originalFetch = globalThis.fetch
|
|
7
|
+
|
|
8
|
+
beforeEach(() => initClient('http://test-api.local', 'test-key'))
|
|
9
|
+
afterEach(() => { globalThis.fetch = originalFetch })
|
|
10
|
+
|
|
11
|
+
it('POSTs api + path + params to /v1/endpoints/use, forwarding the bearer key', async () => {
|
|
12
|
+
let capturedUrl = ''
|
|
13
|
+
let capturedAuth: string | null = null
|
|
14
|
+
let capturedBody: unknown
|
|
15
|
+
globalThis.fetch = vi.fn(async (url: string | URL | Request, opts?: RequestInit) => {
|
|
16
|
+
capturedUrl = url.toString()
|
|
17
|
+
capturedAuth = ((opts?.headers ?? {}) as Record<string, string>).Authorization ?? null
|
|
18
|
+
capturedBody = opts?.body ? JSON.parse(opts.body as string) : undefined
|
|
19
|
+
return new Response(JSON.stringify({ ok: true, status: 200, data: { people: [{ full_name: 'A' }] } }), { status: 200 })
|
|
20
|
+
}) as typeof fetch
|
|
21
|
+
|
|
22
|
+
const params = { filters: [{ filter_type: 'current_title', values: ['Head of Growth'] }] }
|
|
23
|
+
const result = await callEndpointHandler({ api: 'coldiq', path: '/coldiq/prospect/people/filter', params })
|
|
24
|
+
|
|
25
|
+
expect(capturedUrl).toBe('http://test-api.local/v1/endpoints/use')
|
|
26
|
+
expect(capturedAuth).toBe('Bearer test-key')
|
|
27
|
+
expect(capturedBody).toEqual({ api: 'coldiq', path: '/coldiq/prospect/people/filter', params })
|
|
28
|
+
expect(result.isError).toBeFalsy()
|
|
29
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
30
|
+
expect(parsed.data.people).toHaveLength(1)
|
|
31
|
+
})
|
|
32
|
+
|
|
33
|
+
it('returns isError when the call fails (e.g. unknown endpoint 404)', async () => {
|
|
34
|
+
globalThis.fetch = vi.fn(async () => new Response(JSON.stringify({ error: 'Endpoint not found for api=coldiq path=/nope', code: -32004 }), { status: 404 })) as typeof fetch
|
|
35
|
+
const result = await callEndpointHandler({ api: 'coldiq', path: '/nope', params: {} })
|
|
36
|
+
expect(result.isError).toBe(true)
|
|
37
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
38
|
+
expect(parsed.status).toBe(404)
|
|
39
|
+
expect(parsed.error).toBe('Endpoint call failed')
|
|
40
|
+
})
|
|
41
|
+
})
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest'
|
|
2
|
+
import { initClient } from '../../src/client.js'
|
|
3
|
+
import { getEndpointDetailsHandler } from '../../src/tools/get-endpoint-details.js'
|
|
4
|
+
|
|
5
|
+
describe('get_endpoint_details handler', () => {
|
|
6
|
+
const originalFetch = globalThis.fetch
|
|
7
|
+
|
|
8
|
+
beforeEach(() => initClient('http://test-api.local', 'test-key'))
|
|
9
|
+
afterEach(() => { globalThis.fetch = originalFetch })
|
|
10
|
+
|
|
11
|
+
it('POSTs api + path to /v1/endpoints/details and returns the payload', async () => {
|
|
12
|
+
let capturedUrl = ''
|
|
13
|
+
let capturedBody: unknown
|
|
14
|
+
globalThis.fetch = vi.fn(async (url: string | URL | Request, opts?: RequestInit) => {
|
|
15
|
+
capturedUrl = url.toString()
|
|
16
|
+
capturedBody = opts?.body ? JSON.parse(opts.body as string) : undefined
|
|
17
|
+
return new Response(JSON.stringify({ path: '/coldiq/prospect/people/filter', method: 'post' }), { status: 200 })
|
|
18
|
+
}) as typeof fetch
|
|
19
|
+
|
|
20
|
+
const result = await getEndpointDetailsHandler({ api: 'coldiq', path: '/coldiq/prospect/people/filter' })
|
|
21
|
+
|
|
22
|
+
expect(capturedUrl).toBe('http://test-api.local/v1/endpoints/details')
|
|
23
|
+
expect(capturedBody).toEqual({ api: 'coldiq', path: '/coldiq/prospect/people/filter' })
|
|
24
|
+
expect(result.isError).toBeFalsy()
|
|
25
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
26
|
+
expect(parsed.path).toContain('prospect/people/filter')
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
it('returns isError when the endpoint is unknown (404)', async () => {
|
|
30
|
+
globalThis.fetch = vi.fn(async () => new Response(JSON.stringify({ error: 'not found' }), { status: 404 })) as typeof fetch
|
|
31
|
+
const result = await getEndpointDetailsHandler({ api: 'coldiq', path: '/nope' })
|
|
32
|
+
expect(result.isError).toBe(true)
|
|
33
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
34
|
+
expect(parsed.status).toBe(404)
|
|
35
|
+
expect(parsed.error).toBe('Endpoint not found or details unavailable')
|
|
36
|
+
})
|
|
37
|
+
})
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest'
|
|
2
|
+
import { initClient } from '../../src/client.js'
|
|
3
|
+
import { searchEndpointsHandler } from '../../src/tools/search-endpoints.js'
|
|
4
|
+
|
|
5
|
+
describe('search_endpoints handler', () => {
|
|
6
|
+
const originalFetch = globalThis.fetch
|
|
7
|
+
|
|
8
|
+
beforeEach(() => initClient('http://test-api.local', 'test-key'))
|
|
9
|
+
afterEach(() => { globalThis.fetch = originalFetch })
|
|
10
|
+
|
|
11
|
+
it('POSTs prompt + limit to /v1/endpoints/search and returns the payload', async () => {
|
|
12
|
+
let capturedUrl = ''
|
|
13
|
+
let capturedBody: unknown
|
|
14
|
+
globalThis.fetch = vi.fn(async (url: string | URL | Request, opts?: RequestInit) => {
|
|
15
|
+
capturedUrl = url.toString()
|
|
16
|
+
capturedBody = opts?.body ? JSON.parse(opts.body as string) : undefined
|
|
17
|
+
return new Response(JSON.stringify({ results: [{ api: 'coldiq', provider: 'Lima Data', endpoints: [] }] }), { status: 200 })
|
|
18
|
+
}) as typeof fetch
|
|
19
|
+
|
|
20
|
+
const result = await searchEndpointsHandler({ prompt: 'find people by title', limit: 5 })
|
|
21
|
+
|
|
22
|
+
expect(capturedUrl).toBe('http://test-api.local/v1/endpoints/search')
|
|
23
|
+
expect(capturedBody).toEqual({ prompt: 'find people by title', limit: 5 })
|
|
24
|
+
expect(result.isError).toBeFalsy()
|
|
25
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
26
|
+
expect(parsed.results[0].api).toBe('coldiq')
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
it('returns isError when the API responds non-2xx', async () => {
|
|
30
|
+
globalThis.fetch = vi.fn(async () => new Response(JSON.stringify({ error: 'boom' }), { status: 500 })) as typeof fetch
|
|
31
|
+
const result = await searchEndpointsHandler({ prompt: 'x' })
|
|
32
|
+
expect(result.isError).toBe(true)
|
|
33
|
+
const parsed = JSON.parse(result.content[0].text)
|
|
34
|
+
expect(parsed.status).toBe(500)
|
|
35
|
+
expect(parsed.error).toBe('Endpoint search failed')
|
|
36
|
+
})
|
|
37
|
+
})
|