const SENSITIVE_ENV_PATTERNS = [/_KEY$/, /_SECRET$/, /_TOKEN$/, /_PASSWORD$/, /^API_KEY$/];
export function sanitizeEnvironment(env) {
    const sanitized = {};
    for (const [key, value] of Object.entries(env)) {
        if (value === undefined)
            continue;
        if (SENSITIVE_ENV_PATTERNS.some((pattern) => pattern.test(key))) {
            continue;
        }
        sanitized[key] = value;
    }
    return sanitized;
}
//# sourceMappingURL=sanitize_env.js.map