WOX 沃想 AI

API Reference

WOX AI OpenAI 兼容 API 接口参考

GET
/v1/models

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

查询参数

key?string

Google API Key (用于 Gemini 格式)

请求头参数

x-api-key?string

Anthropic API Key (用于 Claude 格式)

anthropic-version?string

Anthropic API 版本

x-goog-api-key?string

Google API Key (用于 Gemini 格式)

响应体

application/json

application/json

curl -X GET "https://example.com/v1/models" \  -H "x-api-key: " \  -H "anthropic-version: " \  -H "x-goog-api-key: "
{  "object": "string",  "data": [    {      "id": "string",      "object": "string",      "created": 0,      "owned_by": "string"    }  ]}
GET
/v1beta/models

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

响应体

application/json

curl -X GET "https://example.com/v1beta/models"
{  "models": [    {      "name": "string",      "version": "string",      "displayName": "string",      "description": "string",      "inputTokenLimit": 0,      "outputTokenLimit": 0,      "supportedGenerationMethods": [        "string"      ]    }  ]}
POST
/v1/chat/completions

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

application/json

application/json

curl -X POST "https://example.com/v1/chat/completions" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "messages": [      {        "role": "system",        "content": "string"      }    ]  }'
{  "id": "string",  "object": "string",  "created": 0,  "model": "string",  "choices": [    {      "index": 0,      "message": {        "role": "system",        "content": "string",        "name": "string",        "tool_calls": [          {            "id": "string",            "type": "string",            "function": {              "name": "string",              "arguments": "string"            }          }        ],        "tool_call_id": "string",        "reasoning_content": "string"      },      "finish_reason": "stop"    }  ],  "usage": {    "prompt_tokens": 0,    "completion_tokens": 0,    "total_tokens": 0,    "prompt_tokens_details": {      "cached_tokens": 0,      "text_tokens": 0,      "audio_tokens": 0,      "image_tokens": 0    },    "completion_tokens_details": {      "text_tokens": 0,      "audio_tokens": 0,      "reasoning_tokens": 0    }  },  "system_fingerprint": "string"}
POST
/v1/responses

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/responses" \  -H "Content-Type: application/json" \  -d '{    "model": "string"  }'
{  "id": "string",  "object": "string",  "created_at": 0,  "status": "completed",  "model": "string",  "output": [    {      "type": "string",      "id": "string",      "status": "string",      "role": "string",      "content": [        {          "type": "string",          "text": "string"        }      ]    }  ],  "usage": {    "prompt_tokens": 0,    "completion_tokens": 0,    "total_tokens": 0,    "prompt_tokens_details": {      "cached_tokens": 0,      "text_tokens": 0,      "audio_tokens": 0,      "image_tokens": 0    },    "completion_tokens_details": {      "text_tokens": 0,      "audio_tokens": 0,      "reasoning_tokens": 0    }  }}
POST
/v1/responses/compact

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/responses/compact" \  -H "Content-Type: application/json" \  -d '{    "model": "string"  }'
{  "id": "string",  "object": "string",  "created_at": 0,  "output": [    {}  ],  "usage": {    "prompt_tokens": 0,    "completion_tokens": 0,    "total_tokens": 0,    "prompt_tokens_details": {      "cached_tokens": 0,      "text_tokens": 0,      "audio_tokens": 0,      "image_tokens": 0    },    "completion_tokens_details": {      "text_tokens": 0,      "audio_tokens": 0,      "reasoning_tokens": 0    }  },  "error": {}}
POST
/v1/images/generations

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/images/generations" \  -H "Content-Type: application/json" \  -d '{    "model": "qwen-image-plus",    "input": {      "messages": [        {          "role": "user",          "content": [            {              "text": "一副典雅庄重的对联悬挂于厅堂之中,房间是个安静古典的中式布置,桌子上放着一些青花瓷,对联上左书“义本生知人机同道善思新”,右书“通云赋智乾坤启数高志远”, 横批“智启通义”,字体飘逸,在中间挂着一幅中国风的画作,内容是岳阳楼。"            }          ]        }      ]    },    "parameters": {      "negative_prompt": "",      "prompt_extend": true,      "watermark": false,      "size": "1328*1328"    }  }'
{  "created": 0,  "data": [    {      "url": "string",      "b64_json": "string",      "revised_prompt": "string"    }  ]}
POST
/v1/images/edits

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/images/edits" \  -H "Content-Type: application/json" \  -d '{      "model": "qwen-image-edit-plus",      "input": {          "messages": [              {                  "role": "user",                  "content": [                      {                          "image": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20250925/fpakfo/image36.webp"                      },                      {                          "text": "生成一张符合深度图的图像,遵循以下描述:一辆红色的破旧的自行车停在一条泥泞的小路上,背景是茂密的原始森林"                      }                  ]              }          ]      },      "parameters": {          "n": 2,          "negative_prompt": " ",          "prompt_extend": true,          "watermark": false      }'
{  "created": 0,  "data": [    {      "url": "string",      "b64_json": "string",      "revised_prompt": "string"    }  ]}
POST
/v1/videos

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

