feat(api): expose outputSizeBytes on job status
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -83,6 +83,10 @@ export function createApp(config, prisma) {
|
||||
res.json({ targets: listTargetFormats(source) });
|
||||
});
|
||||
|
||||
app.get('/api/config', (req, res) => {
|
||||
res.json({ maxFileSizeMb: config.maxFileSizeMb, retentionHours: config.retentionHours });
|
||||
});
|
||||
|
||||
app.post('/api/jobs', jobsRateLimiter, upload.array('files', 10), async (req, res) => {
|
||||
if (!req.files || req.files.length === 0) {
|
||||
return res.status(400).json({ error: 'No files uploaded' });
|
||||
@@ -206,6 +210,7 @@ export function createApp(config, prisma) {
|
||||
originalFilename: job.originalFilename,
|
||||
sourceFormat: job.sourceFormat,
|
||||
targetFormat: job.targetFormat,
|
||||
outputSizeBytes: job.outputSizeBytes,
|
||||
errorMessage: job.errorMessage,
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user