> ## Documentation Index
> Fetch the complete documentation index at: https://docs.qualifire.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# API keys

> Integrate your application with Qualifire

## Setup

In order to use the Qualifire Proxy, you need to set up an Integration or an API key.

### API key

To set up an API key, follow these steps:

<Steps>
  <Step title="Navigate to the API keys page in the Qualifire platform.">
    Navigate to the API keys page in the Qualifire platform.
  </Step>

  <Step title="Click on the 'Create New API key' button.">
    Click on the "Create New API key" button.
  </Step>

  <Step title="Save the API key and start using it in your application.">
    Save the API key and start using it in your application.

    <Warning>
      The API key is sensitive information and should be kept confidential. Never commit API keys to source control or expose them in client-side code. Use environment variables to store and access your keys.
    </Warning>
  </Step>
</Steps>

### Using Your API Key

<Info>
  We recommend storing your API key as an environment variable named `QUALIFIRE_API_KEY` and referencing it in your code.
</Info>

<CodeGroup>
  ```javascript Node.js theme={null}
  import OpenAI from "openai";

  const openai = new OpenAI({
    apiKey: process.env.OPENAI_API_KEY,
    baseURL: "https://proxy.qualifire.ai/api/providers/openai",
    defaultHeaders: {
      "X-Qualifire-Api-Key": process.env.QUALIFIRE_API_KEY,
    },
  });
  ```

  ```python Python theme={null}
  from openai import OpenAI
  import os

  client = OpenAI(
      api_key=os.environ["OPENAI_API_KEY"],
      base_url="https://proxy.qualifire.ai/api/providers/openai",
      default_headers={
          "X-Qualifire-Api-Key": os.environ["QUALIFIRE_API_KEY"],
      },
  )
  ```

  ```bash cURL theme={null}
  curl https://proxy.qualifire.ai/api/providers/openai/chat/completions \
    -H "Content-Type: application/json" \
    -H "Authorization: Bearer $OPENAI_API_KEY" \
    -H "X-Qualifire-Api-Key: $QUALIFIRE_API_KEY" \
    -d '{
      "model": "gpt-4o",
      "messages": [{"role": "user", "content": "Hello!"}]
    }'
  ```
</CodeGroup>

Once you have set up an Integration or an API key, you can use it with your application.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.