veogent 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +18 -6
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -283,12 +283,12 @@ program
|
|
|
283
283
|
// --- Execution Request (Generate Image / Video) ---
|
|
284
284
|
program
|
|
285
285
|
.command('request')
|
|
286
|
-
.description('Create a job request (GENERATE_IMAGES, GENERATE_VIDEO
|
|
286
|
+
.description('Create a job request (GENERATE_IMAGES, GENERATE_VIDEO)')
|
|
287
287
|
.requiredOption('-t, --type <type>', 'Request type (e.g., GENERATE_IMAGES, GENERATE_VIDEO)')
|
|
288
288
|
.requiredOption('-p, --project <project>', 'Project ID')
|
|
289
289
|
.requiredOption('-c, --chapter <chapter>', 'Chapter ID')
|
|
290
290
|
.requiredOption('-s, --scene <scene>', 'Scene ID')
|
|
291
|
-
.option('-o, --orientation <orientation>', 'Request orientation (HORIZONTAL, VERTICAL)'
|
|
291
|
+
.option('-o, --orientation <orientation>', 'Request orientation (HORIZONTAL, VERTICAL)')
|
|
292
292
|
.option('-i, --imagemodel <imagemodel>', 'Image Model (imagen4, imagen3.5)', 'imagen4')
|
|
293
293
|
.option('-v, --videomodel <videomodel>', 'Video Model (veo_3_1_fast, veo_3_1_fast_r2v)', 'veo_3_1_fast_r2v')
|
|
294
294
|
.option('-S, --speed <speed>', 'Video Speed (normal, timelapse, slowmotion)', 'normal')
|
|
@@ -302,9 +302,6 @@ program
|
|
|
302
302
|
};
|
|
303
303
|
|
|
304
304
|
// Conditionally add fields based on strict DTO validators
|
|
305
|
-
if (['CREATE_SCENE_VIDEO', 'CREATE_CHAPTER_VIDEO', 'VIDEO_UPSCALE'].includes(options.type)) {
|
|
306
|
-
payload.orientation = options.orientation || 'HORIZONTAL'; // Provide fallback
|
|
307
|
-
}
|
|
308
305
|
if (options.type === 'GENERATE_IMAGES') {
|
|
309
306
|
payload.imageModel = options.imagemodel;
|
|
310
307
|
}
|
|
@@ -313,11 +310,14 @@ program
|
|
|
313
310
|
payload.videoSpeedMode = options.speed;
|
|
314
311
|
payload.useFlowKey = false;
|
|
315
312
|
}
|
|
313
|
+
if (['CREATE_CHAPTER_VIDEO', 'VIDEO_UPSCALE'].includes(options.type)) {
|
|
314
|
+
payload.orientation = options.orientation || 'HORIZONTAL'; // Provide fallback
|
|
315
|
+
}
|
|
316
316
|
|
|
317
317
|
const data = await api.post('/app/request', payload);
|
|
318
318
|
console.log(JSON.stringify({ status: "success", request: data.data || data }, null, 2));
|
|
319
319
|
} catch (error) {
|
|
320
|
-
console.log(JSON.stringify({ status: "error", message: error.message }));
|
|
320
|
+
console.log(JSON.stringify({ status: "error", message: error.response?.data?.message || error.message }));
|
|
321
321
|
}
|
|
322
322
|
});
|
|
323
323
|
|
|
@@ -333,6 +333,18 @@ program
|
|
|
333
333
|
}
|
|
334
334
|
});
|
|
335
335
|
|
|
336
|
+
program
|
|
337
|
+
.command('assets <projectId> <chapterId> <sceneId> <type>')
|
|
338
|
+
.description('Check generated assets history/status for a scene. Types: GENERATE_IMAGES, CREATE_SCENE_VIDEO, GENERATE_VIDEO, EDIT_IMAGE')
|
|
339
|
+
.action(async (projectId, chapterId, sceneId, type) => {
|
|
340
|
+
try {
|
|
341
|
+
const data = await api.get(`/app/request/assets/${projectId}/${chapterId}/${sceneId}?type=${type}`);
|
|
342
|
+
console.log(JSON.stringify(data.data || data, null, 2));
|
|
343
|
+
} catch (error) {
|
|
344
|
+
console.log(JSON.stringify({ status: "error", message: error.message }));
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
|
|
336
348
|
// --- System ---
|
|
337
349
|
program
|
|
338
350
|
.command('skill')
|