Skip to main content

Storage Quota

client.storage.info() returns the current storage usage and quota for the authenticated account.


Signature

client.storage.info(requestOptions?: RequestOptions): Promise<StorageInfo>

Response — StorageInfo

{
usedBytes: number; // Total bytes used across all stored files
limitBytes: number | null; // Quota limit in bytes. null = unlimited
usagePercent: number | null; // 0–100. null = unlimited
fileCount: number; // Number of files contributing to quota
}

Example

import { Decrackle } from '@decrackle/sdk';

const client = new Decrackle({ apiKey: process.env.DECRACKLE_API_KEY });

const info = await client.storage.info();

if (info.limitBytes !== null) {
const usedMB = (info.usedBytes / 1024 / 1024).toFixed(1);
const limitMB = (info.limitBytes / 1024 / 1024).toFixed(1);
console.log(`Storage: ${usedMB} MB / ${limitMB} MB (${info.usagePercent?.toFixed(1)}%)`);
} else {
console.log(`Storage: ${info.usedBytes} bytes used (unlimited plan)`);
}

Warn when storage is nearly full

const info = await client.storage.info();

if (info.usagePercent !== null && info.usagePercent > 90) {
console.warn(`Storage ${info.usagePercent.toFixed(0)}% full — consider deleting old jobs.`);
}

Storage limits by plan

PlanLimit
Free10 MB
Professional100 MB

Exact usage is shown in your dashboard under Settings → Storage.


Freeing up storage

Delete old jobs to reclaim quota:

// Delete all failed transcription jobs
const page = await client.asr.jobs.list({ status: 'failed' });
for (const job of page.items) {
await client.asr.jobs.delete(job.jobId);
}

// Delete all failed denoising jobs
const denoisePage = await client.denoise.jobs.list({ status: 'failed' });
for (const job of denoisePage.items) {
await client.denoise.jobs.delete(job.jobId);
}