SA
Portal
ServiceAgent × v0

ServiceAgent components in v0 — chat, voice, calendar.

`@serviceagent/react` works inside v0 generations. Use the prompt below to get v0 to drop `<Chat />`, `<CalendarBooking />`, and `<VoiceAgent />` into the right places, with the right env vars and import paths.

Drop-in v0 prompt

Use this in v0

Code
Generate a Next.js page that uses ServiceAgent's @serviceagent/react components.

Install:
npm install @serviceagent/react @serviceagent/aiva-sdk

Imports:
import { Chat, CalendarBooking, VoiceAgent } from '@serviceagent/react';

Use these on the page:
<Chat />
<CalendarBooking bookingKey={process.env.NEXT_PUBLIC_SERVICEAGENT_BOOKING_KEY!} />
<VoiceAgent token={voiceToken} orgId={orgId} />

Env vars expected:
NEXT_PUBLIC_SERVICEAGENT_WIDGET_KEY
NEXT_PUBLIC_SERVICEAGENT_API_URL
NEXT_PUBLIC_SERVICEAGENT_BOOKING_KEY
NEXT_PUBLIC_SERVICEAGENT_VOICE_ENDPOINT

To provision a real demo: npx @serviceagent/cli add all --source v0

After v0 generates

v0 outputs static code. Pull it down to a local repo, then run the CLI to provision a real demo workspace and write env vars:

Code
npx @serviceagent/cli add all --source v0
# Provisions widgetKey, writes .env, drops Cursor rules.

npx @serviceagent/cli claim --email me@company.com
# Converts to a permanent workspace + writes SERVICEAGENT_API_KEY.