Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix: ai preset screenpipe cloud not working in onboarding (#1659)

shaik-zeeshan35e5b57de278
diff --git a/screenpipe-app-tauri/components/onboarding/api-setup.tsx b/screenpipe-app-tauri/components/onboarding/api-setup.tsx
index cb6342c34..536a0b646 100644
--- a/screenpipe-app-tauri/components/onboarding/api-setup.tsx
+++ b/screenpipe-app-tauri/components/onboarding/api-setup.tsx
@@ -79,10 +79,13 @@ const OnboardingAPISetup: React.FC<OnboardingAPISetupProps> = ({
}
const { url, model, provider } = defaultPreset;
+
// Get API key if available based on provider
const apiKey = (provider === "openai" || provider === "custom") && "apiKey" in defaultPreset
? defaultPreset.apiKey
- : "";
+ : provider === "screenpipe-cloud"
+ ? settings.user.token
+ : "";
const t = toast({
title: "Validating AI provider",