Skip to content

Commit 2faf278

Browse files
fix conflicts
1 parent 891737e commit 2faf278

2 files changed

Lines changed: 5 additions & 34 deletions

File tree

packages/mcp/src/client.ts

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -106,28 +106,4 @@ export const listCommits = async (queryParams: ListCommitsQueryParamsSchema) =>
106106
const commits = await parseResponse(response, listCommitsResponseSchema);
107107
const totalCount = parseInt(response.headers.get('X-Total-Count') ?? '0', 10);
108108
return { commits, totalCount };
109-
}
110-
<<<<<<< Updated upstream
111-
=======
112-
113-
/**
114-
* Asks a natural language question about the codebase using the Sourcebot AI agent.
115-
* This is a blocking call that runs the full agent loop and returns when complete.
116-
*
117-
* @param request - The question and optional repo filters
118-
* @returns The agent's answer, chat URL, sources, and metadata
119-
*/
120-
export const askCodebase = async (request: AskCodebaseRequest): Promise<AskCodebaseResponse> => {
121-
const response = await fetch(`${env.SOURCEBOT_HOST}/api/chat/blocking`, {
122-
method: 'POST',
123-
headers: {
124-
'Content-Type': 'application/json',
125-
'X-Sourcebot-Client-Source': 'mcp',
126-
...(env.SOURCEBOT_API_KEY ? { 'X-Sourcebot-Api-Key': env.SOURCEBOT_API_KEY } : {})
127-
},
128-
body: JSON.stringify(request),
129-
});
130-
131-
return parseResponse(response, askCodebaseResponseSchema);
132-
}
133-
>>>>>>> Stashed changes
109+
}

packages/web/src/app/api/(server)/repos/route.ts

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,12 @@
1-
<<<<<<< Updated upstream
2-
import { NextRequest } from "next/server";
31
import { sew } from "@/actions";
4-
import { withOptionalAuthV2 } from "@/withAuthV2";
5-
=======
2+
import { getBrowsePath } from "@/app/[domain]/browse/hooks/utils";
63
import { apiHandler } from "@/lib/apiHandler";
74
import { buildLinkHeader } from "@/lib/pagination";
8-
import { listReposQueryParamsSchema } from "@/lib/schemas";
9-
>>>>>>> Stashed changes
5+
import { listReposQueryParamsSchema, repositoryQuerySchema } from "@/lib/schemas";
106
import { queryParamsSchemaValidationError, serviceErrorResponse } from "@/lib/serviceError";
117
import { isServiceError } from "@/lib/utils";
12-
import { listReposQueryParamsSchema, repositoryQuerySchema } from "@/lib/schemas";
13-
import { buildLinkHeader } from "@/lib/pagination";
14-
import { getBrowsePath } from "@/app/[domain]/browse/hooks/utils";
8+
import { withOptionalAuthV2 } from "@/withAuthV2";
9+
import { NextRequest } from "next/server";
1510

1611
export const GET = apiHandler(async (request: NextRequest) => {
1712
const rawParams = Object.fromEntries(

0 commit comments

Comments
 (0)