feat: fuck mcp, we'll just send the json

This commit is contained in:
2025-08-07 12:55:43 -07:00
parent e49137bb08
commit 0f058870a8
12 changed files with 19 additions and 399 deletions
+2 -14
View File
@@ -41,21 +41,10 @@ export const ai = async(
const parsedPrompt = prompt.replace("{{username}}", username);
const result = await anthropic.beta.messages.create({
betas: [ "web-search-2025-03-05", "mcp-client-2025-04-04" ],
betas: [ "web-search-2025-03-05" ],
// eslint-disable-next-line @typescript-eslint/naming-convention -- API requirement
max_tokens: 20_000,
// eslint-disable-next-line @typescript-eslint/naming-convention -- API requirement
mcp_servers: [
{
name: "nhcarrigan-mcp",
type: "url",
url: "https://hikari.nhcarrigan.com/api/mcp",
tool_configuration: {
allowed_tools: ["docs"],
enabled: true
}
},
],
messages: messages.map((message) => {
return {
content: message.content,
@@ -73,8 +62,7 @@ export const ai = async(
allowed_domains: [ "nhcarrigan.com" ],
name: "web_search",
type: "web_search_20250305",
},
}
],
});
await calculateCost(result.usage, username);