refactor: centralize API URL and internal API key management for improved maintainability

This commit is contained in:
2026-03-06 20:09:14 -05:00
parent 528456c168
commit d21265f443
7 changed files with 23 additions and 31 deletions
+7
View File
@@ -0,0 +1,7 @@
import { env } from '$env/dynamic/private';
export const apiUrl = env.VITE_API_URL ?? 'http://localhost:5050';
export const viewInternalApiKey =
env.NODE_ENV === 'development'
? 'cccdd42d9f2f648493e402f1da7c855ea798ad510e6bb9ea712dd7bed838e58'
: env.VIEW_INTERNAL_API_KEY ?? env.View_HMAC_Internal_API_Key ?? '';