MCPcopy Create free account
hub / github.com/sourcebot-dev/sourcebot / generateSecret

Function generateSecret

packages/setupWizard/src/utils.ts:70–72  ·  view source on GitHub ↗
(bytes: number)

Source from the content-addressed store, hash-verified

68}
69
70export function generateSecret(bytes: number): string {
71 return randomBytes(bytes).toString('base64');
72}
73
74export function toEnvKey(connectionName: string, suffix: string): string {
75 return `${connectionName.toUpperCase().replace(/-/g, '_')}_${suffix}`;

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected