OpenAI SDK

Use the official openai-python SDK against firepass.

1. Sign up and create a key

It's free. Create your account, then open the dashboard and click Create. Save the sk-firepass-… key — it's shown once.

2. Use it like any OpenAI/Anthropic key

Point your client at https://dizosrf-firepass.hf.space/v1 (OpenAI) or https://dizosrf-firepass.hf.space/anthropic (Anthropic). The same key works for both.

3. Use the openai-python SDK

from openai import OpenAI

client = OpenAI(
    base_url="https://dizosrf-firepass.hf.space/v1",
    api_key="sk-firepass-…",
)

resp = client.chat.completions.create(
    model="claude-opus-4-7",
    messages=[{"role": "user", "content": "Hello!"}],
)
print(resp.choices[0].message.content)

Streaming works the same way:

stream = client.chat.completions.create(
    model="gpt-5.5",
    messages=[{"role": "user", "content": "Write a haiku."}],
    stream=True,
)
for chunk in stream:
    print(chunk.choices[0].delta.content or "", end="")