multipart/form-data

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

application/json

curl -X POST "https://example.com/v1/videos"
{  "id": "sora-2-123456",  "object": "video",  "model": "sora-2",  "status": "queued",  "progress": 0,  "created_at": 1764347090922,  "seconds": "8"}
GET
/v1/videos/{task_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

task_id*string

视频任务 ID

响应体

application/json

application/json

curl -X GET "https://example.com/v1/videos/sora-2-123456"
{  "id": "sora-2-123456",  "object": "video",  "model": "sora-2",  "status": "queued",  "progress": 0,  "created_at": 1764347090922,  "seconds": "8"}
GET
/v1/videos/{task_id}/content

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

task_id*string

视频任务 ID

响应体

video/mp4

application/json

curl -X GET "https://example.com/v1/videos/video-abc123/content"
"string"
POST
/kling/v1/videos/text2video

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

视频生成请求

响应体

application/json

application/json

curl -X POST "https://example.com/kling/v1/videos/text2video" \  -H "Content-Type: application/json" \  -d '{    "model": "kling-v1",    "prompt": "宇航员站起身走了",    "duration": 5,    "width": 1280,    "height": 720,    "fps": 30  }'
{  "task_id": "string",  "status": "string"}
GET
/kling/v1/videos/text2video/{task_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

task_id*string

任务 ID

响应体

application/json

application/json

curl -X GET "https://example.com/kling/v1/videos/text2video/task-abc123"
{  "task_id": "string",  "status": "queued",  "url": "string",  "format": "string",  "metadata": {    "duration": 0,    "fps": 0,    "width": 0,    "height": 0,    "seed": 0  },  "error": {    "code": 0,    "message": "string"  }}
POST
/kling/v1/videos/image2video

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

视频生成请求

响应体

application/json

application/json

curl -X POST "https://example.com/kling/v1/videos/image2video" \  -H "Content-Type: application/json" \  -d '{    "model": "kling-v1",    "prompt": "人物转身走开",    "image": "https://example.com/image.jpg",    "duration": 5,    "width": 1280,    "height": 720  }'
{  "task_id": "string",  "status": "string"}
GET
/kling/v1/videos/image2video/{task_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

task_id*string

任务 ID

响应体

application/json

application/json

curl -X GET "https://example.com/kling/v1/videos/image2video/task-abc123"
{  "task_id": "string",  "status": "queued",  "url": "string",  "format": "string",  "metadata": {    "duration": 0,    "fps": 0,    "width": 0,    "height": 0,    "seed": 0  },  "error": {    "code": 0,    "message": "string"  }}
POST
/jimeng/

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

查询参数

Action*string

API 操作类型

Value in

  • "CVSync2AsyncSubmitTask"
  • "CVSync2AsyncGetResult"
Version*string

API 版本

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

即梦官方 API 请求格式

响应体

application/json

application/json

curl -X POST "https://example.com/jimeng/?Action=CVSync2AsyncSubmitTask&Version=2022-08-31" \  -H "Content-Type: application/json" \  -d '{    "req_key": "jimeng_video_generation",    "prompt": "一只猫在弹钢琴"  }'
{  "code": 0,  "message": "string",  "data": {}}
POST
/v1/video/generations

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

视频生成请求

响应体

application/json

application/json

curl -X POST "https://example.com/v1/video/generations" \  -H "Content-Type: application/json" \  -d '{    "model": "kling-v1",    "prompt": "宇航员在月球上漫步",    "duration": 5,    "width": 1280,    "height": 720  }'
{  "task_id": "string",  "status": "string"}
GET
/v1/video/generations/{task_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

task_id*string

任务 ID

响应体

application/json

application/json

curl -X GET "https://example.com/v1/video/generations/abcd1234efgh"
{  "task_id": "string",  "status": "queued",  "url": "string",  "format": "string",  "metadata": {    "duration": 0,    "fps": 0,    "width": 0,    "height": 0,    "seed": 0  },  "error": {    "code": 0,    "message": "string"  }}
POST
/v1/messages

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求头参数

anthropic-version*string

Anthropic API 版本

x-api-key?string

Anthropic API Key (可选,也可使用 Bearer Token)

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/messages" \  -H "anthropic-version: " \  -H "x-api-key: " \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "messages": [      {        "role": "user",        "content": "string"      }    ],    "max_tokens": 1  }'
{  "id": "string",  "type": "string",  "role": "string",  "content": [    {      "type": "string",      "text": "string"    }  ],  "model": "string",  "stop_reason": "end_turn",  "usage": {    "input_tokens": 0,    "output_tokens": 0,    "cache_creation_input_tokens": 0,    "cache_read_input_tokens": 0  }}
POST
/v1beta/models/{model}:generateContent

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

model*string

模型名称

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1beta/models/gemini-3-pro-image-preview:generateContent" \  -H "Content-Type: application/json" \  -d '{    "contents": [      {        "role": "user",        "parts": [          {            "text": "draw a cat"          }        ]      }    ],    "generationConfig": {      "responseModalities": [        "TEXT",        "IMAGE"      ],      "imageConfig": {        "aspectRatio": "16:9",        "imageSize": "4K"      }    }  }'
{  "candidates": [    {      "content": {        "role": "string",        "parts": [          {}        ]      },      "finishReason": "string",      "safetyRatings": [        {}      ]    }  ],  "usageMetadata": {    "promptTokenCount": 0,    "candidatesTokenCount": 0,    "totalTokenCount": 0  }}
POST
/v1/engines/{model}/embeddings

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

model*string

模型/引擎 ID

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/engines//embeddings" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "input": "string"  }'
{  "object": "string",  "data": [    {      "object": "string",      "index": 0,      "embedding": [        0      ]    }  ],  "model": "string",  "usage": {    "prompt_tokens": 0,    "total_tokens": 0  }}
POST
/v1/embeddings

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/embeddings" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "input": "string"  }'
{  "object": "string",  "data": [    {      "object": "string",      "index": 0,      "embedding": [        0      ]    }  ],  "model": "string",  "usage": {    "prompt_tokens": 0,    "total_tokens": 0  }}
POST
/v1/completions

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/completions" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "prompt": "string"  }'
{  "id": "string",  "object": "string",  "created": 0,  "model": "string",  "choices": [    {      "text": "string",      "index": 0,      "finish_reason": "string"    }  ],  "usage": {    "prompt_tokens": 0,    "completion_tokens": 0,    "total_tokens": 0,    "prompt_tokens_details": {      "cached_tokens": 0,      "text_tokens": 0,      "audio_tokens": 0,      "image_tokens": 0    },    "completion_tokens_details": {      "text_tokens": 0,      "audio_tokens": 0,      "reasoning_tokens": 0    }  }}
POST
/v1/audio/transcriptions

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

multipart/form-data

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/audio/transcriptions" \  -F file="string" \  -F model="string"
{  "text": "string"}
POST
/v1/audio/translations

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

multipart/form-data

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/audio/translations" \  -F file="string" \  -F model="string"
{  "text": "string"}
POST
/v1/audio/speech

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

audio/mpeg

curl -X POST "https://example.com/v1/audio/speech" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "input": "string",    "voice": "alloy"  }'
"string"
POST
/v1/rerank

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/rerank" \  -H "Content-Type: application/json" \  -d '{    "model": "string",    "query": "string",    "documents": [      "string"    ]  }'
{  "id": "string",  "results": [    {      "index": 0,      "relevance_score": 0,      "document": {}    }  ],  "meta": {}}
POST
/v1/moderations

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/moderations" \  -H "Content-Type: application/json" \  -d '{    "input": "string"  }'
{  "id": "string",  "model": "string",  "results": [    {      "flagged": true,      "categories": {},      "category_scores": {}    }  ]}
GET
/v1/realtime

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

查询参数

model?string

要使用的模型

响应体

application/json

curl -X GET "https://example.com/v1/realtime"
GET
/v1/fine-tunes

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

响应体

application/json

curl -X GET "https://example.com/v1/fine-tunes"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
POST
/v1/fine-tunes

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

application/json

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/fine-tunes" \  -H "Content-Type: application/json" \  -d '{}'
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
GET
/v1/fine-tunes/{fine_tune_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

fine_tune_id*string

响应体

application/json

curl -X GET "https://example.com/v1/fine-tunes/"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
POST
/v1/fine-tunes/{fine_tune_id}/cancel

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

fine_tune_id*string

响应体

application/json

curl -X POST "https://example.com/v1/fine-tunes//cancel"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
GET
/v1/fine-tunes/{fine_tune_id}/events

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

fine_tune_id*string

响应体

application/json

curl -X GET "https://example.com/v1/fine-tunes//events"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
GET
/v1/files

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

响应体

application/json

curl -X GET "https://example.com/v1/files"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
POST
/v1/files

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

请求体

multipart/form-data

TypeScript 类型定义

Use the request body type in TypeScript.

响应体

application/json

curl -X POST "https://example.com/v1/files"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
GET
/v1/files/{file_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

file_id*string

响应体

application/json

curl -X GET "https://example.com/v1/files/"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
DELETE
/v1/files/{file_id}

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

file_id*string

响应体

application/json

curl -X DELETE "https://example.com/v1/files/"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}
GET
/v1/files/{file_id}/content

认证

BearerAuth
认证Bearer <token>

使用 Bearer Token 认证。 格式: Authorization: Bearer sk-xxxxxx

In: header

路径参数

file_id*string

响应体

application/json

curl -X GET "https://example.com/v1/files//content"
{  "error": {    "message": "string",    "type": "string",    "param": "string",    "code": "string"  }}