Replace the OpenAI base url
POST https://api.openai.com/v1
with Helicone’s
POST https://oai.helicone.ai/v1
Replace the OpenAI base url
POST https://api.openai.com/v1
with Helicone’s
POST https://oai.helicone.ai/v1
Change the default base API url to Helicone’s
import openai
openai.api_base = "https://oai.helicone.ai/v1"
Add a basePath
to the Configuration:
Before:
import { Configuration, OpenAIApi } from "openai";
const configuration = new Configuration({
apiKey: process.env.OPENAI_API_KEY,
});
const openai = new OpenAIApi(configuration);
After:
import { Configuration, OpenAIApi } from "openai";
const configuration = new Configuration({
apiKey: process.env.OPENAI_API_KEY,
basePath: "https://oai.helicone.ai/v1",
});
const openai = new OpenAIApi(configuration);
By using our API, you agree to our
Privacy Policy and
Terms of Services agreements.
Once you’ve integrated,
head on to onboarding to get into your
dashboard 🏡