Skip to content

Supercharge your AI agents with data from the web and beyond. Building the library for superintelligence. 🔥

Hide developer search mechanism fields

Karan Lokchandaniaf55c2a050a6
diff --git a/apps/api/src/__tests__/snips/v2/developer.test.ts b/apps/api/src/__tests__/snips/v2/developer.test.ts
index a07fe1e30..692b28cc5 100644
--- a/apps/api/src/__tests__/snips/v2/developer.test.ts
+++ b/apps/api/src/__tests__/snips/v2/developer.test.ts
@@ -15,8 +15,6 @@ const CANONICAL_PATH = "/v2/search/developer";
const LEGACY_PATH = "/v2/developer/search";
const SERVING_PATHS = [CANONICAL_PATH, LEGACY_PATH];
-const COVERAGE_STATUSES = ["ok", "degraded", "unavailable", "skipped"];
-
const sleep = (ms: number) => new Promise(resolve => setTimeout(resolve, ms));
const sleepForBilling = () => sleep(40000);
@@ -51,17 +49,10 @@ describeIf(HAS_RESEARCH)("Developer Search API", () => {
expect(res.statusCode).toBe(200);
expect(res.body.success).toBe(true);
expect(Array.isArray(res.body.results)).toBe(true);
- for (const type of ["doc", "issue", "pull_request", "readme"]) {
- expect(COVERAGE_STATUSES).toContain(res.body.coverage[type]);
- }
- expect(typeof res.body.reranked).toBe("boolean");
for (const result of res.body.results) {
expect(typeof result.id).toBe("string");
expect(typeof result.url).toBe("string");
- expect(["doc", "issue", "pull_request", "readme"]).toContain(
- result.type,
- );
expect(Array.isArray(result.passages)).toBe(true);
expect(result.license).toBeUndefined();
}
@@ -82,11 +73,6 @@ describeIf(HAS_RESEARCH)("Developer Search API", () => {
expect(res.statusCode).toBe(200);
expect(res.body.success).toBe(true);
expect(Array.isArray(res.body.results)).toBe(true);
- for (const result of res.body.results) {
- expect(["issue", "readme"]).toContain(result.type);
- }
- expect(res.body.coverage.doc).toBe("skipped");
- expect(res.body.coverage.pull_request).toBe("skipped");
}, 120000);
});
diff --git a/apps/js-sdk/firecrawl/src/v2/types.ts b/apps/js-sdk/firecrawl/src/v2/types.ts
index cb229d197..e1ec6c958 100644
--- a/apps/js-sdk/firecrawl/src/v2/types.ts
+++ b/apps/js-sdk/firecrawl/src/v2/types.ts
@@ -1459,7 +1459,7 @@ export interface GitHubScoreBreakdown {
}
export interface GitHubSearchItem {
- resultType: "github_history" | "repo_readme" | "web";
+ resultType?: "github_history" | "repo_readme" | "web";
/** `owner/name`; empty for web results whose URL is not a repo page. */
repo: string;
url: string;