natureco-cli 5.6.23 → 5.6.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "natureco-cli",
3
- "version": "5.6.23",
3
+ "version": "5.6.24",
4
4
  "description": "OpenClaw'dan daha güvenli, daha hızlı, daha ucuz AI agent CLI. Multi-agent, self-evolving skills, audit log, maliyet optimizasyonu ve NatureCo platform-native.",
5
5
  "bin": {
6
6
  "natureco": "bin/natureco.js"
@@ -74,6 +74,7 @@
74
74
  "node-telegram-bot-api": "^0.67.0",
75
75
  "openai": "^6.44.0",
76
76
  "pino": "^8.21.0",
77
+ "qrcode": "^1.5.4",
77
78
  "qrcode-terminal": "^0.12.0",
78
79
  "semver": "^7.8.1",
79
80
  "twilio": "^6.0.2",
@@ -1,6 +1,7 @@
1
1
  const chalk = require('chalk');
2
2
  const inquirer = require('../utils/inquirer-wrapper');
3
3
  const qrcode = require('qrcode-terminal');
4
+ const QRCode = require('qrcode');
4
5
  const fs = require('fs');
5
6
  const path = require('path');
6
7
  const os = require('os');
@@ -108,7 +109,22 @@ async function startWhatsAppConnection(sessionDir, botId, selectedBot, config) {
108
109
 
109
110
  // Display QR code in terminal
110
111
  qrcode.generate(qr, { small: true });
111
-
112
+
113
+ // v5.6.24: QR'i PNG olarak da kaydet, browserda ac
114
+ try {
115
+ const qrPngPath = path.join(sessionDir, 'qr.png');
116
+ await QRCode.toFile(qrPngPath, qr, {
117
+ type: 'png',
118
+ width: 600,
119
+ margin: 4,
120
+ color: { dark: '#000000', light: '#FFFFFF' }
121
+ });
122
+ console.log(chalk.green('\n📸 QR PNG kaydedildi: ' + qrPngPath));
123
+ console.log(chalk.cyan('🔗 Browserda acmak icin: open ' + qrPngPath));
124
+ } catch (e) {
125
+ // Sessizce gec, terminal QR yeterli
126
+ }
127
+
112
128
  console.log('');
113
129
  console.log(chalk.gray('1. WhatsApp\'ı açın'));
114
130
  console.log(chalk.gray('2. Ayarlar > Bağlı Cihazlar > Cihaz Bağla'));