feat: Add OpenAI API type configuration and update provider settings
This commit is contained in:
@@ -290,6 +290,7 @@ export async function updateProviderSettings(
|
||||
query.set("provider", update.provider);
|
||||
if (update.apiKey !== undefined) query.set("api_key", update.apiKey);
|
||||
if (update.apiBase !== undefined) query.set("api_base", update.apiBase);
|
||||
if (update.apiType !== undefined) query.set("api_type", update.apiType);
|
||||
return request<SettingsPayload>(
|
||||
`${base}/api/settings/provider/update?${query}`,
|
||||
token,
|
||||
|
||||
@@ -206,6 +206,7 @@ export interface SettingsPayload {
|
||||
api_key_hint?: string | null;
|
||||
api_base?: string | null;
|
||||
default_api_base?: string | null;
|
||||
api_type?: "auto" | "chat_completions" | "responses";
|
||||
}>;
|
||||
web_search: {
|
||||
provider: string;
|
||||
@@ -391,6 +392,7 @@ export interface ProviderSettingsUpdate {
|
||||
provider: string;
|
||||
apiKey?: string;
|
||||
apiBase?: string;
|
||||
apiType?: "auto" | "chat_completions" | "responses";
|
||||
}
|
||||
|
||||
export interface WebSearchSettingsUpdate {
|
||||
|
||||
Reference in New Issue
Block a user