forked from DouDOU-start/airgate-openai
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathplugin.yaml
More file actions
349 lines (348 loc) · 10.2 KB
/
Copy pathplugin.yaml
File metadata and controls
349 lines (348 loc) · 10.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
# 本文件由 backend/cmd/genmanifest 自动生成,请勿手工修改。
id: gateway-openai
name: OpenAI 网关
version: dev
description: OpenAI Responses API / Chat Completions 转发
author: airgate
type: gateway
min_core_version: 1.0.0
dependencies: []
frontend_widgets:
- slot: account-identity
entry_file: index.js
title: OpenAI 账号身份
- slot: account-create
entry_file: index.js
title: 创建 OpenAI 账号
- slot: account-edit
entry_file: index.js
title: 编辑 OpenAI 账号
- slot: account-usage-window
entry_file: index.js
title: 账号用量窗口
- slot: usage-metric-detail
entry_file: index.js
title: OpenAI 计量明细
- slot: usage-cost-detail
entry_file: index.js
title: OpenAI 费用明细
gateway:
platform: openai
mode: simple
routes:
- method: POST
path: /v1/responses
description: Responses API(Codex 核心端点)
- method: POST
path: /v1/responses/compact
description: Responses Compact API(上下文压缩)
- method: POST
path: /v1/chat/completions
description: Chat Completions API
- method: POST
path: /v1/messages
description: Anthropic Messages API(协议翻译)
- method: POST
path: /v1/messages/count_tokens
description: Anthropic Count Tokens(兼容回退)
- method: GET
path: /v1/models
description: 模型列表
- method: POST
path: /v1/images/generations
description: Images API(文生图)
- method: POST
path: /v1/images/edits
description: Images API(图生图 / 编辑)
- method: GET
path: /v1/images/tasks
description: Images Task 状态查询
- method: GET
path: /v1/images/tasks/list
description: Images Task 历史列表
- method: WS
path: /v1/responses
description: Responses API(WebSocket)
- method: POST
path: /responses
description: Responses API(无 /v1 前缀)
- method: POST
path: /responses/compact
description: Responses Compact API(无 /v1 前缀)
- method: POST
path: /chat/completions
description: Chat Completions API(无 /v1 前缀)
- method: POST
path: /messages
description: Anthropic Messages API(无 /v1 前缀)
- method: POST
path: /messages/count_tokens
description: Anthropic Count Tokens(无 /v1 前缀)
- method: GET
path: /models
description: 模型列表(无 /v1 前缀)
- method: POST
path: /images/generations
description: Images API(文生图,无 /v1 前缀)
- method: POST
path: /images/edits
description: Images API(图生图,无 /v1 前缀)
- method: GET
path: /images/tasks
description: Images Task 状态查询(无 /v1 前缀)
- method: GET
path: /images/tasks/list
description: Images Task 历史列表(无 /v1 前缀)
- method: WS
path: /responses
description: Responses API WebSocket(无 /v1 前缀)
models:
- id: gpt-5.3-codex-spark
name: GPT 5.3 Codex Spark
context_window: 128000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 1.75
output_price: 14
cached_input_price: 0.175
input_price_priority: 3.5
output_price_priority: 28
cached_input_price_priority: 0.35
input_price_flex: 0.875
output_price_flex: 7
cached_input_price_flex: 0.0875
- id: gpt-5.4
name: GPT 5.4
context_window: 1050000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 2.5
output_price: 15
cached_input_price: 0.25
input_price_priority: 5
output_price_priority: 30
cached_input_price_priority: 0.5
input_price_flex: 1.25
output_price_flex: 7.5
cached_input_price_flex: 0.125
long_context_threshold: 272000
long_context_input_multiplier: 2
long_context_output_multiplier: 1.5
long_context_cached_multiplier: 2
- id: gpt-5.4-mini
name: GPT 5.4 Mini
context_window: 128000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 0.75
output_price: 4.5
cached_input_price: 0.075
input_price_priority: 1.5
output_price_priority: 9
cached_input_price_priority: 0.15
input_price_flex: 0.375
output_price_flex: 2.25
cached_input_price_flex: 0.0375
- id: gpt-5.5
name: GPT 5.5
context_window: 272000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 5
output_price: 30
cached_input_price: 0.5
input_price_priority: 12.5
output_price_priority: 75
cached_input_price_priority: 1.25
input_price_flex: 2.5
output_price_flex: 15
cached_input_price_flex: 0.25
- id: gpt-5.6-luna
name: GPT-5.6-Luna
context_window: 372000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 1
output_price: 6
cached_input_price: 0.1
cache_creation_price: 1.25
input_price_priority: 2
output_price_priority: 12
cached_input_price_priority: 0.2
cache_creation_price_priority: 2.5
input_price_flex: 0.5
output_price_flex: 3
cached_input_price_flex: 0.05
cache_creation_price_flex: 0.625
long_context_threshold: 272000
long_context_input_multiplier: 2
long_context_output_multiplier: 1.5
long_context_cached_multiplier: 2
long_context_cache_creation_multiplier: 2
- id: gpt-5.6-sol
name: GPT-5.6-Sol
context_window: 372000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 5
output_price: 30
cached_input_price: 0.5
cache_creation_price: 6.25
input_price_priority: 10
output_price_priority: 60
cached_input_price_priority: 1
cache_creation_price_priority: 12.5
input_price_flex: 2.5
output_price_flex: 15
cached_input_price_flex: 0.25
cache_creation_price_flex: 3.125
long_context_threshold: 272000
long_context_input_multiplier: 2
long_context_output_multiplier: 1.5
long_context_cached_multiplier: 2
long_context_cache_creation_multiplier: 2
- id: gpt-5.6-terra
name: GPT-5.6-Terra
context_window: 372000
max_output_tokens: 128000
capabilities:
- chat
- reasoning
input_price: 2
output_price: 12
cached_input_price: 0.2
cache_creation_price: 2.5
input_price_priority: 4
output_price_priority: 24
cached_input_price_priority: 0.4
cache_creation_price_priority: 5
input_price_flex: 1
output_price_flex: 6
cached_input_price_flex: 0.1
cache_creation_price_flex: 1.25
long_context_threshold: 272000
long_context_input_multiplier: 2
long_context_output_multiplier: 1.5
long_context_cached_multiplier: 2
long_context_cache_creation_multiplier: 2
- id: gpt-image-1
name: GPT Image 1
context_window: 32000
max_output_tokens: 0
capabilities:
- image_generation
input_price: 5
output_price: 30
cached_input_price: 0.5
input_price_priority: 10
output_price_priority: 60
cached_input_price_priority: 1
input_price_flex: 2.5
output_price_flex: 15
cached_input_price_flex: 0.25
- id: gpt-image-1.5
name: GPT Image 1.5
context_window: 32000
max_output_tokens: 0
capabilities:
- image_generation
input_price: 5
output_price: 30
cached_input_price: 0.5
input_price_priority: 10
output_price_priority: 60
cached_input_price_priority: 1
input_price_flex: 2.5
output_price_flex: 15
cached_input_price_flex: 0.25
- id: gpt-image-2
name: GPT Image 2
context_window: 32000
max_output_tokens: 0
capabilities:
- image_generation
input_price: 5
output_price: 30
cached_input_price: 0.5
input_price_priority: 10
output_price_priority: 60
cached_input_price_priority: 1
input_price_flex: 2.5
output_price_flex: 15
cached_input_price_flex: 0.25
account_types:
- key: apikey
label: API Key
description: 支持所有提供 Responses 标准接口的服务
fields:
- key: api_key
label: API Key
type: password
required: true
placeholder: sk-...
- key: base_url
label: API 地址
type: text
required: false
placeholder: https://api.openai.com
- key: oauth
label: OAuth 登录
description: 浏览器 OAuth 或新版 Sub2API Agent Identity 凭证
fields:
- key: access_token
label: Access Token
type: password
required: false
placeholder: 授权后自动填充
- key: refresh_token
label: Refresh Token
type: password
required: false
placeholder: 授权后自动填充
- key: session_token
label: Session Token (JWE)
type: password
required: false
placeholder: Session 导入后自动填充
- key: chatgpt_account_id
label: ChatGPT Account ID
type: text
required: false
placeholder: 授权后自动填充
- key: auth_mode
label: 认证模式
type: text
required: false
placeholder: agentIdentity
- key: agent_runtime_id
label: Agent Runtime ID
type: text
required: false
placeholder: Agent Identity 导入后自动填充
- key: agent_private_key
label: Agent Private Key
type: password
required: false
placeholder: Agent Identity 导入后自动填充
- key: task_id
label: Agent Task ID
type: text
required: false
placeholder: 首次请求自动注册
- key: chatgpt_user_id
label: ChatGPT User ID
type: text
required: false
placeholder: Agent Identity 导入后自动填充