SA
Portal
ServiceAgent × Lovable

AI chat, voice, and calendar in your Lovable app — 30 seconds, no portal.

`@serviceagent/cli` auto-detects Lovable and provisions a demo workspace with one command. Drop `<Chat />`, `<CalendarBooking />`, and `<VoiceAgent />` on any page. When you're ready to ship, claim the workspace from the CLI — never leave Lovable.

Drop-in Lovable prompt

Paste this into Lovable's chat. Lovable runs the CLI command, drops the components, and wires the env vars in one turn.

Pre-baked Lovable prompt

Code
Add ServiceAgent to my app — install @serviceagent/react, then run:
npx @serviceagent/cli add all --source lovable

Drop these on the home page:
import { Chat, CalendarBooking, VoiceAgent } from '@serviceagent/react';
<Chat />
<CalendarBooking bookingKey={import.meta.env.VITE_SERVICEAGENT_BOOKING_KEY} />
<VoiceAgent token={voiceToken} orgId={orgId} />

After it works, run: npx @serviceagent/cli claim --email me@company.com
to convert the demo workspace into a permanent account.

Installs from Lovable are tracked via --source lovable so we can attribute every demo correctly.

Working starter repo

serviceagent-starters/lovable ships a Vite + React project with <Chat />, <CalendarBooking />, and <VoiceAgent /> wired into a tabbed UI. Use it as a reference or fork it directly.

Code
git clone https://github.com/serviceagent/serviceagent-backend
cd serviceagent-backend/serviceagent-starters/lovable
cp .env.example .env
npm install && npm run dev

Claim your workspace

Demo workspaces are intentionally client-only — <Chat /> works immediately, but voice agents, webhooks, and the CRM API are gated until you claim. The CLI does it in one step, without a portal trip:

Code
npx @serviceagent/cli claim --email me@company.com

ServiceAgent emails a magic link, the CLI polls until you click it, then writes SERVICEAGENT_API_KEY straight into your .env. Voice and webhooks unlock immediately.

Environment variables

Code
VITE_SERVICEAGENT_WIDGET_KEY=wid_...
VITE_SERVICEAGENT_API_URL=https://process.serviceagent.ai
VITE_SERVICEAGENT_BOOKING_KEY=...
VITE_SERVICEAGENT_VOICE_ENDPOINT=wss://process.serviceagent.ai/v1/voice/stream
SERVICEAGENT_API_KEY=...   # written by claim, server-side only