feat: migrate openai-video provider into tools plugin
This commit is contained in:
1 parent
42ef37f10a
commit
720f48844d
13 files changed
+1306
-38
No files matched your search
Vendored
+56
@@ -0,0 +1,56 @@
|
||||
declare module "openclaw/plugin-sdk/blob-runtime" {
|
||||
export function bufferToBlobPart(buffer: Buffer): BlobPart;
|
||||
}
|
||||
|
||||
declare module "openclaw/plugin-sdk/video-generation" {
|
||||
export interface VideoGenerationProvider {
|
||||
id: string;
|
||||
aliases?: string[];
|
||||
label?: string;
|
||||
defaultModel?: string;
|
||||
models?: string[];
|
||||
isConfigured: (ctx: { cfg?: any }) => boolean;
|
||||
capabilities: any;
|
||||
generateVideo: (req: VideoGenerationRequest) => Promise<any>;
|
||||
}
|
||||
|
||||
export interface VideoGenerationRequest {
|
||||
prompt: string;
|
||||
model?: string;
|
||||
durationSeconds?: number;
|
||||
size?: string;
|
||||
aspectRatio?: string;
|
||||
resolution?: string;
|
||||
inputImages?: Array<{ buffer?: Buffer; mimeType?: string; fileName?: string }>;
|
||||
inputVideos?: Array<{ buffer?: Buffer; mimeType?: string; fileName?: string }>;
|
||||
cfg?: any;
|
||||
agentDir?: string;
|
||||
authStore?: any;
|
||||
timeoutMs?: number;
|
||||
}
|
||||
}
|
||||
|
||||
declare module "openclaw/plugin-sdk/provider-http" {
|
||||
export function createProviderOperationDeadline(params: { timeoutMs?: number; label: string }): any;
|
||||
export function createProviderOperationTimeoutResolver(params: { deadline: any; defaultTimeoutMs: number }): () => number;
|
||||
export function executeProviderOperationWithRetry(params: any): Promise<any>;
|
||||
export function fetchProviderDownloadResponse(params: any): Promise<any>;
|
||||
export function fetchWithTimeoutGuarded(url: string, init: any, timeoutMs: number, fetchFn: any, opts: any): Promise<any>;
|
||||
export function assertOkOrThrowHttpError(response: Response, message: string): Promise<void>;
|
||||
export function postMultipartRequest(params: any): Promise<{ response: Response; release: () => Promise<void> }>;
|
||||
export function postJsonRequest(params: any): Promise<{ response: Response; release: () => Promise<void> }>;
|
||||
export function readProviderJsonResponse<T = any>(response: Response, message: string): Promise<T>;
|
||||
export function pollProviderOperationJson<T = any>(params: any): Promise<T>;
|
||||
export function resolveProviderOperationTimeoutMs(params: any): number;
|
||||
export function resolveProviderHttpRequestConfig(params: any): any;
|
||||
export function sanitizeConfiguredModelProviderRequest(params: any): any;
|
||||
}
|
||||
|
||||
declare module "openclaw/plugin-sdk/provider-auth-runtime" {
|
||||
export function resolveApiKeyForProvider(params: any): Promise<{ apiKey?: string; mode?: string }>;
|
||||
}
|
||||
|
||||
declare module "openclaw/plugin-sdk/media-generation-runtime" {
|
||||
export function downloadGeneratedVideoAsset(params: any): Promise<any>;
|
||||
export function resolveGeneratedMediaMaxBytes(cfg: any, type: string): number;
|
||||
}
|
||||
Reference in new issue
Block a user