API 概览

WooaAI API 提供兼容 OpenAI 接口格式的大模型调用服务,支持 GPT、Claude、DeepSeek、GLM、Kimi、Gemini、Qwen 等数十种主流 AI 模型。通过标准 HTTP 请求即可接入语言模型、图片理解、图片生成、视频生成、代码生成等能力。

Base URL
所有 API 请求的基础地址:https://open.e5e.cn/v1

语言模型

Chat Completions,支持流式/非流式,兼容 OpenAI SDK

图片理解

Vision 多模态,支持图片 URL 和 Base64 输入

视频生成

文生视频 / 图生视频,异步任务 + 状态查询

代码生成

Codex 专用接口,编程与代码推理

海量模型

30+ 模型,覆盖文本/视觉/视频/代码全场景

鉴权方式

所有 API 请求需要在 HTTP Header 中携带有效的 API Key 进行身份认证。

认证方式
在所有请求的 Header 中添加:
Authorization: Bearer YOUR_API_KEY

获取 API Key

登录 WooaAI 控制台,前往 API 令牌 页面创建和管理密钥。每个账户可创建多个 Key,支持分别设置权限等级和调用限额。

⚠️ 安全提示
请勿在客户端代码或公共仓库中暴露 API Key。建议通过环境变量或后端服务转发请求。Key 泄露可能导致余额被盗用。

模型列表

获取当前可用的所有模型及其信息。

接口地址

GET https://open.e5e.cn/v1/models

请求参数

参数位置必填说明
AuthorizationHeaderBearer 认证,格式 Bearer…_KEY

响应格式

字段类型说明
objectstring固定 list
dataarray模型列表,每项含 idobject("model")、owned_by
GET /v1/models 获取可用模型列表

返回所有已发布且非维护状态的模型,包含模型 ID、所属厂商、能力标签等信息。

curl https://open.e5e.cn/v1/models \
  -H "Authorization: Bearer YOUR_API_KEY"
from openai import OpenAI

# 初始化客户端
client = OpenAI(
    base_url="https://open.e5e.cn/v1",
    api_key="YOUR_API_KEY",
)

# 列出所有模型
for m in client.models.list().data:
    print(f"{m.id:35s} {m.owned_by}")
const resp = await fetch("https://open.e5e.cn/v1/models", {
  headers: { "Authorization": "Bearer YOUR_API_KEY" }
});
const data = await resp.json();
data.data.forEach(m => console.log(m.id, m.owned_by));
package main

import (
	"encoding/json"
	"fmt"
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://open.e5e.cn/v1/models", nil)
	req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
	var result map[string]interface{}
	json.NewDecoder(resp.Body).Decode(&result)
	for _, m := range result["data"].([]interface{}) {
		model := m.(map[string]interface{})
		fmt.Println(model["id"], model["owned_by"])
	}
}
using System.Net.Http.Headers;
using System.Text.Json;

var client = new HttpClient();
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", "YOUR_API_KEY");
var response = await client.GetAsync("https://open.e5e.cn/v1/models");
var json = JsonSerializer.Deserialize<JsonElement>(await response.Content.ReadAsStringAsync());
foreach (var m in json.GetProperty("data").EnumerateArray())
    Console.WriteLine($"{m.GetProperty("id").GetString()} {m.GetProperty("owned_by").GetString()}");
<?php
$ch = curl_init("https://open.e5e.cn/v1/models");
curl_setopt_array($ch, [
    CURLOPT_HTTPHEADER => ["Authorization: Bearer YOUR_API_KEY"],
    CURLOPT_RETURNTRANSFER => true,
]);
$result = json_decode(curl_exec($ch), true);
foreach ($result["data"] as $m) echo $m["id"] . " " . $m["owned_by"] . "\n";
curl_close($ch);

响应示例

{
  "object": "list",
  "data": [
    { "id": "deepseek-v4-pro",     "object": "model", "owned_by": "deepseek" },
    { "id": "doubao-seed-2-0-pro-260215", "object": "model", "owned_by": "volces" },
    { "id": "claude-opus-4-8-1", "object": "model", "owned_by": "anthropic" },
    { "id": "gemini-3.1-pro-preview", "object": "model", "owned_by": "google" }
  ]
}

健康检查

查看各模型的可用状态和延迟数据。

接口地址

GET https://open.e5e.cn/api/models/health

请求参数

无需认证,无需请求体。

响应格式

字段类型说明
healthobject模型健康状态映射,key 为模型 ID,value 含 available + latencyMs
capabilitiesobject模型能力标签映射
labelsobject能力标签中文名称
GET /api/models/health 模型健康状态
curl https://open.e5e.cn/api/models/health
import requests
resp = requests.get("https://open.e5e.cn/api/models/health")
data = resp.json()
for model, info in data.get("health", {}).items():
    avail = "✅" if info.get("available") else "❌"
    print(f"{model}: {avail} ({info.get('latencyMs', '?')}ms)")
const resp = await fetch("https://open.e5e.cn/api/models/health");
const data = await resp.json();
for (const [model, info] of Object.entries(data.health || {})) {
  const avail = info.available ? "✅" : "❌";
  console.log(model + ": " + avail + " (" + (info.latencyMs || "?") + "ms)");
}
package main

import (
	"encoding/json"
	"fmt"
	"net/http"
)

func main() {
	resp, _ := http.Get("https://open.e5e.cn/api/models/health")
	defer resp.Body.Close()
	var result map[string]interface{}
	json.NewDecoder(resp.Body).Decode(&result)
	health := result["health"].(map[string]interface{})
	for model, info := range health {
		m := info.(map[string]interface{})
		avail := "❌"
		if m["available"].(bool) { avail = "✅" }
		fmt.Printf("%s: %s (%vms)\n", model, avail, m["latencyMs"])
	}
}
using System.Text.Json;

var client = new HttpClient();
var response = await client.GetAsync("https://open.e5e.cn/api/models/health");
var json = JsonSerializer.Deserialize<JsonElement>(await response.Content.ReadAsStringAsync());
foreach (var entry in json.GetProperty("health").EnumerateObject()) {
    var info = entry.Value;
    var avail = info.GetProperty("available").GetBoolean() ? "✅" : "❌";
    Console.WriteLine(entry.Name + ": " + avail + " (" + info.GetProperty("latencyMs") + "ms)");
}
<?php
$ch = curl_init("https://open.e5e.cn/api/models/health");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$result = json_decode(curl_exec($ch), true);
foreach ($result["health"] as $model => $info) {
    $avail = $info["available"] ? "✅" : "❌";
    echo $model . ": " . $avail . " (" . $info["latencyMs"] . "ms)\n";
}
curl_close($ch);

响应示例

{
  "health": {
    "deepseek-v4-pro": { "available": true, "latencyMs": 2449, "lastChecked": 1715367049000 },
    "DeepSeek-V3.2": { "available": true, "latencyMs": 1804, "lastChecked": 1715367049000 }
  }
}