import 'dotenv/config';

import { loadVaultEnvironment } from './vault/env.js';

await loadVaultEnvironment();

export const config = {
  host: process.env.HOST ?? '0.0.0.0',
  port: Number(process.env.PORT ?? '4000'),
  databaseUrl: process.env.DATABASE_URL ?? '',
  hatchetToken: process.env.HATCHET_CLIENT_TOKEN ?? '',
  telegramMiniAppBotToken: process.env.TELEGRAM_MINI_APP_BOT_TOKEN ?? '',
  telegramAuthMaxAgeSeconds: Number(
    process.env.TELEGRAM_AUTH_MAX_AGE_SECONDS ?? '86400',
  ),
};
