MCPcopy Index your code
hub / github.com/simstudioai/sim / getStorageLimits

Function getStorageLimits

apps/sim/lib/billing/storage/limits.ts:41–58  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

39 * Returns limits in bytes
40 */
41export function getStorageLimits() {
42 return {
43 free: gbToBytes(
44 Number.parseInt(getEnv('FREE_STORAGE_LIMIT_GB') || String(DEFAULT_FREE_STORAGE_LIMIT_GB))
45 ),
46 pro: gbToBytes(
47 Number.parseInt(getEnv('PRO_STORAGE_LIMIT_GB') || String(DEFAULT_PRO_STORAGE_LIMIT_GB))
48 ),
49 team: gbToBytes(
50 Number.parseInt(getEnv('TEAM_STORAGE_LIMIT_GB') || String(DEFAULT_TEAM_STORAGE_LIMIT_GB))
51 ),
52 enterpriseDefault: gbToBytes(
53 Number.parseInt(
54 getEnv('ENTERPRISE_STORAGE_LIMIT_GB') || String(DEFAULT_ENTERPRISE_STORAGE_LIMIT_GB)
55 )
56 ),
57 }
58}
59
60/**
61 * Get storage limit for a specific plan

Callers 2

getStorageLimitForPlanFunction · 0.85
getUserStorageLimitFunction · 0.85

Calls 2

getEnvFunction · 0.90
gbToBytesFunction · 0.85

Tested by

no test coverage detected