@sogni-ai/sogni-creative-agent-skill
Version:
Sogni Creative Agent Skill: agent skill and CLI for Sogni AI image, video, and music generation.
18 lines (14 loc) • 437 B
JavaScript
/**
* Centralized environment access so execution/networking modules do not read
* environment variables directly.
*/
const ENV = process.env;
export function getEnv(name, { trim = false } = {}) {
const value = ENV[name];
if (typeof value !== 'string') return undefined;
return trim ? value.trim() : value;
}
export function hasEnv(name) {
const value = ENV[name];
return typeof value === 'string' && value.length > 0;
}