top of page
import { Permissions, webMethod } from 'wix-web-module'; import { secrets } from 'wix-secrets-backend.v2'; import { elevate } from 'wix-auth'; const listSecrets = elevate(secrets.listSecretInfo); export const checkLoungeSecret = webMethod( Permissions.Admin, async () => { const result = await listSecrets(); const names = (Array.isArray(result) ? result : result.secrets || [] ).map(secret => secret.name); return { secretFound: names.includes("OPENAI_API_KEY"), numberOfSecrets: names.length }; } );
Bishop
Testing, testing! Is this thing on?
bottom of page
