Portkey
portkey.aiDemocratize and productionize Gen AI across your entire org with Portkey's suite of AI gateway, observability, guardrails, and prompt management modules.
计费方式
按量计费
价格区间
—
注册方式
—
最后更新:2026-03-16
如何接入 Portkey?
Portkey 接口完全兼容 OpenAI API 格式。只需将 base_url 替换为中转站地址,即可在任何支持自定义 API 端点的客户端或代码中使用。
from openai import OpenAI
client = OpenAI(
api_key="你的 Portkey API Key",
base_url="https://portkey.ai/v1"
)
response = client.chat.completions.create(
model="gpt-4o",
messages=[{"role": "user", "content": "你好"}]
)
print(response.choices[0].message.content)常见问题
Portkey 支持哪些模型?
支持多种主流 AI 模型,具体以官网为准。
Portkey 价格如何?
采用按量计费模式,具体价格请查看官网价格页面。
国内可以直接访问 Portkey 吗?
Portkey 提供 API 中转服务,国内用户可直接调用其 API 接口,无需自行翻墙。