diff --git a/.env.example b/.env.example new file mode 100644 index 000000000..9a37d7e3e --- /dev/null +++ b/.env.example @@ -0,0 +1,5 @@ +HEYGEN_API_KEY="your Heygen API key" +NEXT_PUBLIC_BASE_API_URL=https://api.heygen.com +# Optional OpenAI integration keys +OPENAI_API_KEY="your OpenAI API key" +NEXT_PUBLIC_OPENAI_API_KEY="your OpenAI API key" diff --git a/README.md b/README.md index b647533a3..2e1cf64af 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,15 @@ Feel free to play around with the existing code and please leave any feedback fo 6. Run `npm run dev` +### Environment variables + +Copy `.env.example` to `.env` and fill in your credentials. The demo understands the following keys: + +- `HEYGEN_API_KEY` – used by `app/api/get-access-token/route.ts` to request streaming tokens. +- `NEXT_PUBLIC_BASE_API_URL` – base URL for HeyGen's API (`https://api.heygen.com` by default). +- `OPENAI_API_KEY` – optional key for sample OpenAI integrations. +- `NEXT_PUBLIC_OPENAI_API_KEY` – optional client-side key for OpenAI demos. + ### Starting sessions NOTE: Make sure you have enter your token into the `.env` file and run `npm run dev`.