Closed langduhau closed 1 month ago
the error message indicates LIVEKIT_API_KEY
is not set
设置了的,
I have exactly the same issue. All env is set but I still get
/Users/abiodun/PROJECTS/Personal/ConversationalAI/realtime-playground/agent/node_modules/@livekit/agents/src/worker.ts:279 throw new MissingCredentialsError( ^
MissingCredentialsError: API Key is required: Set LIVEKIT_API_KEY, run with --api-key, or pass apiKey in WorkerOptions
at Worker (/Users/abiodun/PROJECTS/Personal/ConversationalAI/realtime-playground/agent/node_modules/@livekit/agents/src/worker.ts:279:13)
at runWorker (/Users/abiodun/PROJECTS/Personal/ConversationalAI/realtime-playground/agent/node_modules/@livekit/agents/src/cli.ts:25:18)
at Command.
i figured out what the issue was.
The command you use to set environment variables from a .env.local file in the terminal depends on your operating system and shell. Based on the README content you provided, here are the recommended commands:
For macOS and Linux (bash or similar shells):
source .env.local
For Windows (PowerShell):
set -a; . .env.local; set +a
These commands are mentioned in the README under the "Agent Setup" section, specifically for the Python version. However, they can be used generally to load environment variables from a .env.local file.
Readme needs to be updated