47 lines
890 B
TypeScript
47 lines
890 B
TypeScript
export type TripoTaskType = "text_to_model" | "image_to_model" | "convert_model";
|
|
|
|
export type TripoTaskStatus =
|
|
| "queued"
|
|
| "running"
|
|
| "success"
|
|
| "failed"
|
|
| "banned"
|
|
| "expired"
|
|
| "cancelled"
|
|
| "unknown";
|
|
|
|
export interface TripoTaskOutput {
|
|
model?: string;
|
|
base_model?: string;
|
|
pbr_model?: string;
|
|
generated_image?: string;
|
|
rendered_image?: string;
|
|
[key: string]: unknown;
|
|
}
|
|
|
|
export interface TripoTaskData {
|
|
task_id: string;
|
|
type: TripoTaskType | string;
|
|
status: TripoTaskStatus | string;
|
|
progress?: number;
|
|
output?: TripoTaskOutput;
|
|
error_code?: number;
|
|
error_msg?: string;
|
|
[key: string]: unknown;
|
|
}
|
|
|
|
export interface TripoProviderConfig {
|
|
apiKey: string;
|
|
baseUrl: string;
|
|
providerId?: string;
|
|
providerName?: string;
|
|
}
|
|
|
|
export interface TripoApiEnvelope<T> {
|
|
code: number;
|
|
data: T;
|
|
message?: string;
|
|
suggestion?: string;
|
|
}
|
|
|