Proxy Integration


Create an account + Generate an API Key

Log into helicone or create an account. Once you have an account, you can generate an API key.


Create Google Generative AI API Key

Visit the Google Generative AI API Key page. Follow the instructions to create a new API key. Make sure to save the key as you will need it for the next steps.


Set API keys as environment variables

export HELICONE_API_KEY=<your Helicone API key>
export GOOGLE_GENERATIVE_API_KEY=<your Google Generative AI API key>

Send a request using cURL

Use the following cURL command to send a request to the Google Generative AI API through the Helicone proxy:

curl --request POST \
  --header "Content-Type: application/json" \
  --header "Helicone-Auth: Bearer ${HELICONE_API_KEY}" \
  --header "Helicone-Target-URL:" \
  --data '{
    "contents": [{
        "text": "Write a story about a magic backpack."