เข้ากันได้กับ OpenAI — ใช้ SDK เดิมของคุณได้เลย
https://api.orcarouter.ai/v1https://api.orcarouter.aifrom openai import OpenAI
client = OpenAI(
base_url="https://api.orcarouter.ai/v1",
api_key="$ORCAROUTER_API_KEY",
)
response = client.chat.completions.create(
model="google/gemini-flash-latest",
messages=[{"role": "user", "content": "Hello"}],
)
print(response.choices[0].message.content)max_tokensresponse_formatseedstopstructured_outputstemperaturetool_choicetoolstop_pinclude_reasoningreasoning| อินพุต / 1M โทเค็น | $0.500 |
| เอาต์พุต / 1M โทเค็น | $3.00 |
| อ่านแคช / 1M | $0.100 |
| สกุลเงิน | USD |
ประมาณการจากราคาตั้ง
เป็นเพียงการประเมิน — จำนวน token จริงขึ้นอยู่กับ tokenizer ของผู้ให้บริการ
GET /api/public/models/google/gemini-flash-latestเปิด @misc{orcarouter_gemini_flash_latest,
title = {google/gemini-flash-latest API},
author = {google},
year = {n.d.},
howpublished = {OrcaRouter},
url = {https://www.orcarouter.ai/models/google/gemini-flash-latest}
}google. (n.d.). google/gemini-flash-latest API. OrcaRouter. https://www.orcarouter.ai/models/google/gemini-flash-latest