Files
calendar/apps/api/v2/scripts/generate-secrets.ts
T
Lauris SkraucisGitHubDevin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>Ryukemeister
3b2e3351c4 docs: api v2 and examples app setup (#27290)
* docs: api v2 and examples app setup

* docs: api v2 and examples app setup

* fix: address Cubic AI review feedback

- Fix env file path typo in README.md (apps/api/v2.env -> apps/api/v2/.env)
- Write generated secrets to file instead of logging to console
- Add .generated-secrets to gitignore
- Update README-PLATFORM.md to reflect new secret generation behavior

Co-Authored-By: unknown <>

* chore: update locale

* chore: update docs

---------

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Co-authored-by: Ryukemeister <sahalrajiv6900@gmail.com>
2026-01-29 11:18:23 +00:00

14 lines
391 B
TypeScript

import fs from "node:fs";
import path from "node:path";
import { generateSecret } from "@calcom/platform-libraries";
const [hashed, plain] = generateSecret();
const outputPath = path.join(__dirname, "..", ".generated-secrets");
const content = `plain - ${plain}\nhashed - ${hashed}\n`;
fs.writeFileSync(outputPath, content);
process.stdout.write(`Secrets written to: ${outputPath}\n`);