Files
timmy-tower/lib/integrations-anthropic-ai/src/client.ts
alexpaynex b095efcfd3 Add AI agent capabilities and integrate with Anthropic and LNbits
Integrate Anthropic AI for agent capabilities, introduce database schemas for jobs and invoices, and set up LNbits for payment processing.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 418bf6f8-212b-4bb0-a7a5-8231a061da4e
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Event-Id: cce28acc-aeac-46ff-80ec-af4ade39e30f
Replit-Helium-Checkpoint-Created: true
2026-03-18 14:59:02 +00:00

19 lines
593 B
TypeScript

import Anthropic from "@anthropic-ai/sdk";
if (!process.env.AI_INTEGRATIONS_ANTHROPIC_BASE_URL) {
throw new Error(
"AI_INTEGRATIONS_ANTHROPIC_BASE_URL must be set. Did you forget to provision the Anthropic AI integration?",
);
}
if (!process.env.AI_INTEGRATIONS_ANTHROPIC_API_KEY) {
throw new Error(
"AI_INTEGRATIONS_ANTHROPIC_API_KEY must be set. Did you forget to provision the Anthropic AI integration?",
);
}
export const anthropic = new Anthropic({
apiKey: process.env.AI_INTEGRATIONS_ANTHROPIC_API_KEY,
baseURL: process.env.AI_INTEGRATIONS_ANTHROPIC_BASE_URL,
});