OpenAI
OpenAI JavaScript SDK Integration
Use OpenAI’s JavaScript SDK to integrate with Helicone to log your OpenAI usage.
Proxy Integration (recommended)
1
2
Set HELICONE_API_KEY as an environment variable
3
Modify the base path and add a Helicone-Auth header
Package Integration
@helicone/helicone
has been deprecated and will no longer be maintained. We recommend you setup OpenAI integration with Proxy as mentioned above.
1
To get started, install the `helicone-openai` package
2
Set `HELICONE_API_KEY` as an environment variable
You can also set the Helicone API Key in your code (See below)
3
Replace
with
4
Make a request
Chat, Completion, Embedding, etc usage is equivalent to OpenAI package.
Was this page helpful?