Skip to content

A tiny friend in your Mac's notch and on your iPhone that keeps an eye on your AI coding agents: Claude Code, Codex, Cursor, Gemini CLI, Antigravity and more. Approve from the notch or your Lock Screen.

WhatsApp pill, phase 1: see incoming messages in the notch

Claude2a0c5682ec77
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index ef8263a4..b451e949 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -42,6 +42,9 @@ jobs:
- name: Test Notetaker transcript (speakers, echo, summary, Markdown)
run: bash scripts/test-notetaker.sh
+ - name: Test WhatsApp (gateway payloads, signatures, inbox, filters)
+ run: bash scripts/test-whatsapp.sh
+
- name: Desktop Mochi and gaze tests
run: bash scripts/test-desktop-mochi.sh
diff --git a/NotchBuddy/Resources/Info.plist b/NotchBuddy/Resources/Info.plist
index 20ec715b..9eb9fa21 100644
--- a/NotchBuddy/Resources/Info.plist
+++ b/NotchBuddy/Resources/Info.plist
@@ -48,6 +48,8 @@
<string>Coucou records what your Mac plays only while you note a call, to write down what the other people say.</string>
<key>NSContactsUsageDescription</key>
<string>Coucou looks up an email address when you ask it, by voice, to prepare an email.</string>
+ <key>NSFocusStatusUsageDescription</key>
+ <string>Coucou stays quiet about new WhatsApp messages while a Focus is on.</string>
<key>NSHighResolutionCapable</key>
<true/>
<key>NSMicrophoneUsageDescription</key>
diff --git a/NotchBuddy/Resources/Localizable.xcstrings b/NotchBuddy/Resources/Localizable.xcstrings
index a3131a0f..8e399247 100644
--- a/NotchBuddy/Resources/Localizable.xcstrings
+++ b/NotchBuddy/Resources/Localizable.xcstrings
@@ -1,6 +1,2866 @@
{
"sourceLanguage" : "en",
"strings" : {
+ "whatsapp.add" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "إضافة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "যোগ করো"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Add"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Añadir"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ajouter"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "जोड़ें"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tambah"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Adicionar"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Добавить"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "添加"
+ }
+ }
+ }
+ },
+ "whatsapp.connected-as %@" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "متصل باسم %@"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "%@ হিসেবে সংযুক্ত"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connected as %@"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado como %@"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connecté en tant que %@"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "%@ के रूप में कनेक्टेड"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Terhubung sebagai %@"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado como %@"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Подключено как %@"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "已连接:%@"
+ }
+ }
+ }
+ },
+ "whatsapp.credential.gowa" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "مصادقة أساسية (مستخدم:كلمة مرور، إن وُجدت)"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "বেসিক অথ (user:password, থাকলে)"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Basic auth (user:password, if set)"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Auth básica (usuario:contraseña, si la hay)"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Auth basique (utilisateur:mot de passe, si activée)"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "बेसिक ऑथ (user:password, अगर सेट हो)"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Basic auth (pengguna:sandi, jika ada)"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Auth básica (usuário:senha, se houver)"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Basic auth (пользователь:пароль, если задан)"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "基本认证(用户:密码,如已设置)"
+ }
+ }
+ }
+ },
+ "whatsapp.credential.openwa" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "مفتاح API (owa_k1_…)"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "API কী (owa_k1_…)"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "API key (owa_k1_…)"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Clave API (owa_k1_…)"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Clé API (owa_k1_…)"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "API कुंजी (owa_k1_…)"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Kunci API (owa_k1_…)"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Chave de API (owa_k1_…)"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "API-ключ (owa_k1_…)"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "API 密钥(owa_k1_…)"
+ }
+ }
+ }
+ },
+ "whatsapp.empty" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "لا رسائل جديدة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "নতুন বার্তা নেই"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "No new messages"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "No hay mensajes nuevos"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Aucun nouveau message"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "कोई नया संदेश नहीं"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tidak ada pesan baru"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Nenhuma mensagem nova"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Нет новых сообщений"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "没有新消息"
+ }
+ }
+ }
+ },
+ "whatsapp.enable" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "عرض رسائل واتساب"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "আমার WhatsApp বার্তা দেখাও"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Show my WhatsApp messages"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Mostrar mis mensajes de WhatsApp"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Afficher mes messages WhatsApp"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "मेरे WhatsApp संदेश दिखाएँ"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tampilkan pesan WhatsApp saya"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Mostrar minhas mensagens do WhatsApp"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Показывать мои сообщения WhatsApp"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "显示我的 WhatsApp 消息"
+ }
+ }
+ }
+ },
+ "whatsapp.focus-unavailable" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "لا يسمح macOS بعد لهذا الإصدار من Coucou بقراءة حالة التركيز: تستمر الرسائل في الوصول ويستمر Mochi في التفاعل."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS এখনও Coucou-র এই বিল্ডকে ফোকাসের অবস্থা পড়তে দেয় না: বার্তা আসতে থাকবে, Mochi সাড়া দিতে থাকবে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS doesn’t let this build of Coucou read the Focus state yet: messages still arrive, Mochi keeps reacting."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS aún no deja a esta versión de Coucou leer el estado de Concentración: los mensajes siguen llegando y Mochi sigue reaccionando."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS ne laisse pas encore cette version de Coucou lire l’état Concentration : les messages arrivent quand même, Mochi continue de réagir."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS अभी Coucou के इस बिल्ड को फ़ोकस की स्थिति पढ़ने नहीं देता: संदेश आते रहेंगे, Mochi प्रतिक्रिया देता रहेगा।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS belum mengizinkan build Coucou ini membaca status Fokus: pesan tetap masuk, Mochi tetap bereaksi."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O macOS ainda não deixa esta versão do Coucou ler o estado do Foco: as mensagens continuam chegando e o Mochi continua reagindo."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS пока не даёт этой сборке Coucou читать состояние фокусирования: сообщения приходят, Mochi реагирует."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "macOS 暂不允许此版本的 Coucou 读取专注状态:消息仍会到达,Mochi 仍会做出反应。"
+ }
+ }
+ }
+ },
+ "whatsapp.gateway" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "البوابة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Pasarela"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Passerelle"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关"
+ }
+ }
+ }
+ },
+ "whatsapp.ignore-chat" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "تجاهل هذه الدردشة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "এই চ্যাট উপেক্ষা করো"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ignore this chat"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ignorar este chat"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ignorer ce chat"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "इस चैट को अनदेखा करें"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Abaikan chat ini"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ignorar esta conversa"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Игнорировать этот чат"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "忽略此聊天"
+ }
+ }
+ }
+ },
+ "whatsapp.ignore-placeholder" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "رقم أو معرّف دردشة لتجاهله"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "উপেক্ষা করার নম্বর বা চ্যাট id"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Phone number or chat id to ignore"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Número o id de chat que ignorar"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Numéro ou identifiant de chat à ignorer"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "अनदेखा करने के लिए नंबर या चैट id"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Nomor atau id chat yang diabaikan"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Número ou id da conversa a ignorar"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Номер или id чата для игнорирования"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "要忽略的号码或聊天 ID"
+ }
+ }
+ }
+ },
+ "whatsapp.ignored" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "الدردشات المتجاهَلة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "উপেক্ষিত চ্যাট"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ignored chats"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Chats ignorados"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Chats ignorés"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "अनदेखी चैट"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Chat yang diabaikan"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conversas ignoradas"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Игнорируемые чаты"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "已忽略的聊天"
+ }
+ }
+ }
+ },
+ "whatsapp.media.contact" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "جهة اتصال"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "পরিচিতি"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Contact"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Contacto"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Contact"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "संपर्क"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Kontak"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Contato"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Контакт"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "联系人"
+ }
+ }
+ }
+ },
+ "whatsapp.media.document" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "مستند"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ডকুমেন্ট"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Document"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Documento"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Document"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "दस्तावेज़"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Dokumen"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Documento"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Документ"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "文档"
+ }
+ }
+ }
+ },
+ "whatsapp.media.location" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "موقع"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "লোকেশন"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Location"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ubicación"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Position"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "लोकेशन"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Lokasi"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Localização"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Местоположение"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "位置"
+ }
+ }
+ }
+ },
+ "whatsapp.media.other" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "رسالة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "বার্তা"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Message"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Mensaje"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Message"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "संदेश"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Pesan"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Mensagem"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Сообщение"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "消息"
+ }
+ }
+ }
+ },
+ "whatsapp.media.photo" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "صورة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ছবি"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Photo"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Foto"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Photo"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "फ़ोटो"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Foto"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Foto"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Фото"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "照片"
+ }
+ }
+ }
+ },
+ "whatsapp.media.sticker" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ملصق"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "স্টিকার"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Sticker"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Sticker"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Sticker"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "स्टिकर"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Stiker"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Figurinha"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Стикер"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "贴纸"
+ }
+ }
+ }
+ },
+ "whatsapp.media.video" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "فيديو"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ভিডিও"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Video"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Vídeo"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Vidéo"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "वीडियो"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Video"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Vídeo"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Видео"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "视频"
+ }
+ }
+ }
+ },
+ "whatsapp.media.voice" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "رسالة صوتية"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ভয়েস বার্তা"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Voice message"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Audio"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Vocal"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "वॉइस संदेश"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Pesan suara"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Áudio"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Голосовое"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "语音消息"
+ }
+ }
+ }
+ },
+ "whatsapp.mute-groups" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "كتم المجموعات (إلا إذا أُشير إليّ)"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গ্রুপ মিউট (আমাকে উল্লেখ না করলে)"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Mute groups (unless I’m mentioned)"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Silenciar grupos (salvo si me mencionan)"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Groupes muets (sauf si on me mentionne)"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ग्रुप म्यूट करें (जब तक मेरा ज़िक्र न हो)"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Bisukan grup (kecuali saya disebut)"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Silenciar grupos (exceto quando me mencionam)"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Без звука в группах (если меня не упомянули)"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "群组静音(除非提到我)"
+ }
+ }
+ }
+ },
+ "whatsapp.no-slot" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "أفرغ مكانًا في الحبوب النشطة لعرض حبة واتساب (4 كحد أقصى)."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp পিল দেখাতে সক্রিয় পিলে জায়গা খালি করুন (সর্বোচ্চ ৪টি)।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Make room in Active pills to show the WhatsApp pill (4 at most)."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Libera un hueco en Píldoras activas para mostrar la de WhatsApp (4 como máximo)."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Libère une place dans Pills actives pour afficher la pill WhatsApp (4 au maximum)."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp पिल दिखाने के लिए सक्रिय पिल्स में जगह बनाएँ (अधिकतम 4)।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Kosongkan tempat di Pil aktif untuk menampilkan pil WhatsApp (maksimal 4)."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Libere um espaço em Pílulas ativas para mostrar a do WhatsApp (no máximo 4)."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Освободите место в активных пилюлях для WhatsApp (не больше 4)."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "请在“活跃胶囊”中腾出位置以显示 WhatsApp(最多 4 个)。"
+ }
+ }
+ }
+ },
+ "whatsapp.port" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "منفذ webhook في Coucou"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou-র ওয়েবহুক পোর্ট"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou’s webhook port"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Puerto del webhook de Coucou"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Port du webhook de Coucou"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou का वेबहुक पोर्ट"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Port webhook Coucou"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Porta do webhook do Coucou"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Порт вебхука Coucou"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou 的 Webhook 端口"
+ }
+ }
+ }
+ },
+ "whatsapp.privacy" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "يتواصل Coucou فقط مع البوابة على هذا الـMac. تبقى الرسائل في الذاكرة، ولا تُسجَّل ولا تُحفَظ أبدًا، وتُنسى عند إغلاق Coucou. لا تُنزَّل أي صورة أو وسائط."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou শুধু এই Mac-এর গেটওয়ের সঙ্গে কথা বলে। বার্তা মেমরিতে থাকে, কখনও লগ বা সেভ হয় না, এবং Coucou বন্ধ হলে মুছে যায়। কোনো ছবি বা মিডিয়া ডাউনলোড হয় না।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou only talks to the gateway on this Mac. Messages stay in memory, are never logged or saved, and are forgotten when Coucou quits. No photo or media is ever downloaded."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou solo habla con la pasarela de este Mac. Los mensajes se quedan en memoria, nunca se registran ni se guardan, y se olvidan al cerrar Coucou. Nunca se descarga ninguna foto ni archivo."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou ne parle qu’à la passerelle sur ce Mac. Les messages restent en mémoire, ne sont jamais journalisés ni enregistrés, et sont oubliés quand Coucou quitte. Aucune photo ni aucun média n’est téléchargé."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou सिर्फ़ इस Mac पर चल रहे गेटवे से बात करता है। संदेश मेमोरी में रहते हैं, कभी लॉग या सेव नहीं होते, और Coucou बंद होने पर भुला दिए जाते हैं। कोई फ़ोटो या मीडिया डाउनलोड नहीं होता।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou hanya berbicara dengan gateway di Mac ini. Pesan tetap di memori, tidak pernah dicatat atau disimpan, dan dilupakan saat Coucou ditutup. Tidak ada foto atau media yang diunduh."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O Coucou só fala com o gateway neste Mac. As mensagens ficam na memória, nunca são registradas nem salvas e são esquecidas quando o Coucou fecha. Nenhuma foto ou mídia é baixada."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou общается только со шлюзом на этом Mac. Сообщения хранятся в памяти, никогда не пишутся в журнал и не сохраняются, и забываются при выходе из Coucou. Фото и медиа не загружаются."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Coucou 只与这台 Mac 上的网关通信。消息只保存在内存中,从不记录或保存,退出 Coucou 时即被清除。从不下载任何照片或媒体。"
+ }
+ }
+ }
+ },
+ "whatsapp.qr.hint" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "على هاتفك: واتساب › الإعدادات › الأجهزة المرتبطة › ربط جهاز، ثم امسح هذا الرمز."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ফোনে: WhatsApp › সেটিংস › লিঙ্ক করা ডিভাইস › ডিভাইস লিঙ্ক করুন, তারপর এই কোডটি স্ক্যান করুন।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "On your phone: WhatsApp › Settings › Linked devices › Link a device, then scan this code."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "En tu teléfono: WhatsApp › Ajustes › Dispositivos vinculados › Vincular un dispositivo, y escanea este código."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Sur ton téléphone : WhatsApp › Réglages › Appareils connectés › Connecter un appareil, puis scanne ce code."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "फ़ोन पर: WhatsApp › सेटिंग्स › लिंक किए गए डिवाइस › डिवाइस लिंक करें, फिर यह कोड स्कैन करें।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Di ponsel: WhatsApp › Setelan › Perangkat tertaut › Tautkan perangkat, lalu pindai kode ini."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "No celular: WhatsApp › Configurações › Dispositivos conectados › Conectar dispositivo, e escaneie este código."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "На телефоне: WhatsApp › Настройки › Связанные устройства › Привязка устройства, затем отсканируйте этот код."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "在手机上:WhatsApp › 设置 › 已关联的设备 › 关联新设备,然后扫描此二维码。"
+ }
+ }
+ }
+ },
+ "whatsapp.remove" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "إزالة"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "সরাও"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Remove"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Quitar"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Retirer"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "हटाएँ"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Hapus"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Remover"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Убрать"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "移除"
+ }
+ }
+ }
+ },
+ "whatsapp.respect-focus" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "التزام الهدوء أثناء التركيز"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "ফোকাসের সময় চুপ থাকো"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Stay quiet during a Focus"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "No molestar durante un modo Concentración"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Rester discret pendant une Concentration"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "फ़ोकस के दौरान शांत रहें"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tetap tenang saat mode Fokus"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ficar quieto durante um Foco"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Не беспокоить в режиме фокусирования"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "专注模式期间保持安静"
+ }
+ }
+ }
+ },
+ "whatsapp.status.bad-url" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "عنوان البوابة غير صالح (http://…)"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ের URL সঠিক নয় (http://…)"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway URL isn’t valid (http://…)"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La URL de la pasarela no es válida (http://…)"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "L’URL de la passerelle n’est pas valide (http://…)"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे URL मान्य नहीं है (http://…)"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "URL gateway tidak valid (http://…)"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "A URL do gateway não é válida (http://…)"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Неверный адрес шлюза (http://…)"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关地址无效(http://…)"
+ }
+ }
+ }
+ },
+ "whatsapp.status.connected" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "متصل"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "সংযুক্ত"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connected"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connecté"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "कनेक्टेड"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Terhubung"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Подключено"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "已连接"
+ }
+ }
+ }
+ },
+ "whatsapp.status.connecting" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "جارٍ الاتصال بالبوابة…"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়েতে সংযুক্ত হচ্ছে…"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connecting to the gateway…"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectando con la pasarela…"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connexion à la passerelle…"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे से जुड़ रहा है…"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Menghubungkan ke gateway…"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectando ao gateway…"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Подключение к шлюзу…"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "正在连接网关…"
+ }
+ }
+ }
+ },
+ "whatsapp.status.needs-qr" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "امسح رمز QR في الإعدادات"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "সেটিংসে QR কোড স্ক্যান করুন"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Scan the QR code in Settings"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Escanea el código QR en Ajustes"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Scanne le QR code dans les réglages"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "सेटिंग्स में QR कोड स्कैन करें"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Pindai kode QR di Pengaturan"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Escaneie o QR code nos Ajustes"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Отсканируйте QR-код в настройках"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "请在设置中扫描二维码"
+ }
+ }
+ }
+ },
+ "whatsapp.status.off" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "متوقف في الإعدادات"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "সেটিংসে বন্ধ"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Turned off in Settings"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Desactivado en Ajustes"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Désactivé dans les réglages"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "सेटिंग्स में बंद है"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Dimatikan di Pengaturan"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Desativado nos Ajustes"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Выключено в настройках"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "已在设置中关闭"
+ }
+ }
+ }
+ },
+ "whatsapp.status.unauthorized" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "البوابة ترفض بيانات الاعتماد"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে পরিচয়পত্র প্রত্যাখ্যান করছে"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway refuses the credentials"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La pasarela rechaza las credenciales"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La passerelle refuse les identifiants"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे ने क्रेडेंशियल अस्वीकार किए"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway menolak kredensial"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O gateway recusa as credenciais"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз отклоняет учётные данные"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关拒绝了凭据"
+ }
+ }
+ }
+ },
+ "whatsapp.status.unreachable" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "البوابة لا تستجيب: هل هي قيد التشغيل؟"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে সাড়া দিচ্ছে না: এটি চালু আছে?"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway doesn’t answer: is it running?"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La pasarela no responde: ¿está en marcha?"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La passerelle ne répond pas : est-elle lancée ?"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे जवाब नहीं दे रहा: क्या वह चल रहा है?"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway tidak merespons: apakah sedang berjalan?"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O gateway não responde: ele está rodando?"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз не отвечает: он запущен?"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关没有响应:它在运行吗?"
+ }
+ }
+ }
+ },
+ "whatsapp.test" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "اختبار الاتصال"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "সংযোগ পরীক্ষা"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Test connection"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Probar la conexión"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tester la connexion"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "कनेक्शन जाँचें"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Uji koneksi"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Testar a conexão"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Проверить подключение"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "测试连接"
+ }
+ }
+ }
+ },
+ "whatsapp.test.connected %@" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "متصل باسم %@."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "%@ হিসেবে সংযুক্ত।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connected as %@."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado como %@."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Connecté en tant que %@."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "%@ के रूप में कनेक्टेड।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Terhubung sebagai %@."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Conectado como %@."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Подключено как %@."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "已连接:%@。"
+ }
+ }
+ }
+ },
+ "whatsapp.test.connecting" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "البوابة تستجيب وتتصل بواتساب…"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে সাড়া দিচ্ছে এবং WhatsApp-এ সংযুক্ত হচ্ছে…"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway answers and is connecting to WhatsApp…"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La pasarela responde y se está conectando a WhatsApp…"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La passerelle répond et se connecte à WhatsApp…"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे जवाब दे रहा है और WhatsApp से जुड़ रहा है…"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway merespons dan sedang terhubung ke WhatsApp…"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O gateway responde e está se conectando ao WhatsApp…"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз отвечает и подключается к WhatsApp…"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关有响应,正在连接 WhatsApp…"
+ }
+ }
+ }
+ },
+ "whatsapp.test.needs-qr" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "البوابة تستجيب. امسح رمز QR أدناه بهاتفك."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে সাড়া দিচ্ছে। নিচের QR কোডটি ফোনে স্ক্যান করুন।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway answers. Scan the QR code below with your phone."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La pasarela responde. Escanea el código QR de abajo con tu teléfono."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La passerelle répond. Scanne le QR code ci-dessous avec ton téléphone."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे जवाब दे रहा है। नीचे दिया QR कोड फ़ोन से स्कैन करें।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway merespons. Pindai kode QR di bawah dengan ponselmu."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O gateway responde. Escaneie o QR code abaixo com o celular."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз отвечает. Отсканируйте QR-код ниже телефоном."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关有响应。请用手机扫描下面的二维码。"
+ }
+ }
+ }
+ },
+ "whatsapp.title" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "واتساب (تجريبي)"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (পরীক্ষামূলক)"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (experimental)"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (experimental)"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (expérimental)"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (प्रायोगिक)"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (eksperimental)"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (experimental)"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp (экспериментально)"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "WhatsApp(实验性)"
+ }
+ }
+ }
+ },
+ "whatsapp.warning" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "تكامل غير رسمي: يمرّ عبر بوابة تشغّلها على هذا الـMac. استخدمه على حسابك فقط. قد يقيّد واتساب الحسابات عند إساءة الاستخدام."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "অনানুষ্ঠানিক ইন্টিগ্রেশন: এটি এই Mac-এ চালানো একটি গেটওয়ে দিয়ে কাজ করে। শুধু নিজের অ্যাকাউন্টে ব্যবহার করুন। অপব্যবহারে WhatsApp অ্যাকাউন্ট সীমিত করতে পারে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Unofficial integration: it goes through a gateway you run on this Mac. Use it on your own account only. WhatsApp may restrict accounts that abuse it."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Integración no oficial: pasa por una pasarela que ejecutas en este Mac. Úsala solo con tu propia cuenta. WhatsApp puede restringir las cuentas que abusen."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Intégration non officielle : elle passe par une passerelle que tu lances sur ce Mac. À utiliser sur ton propre compte uniquement. WhatsApp peut restreindre un compte en cas d’abus."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "अनौपचारिक इंटीग्रेशन: यह इस Mac पर चल रहे गेटवे से होकर काम करता है। सिर्फ़ अपने अकाउंट पर इस्तेमाल करें। दुरुपयोग पर WhatsApp अकाउंट सीमित कर सकता है।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Integrasi tidak resmi: berjalan lewat gateway yang kamu jalankan di Mac ini. Gunakan hanya di akunmu sendiri. WhatsApp bisa membatasi akun yang menyalahgunakannya."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Integração não oficial: passa por um gateway que você executa neste Mac. Use só na sua própria conta. O WhatsApp pode restringir contas em caso de abuso."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Неофициальная интеграция: работает через шлюз, запущенный на этом Mac. Используйте только со своим аккаунтом. WhatsApp может ограничить аккаунт при злоупотреблении."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "非官方集成:通过你在这台 Mac 上运行的网关工作。仅限用于你自己的账号。滥用时 WhatsApp 可能会限制账号。"
+ }
+ }
+ }
+ },
+ "whatsapp.webhook.live" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "مباشر: تصل الرسائل الجديدة فورًا."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "লাইভ: নতুন বার্তা সঙ্গে সঙ্গে আসে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Live: new messages arrive at once."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "En directo: los mensajes nuevos llegan al instante."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "En direct : les nouveaux messages arrivent tout de suite."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "लाइव: नए संदेश तुरंत आते हैं।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Langsung: pesan baru datang seketika."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Ao vivo: as novas mensagens chegam na hora."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "В реальном времени: новые сообщения приходят сразу."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "实时:新消息会立即送达。"
+ }
+ }
+ }
+ },
+ "whatsapp.webhook.polling" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "التحقق من الرسائل الجديدة كل 20 ث."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "প্রতি ২০ সেকেন্ডে নতুন বার্তা দেখা হচ্ছে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Checking for new messages every 20 s."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Comprobando mensajes nuevos cada 20 s."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Vérification des nouveaux messages toutes les 20 s."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "हर 20 सेकंड में नए संदेश जाँचे जा रहे हैं।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Memeriksa pesan baru setiap 20 dtk."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Verificando novas mensagens a cada 20 s."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Проверка новых сообщений каждые 20 с."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "每 20 秒检查一次新消息。"
+ }
+ }
+ }
+ },
+ "whatsapp.webhook.port-busy %lld" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "المنفذ %lld مستخدم: اختر منفذًا آخر. في الأثناء يتم التحقق كل 20 ث."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "পোর্ট %lld ব্যস্ত: অন্যটি বেছে নিন। ততক্ষণ প্রতি ২০ সেকেন্ডে দেখা হচ্ছে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Port %lld is taken: pick another one. Checking every 20 s meanwhile."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "El puerto %lld está ocupado: elige otro. Mientras tanto, se comprueba cada 20 s."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Le port %lld est déjà pris : choisis-en un autre. Vérification toutes les 20 s en attendant."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "पोर्ट %lld पहले से इस्तेमाल में है: कोई और चुनें। तब तक हर 20 सेकंड में जाँच।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Port %lld sudah dipakai: pilih yang lain. Sementara itu diperiksa setiap 20 dtk."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "A porta %lld está ocupada: escolha outra. Enquanto isso, verificando a cada 20 s."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Порт %lld занят: выберите другой. Пока проверка каждые 20 с."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "端口 %lld 已被占用:请换一个。在此期间每 20 秒检查一次。"
+ }
+ }
+ }
+ },
+ "whatsapp.webhook.refused %@" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "رفضت البوابة عنوان Coucou ‏(%@). يتم التحقق كل 20 ث بدلًا من ذلك."
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "গেটওয়ে Coucou-র ঠিকানা প্রত্যাখ্যান করেছে (%@)। এর বদলে প্রতি ২০ সেকেন্ডে দেখা হচ্ছে।"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "The gateway refused Coucou’s address (%@). Checking every 20 s instead."
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La pasarela rechazó la dirección de Coucou (%@). Se comprueba cada 20 s en su lugar."
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "La passerelle a refusé l’adresse de Coucou (%@). Vérification toutes les 20 s à la place."
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "गेटवे ने Coucou का पता अस्वीकार किया (%@)। इसके बजाय हर 20 सेकंड में जाँच।"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Gateway menolak alamat Coucou (%@). Sebagai gantinya diperiksa setiap 20 dtk."
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "O gateway recusou o endereço do Coucou (%@). Verificando a cada 20 s no lugar."
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Шлюз отклонил адрес Coucou (%@). Вместо этого проверка каждые 20 с."
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "网关拒绝了 Coucou 的地址(%@)。改为每 20 秒检查一次。"
+ }
+ }
+ }
+ },
+ "whatsapp.you" : {
+ "extractionState" : "manual",
+ "localizations" : {
+ "ar" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "أنت"
+ }
+ },
+ "bn" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "আপনি"
+ }
+ },
+ "en" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "You"
+ }
+ },
+ "es" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Tú"
+ }
+ },
+ "fr" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Toi"
+ }
+ },
+ "hi" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "आप"
+ }
+ },
+ "id" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Kamu"
+ }
+ },
+ "pt-BR" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Você"
+ }
+ },
+ "ru" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "Вы"
+ }
+ },
+ "zh-Hans" : {
+ "stringUnit" : {
+ "state" : "translated",
+ "value" : "你"
+ }
+ }
+ }
+ },
"Agent" : {
"extractionState" : "manual",
"localizations" : {
diff --git a/NotchBuddy/Sources/App/AppDelegate.swift b/NotchBuddy/Sources/App/AppDelegate.swift
index 4321ae2b..cb5fb24e 100644
--- a/NotchBuddy/Sources/App/AppDelegate.swift
+++ b/NotchBuddy/Sources/App/AppDelegate.swift
@@ -292,6 +292,7 @@ final class AppDelegate: NSObject, NSApplicationDelegate {
_ = MusicController.shared
_ = SpotifyController.shared
MailController.shared.start()
+ WhatsAppController.shared.start()
#endif
CryptoController.shared.start()
PortfolioController.shared.start()
diff --git a/NotchBuddy/Sources/App/ClaudeService.swift b/NotchBuddy/Sources/App/ClaudeService.swift
index ac4809ce..bf32ae4e 100644
--- a/NotchBuddy/Sources/App/ClaudeService.swift
+++ b/NotchBuddy/Sources/App/ClaudeService.swift
@@ -75,6 +75,8 @@ final class KeychainStore: @unchecked Sendable {
"calcom-api-key",
"notion-api-key",
"elevenlabs-api-key",
+ // WhatsApp (local gateway): its address, credentials and the webhook's signing secret
+ "whatsapp-url", "whatsapp-api-key", "whatsapp-webhook-secret",
// Portfolio exchange credentials
"portfolio-binance-key", "portfolio-binance-secret",
"portfolio-okx-key", "portfolio-okx-secret", "portfolio-okx-passphrase",
diff --git a/NotchBuddy/Sources/App/IslandViewContent.swift b/NotchBuddy/Sources/App/IslandViewContent.swift
index 883eb1b6..18e3f695 100644
--- a/NotchBuddy/Sources/App/IslandViewContent.swift
+++ b/NotchBuddy/Sources/App/IslandViewContent.swift
@@ -231,6 +231,12 @@ struct OverviewView: View {
#if !APPSTORE
MailController.shared.openMail()
#endif
+ case "integration_whatsapp":
+ #if !APPSTORE
+ if let url = NSWorkspace.shared.urlForApplication(withBundleIdentifier: "net.whatsapp.WhatsApp") {
+ NSWorkspace.shared.openApplication(at: url, configuration: .init(), completionHandler: nil)
+ }
+ #endif
case "integration_crypto":
let exchange = CryptoSettings.exchange
if let first = CryptoSettings.coins.first,
@@ -1936,6 +1942,12 @@ struct IntegrationCardView: View {
#else
return false
#endif
+ case "integration_whatsapp":
+ #if !APPSTORE
+ return WhatsAppSettings.enabled
+ #else
+ return false
+ #endif
case "integration_crypto":
return true // public market data: no key, nothing to set up
case "integration_portfolio":
@@ -2195,6 +2207,12 @@ struct IntegrationCardView: View {
} else if task.id == "integration_portfolio" {
PortfolioCardView()
.transition(.opacity)
+ } else if task.id == "integration_whatsapp" {
+ // Its own card in every state (not linked, no message, conversations).
+ #if !APPSTORE
+ WhatsAppCardView()
+ .transition(.opacity)
+ #endif
} else if mailHasData {
#if !APPSTORE
MailCardView()
diff --git a/NotchBuddy/Sources/App/SettingsView.swift b/NotchBuddy/Sources/App/SettingsView.swift
index c7663733..a08fc6f2 100644
--- a/NotchBuddy/Sources/App/SettingsView.swift
+++ b/NotchBuddy/Sources/App/SettingsView.swift
@@ -1358,6 +1358,12 @@ struct SettingsView: View {
PortfolioSettingsSection()
.padding(.top, 4)
+ #if !APPSTORE
+ // WhatsApp through a local gateway: its own fields, saved by its own button.
+ WhatsAppSettingsSection()
+ .padding(.top, 4)
+ #endif
+
Button(String(localized: "integrations.save")) {
saveIntegrations()
CryptoController.shared.settingsChanged()
diff --git a/NotchBuddy/Sources/App/WhatsAppController.swift b/NotchBuddy/Sources/App/WhatsAppController.swift
new file mode 100644
index 00000000..e873286c
--- /dev/null
+++ b/NotchBuddy/Sources/App/WhatsAppController.swift
@@ -0,0 +1,477 @@
+#if !APPSTORE
+import Foundation
+import AppKit
+import Combine
+import Intents
+
+// MARK: - Settings
+
+/// WhatsApp's choices (Settings → Integrations → WhatsApp). Secrets (gateway URL, credentials,
+/// webhook secret) live in the Keychain; only harmless choices go to UserDefaults.
+enum WhatsAppSettings {
+ static let urlKey = "whatsapp-url"
+ static let credentialKey = "whatsapp-api-key"
+ static let secretKey = "whatsapp-webhook-secret"
+ static let defaultPort = 47823
+
+ private static var ud: UserDefaults { .standard }
+
+ static var enabled: Bool {
+ get { ud.bool(forKey: "whatsappEnabled") }
+ set { ud.set(newValue, forKey: "whatsappEnabled") }
+ }
+ static var gateway: WAGatewayKind {
+ get { WAGatewayKind(rawValue: ud.string(forKey: "whatsappGateway") ?? "") ?? .gowa }
+ set { ud.set(newValue.rawValue, forKey: "whatsappGateway") }
+ }
+ static var port: Int {
+ get { let p = ud.integer(forKey: "whatsappPort"); return (1024...65535).contains(p) ? p : defaultPort }
+ set { ud.set(newValue, forKey: "whatsappPort") }
+ }
+ static var respectFocus: Bool {
+ get { ud.object(forKey: "whatsappRespectFocus") as? Bool ?? true }
+ set { ud.set(newValue, forKey: "whatsappRespectFocus") }
+ }
+ static var filters: WAFilters {
+ get {
+ WAFilters(muteGroups: ud.object(forKey: "whatsappMuteGroups") as? Bool ?? true,
+ ignored: Set(ud.stringArray(forKey: "whatsappIgnored") ?? []))
+ }
+ set {
+ ud.set(newValue.muteGroups, forKey: "whatsappMuteGroups")
+ ud.set(Array(newValue.ignored).sorted(), forKey: "whatsappIgnored")
+ }
+ }
+
+ static var url: String {
+ KeychainStore.shared.get(urlKey) ?? gateway.defaultURL
+ }
+
+ /// The webhook's signing secret, made once (random, 64 hex characters).
+ static func webhookSecret() -> String {
+ if let s = KeychainStore.shared.get(secretKey), s.count >= 16 { return s }
+ var bytes = [UInt8](repeating: 0, count: 32)
+ for i in bytes.indices { bytes[i] = UInt8.random(in: 0...255) }
+ let s = Data(bytes).waHex
+ KeychainStore.shared.set(secretKey, value: s)
+ return s
+ }
+
+ static func makeProvider() -> WhatsAppProvider? {
+ guard let base = URL(string: url.trimmingCharacters(in: .whitespaces)), base.scheme?.hasPrefix("http") == true else { return nil }
+ let credential = KeychainStore.shared.get(credentialKey)
+ switch gateway {
+ case .gowa: return GOWAProvider(base: base, basicAuth: credential)
+ case .openwa: return OpenWAProvider(base: base, apiKey: credential)
+ }
+ }
+}
+
+// MARK: - Controller
+
+/// WhatsApp in the notch (GitHub build only). Talks to the local gateway the user runs (GOWA
+/// or OpenWA), receives new messages on a webhook bound to 127.0.0.1, falls back to polling
+/// when no webhook comes, and keeps the conversations in memory only: nothing of a message is
+/// ever written to disk or to a log, and everything is forgotten when Coucou quits or the
+/// integration is turned off. Runs only while the integration is on and its pill is active.
+@MainActor
+final class WhatsAppController: ObservableObject {
+ static let shared = WhatsAppController()
+ nonisolated static let pillId = "integration_whatsapp"
+ nonisolated static let webhookPath = "/whatsapp"
+
+ enum Link: Equatable {
+ case off
+ case connecting
+ /// The gateway runs, WhatsApp isn't linked: the QR is shown in Settings.
+ case needsQR
+ case connected
+ case unreachable
+ case unauthorized
+ case failed(String)
+ }
+
+ enum Webhook: Equatable {
+ case off
+ /// Listening on the port, not yet accepted by the gateway.
+ case listening
+ /// The gateway accepted the address: messages should come on their own.
+ case registered
+ /// The gateway refused it (its message): polling instead.
+ case refused(String)
+ /// The port is taken.
+ case portBusy
+ }
+
+ @Published private(set) var inbox = WAInbox()
+ @Published private(set) var link: Link = .off
+ @Published private(set) var webhook: Webhook = .off
+ @Published private(set) var qrPNG: Data?
+ /// This account (JID or number), once linked.
+ @Published private(set) var me: String?
+ /// Whether macOS lets Coucou read the Focus state (nil: not asked yet).
+ @Published private(set) var focusReadable: Bool?
+ @Published var filters = WhatsAppSettings.filters {
+ didSet { WhatsAppSettings.filters = filters }
+ }
+
+ var visibleConversations: [WAConversation] { inbox.visible(filters: filters) }
+
+ private var provider: WhatsAppProvider?
+ private let listener = WhatsAppWebhook()
+ private var timer: Timer?
+ private var tick = 0
+ private var refreshing = false
+ private var polling = false
+ private var backfilled = false
+ private var qrExpiry: Date = .distantPast
+ private var lastWebhook: Date?
+ private var lastPoll = Date()
+ private var lastAnnounce: Date = .distantPast
+ private var namingGroups: Set<String> = []
+ private var cancellables = Set<AnyCancellable>()
+
+ private var shouldRun: Bool {
+ WhatsAppSettings.enabled && AppState.shared.activeIntegrations.contains(Self.pillId)
+ }
+
+ private init() {
+ // Pill turned on or off from anywhere: follow it on the next turn (the sink runs
+ // before the property changes).
+ AppState.shared.$activeIntegrations
+ .map { $0.contains(Self.pillId) }
+ .removeDuplicates()
+ .sink { [weak self] _ in DispatchQueue.main.async { self?.update() } }
+ .store(in: &cancellables)
+ // Back from sleep: ask the gateway again at once.
+ NSWorkspace.shared.notificationCenter.publisher(for: NSWorkspace.didWakeNotification)
+ .sink { [weak self] _ in
+ DispatchQueue.main.asyncAfter(deadline: .now() + 3) { self?.wake() }
+ }
+ .store(in: &cancellables)
+ }
+
+ /// Called once at launch.
+ func start() { update() }
+
+ /// Settings changed (turned on/off, gateway, URL, credentials, port): start over.
+ func settingsChanged() {
+ stop(forget: !shouldRun)
+ update()
+ }
+
+ /// Turns the integration on or off; on also makes room for its pill when a slot is free.
+ func setEnabled(_ on: Bool) {
+ WhatsAppSettings.enabled = on
+ let state = AppState.shared
+ if on, !state.activeIntegrations.contains(Self.pillId), state.activeIntegrations.count < 4 {
+ state.toggleIntegration(Self.pillId)
+ } else if !on, state.activeIntegrations.contains(Self.pillId) {
+ state.toggleIntegration(Self.pillId)
+ }
+ settingsChanged()
+ }
+
+ private func update() {
+ if shouldRun && provider == nil { begin() }
+ else if !shouldRun && provider != nil { stop(forget: true) }
+ }
+
+ // MARK: - Lifecycle
+
+ private func begin() {
+ guard let provider = WhatsAppSettings.makeProvider() else {
+ link = .failed(String(localized: "whatsapp.status.bad-url"))
+ return
+ }
+ self.provider = provider
+ link = .connecting
+ startListener(kind: provider.kind)
+ if WhatsAppSettings.respectFocus { askFocus() }
+ let t = Timer(timeInterval: 5, repeats: true) { _ in
+ MainActor.assumeIsolated { WhatsAppController.shared.onTick() }
+ }
+ t.tolerance = 2
+ RunLoop.main.add(t, forMode: .common)
+ timer = t
+ refresh()
+ }
+
+ /// Stops talking to the gateway. `forget`: the conversations go too.
+ private func stop(forget: Bool) {
+ timer?.invalidate()
+ timer = nil
+ listener.stop()
+ provider = nil
+ link = .off
+ webhook = .off
+ qrPNG = nil
+ me = nil
+ backfilled = false
+ lastWebhook = nil
+ namingGroups = []
+ if forget {
+ inbox.clear()
+ resetTask()
+ }
+ }
+
+ private func wake() {
+ guard provider != nil else { return }
+ // Nothing is trusted after a sleep: the gateway may have restarted without Coucou's webhook.
+ webhook = webhook == .portBusy ? .portBusy : .listening
+ lastWebhook = nil
+ refresh()
+ }
+
+ private func onTick() {
+ tick += 1
+ if link != .connected {
+ refresh() // every 5 s while linking (QR, gateway coming up)
+ } else {
+ if tick % 12 == 0 { refresh() } // every minute: still linked?
+ if tick % 4 == 0 { poll() } // every 20 s, unless the webhook delivers
+ }
+ }
+
+ // MARK: - Status and QR
+
+ func refresh() {
+ guard let provider, !refreshing else { return }
+ refreshing = true
+ Task {
+ defer { refreshing = false }
+ do {
+ let status = try await provider.status()
+ guard self.provider != nil else { return }
+ me = status.me
+ switch status.link {
+ case .connected:
+ if link != .connected { qrPNG = nil }
+ link = .connected
+ if webhook == .listening { await register(provider) }
+ if !backfilled { await backfill(provider) }
+ case .needsQR:
+ link = .needsQR
+ if qrPNG == nil || Date() > qrExpiry {
+ if let qr = try await provider.qrCode() {
+ qrPNG = qr.png
+ qrExpiry = Date().addingTimeInterval(TimeInterval(qr.seconds))
+ }
+ }
+ case .connecting:
+ link = .connecting
+ }
+ } catch let error as WAError {
+ apply(error)
+ } catch {
+ link = .unreachable
+ }
+ }
+ }
+
+ private func apply(_ error: WAError) {
+ switch error {
+ case .unreachable: link = .unreachable
+ case .unauthorized: link = .unauthorized
+ case .notLoggedIn: link = .needsQR
+ case .refused(let why): link = .failed(why)
+ }
+ }
+
+ /// One check from Settings' "Test connection": what the gateway says, in a sentence.
+ func testConnection() async -> String {
+ guard let provider = WhatsAppSettings.makeProvider() else { return String(localized: "whatsapp.status.bad-url") }
+ do {
+ let status = try await provider.status()
+ switch status.link {
+ case .connected:
+ let who = status.me.map(WAJID.displayNumber) ?? ""
+ return String(format: String(localized: "whatsapp.test.connected %@"), who)
+ case .needsQR: return String(localized: "whatsapp.test.needs-qr")
+ case .connecting: return String(localized: "whatsapp.test.connecting")
+ }
+ } catch let error as WAError {
+ switch error {
+ case .unreachable: return String(localized: "whatsapp.status.unreachable")
+ case .unauthorized: return String(localized: "whatsapp.status.unauthorized")
+ case .notLoggedIn: return String(localized: "whatsapp.test.needs-qr")
+ case .refused(let why): return why
+ }
+ } catch {
+ return String(localized: "whatsapp.status.unreachable")
+ }
+ }
+
+ // MARK: - Webhook
+
+ private func startListener(kind: WAGatewayKind) {
+ let secret = WhatsAppSettings.webhookSecret()
+ listener.onRequest = { request in
+ guard request.method == "POST", request.path.hasPrefix(WhatsAppController.webhookPath) else { return 404 }
+ // Signed by the gateway with Coucou's secret, over the exact bytes received.
+ guard WAWebhook.verify(kind: kind, headers: request.headers, body: request.body, secret: secret) else { return 401 }
+ let body = request.body
+ Task { @MainActor in WhatsAppController.shared.received(body, kind: kind) }
+ return 200
+ }
+ listener.onListening = { ok in
+ Task { @MainActor in
+ let c = WhatsAppController.shared
+ guard c.provider != nil else { return }
+ if !ok { c.webhook = .portBusy }
+ else if c.webhook == .off || c.webhook == .portBusy { c.webhook = .listening; c.refresh() }
+ }
+ }
+ if !listener.start(port: UInt16(WhatsAppSettings.port)) { webhook = .portBusy }
+ }
+
+ private var webhookURL: String { "http://127.0.0.1:\(WhatsAppSettings.port)\(Self.webhookPath)" }
+
+ private func register(_ provider: WhatsAppProvider) async {
+ do {
+ try await provider.registerWebhook(url: webhookURL, secret: WhatsAppSettings.webhookSecret())
+ if self.provider != nil { webhook = .registered }
+ } catch WAError.refused(let why) {
+ webhook = .refused(why)
+ appendAppLog("nb.log", "[WhatsApp] gateway refused the webhook: \(why)")
+ } catch {
+ // Tried again on the next minute's check.
+ }
+ }
+
+ private func received(_ body: Data, kind: WAGatewayKind) {
+ guard provider != nil else { return }
+ lastWebhook = Date()
+ if webhook != .registered { webhook = .registered }
+ guard case .message(let message)? = WAWebhook.parse(kind: kind, body: body, me: me) else { return }
+ ingest([message], announce: true)
+ }
+
+ /// True while webhooks keep coming: no need to poll.
+ private var webhookAlive: Bool {
+ guard let lastWebhook else { return false }
+ return Date().timeIntervalSince(lastWebhook) < 300
+ }
+
+ // MARK: - Messages
+
+ /// The last hours of history, once linked: kept, but nothing counts as new.
+ private func backfill(_ provider: WhatsAppProvider) async {
+ backfilled = true
+ let since = Date().addingTimeInterval(-12 * 3600)
+ guard let messages = try? await provider.recentMessages(since: since, me: me), self.provider != nil else { return }
+ ingest(messages, announce: false)
+ inbox.markAllRead()
+ lastPoll = Date()
+ }
+
+ private func poll() {
+ guard let provider, !polling, !webhookAlive, backfilled else { return }
+ polling = true
+ let since = lastPoll.addingTimeInterval(-30) // a little overlap; duplicates are dropped
+ let started = Date()
+ Task {
+ defer { polling = false }
+ guard let messages = try? await provider.recentMessages(since: since, me: me), self.provider != nil else { return }
+ lastPoll = started
+ ingest(messages, announce: true)
+ }
+ }
+
+ private func ingest(_ messages: [WAMessage], announce: Bool) {
+ var fresh: WAMessage?
+ for message in messages {
+ let outcome = inbox.add(message, filters: filters)
+ if outcome == .notify, !message.fromMe { fresh = message }
+ nameGroupIfNeeded(WAJID.normalized(message.chat))
+ }
+ if announce, let fresh { self.announce(fresh) }
+ }
+
+ /// Groups arrive under their id (GOWA's webhook carries no group name): asked once.
+ private func nameGroupIfNeeded(_ chat: String) {
+ guard WAJID.isGroup(chat), let provider, let conv = inbox.conversations[chat],
+ conv.name == WAJID.displayNumber(chat), !namingGroups.contains(chat) else { return }
+ namingGroups.insert(chat)
+ Task {
+ if let name = await provider.groupName(chat) { inbox.rename(chat, to: name) }
+ }
+ }
+
+ // MARK: - Mochi
+
+ /// A new message reaches you: Mochi's little "happy" emote, the global sound setting, and
+ /// the pill lights up under the island's usual rules. Silent during a Focus.
+ private func announce(_ message: WAMessage) {
+ if WhatsAppSettings.respectFocus && focusIsOn { return }
+ let state = AppState.shared
+ guard let idx = state.tasks.firstIndex(where: { $0.id == Self.pillId }) else { return }
+ let name = inbox.conversations[WAJID.normalized(message.chat)]?.name ?? WAJID.displayNumber(message.chat)
+ state.tasks[idx].state = .finished
+ // Only the conversation's name on the pill, never the text.
+ state.tasks[idx].steps = [name]
+ if state.focusId != Self.pillId { state.tasks[idx].pillBadge = .finished }
+ // A burst of messages is one reaction, not ten.
+ if Date().timeIntervalSince(lastAnnounce) > 4 {
+ lastAnnounce = Date()
+ NotificationCenter.default.post(name: .triggerEmote, object: BotEmote.happy)
+ SoundEngine.shared.play("pop")
+ }
+ DispatchQueue.main.asyncAfter(deadline: .now() + 60) {
+ let state = AppState.shared
+ guard let i = state.tasks.firstIndex(where: { $0.id == Self.pillId }),
+ state.tasks[i].state == .finished,
+ Date().timeIntervalSince(WhatsAppController.shared.lastAnnounce) >= 59 else { return }
+ state.tasks[i].state = .idle
+ state.tasks[i].steps = []
+ state.tasks[i].pillBadge = nil
+ }
+ }
+
+ private func resetTask() {
+ let state = AppState.shared
+ guard let i = state.tasks.firstIndex(where: { $0.id == Self.pillId }) else { return }
+ state.tasks[i].state = .idle
+ state.tasks[i].steps = []
+ state.tasks[i].pillBadge = nil
+ }
+
+ // MARK: - Focus
+
+ /// macOS Focus (Concentration), when the system lets Coucou read it.
+ private var focusIsOn: Bool {
+ guard focusReadable == true else { return false }
+ return INFocusStatusCenter.default.focusStatus.isFocused ?? false
+ }
+
+ /// Asks once to read the Focus state. macOS answers only to apps signed with the
+ /// Communication Notifications capability; elsewhere this stays unreadable.
+ func askFocus() {
+ let center = INFocusStatusCenter.default
+ switch center.authorizationStatus {
+ case .authorized:
+ focusReadable = center.focusStatus.isFocused != nil
+ case .notDetermined:
+ center.requestAuthorization { status in
+ Task { @MainActor in
+ WhatsAppController.shared.focusReadable = status == .authorized
+ && INFocusStatusCenter.default.focusStatus.isFocused != nil
+ }
+ }
+ default:
+ focusReadable = false
+ }
+ }
+
+ // MARK: - Filters
+
+ func ignore(_ chat: String) {
+ filters.ignored.insert(WAJID.normalized(chat))
+ }
+
+ func unignore(_ chat: String) {
+ filters.ignored.remove(chat)
+ }
+}
+#endif
diff --git a/NotchBuddy/Sources/App/WhatsAppGateway.swift b/NotchBuddy/Sources/App/WhatsAppGateway.swift
new file mode 100644
index 00000000..527d8019
--- /dev/null
+++ b/NotchBuddy/Sources/App/WhatsAppGateway.swift
@@ -0,0 +1,414 @@
+import Foundation
+#if canImport(CryptoKit)
+import CryptoKit
+#endif
+
+// What the two local WhatsApp gateways send and answer, turned into WAMessage. Pure Foundation
+// so tests/WhatsAppTests.swift checks it against the payloads printed in each gateway's docs.
+// Every field name here comes from those docs and their source code:
+// GOWA — github.com/aldinokemal/go-whatsapp-web-multidevice (docs/webhook-payload.md, docs/openapi.yaml)
+// OpenWA — github.com/rmyndharis/OpenWA (docs/06-api-specification.md)
+// Nothing parsed here is logged or written anywhere.
+
+enum WAGatewayKind: String, CaseIterable, Sendable {
+ case gowa, openwa
+
+ var name: String { self == .gowa ? "GOWA" : "OpenWA" }
+ var defaultURL: String { self == .gowa ? "http://127.0.0.1:3000" : "http://127.0.0.1:2785" }
+ /// The header carrying the webhook's HMAC-SHA256 ("sha256=<hex>"), lowercased.
+ var signatureHeader: String { self == .gowa ? "x-hub-signature-256" : "x-openwa-signature" }
+}
+
+/// What one webhook delivery holds for Coucou.
+enum WAWebhookEvent: Equatable, Sendable {
+ case message(WAMessage)
+ /// A valid delivery Coucou has no use for (receipts, reactions, a test ping…).
+ case ignored
+}
+
+enum WAWebhook {
+ /// "sha256=<lowercase hex>" of HMAC-SHA256(secret, body): what both gateways send.
+ static func signature(body: Data, secret: String) -> String {
+ "sha256=" + waHMACSHA256(key: Data(secret.utf8), message: body).waHex
+ }
+
+ /// True when the delivery carries the signature `secret` gives, over the raw body bytes.
+ static func verify(kind: WAGatewayKind, headers: [String: String], body: Data, secret: String) -> Bool {
+ guard !secret.isEmpty, let sent = headers[kind.signatureHeader], sent.hasPrefix("sha256=") else { return false }
+ return waConstantTimeEqual(sent, signature(body: body, secret: secret))
+ }
+
+ /// Parses one delivery. nil when it isn't JSON at all. `me` is this account's JID or number,
+ /// to tell a mention of you (GOWA also gives it in the delivery itself).
+ static func parse(kind: WAGatewayKind, body: Data, me: String? = nil) -> WAWebhookEvent? {
+ guard let json = (try? JSONSerialization.jsonObject(with: body)) as? [String: Any] else { return nil }
+ switch kind {
+ case .gowa: return parseGOWA(json, me: me)
+ case .openwa: return parseOpenWA(json, me: me)
+ }
+ }
+
+ // MARK: GOWA
+
+ /// `{"event":"message","device_id":"<own JID>","payload":{id, chat_id, from, from_name,
+ /// sender_display_name, timestamp (RFC3339), is_from_me, body, image|video|audio|document|…}}`
+ private static func parseGOWA(_ json: [String: Any], me: String?) -> WAWebhookEvent {
+ guard json["event"] as? String == "message",
+ let p = json["payload"] as? [String: Any],
+ let id = p["id"] as? String, !id.isEmpty,
+ let chat = p["chat_id"] as? String, !chat.isEmpty else { return .ignored }
+ let from = (p["from"] as? String) ?? chat
+ let text = (p["body"] as? String) ?? ""
+ let mine = me ?? (json["device_id"] as? String)
+ var message = WAMessage(
+ id: id, chat: chat, sender: from,
+ senderName: nonEmpty(p["sender_display_name"]) ?? nonEmpty(p["from_name"]) ?? "",
+ text: text, media: gowaMedia(p),
+ date: WADate.rfc3339(p["timestamp"] as? String) ?? Date(),
+ fromMe: p["is_from_me"] as? Bool ?? false)
+ message.mentionsMe = WAJID.isGroup(chat) && WAMention.textMentions(text, me: mine)
+ return .message(message)
+ }
+
+ /// GOWA puts each media under its own key; only the label matters to Coucou.
+ static func gowaMedia(_ p: [String: Any]) -> WAMedia {
+ if p["image"] != nil { return .image }
+ if p["video"] != nil || p["video_note"] != nil { return .video }
+ if p["audio"] != nil { return .voice(seconds: nil) }
+ if let doc = p["document"] {
+ return .document(name: (doc as? [String: Any]).flatMap { nonEmpty($0["filename"]) })
+ }
+ if p["sticker"] != nil { return .sticker }
+ if p["location"] != nil || p["live_location"] != nil { return .location }
+ if p["contact"] != nil || p["contacts_array"] != nil { return .contact }
+ if p["poll"] != nil { return .other }
+ return .none
+ }
+
+ // MARK: OpenWA
+
+ /// `{"event":"message.received"|"message.sent","sessionId","data":{id, from, to, chatId, author,
+ /// body, type, timestamp (epoch s), fromMe, isGroup, mentionedIds, contact{name, pushName}, media{filename}}}`
+ private static func parseOpenWA(_ json: [String: Any], me: String?) -> WAWebhookEvent {
+ let event = json["event"] as? String
+ guard event == "message.received" || event == "message.sent",
+ let d = json["data"] as? [String: Any],
+ let id = d["id"] as? String, !id.isEmpty,
+ let chat = (d["chatId"] as? String) ?? (d["from"] as? String), !chat.isEmpty else { return .ignored }
+ let type = (d["type"] as? String) ?? "text"
+ guard type != "revoked" else { return .ignored }
+ let fromMe = (d["fromMe"] as? Bool) ?? (event == "message.sent")
+ let contact = d["contact"] as? [String: Any]
+ let media = d["media"] as? [String: Any]
+ var message = WAMessage(
+ id: id, chat: chat,
+ sender: nonEmpty(d["author"]) ?? (d["from"] as? String) ?? chat,
+ senderName: nonEmpty(contact?["name"]) ?? nonEmpty(contact?["pushName"]) ?? "",
+ text: (d["body"] as? String) ?? "",
+ media: openwaMedia(type, filename: nonEmpty(media?["filename"])),
+ date: WADate.epoch(d["timestamp"]) ?? Date(),
+ fromMe: fromMe)
+ let isGroup = (d["isGroup"] as? Bool) ?? WAJID.isGroup(chat)
+ if isGroup, let mine = me {
+ let ids = (d["mentionedIds"] as? [String]) ?? []
+ message.mentionsMe = ids.contains { WAJID.sameUser($0, mine) } || WAMention.textMentions(message.text, me: mine)
+ }
+ return .message(message)
+ }
+
+ /// OpenWA's `type` (text|image|video|audio|voice|document|sticker|location|contact|poll|…).
+ static func openwaMedia(_ type: String, filename: String? = nil) -> WAMedia {
+ switch type {
+ case "text", "": return .none
+ case "image": return .image
+ case "video": return .video
+ case "audio": return .audio(seconds: nil)
+ case "voice": return .voice(seconds: nil)
+ case "document": return .document(name: filename)
+ case "sticker": return .sticker
+ case "location": return .location
+ case "contact": return .contact
+ default: return .other
+ }
+ }
+}
+
+// MARK: - REST answers (status, QR, polling)
+
+/// What a gateway says of the WhatsApp link.
+struct WAStatus: Equatable, Sendable {
+ enum Link: Equatable, Sendable {
+ /// Logged in and online.
+ case connected
+ /// Waiting for the QR to be scanned.
+ case needsQR
+ /// Logged in but offline, starting, or anything in between.
+ case connecting
+ }
+ var link: Link
+ /// This account's JID or number, once logged in.
+ var me: String?
+}
+
+enum WAGOWA {
+ /// GOWA's envelope: `{code, message, results}` (no "status": the HTTP code says it).
+ static func results(_ data: Data) -> Any? {
+ ((try? JSONSerialization.jsonObject(with: data)) as? [String: Any])?["results"]
+ }
+
+ /// `GET /devices` → `results: [{id, phone_number, display_name, state, jid, created_at}]`.
+ /// The device Coucou uses: a logged-in one first, else the first one.
+ static func device(_ data: Data) -> (id: String, status: WAStatus)? {
+ guard let list = results(data) as? [[String: Any]], !list.isEmpty else { return nil }
+ let pick = list.first { $0["state"] as? String == "logged_in" } ?? list[0]
+ guard let id = pick["id"] as? String, !id.isEmpty else { return nil }
+ let jid = nonEmpty(pick["jid"])
+ let link: WAStatus.Link
+ switch pick["state"] as? String {
+ case "logged_in": link = .connected
+ case "connecting", "connected": link = jid == nil ? .needsQR : .connecting
+ default: link = jid == nil ? .needsQR : .connecting
+ }
+ return (id, WAStatus(link: link, me: jid))
+ }
+
+ /// `GET /devices/{id}/login` → `results: {device_id, qr_link, qr_duration}`. The PNG's path,
+ /// to fetch from the gateway itself (never from another host the link may name).
+ static func qrPath(_ data: Data) -> (path: String, seconds: Int)? {
+ guard let r = results(data) as? [String: Any], let link = r["qr_link"] as? String,
+ let url = URL(string: link), !url.path.isEmpty else { return nil }
+ return (url.path, (r["qr_duration"] as? Int) ?? 30)
+ }
+
+ /// The error code of a refused call (`ALREADY_LOGGED_IN`, `DEVICE_ID_REQUIRED`…).
+ static func errorCode(_ data: Data) -> String? {
+ ((try? JSONSerialization.jsonObject(with: data)) as? [String: Any])?["code"] as? String
+ }
+
+ /// `GET /chats` → `results: {data: [{jid, name, last_message_time, …}], pagination}`.
+ static func chats(_ data: Data) -> [(jid: String, name: String, last: Date)] {
+ guard let r = results(data) as? [String: Any], let list = r["data"] as? [[String: Any]] else { return [] }
+ return list.compactMap { c in
+ guard let jid = c["jid"] as? String, !jid.isEmpty else { return nil }
+ return (jid, (c["name"] as? String) ?? "", WADate.rfc3339(c["last_message_time"] as? String) ?? .distantPast)
+ }
+ }
+
+ /// `GET /chat/{jid}/messages` → `results: {data: [{id, chat_jid, sender_jid, sender_display_name,
+ /// content, timestamp, is_from_me, media_type, filename}], chat_info}`. Newest first there.
+ static func messages(_ data: Data, me: String?) -> [WAMessage] {
+ guard let r = results(data) as? [String: Any], let list = r["data"] as? [[String: Any]] else { return [] }
+ let chatName = nonEmpty((r["chat_info"] as? [String: Any])?["name"])
+ return list.compactMap { m in
+ guard let id = m["id"] as? String, let chat = m["chat_jid"] as? String else { return nil }
+ let text = (m["content"] as? String) ?? ""
+ var msg = WAMessage(
+ id: id, chat: chat, sender: (m["sender_jid"] as? String) ?? chat,
+ senderName: nonEmpty(m["sender_display_name"]) ?? "",
+ text: text, media: gowaStoredMedia(m["media_type"] as? String, filename: nonEmpty(m["filename"])),
+ date: WADate.rfc3339(m["timestamp"] as? String) ?? .distantPast,
+ fromMe: m["is_from_me"] as? Bool ?? false)
+ msg.chatName = WAJID.isGroup(chat) ? chatName : nil
+ msg.mentionsMe = WAJID.isGroup(chat) && WAMention.textMentions(text, me: me)
+ return msg
+ }
+ }
+
+ /// `media_type` of a stored message: image|video|video_note|audio|document|sticker|call or "".
+ static func gowaStoredMedia(_ type: String?, filename: String?) -> WAMedia {
+ switch type ?? "" {
+ case "": return .none
+ case "image": return .image
+ case "video", "video_note": return .video
+ case "audio": return .voice(seconds: nil)
+ case "document": return .document(name: filename)
+ case "sticker": return .sticker
+ default: return .other
+ }
+ }
+}
+
+enum WAOpenWA {
+ /// A session: `{id (uuid), name, status, phone, pushName, …}`.
+ /// status: created|initializing|qr_ready|authenticating|ready|disconnected|action_required|failed.
+ static func session(_ obj: Any?) -> (id: String, status: String, phone: String?)? {
+ guard let s = obj as? [String: Any], let id = s["id"] as? String, !id.isEmpty else { return nil }
+ return (id, (s["status"] as? String) ?? "", nonEmpty(s["phone"]))
+ }
+
+ /// `GET /api/sessions?name=…` → a bare array of sessions.
+ static func firstSession(_ data: Data) -> (id: String, status: String, phone: String?)? {
+ let json = try? JSONSerialization.jsonObject(with: data)
+ if let list = json as? [Any] { return list.lazy.compactMap(session).first }
+ return session(json)
+ }
+
+ static func status(_ s: (id: String, status: String, phone: String?)) -> WAStatus {
+ switch s.status {
+ case "ready": return WAStatus(link: .connected, me: s.phone)
+ case "qr_ready": return WAStatus(link: .needsQR, me: nil)
+ default: return WAStatus(link: .connecting, me: s.phone)
+ }
+ }
+
+ /// Sessions that must be started before a QR can come: never started, stopped or failed.
+ static func needsStart(_ status: String) -> Bool {
+ ["created", "disconnected", "failed"].contains(status)
+ }
+
+ /// `GET /api/sessions/{id}/qr` → `{qrCode: "data:image/png;base64,…", status}`: the PNG bytes.
+ static func qrPNG(_ data: Data) -> Data? {
+ guard let obj = (try? JSONSerialization.jsonObject(with: data)) as? [String: Any],
+ let url = obj["qrCode"] as? String,
+ let comma = url.firstIndex(of: ","), url.hasPrefix("data:image/png;base64") else { return nil }
+ return Data(base64Encoded: String(url[url.index(after: comma)...]))
+ }
+
+ /// `GET /api/sessions/{id}/chats` → bare `[{id, name, isGroup, unreadCount, timestamp, …}]`.
+ static func chats(_ data: Data) -> [(jid: String, name: String, unread: Int, last: Date)] {
+ guard let list = (try? JSONSerialization.jsonObject(with: data)) as? [[String: Any]] else { return [] }
+ return list.compactMap { c in
+ guard let id = c["id"] as? String, !id.isEmpty else { return nil }
+ return (id, (c["name"] as? String) ?? "", (c["unreadCount"] as? Int) ?? 0, WADate.epoch(c["timestamp"]) ?? .distantPast)
+ }
+ }
+
+ /// `GET /api/sessions/{id}/messages` → `{messages: [{waMessageId, chatId, from, author, chatName,
+ /// body, type, direction, timestamp (s), metadata}], total}`.
+ static func messages(_ data: Data, me: String?) -> [WAMessage] {
+ guard let obj = (try? JSONSerialization.jsonObject(with: data)) as? [String: Any],
+ let list = obj["messages"] as? [[String: Any]] else { return [] }
+ return list.compactMap { m in
+ guard let id = nonEmpty(m["waMessageId"]) ?? nonEmpty(m["id"]),
+ let chat = m["chatId"] as? String, !chat.isEmpty else { return nil }
+ let type = (m["type"] as? String) ?? "text"
+ guard type != "revoked" else { return nil }
+ let media = (m["metadata"] as? [String: Any])?["media"] as? [String: Any]
+ var msg = WAMessage(
+ id: id, chat: chat, sender: nonEmpty(m["author"]) ?? (m["from"] as? String) ?? chat,
+ senderName: "", text: (m["body"] as? String) ?? "",
+ media: WAWebhook.openwaMedia(type, filename: nonEmpty(media?["filename"])),
+ date: WADate.epoch(m["timestamp"]) ?? .distantPast,
+ fromMe: m["direction"] as? String == "outgoing")
+ msg.chatName = nonEmpty(m["chatName"])
+ if WAJID.isGroup(chat), let me { msg.mentionsMe = WAMention.textMentions(msg.text, me: me) }
+ return msg
+ }
+ }
+
+ /// NestJS error: `{statusCode, message (string or [string]), error}`.
+ static func errorMessage(_ data: Data) -> String? {
+ guard let obj = (try? JSONSerialization.jsonObject(with: data)) as? [String: Any] else { return nil }
+ if let s = obj["message"] as? String { return s }
+ return (obj["message"] as? [String])?.joined(separator: ", ")
+ }
+}
+
+// MARK: - Helpers
+
+enum WAMention {
+ /// "@33612345678" in the text, for this account's number (how GOWA shows a mention of you).
+ static func textMentions(_ text: String, me: String?) -> Bool {
+ guard let me, case let digits = WAJID.digits(me), digits.count >= 6 else { return false }
+ return text.contains("@" + digits)
+ }
+}
+
+extension WAJID {
+ /// The user part's digits: "33612345678:[email protected]" → "33612345678".
+ static func digits(_ jid: String) -> String {
+ let user = jid.split(separator: "@").first.map(String.init) ?? jid
+ let base = user.split(separator: ":").first.map(String.init) ?? user
+ return base.filter(\.isNumber)
+ }
+
+ /// Two ids of the same person, whatever their server part (@c.us, @s.whatsapp.net, a bare number).
+ static func sameUser(_ a: String, _ b: String) -> Bool {
+ let x = digits(a), y = digits(b)
+ return !x.isEmpty && x == y
+ }
+}
+
+enum WADate {
+ static func rfc3339(_ s: String?) -> Date? {
+ guard let s, !s.isEmpty else { return nil }
+ let f = ISO8601DateFormatter()
+ if let d = f.date(from: s) { return d }
+ f.formatOptions = [.withInternetDateTime, .withFractionalSeconds]
+ return f.date(from: s)
+ }
+
+ static func iso(_ date: Date) -> String { ISO8601DateFormatter().string(from: date) }
+
+ /// Epoch seconds, as a number or a numeric string.
+ static func epoch(_ v: Any?) -> Date? {
+ if let n = v as? Double, n > 0 { return Date(timeIntervalSince1970: n) }
+ if let n = v as? Int, n > 0 { return Date(timeIntervalSince1970: TimeInterval(n)) }
+ if let s = v as? String, let n = Double(s), n > 0 { return Date(timeIntervalSince1970: n) }
+ return nil
+ }
+}
+
+private func nonEmpty(_ v: Any?) -> String? {
+ guard let s = v as? String, !s.isEmpty else { return nil }
+ return s
+}
+
+// MARK: - HMAC-SHA256
+
+/// HMAC-SHA256 (RFC 2104). CryptoKit on Apple platforms; a plain SHA-256 elsewhere, so the
+/// tests run the same checks on Linux.
+func waHMACSHA256(key: Data, message: Data) -> Data {
+ #if canImport(CryptoKit)
+ return Data(HMAC<SHA256>.authenticationCode(for: message, using: SymmetricKey(data: key)))
+ #else
+ var k = key.count > 64 ? waSHA256(key) : key
+ k.append(contentsOf: [UInt8](repeating: 0, count: 64 - k.count))
+ let inner = Data(k.map { $0 ^ 0x36 }) + message
+ return waSHA256(Data(k.map { $0 ^ 0x5c }) + waSHA256(inner))
+ #endif
+}
+
+#if !canImport(CryptoKit)
+/// SHA-256 (FIPS 180-4), only where CryptoKit is missing.
+func waSHA256(_ data: Data) -> Data {
+ let k: [UInt32] = [
+ 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5,
+ 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174,
+ 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,
+ 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967,
+ 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85,
+ 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070,
+ 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3,
+ 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2]
+ var h: [UInt32] = [0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19]
+ var bytes = [UInt8](data)
+ let bitLength = UInt64(bytes.count) * 8
+ bytes.append(0x80)
+ while bytes.count % 64 != 56 { bytes.append(0) }
+ for i in (0..<8).reversed() { bytes.append(UInt8((bitLength >> (UInt64(i) * 8)) & 0xff)) }
+ func rotr(_ x: UInt32, _ n: UInt32) -> UInt32 { (x >> n) | (x << (32 - n)) }
+ var w = [UInt32](repeating: 0, count: 64)
+ for chunk in stride(from: 0, to: bytes.count, by: 64) {
+ for i in 0..<16 {
+ let j = chunk + i * 4
+ w[i] = UInt32(bytes[j]) << 24 | UInt32(bytes[j + 1]) << 16 | UInt32(bytes[j + 2]) << 8 | UInt32(bytes[j + 3])
+ }
+ for i in 16..<64 {
+ let s0 = rotr(w[i - 15], 7) ^ rotr(w[i - 15], 18) ^ (w[i - 15] >> 3)
+ let s1 = rotr(w[i - 2], 17) ^ rotr(w[i - 2], 19) ^ (w[i - 2] >> 10)
+ w[i] = w[i - 16] &+ s0 &+ w[i - 7] &+ s1
+ }
+ var (a, b, c, d, e, f, g, hh) = (h[0], h[1], h[2], h[3], h[4], h[5], h[6], h[7])
+ for i in 0..<64 {
+ let t1 = hh &+ (rotr(e, 6) ^ rotr(e, 11) ^ rotr(e, 25)) &+ ((e & f) ^ (~e & g)) &+ k[i] &+ w[i]
+ let t2 = (rotr(a, 2) ^ rotr(a, 13) ^ rotr(a, 22)) &+ ((a & b) ^ (a & c) ^ (b & c))
+ (hh, g, f, e, d, c, b, a) = (g, f, e, d &+ t1, c, b, a, t1 &+ t2)
+ }
+ h[0] &+= a; h[1] &+= b; h[2] &+= c; h[3] &+= d; h[4] &+= e; h[5] &+= f; h[6] &+= g; h[7] &+= hh
+ }
+ var out = Data()
+ for v in h { out.append(contentsOf: [UInt8(v >> 24), UInt8((v >> 16) & 0xff), UInt8((v >> 8) & 0xff), UInt8(v & 0xff)]) }
+ return out
+}
+#endif
diff --git a/NotchBuddy/Sources/App/WhatsAppModels.swift b/NotchBuddy/Sources/App/WhatsAppModels.swift
index 3ddd3b81..30bd1bda 100644
--- a/NotchBuddy/Sources/App/WhatsAppModels.swift
+++ b/NotchBuddy/Sources/App/WhatsAppModels.swift
@@ -131,10 +131,14 @@ struct WAInbox: Equatable, Sendable {
if seenIds.count > 2_000 { seenIds = Set(seenIds.suffix(1_000)) }
let isGroup = WAJID.isGroup(chat)
+ let number = WAJID.displayNumber(chat)
+ // In a private chat the other person names it: never your own name on your own message.
+ let personName = isGroup || message.fromMe ? nil : nonEmpty(message.senderName)
var conversation = conversations[chat] ?? WAConversation(
- id: chat, name: name ?? message.chatName ?? (isGroup ? WAJID.displayNumber(chat) : nonEmpty(message.senderName) ?? WAJID.displayNumber(chat)),
+ id: chat, name: name ?? message.chatName ?? personName ?? number,
isGroup: isGroup, lastActivity: message.date)
if let name = name ?? message.chatName, !name.isEmpty { conversation.name = name }
+ else if conversation.name == number, let personName { conversation.name = personName }
var msg = message
msg.chat = chat
conversation.messages.append(msg)
@@ -164,6 +168,11 @@ struct WAInbox: Equatable, Sendable {
conversations[WAJID.normalized(chat)]?.unread = 0
}
+ /// History loaded at connection: whether it was read is unknown, so nothing counts as new.
+ mutating func markAllRead() {
+ for key in conversations.keys { conversations[key]?.unread = 0 }
+ }
+
mutating func rename(_ chat: String, to name: String) {
guard !name.isEmpty else { return }
conversations[WAJID.normalized(chat)]?.name = name
@@ -240,7 +249,7 @@ struct WAHTTPRequest: Equatable, Sendable {
// MARK: - Hex
extension Data {
- var hexString: String { map { String(format: "%02x", $0) }.joined() }
+ var waHex: String { map { String(format: "%02x", $0) }.joined() }
}
/// Compares two strings in constant time (signatures).
diff --git a/NotchBuddy/Sources/App/WhatsAppProvider.swift b/NotchBuddy/Sources/App/WhatsAppProvider.swift
new file mode 100644
index 00000000..235244d8
--- /dev/null
+++ b/NotchBuddy/Sources/App/WhatsAppProvider.swift
@@ -0,0 +1,341 @@
+#if !APPSTORE
+import Foundation
+
+// The two local WhatsApp gateways Coucou can talk to. Each call goes to the URL set in
+// Settings (127.0.0.1 by default) and nowhere else: no photo, no media, nothing from
+// WhatsApp's own servers. Endpoints, headers and bodies follow each gateway's docs (see
+// WhatsAppGateway.swift for the references).
+
+enum WAError: Error, Equatable {
+ /// Nothing answers at that URL.
+ case unreachable
+ /// Wrong user:pass (GOWA) or API key (OpenWA).
+ case unauthorized
+ /// The gateway answered with an error (its own message, never a message's content).
+ case refused(String)
+ /// WhatsApp isn't linked yet.
+ case notLoggedIn
+}
+
+protocol WhatsAppProvider: Sendable {
+ var kind: WAGatewayKind { get }
+ /// The link to WhatsApp (sets up the gateway's device or session the first time).
+ func status() async throws -> WAStatus
+ /// The QR to scan, as PNG bytes, and how long it stays valid; nil when there is none to
+ /// show (already linked, not ready yet).
+ func qrCode() async throws -> (png: Data, seconds: Int)?
+ /// Tells the gateway to post new messages to Coucou's local webhook, signed with `secret`.
+ func registerWebhook(url: String, secret: String) async throws
+ /// Messages of every chat since `date` (the polling fallback), oldest first.
+ func recentMessages(since date: Date, me: String?) async throws -> [WAMessage]
+ /// The latest `limit` messages of one chat, oldest first.
+ func messages(chat: String, limit: Int, me: String?) async throws -> [WAMessage]
+ /// Sends a text to an existing chat; returns the new message's id when the gateway gives it.
+ func send(text: String, to chat: String) async throws -> String?
+ /// Marks the chat read up to `lastIncoming` (the newest message received in it).
+ func markRead(chat: String, lastIncoming: String?) async throws
+ /// A group's name, when the messages don't carry it.
+ func groupName(_ chat: String) async -> String?
+}
+
+/// HTTP to the local gateway: no cookies, no cache, nothing stored on disk.
+final class WAHTTP: Sendable {
+ let base: URL
+ let headers: [String: String]
+ private let session: URLSession
+
+ init(base: URL, headers: [String: String]) {
+ self.base = base
+ self.headers = headers
+ let config = URLSessionConfiguration.ephemeral
+ config.urlCache = nil
+ config.requestCachePolicy = .reloadIgnoringLocalCacheData
+ config.httpCookieStorage = nil
+ config.timeoutIntervalForRequest = 10
+ config.connectionProxyDictionary = [:] // straight to the local gateway
+ session = URLSession(configuration: config)
+ }
+
+ /// `path` is appended to the base URL as given (already percent-encoded where needed).
+ func call(_ method: String, _ path: String, query: [URLQueryItem] = [], json: [String: any Sendable]? = nil) async throws -> (Data, Int) {
+ guard var comps = URLComponents(url: base, resolvingAgainstBaseURL: false) else { throw WAError.unreachable }
+ comps.percentEncodedPath = comps.percentEncodedPath.trimmingCharacters(in: CharacterSet(charactersIn: "/")).isEmpty
+ ? path : "/" + comps.percentEncodedPath.trimmingCharacters(in: CharacterSet(charactersIn: "/")) + path
+ if !query.isEmpty { comps.queryItems = query }
+ guard let url = comps.url else { throw WAError.unreachable }
+ var req = URLRequest(url: url)
+ req.httpMethod = method
+ for (k, v) in headers { req.setValue(v, forHTTPHeaderField: k) }
+ req.setValue("application/json", forHTTPHeaderField: "Accept")
+ if let json {
+ req.httpBody = try JSONSerialization.data(withJSONObject: json)
+ req.setValue("application/json", forHTTPHeaderField: "Content-Type")
+ }
+ do {
+ let (data, response) = try await session.data(for: req)
+ let code = (response as? HTTPURLResponse)?.statusCode ?? 0
+ return (data, code)
+ } catch {
+ throw WAError.unreachable
+ }
+ }
+
+ static func pathComponent(_ s: String) -> String {
+ s.addingPercentEncoding(withAllowedCharacters: .alphanumerics.union(CharacterSet(charactersIn: "-._~@"))) ?? s
+ }
+}
+
+// MARK: - GOWA
+
+/// go-whatsapp-web-multidevice, `./whatsapp rest` (port 3000). Auth: HTTP basic `user:pass`
+/// when the gateway was started with `--basic-auth`. Coucou works on one device (the one
+/// already logged in, else a new one named "coucou"), named in `X-Device-Id`.
+actor GOWAProvider: WhatsAppProvider {
+ nonisolated let kind = WAGatewayKind.gowa
+ private let http: WAHTTP
+ private var deviceId: String?
+
+ init(base: URL, basicAuth: String?) {
+ var headers: [String: String] = [:]
+ if let auth = basicAuth, auth.contains(":") {
+ headers["Authorization"] = "Basic " + Data(auth.utf8).base64EncodedString()
+ }
+ http = WAHTTP(base: base, headers: headers)
+ }
+
+ private func check(_ data: Data, _ code: Int) throws {
+ if code == 401 && WAGOWA.errorCode(data) != "AUTHENTICATION_ERROR" { throw WAError.unauthorized }
+ if code == 401 { throw WAError.notLoggedIn }
+ guard (200..<300).contains(code) else {
+ throw WAError.refused(WAGOWA.errorCode(data) ?? "HTTP \(code)")
+ }
+ }
+
+ /// The device to work on; created ("coucou") when the gateway has none.
+ private func device() async throws -> (id: String, status: WAStatus) {
+ let (data, code) = try await http.call("GET", "/devices")
+ try check(data, code)
+ if let found = WAGOWA.device(data) {
+ deviceId = found.id
+ return found
+ }
+ let (made, madeCode) = try await http.call("POST", "/devices", json: ["device_id": "coucou"])
+ try check(made, madeCode)
+ deviceId = "coucou"
+ return ("coucou", WAStatus(link: .needsQR, me: nil))
+ }
+
+ private func scoped(_ method: String, _ path: String, query: [URLQueryItem] = [], json: [String: any Sendable]? = nil) async throws -> Data {
+ let id: String
+ if let deviceId { id = deviceId } else { id = try await device().id }
+ var q = query
+ q.append(URLQueryItem(name: "device_id", value: id))
+ let (data, code) = try await http.call(method, path, query: q, json: json)
+ try check(data, code)
+ return data
+ }
+
+ func status() async throws -> WAStatus {
+ try await device().status
+ }
+
+ func qrCode() async throws -> (png: Data, seconds: Int)? {
+ let id: String
+ if let deviceId { id = deviceId } else { id = try await device().id }
+ let (data, code) = try await http.call("GET", "/devices/\(WAHTTP.pathComponent(id))/login")
+ if WAGOWA.errorCode(data) == "ALREADY_LOGGED_IN" { return nil }
+ try check(data, code)
+ guard let qr = WAGOWA.qrPath(data) else { return nil }
+ // The PNG is served by the gateway itself under /statics: fetched from the configured
+ // URL, whatever host the link names.
+ let (png, pngCode) = try await http.call("GET", qr.path)
+ guard pngCode == 200, png.starts(with: [0x89, 0x50, 0x4E, 0x47]) else { return nil }
+ return (png, max(10, qr.seconds))
+ }
+
+ func registerWebhook(url: String, secret: String) async throws {
+ let id: String
+ if let deviceId { id = deviceId } else { id = try await device().id }
+ let (data, code) = try await http.call("PATCH", "/devices/\(WAHTTP.pathComponent(id))/webhook", json: [
+ "webhook_url": url, "webhook_secret": secret, "webhook_events": "message",
+ ])
+ try check(data, code)
+ }
+
+ func recentMessages(since date: Date, me: String?) async throws -> [WAMessage] {
+ let chats = WAGOWA.chats(try await scoped("GET", "/chats", query: [URLQueryItem(name: "limit", value: "20")]))
+ var out: [WAMessage] = []
+ // Only the chats that moved since `date` (sorted newest first by the gateway).
+ for chat in chats.prefix(8) where chat.last > date {
+ let data = try await scoped("GET", "/chat/\(WAHTTP.pathComponent(chat.jid))/messages", query: [
+ URLQueryItem(name: "limit", value: "10"),
+ URLQueryItem(name: "start_time", value: WADate.iso(date)),
+ ])
+ out += WAGOWA.messages(data, me: me).map { m in
+ var m = m
+ if m.chatName == nil, !chat.name.isEmpty, WAJID.isGroup(chat.jid) { m.chatName = chat.name }
+ return m
+ }
+ }
+ return out.sorted { $0.date < $1.date }
+ }
+
+ func messages(chat: String, limit: Int, me: String?) async throws -> [WAMessage] {
+ let data = try await scoped("GET", "/chat/\(WAHTTP.pathComponent(chat))/messages",
+ query: [URLQueryItem(name: "limit", value: String(limit))])
+ return WAGOWA.messages(data, me: me).sorted { $0.date < $1.date }
+ }
+
+ func send(text: String, to chat: String) async throws -> String? {
+ let data = try await scoped("POST", "/send/message", json: ["phone": chat, "message": text])
+ return (WAGOWA.results(data) as? [String: Any])?["message_id"] as? String
+ }
+
+ func markRead(chat: String, lastIncoming: String?) async throws {
+ guard let id = lastIncoming else { return }
+ _ = try await scoped("POST", "/message/\(WAHTTP.pathComponent(id))/read", json: ["phone": chat])
+ }
+
+ func groupName(_ chat: String) async -> String? {
+ guard WAJID.isGroup(chat),
+ let data = try? await scoped("GET", "/group/info", query: [URLQueryItem(name: "group_id", value: chat)]),
+ let r = WAGOWA.results(data) as? [String: Any],
+ let name = r["Name"] as? String, !name.isEmpty else { return nil }
+ return name
+ }
+}
+
+// MARK: - OpenWA
+
+/// OpenWA (port 2785, every route under /api). Auth: `X-API-Key`. Coucou works on one session
+/// (the one ready, else one named "coucou", created and started when missing).
+actor OpenWAProvider: WhatsAppProvider {
+ nonisolated let kind = WAGatewayKind.openwa
+ private let http: WAHTTP
+ private var sessionId: String?
+
+ init(base: URL, apiKey: String?) {
+ var headers: [String: String] = [:]
+ if let apiKey, !apiKey.isEmpty { headers["X-API-Key"] = apiKey }
+ http = WAHTTP(base: base, headers: headers)
+ }
+
+ private func check(_ data: Data, _ code: Int) throws {
+ if code == 401 || code == 403 { throw WAError.unauthorized }
+ guard (200..<300).contains(code) else {
+ throw WAError.refused(WAOpenWA.errorMessage(data) ?? "HTTP \(code)")
+ }
+ }
+
+ private func session() async throws -> (id: String, status: String, phone: String?) {
+ let (data, code) = try await http.call("GET", "/api/sessions")
+ try check(data, code)
+ let all = ((try? JSONSerialization.jsonObject(with: data)) as? [Any] ?? []).compactMap(WAOpenWA.session)
+ let pick = all.first { $0.status == "ready" }
+ ?? all.first { ($0.id == sessionId) }
+ ?? named("coucou", in: data) ?? all.first
+ if var s = pick {
+ sessionId = s.id
+ if WAOpenWA.needsStart(s.status) {
+ let (started, startCode) = try await http.call("POST", "/api/sessions/\(s.id)/start")
+ try check(started, startCode)
+ s = WAOpenWA.session(try? JSONSerialization.jsonObject(with: started)) ?? s
+ }
+ return s
+ }
+ let (made, madeCode) = try await http.call("POST", "/api/sessions", json: ["name": "coucou"])
+ try check(made, madeCode)
+ guard let s = WAOpenWA.session(try? JSONSerialization.jsonObject(with: made)) else { throw WAError.refused("session") }
+ sessionId = s.id
+ let (started, startCode) = try await http.call("POST", "/api/sessions/\(s.id)/start")
+ try check(started, startCode)
+ return WAOpenWA.session(try? JSONSerialization.jsonObject(with: started)) ?? s
+ }
+
+ private func named(_ name: String, in data: Data) -> (id: String, status: String, phone: String?)? {
+ guard let list = (try? JSONSerialization.jsonObject(with: data)) as? [[String: Any]],
+ let s = list.first(where: { $0["name"] as? String == name }) else { return nil }
+ return WAOpenWA.session(s)
+ }
+
+ private func sid() async throws -> String {
+ if let sessionId { return sessionId }
+ return try await session().id
+ }
+
+ private func scoped(_ method: String, _ path: String, query: [URLQueryItem] = [], json: [String: any Sendable]? = nil) async throws -> Data {
+ let id = try await sid()
+ let (data, code) = try await http.call(method, "/api/sessions/\(id)" + path, query: query, json: json)
+ try check(data, code)
+ return data
+ }
+
+ func status() async throws -> WAStatus {
+ WAOpenWA.status(try await session())
+ }
+
+ func qrCode() async throws -> (png: Data, seconds: Int)? {
+ let id = try await sid()
+ let (data, code) = try await http.call("GET", "/api/sessions/\(id)/qr")
+ if code == 400 { return nil } // not started, already linked, or not ready yet
+ try check(data, code)
+ // The QR turns every 20 s or so on WhatsApp's side: asked again after 15.
+ return WAOpenWA.qrPNG(data).map { ($0, 15) }
+ }
+
+ func registerWebhook(url: String, secret: String) async throws {
+ let id = try await sid()
+ let body: [String: any Sendable] = ["url": url, "events": ["message.received", "message.sent"], "secret": secret]
+ let (list, listCode) = try await http.call("GET", "/api/sessions/\(id)/webhooks")
+ try check(list, listCode)
+ let hooks = (try? JSONSerialization.jsonObject(with: list)) as? [[String: Any]] ?? []
+ if let mine = hooks.first(where: { $0["url"] as? String == url }), let hookId = mine["id"] as? String {
+ let (data, code) = try await http.call("PUT", "/api/sessions/\(id)/webhooks/\(hookId)", json: body)
+ try check(data, code)
+ } else {
+ let (data, code) = try await http.call("POST", "/api/sessions/\(id)/webhooks", json: body)
+ try check(data, code)
+ }
+ }
+
+ func recentMessages(since date: Date, me: String?) async throws -> [WAMessage] {
+ let data = try await scoped("GET", "/messages", query: [
+ URLQueryItem(name: "since", value: String(Int64(date.timeIntervalSince1970 * 1000))),
+ URLQueryItem(name: "limit", value: "50"),
+ URLQueryItem(name: "inlineMedia", value: "false"),
+ ])
+ return WAOpenWA.messages(data, me: me).sorted { $0.date < $1.date }
+ }
+
+ func messages(chat: String, limit: Int, me: String?) async throws -> [WAMessage] {
+ let data = try await scoped("GET", "/messages", query: [
+ URLQueryItem(name: "chatId", value: Self.openwaId(chat)),
+ URLQueryItem(name: "limit", value: String(limit)),
+ URLQueryItem(name: "inlineMedia", value: "false"),
+ ])
+ return WAOpenWA.messages(data, me: me).sorted { $0.date < $1.date }
+ }
+
+ func send(text: String, to chat: String) async throws -> String? {
+ let data = try await scoped("POST", "/messages/send-text", json: ["chatId": Self.openwaId(chat), "text": text])
+ return ((try? JSONSerialization.jsonObject(with: data)) as? [String: Any])?["messageId"] as? String
+ }
+
+ func markRead(chat: String, lastIncoming: String?) async throws {
+ _ = try await scoped("POST", "/chats/read", json: ["chatId": Self.openwaId(chat)])
+ }
+
+ func groupName(_ chat: String) async -> String? {
+ guard WAJID.isGroup(chat),
+ let data = try? await scoped("GET", "/groups/\(WAHTTP.pathComponent(chat))"),
+ let obj = (try? JSONSerialization.jsonObject(with: data)) as? [String: Any],
+ let name = obj["name"] as? String, !name.isEmpty else { return nil }
+ return name
+ }
+
+ /// OpenWA names people `<number>@c.us` (Coucou keeps the @s.whatsapp.net form inside).
+ static func openwaId(_ jid: String) -> String {
+ jid.hasSuffix("@s.whatsapp.net") ? jid.replacingOccurrences(of: "@s.whatsapp.net", with: "@c.us") : jid
+ }
+}
+#endif
diff --git a/NotchBuddy/Sources/App/WhatsAppViews.swift b/NotchBuddy/Sources/App/WhatsAppViews.swift
new file mode 100644
index 00000000..52ef6b1e
--- /dev/null
+++ b/NotchBuddy/Sources/App/WhatsAppViews.swift
@@ -0,0 +1,429 @@
+#if !APPSTORE
+import SwiftUI
+import AppKit
+
+// MARK: - WhatsApp card (WhatsApp pill)
+
+/// WhatsApp's own green: the pill keeps it whatever, like the brand.
+let whatsAppAccent = "#25D366"
+
+/// The conversations with new messages, newest first: one row per conversation (never one
+/// per message) with initials, name, the last message cut short and the unread count.
+/// When the gateway isn't linked, the card says why and leads to Settings.
+struct WhatsAppCardView: View {
+ @ObservedObject private var wa = WhatsAppController.shared
+
+ var body: some View {
+ VStack(alignment: .leading, spacing: 0) {
+ header
+ if wa.link == .connected {
+ list
+ } else {
+ status
+ }
+ }
+ .frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .topLeading)
+ .padding(.top, 4)
+ }
+
+ private var header: some View {
+ HStack(spacing: 6) {
+ Circle()
+ .fill(Color(hex: whatsAppAccent))
+ .frame(width: 7, height: 7)
+ Text(verbatim: "WhatsApp")
+ .font(.system(size: 12, weight: .semibold))
+ .foregroundColor(Color(hex: "#F5F6F8"))
+ let unread = wa.visibleConversations.reduce(0) { $0 + $1.unread }
+ if unread > 0 {
+ Text(String(format: String(localized: "%lld unread"), Int64(unread)))
+ .font(.system(size: 10, weight: .semibold))
+ .foregroundColor(Color(hex: whatsAppAccent))
+ .monospacedDigit()
+ .padding(.horizontal, 6).padding(.vertical, 1)
+ .background(Color(hex: whatsAppAccent).opacity(0.14))
+ .clipShape(Capsule())
+ }
+ Spacer(minLength: 2)
+ }
+ .padding(.top, 6)
+ .padding(.leading, 108)
+ .padding(.trailing, 36)
+ }
+
+ @ViewBuilder private var list: some View {
+ let conversations = wa.visibleConversations
+ if conversations.isEmpty {
+ Text("whatsapp.empty")
+ .font(.system(size: 11))
+ .foregroundColor(Color(hex: "#6B7079"))
+ .padding(.top, 8)
+ .padding(.leading, 116)
+ } else {
+ ScrollView(.vertical, showsIndicators: false) {
+ VStack(alignment: .leading, spacing: 3) {
+ ForEach(conversations) { conversation in
+ WhatsAppRow(conversation: conversation)
+ }
+ }
+ }
+ .padding(.top, 5)
+ .padding(.leading, 108)
+ .padding(.trailing, 12)
+ }
+ }
+
+ private var status: some View {
+ VStack(alignment: .leading, spacing: 6) {
+ HStack(spacing: 5) {
+ Circle().fill(WhatsAppStatus.dot(wa.link)).frame(width: 5, height: 5)
+ Text(WhatsAppStatus.label(wa.link))
+ .font(.system(size: 11))
+ .foregroundColor(Color(hex: "#6B7079"))
+ .lineLimit(1).truncationMode(.tail)
+ }
+ Button("Settings…") {
+ NotificationCenter.default.post(name: .openFullSettings, object: "integrations")
+ }
+ .font(.system(size: 11))
+ .foregroundColor(Color(hex: "#8E939C"))
+ .buttonStyle(.plain)
+ }
+ .padding(.top, 8)
+ .padding(.leading, 108)
+ }
+}
+
+/// What the link's state reads like, in the card and in Settings.
+enum WhatsAppStatus {
+ static func label(_ link: WhatsAppController.Link) -> String {
+ switch link {
+ case .off: return String(localized: "whatsapp.status.off")
+ case .connecting: return String(localized: "whatsapp.status.connecting")
+ case .needsQR: return String(localized: "whatsapp.status.needs-qr")
+ case .connected: return String(localized: "whatsapp.status.connected")
+ case .unreachable: return String(localized: "whatsapp.status.unreachable")
+ case .unauthorized: return String(localized: "whatsapp.status.unauthorized")
+ case .failed(let why): return why
+ }
+ }
+
+ static func dot(_ link: WhatsAppController.Link) -> Color {
+ switch link {
+ case .connected: return Color(hex: "#22C55E")
+ case .connecting, .needsQR: return Color(hex: "#F5B83D")
+ case .off: return Color(hex: "#6B7079")
+ default: return Color(hex: "#F4505E")
+ }
+ }
+}
+
+/// One conversation: initials, name, age, the last message, and how many are unread.
+struct WhatsAppRow: View {
+ let conversation: WAConversation
+ var onOpen: (() -> Void)? = nil
+ @State private var hovered = false
+
+ var body: some View {
+ let accent = Color(hex: whatsAppAccent)
+ let unread = conversation.unread > 0
+ Button(action: { onOpen?() }) {
+ HStack(spacing: 6) {
+ WhatsAppAvatar(name: conversation.name, isGroup: conversation.isGroup, size: 16)
+ Text(conversation.name)
+ .font(.system(size: 11, weight: unread ? .semibold : .regular))
+ .foregroundColor(Color(hex: unread ? "#E8E9EC" : "#9398A1"))
+ .lineLimit(1).truncationMode(.tail)
+ .frame(maxWidth: 92, alignment: .leading)
+ .layoutPriority(1)
+ Text(waTimeAgo(conversation.lastActivity))
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#6B7079"))
+ .fixedSize()
+ if let last = conversation.messages.last {
+ Text(waPreview(last, isGroup: conversation.isGroup))
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: unread ? "#8E939C" : "#4D5159"))
+ .lineLimit(1).truncationMode(.tail)
+ }
+ Spacer(minLength: 0)
+ if unread {
+ Text(verbatim: conversation.unread > 99 ? "99+" : "\(conversation.unread)")
+ .font(.system(size: 9, weight: .bold))
+ .foregroundColor(Color(hex: "#0B0C0E"))
+ .monospacedDigit()
+ .padding(.horizontal, 5).padding(.vertical, 1)
+ .background(accent)
+ .clipShape(Capsule())
+ .fixedSize()
+ }
+ }
+ .padding(.horizontal, 6).padding(.vertical, 3)
+ .frame(maxWidth: .infinity, alignment: .leading)
+ .background(
+ RoundedRectangle(cornerRadius: 5)
+ .fill(unread ? accent.opacity(hovered ? 0.14 : 0.08) : Color.white.opacity(hovered ? 0.05 : 0))
+ )
+ .contentShape(Rectangle())
+ }
+ .buttonStyle(.plain)
+ .onHover { hovered = $0 }
+ .contextMenu {
+ Button("whatsapp.ignore-chat") { WhatsAppController.shared.ignore(conversation.id) }
+ }
+ }
+}
+
+/// Initials on WhatsApp green: no photo is ever fetched (they live on WhatsApp's servers).
+struct WhatsAppAvatar: View {
+ let name: String
+ let isGroup: Bool
+ var size: CGFloat = 16
+
+ var body: some View {
+ ZStack {
+ Circle().fill(Color(hex: whatsAppAccent).opacity(0.22))
+ if isGroup && WAJID.initials(name) == "#" {
+ Image(systemName: "person.2.fill")
+ .font(.system(size: size * 0.42, weight: .semibold))
+ .foregroundColor(Color(hex: whatsAppAccent))
+ } else {
+ Text(verbatim: WAJID.initials(name))
+ .font(.system(size: size * 0.42, weight: .bold))
+ .foregroundColor(Color(hex: whatsAppAccent))
+ }
+ }
+ .frame(width: size, height: size)
+ }
+}
+
+/// "Marie: see you", "You: ok", "Photo · look", "Voice": one line, media as a label only.
+func waPreview(_ message: WAMessage, isGroup: Bool) -> String {
+ let (key, value) = message.previewKey
+ var line: String
+ if key.isEmpty {
+ line = value
+ } else {
+ let label = NSLocalizedString(key, comment: "")
+ line = value.isEmpty ? label : "\(label) · \(value)"
+ }
+ line = line.replacingOccurrences(of: "\n", with: " ")
+ if message.fromMe { return String(localized: "whatsapp.you") + ": " + line }
+ if isGroup, !message.senderName.isEmpty { return message.senderName + ": " + line }
+ return line
+}
+
+func waTimeAgo(_ date: Date) -> String {
+ let diff = Date().timeIntervalSince(date)
+ if diff < 60 { return String(localized: "mail.now") }
+ if diff < 3600 { return "\(Int(diff / 60))m" }
+ if diff < 86400 { return "\(Int(diff / 3600))h" }
+ return "\(Int(diff / 86400))d"
+}
+
+// MARK: - Settings
+
+/// Settings → Integrations → WhatsApp (experimental). Off until turned on; the gateway's
+/// address and credentials go to the Keychain; the QR to link WhatsApp shows right here.
+struct WhatsAppSettingsSection: View {
+ @ObservedObject private var wa = WhatsAppController.shared
+ @ObservedObject private var appState = AppState.shared
+ @State private var enabled = WhatsAppSettings.enabled
+ @State private var gateway = WhatsAppSettings.gateway
+ @State private var url = KeychainStore.shared.get(WhatsAppSettings.urlKey) ?? ""
+ @State private var credential = KeychainStore.shared.get(WhatsAppSettings.credentialKey) ?? ""
+ @State private var port = String(WhatsAppSettings.port)
+ @State private var respectFocus = WhatsAppSettings.respectFocus
+ @State private var testResult: String?
+ @State private var testing = false
+ @State private var ignoreEntry = ""
+
+ var body: some View {
+ VStack(alignment: .leading, spacing: 6) {
+ HStack(spacing: 6) {
+ Circle().fill(Color(hex: whatsAppAccent)).frame(width: 8, height: 8)
+ Text("whatsapp.title").font(.system(size: 12, weight: .semibold))
+ }
+
+ Text("whatsapp.warning")
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#F5B83D"))
+ .fixedSize(horizontal: false, vertical: true)
+
+ Toggle("whatsapp.enable", isOn: $enabled)
+ .onChange(of: enabled) { _, on in wa.setEnabled(on) }
+
+ if enabled {
+ if !appState.activeIntegrations.contains(WhatsAppController.pillId) {
+ Text("whatsapp.no-slot")
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#F4505E"))
+ }
+
+ Picker("whatsapp.gateway", selection: $gateway) {
+ ForEach(WAGatewayKind.allCases, id: \.self) { kind in
+ Text(verbatim: kind == .gowa ? "GOWA" : "OpenWA").tag(kind)
+ }
+ }
+ .pickerStyle(.segmented)
+
+ TextField(gateway.defaultURL, text: $url)
+ .textFieldStyle(.roundedBorder)
+ SecureField(gateway == .gowa ? String(localized: "whatsapp.credential.gowa")
+ : String(localized: "whatsapp.credential.openwa"),
+ text: $credential)
+ .textFieldStyle(.roundedBorder)
+ HStack(spacing: 6) {
+ Text("whatsapp.port").font(.system(size: 11))
+ TextField(String(WhatsAppSettings.defaultPort), text: $port)
+ .textFieldStyle(.roundedBorder)
+ .frame(width: 80)
+ Spacer()
+ }
+
+ HStack(spacing: 8) {
+ Button("integrations.save") { save() }
+ .buttonStyle(.borderedProminent)
+ Button("whatsapp.test") {
+ save()
+ testing = true
+ Task {
+ testResult = await wa.testConnection()
+ testing = false
+ }
+ }
+ .buttonStyle(.bordered)
+ .disabled(testing)
+ if testing { ProgressView().controlSize(.small) }
+ }
+ if let testResult {
+ Text(verbatim: testResult)
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#8E939C"))
+ }
+
+ linkState
+
+ // Filters
+ Toggle("whatsapp.mute-groups", isOn: Binding(
+ get: { wa.filters.muteGroups },
+ set: { wa.filters.muteGroups = $0 }))
+ Toggle("whatsapp.respect-focus", isOn: $respectFocus)
+ .onChange(of: respectFocus) { _, on in
+ WhatsAppSettings.respectFocus = on
+ if on { wa.askFocus() }
+ }
+ if respectFocus && wa.focusReadable == false {
+ Text("whatsapp.focus-unavailable")
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#8E939C"))
+ .fixedSize(horizontal: false, vertical: true)
+ }
+
+ ignoredChats
+
+ Text("whatsapp.privacy")
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#8E939C"))
+ .fixedSize(horizontal: false, vertical: true)
+ }
+ }
+ .onChange(of: gateway) { old, new in
+ // Still on the other gateway's default address: follow the switch.
+ if url.isEmpty || url == old.defaultURL { url = new.defaultURL }
+ }
+ }
+
+ /// Linked or not, and the QR to scan when it's needed.
+ @ViewBuilder private var linkState: some View {
+ HStack(spacing: 5) {
+ Circle().fill(WhatsAppStatus.dot(wa.link)).frame(width: 6, height: 6)
+ if wa.link == .connected, let me = wa.me {
+ Text(String(format: String(localized: "whatsapp.connected-as %@"), WAJID.displayNumber(me)))
+ .font(.system(size: 11))
+ } else {
+ Text(verbatim: WhatsAppStatus.label(wa.link))
+ .font(.system(size: 11))
+ }
+ Spacer()
+ }
+ if wa.link == .connected {
+ Text(webhookLine)
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#8E939C"))
+ .fixedSize(horizontal: false, vertical: true)
+ }
+ if wa.link == .needsQR {
+ if let png = wa.qrPNG, let image = NSImage(data: png) {
+ HStack(alignment: .top, spacing: 10) {
+ Image(nsImage: image)
+ .interpolation(.none)
+ .resizable()
+ .frame(width: 168, height: 168)
+ .background(Color.white)
+ .clipShape(RoundedRectangle(cornerRadius: 6))
+ Text("whatsapp.qr.hint")
+ .font(.system(size: 10))
+ .foregroundColor(Color(hex: "#8E939C"))
+ .fixedSize(horizontal: false, vertical: true)
+ }
+ } else {
+ ProgressView().controlSize(.small)
+ }
+ }
+ }
+
+ private var webhookLine: String {
+ switch wa.webhook {
+ case .registered: return String(localized: "whatsapp.webhook.live")
+ case .portBusy: return String(format: String(localized: "whatsapp.webhook.port-busy %lld"), Int64(WhatsAppSettings.port))
+ case .refused(let why): return String(format: String(localized: "whatsapp.webhook.refused %@"), why)
+ case .off, .listening: return String(localized: "whatsapp.webhook.polling")
+ }
+ }
+
+ @ViewBuilder private var ignoredChats: some View {
+ Text("whatsapp.ignored").font(.system(size: 11, weight: .medium))
+ ForEach(wa.filters.ignored.sorted(), id: \.self) { chat in
+ HStack(spacing: 6) {
+ Text(verbatim: wa.inbox.conversations[chat]?.name ?? WAJID.displayNumber(chat))
+ .font(.system(size: 11))
+ Spacer()
+ Button("whatsapp.remove") { wa.unignore(chat) }
+ .buttonStyle(.borderless)
+ .font(.system(size: 11))
+ }
+ }
+ HStack(spacing: 6) {
+ TextField(String(localized: "whatsapp.ignore-placeholder"), text: $ignoreEntry)
+ .textFieldStyle(.roundedBorder)
+ .onSubmit(addIgnored)
+ Button("whatsapp.add", action: addIgnored)
+ .disabled(ignoreEntry.trimmingCharacters(in: .whitespaces).isEmpty)
+ }
+ }
+
+ private func addIgnored() {
+ let raw = ignoreEntry.trimmingCharacters(in: .whitespaces)
+ guard !raw.isEmpty else { return }
+ // A phone number ("+33 6 12…") or a full chat id ("…@g.us").
+ let chat = raw.contains("@") ? raw : raw.filter(\.isNumber) + "@s.whatsapp.net"
+ guard chat.count > "@s.whatsapp.net".count else { return }
+ wa.ignore(chat)
+ ignoreEntry = ""
+ }
+
+ private func save() {
+ let trimmedURL = url.trimmingCharacters(in: .whitespaces)
+ if trimmedURL.isEmpty { KeychainStore.shared.remove(WhatsAppSettings.urlKey) }
+ else { KeychainStore.shared.set(WhatsAppSettings.urlKey, value: trimmedURL) }
+ let trimmedCredential = credential.trimmingCharacters(in: .whitespaces)
+ if trimmedCredential.isEmpty { KeychainStore.shared.remove(WhatsAppSettings.credentialKey) }
+ else { KeychainStore.shared.set(WhatsAppSettings.credentialKey, value: trimmedCredential) }
+ WhatsAppSettings.gateway = gateway
+ if let p = Int(port), (1024...65535).contains(p) { WhatsAppSettings.port = p }
+ port = String(WhatsAppSettings.port)
+ wa.settingsChanged()
+ }
+}
+#endif
diff --git a/NotchBuddy/Sources/App/WhatsAppWebhook.swift b/NotchBuddy/Sources/App/WhatsAppWebhook.swift
index dfcc0712..2f7e321b 100644
--- a/NotchBuddy/Sources/App/WhatsAppWebhook.swift
+++ b/NotchBuddy/Sources/App/WhatsAppWebhook.swift
@@ -12,6 +12,8 @@ final class WhatsAppWebhook: @unchecked Sendable {
/// Called on `queue` with each complete request; returns the HTTP status to answer.
var onRequest: (@Sendable (WAHTTPRequest) -> Int)?
+ /// Called on `queue`: true once listening, false when the port can't be used.
+ var onListening: (@Sendable (Bool) -> Void)?
/// Starts listening; false when the port is taken or invalid.
@discardableResult
@@ -24,9 +26,15 @@ final class WhatsAppWebhook: @unchecked Sendable {
params.acceptLocalOnly = true
guard let listener = try? NWListener(using: params) else { return false }
listener.newConnectionHandler = { [weak self] connection in self?.serve(connection) }
- listener.stateUpdateHandler = { state in
- if case .failed(let error) = state {
+ listener.stateUpdateHandler = { [weak self] state in
+ switch state {
+ case .ready:
+ self?.onListening?(true)
+ case .failed(let error):
appendAppLog("nb.log", "[WhatsApp] webhook listener failed: \(error.localizedDescription)")
+ self?.onListening?(false)
+ default:
+ break
}
}
listener.start(queue: queue)
@@ -68,7 +76,7 @@ final class WhatsAppWebhook: @unchecked Sendable {
self.receive(connection, buffer: buffer)
case .done(let request):
let status = self.onRequest?(request) ?? 503
- let reason = status == 200 ? "OK" : (status == 401 ? "Unauthorized" : "Error")
+ let reason = status == 200 ? "OK" : status == 401 ? "Unauthorized" : status == 404 ? "Not Found" : "Error"
connection.send(content: WAHTTPRequest.response(status, reason), completion: .contentProcessed { _ in connection.cancel() })
default:
connection.send(content: WAHTTPRequest.response(400, "Bad Request"), completion: .contentProcessed { _ in connection.cancel() })
diff --git a/NotchBuddy/Sources/CoucouKit/PillCatalog.swift b/NotchBuddy/Sources/CoucouKit/PillCatalog.swift
index 24ac53bd..f821ad52 100644
--- a/NotchBuddy/Sources/CoucouKit/PillCatalog.swift
+++ b/NotchBuddy/Sources/CoucouKit/PillCatalog.swift
@@ -126,6 +126,8 @@ enum PillCatalog {
category: .service, subtitle: "Integration", source: .n8n, githubOnly: true),
.init(id: "integration_mail", name: "Mail", color: "#2F8CFF",
category: .service, subtitle: "Integration", source: .n8n, githubOnly: true),
+ .init(id: "integration_whatsapp", name: "WhatsApp", color: "#25D366",
+ category: .service, subtitle: "Integration", source: .n8n, githubOnly: true),
.init(id: "integration_crypto", name: "Crypto", color: "#F7931A",
category: .service, subtitle: "Integration", source: .n8n),
.init(id: "integration_portfolio", name: "Portfolio", color: "#FFD700",
diff --git a/NotchBuddy/project.yml b/NotchBuddy/project.yml
index 84952d5e..b76c3320 100644
--- a/NotchBuddy/project.yml
+++ b/NotchBuddy/project.yml
@@ -149,6 +149,7 @@ targets:
NSSpeechRecognitionUsageDescription: "Coucou turns your voice into the text of a chat message."
NSAccessibilityUsageDescription: "Pour lire le titre de la fenêtre active et l'attacher comme contexte."
NSContactsUsageDescription: "Coucou looks up an email address when you ask it, by voice, to prepare an email."
+ NSFocusStatusUsageDescription: "Coucou stays quiet about new WhatsApp messages while a Focus is on."
NSAppTransportSecurity:
NSAllowsLocalNetworking: true
CFBundleLocalizations:
diff --git a/scripts/test-whatsapp.sh b/scripts/test-whatsapp.sh
new file mode 100755
index 00000000..95200d18
--- /dev/null
+++ b/scripts/test-whatsapp.sh
@@ -0,0 +1,10 @@
+#!/usr/bin/env bash
+set -euo pipefail
+cd "$(dirname "$0")/.."
+TEST_DIR="$(mktemp -d "${TMPDIR:-/tmp}/coucou-whatsapp.XXXXXX")"
+trap 'rm -rf "$TEST_DIR"' EXIT
+swiftc NotchBuddy/Sources/App/WhatsAppModels.swift \
+ NotchBuddy/Sources/App/WhatsAppGateway.swift \
+ tests/WhatsAppTests.swift tests/WhatsAppGatewayTests.swift \
+ -o "$TEST_DIR/whatsapp-tests"
+"$TEST_DIR/whatsapp-tests"
diff --git a/tests/WhatsAppGatewayTests.swift b/tests/WhatsAppGatewayTests.swift
new file mode 100644
index 00000000..72b240f9
--- /dev/null
+++ b/tests/WhatsAppGatewayTests.swift
@@ -0,0 +1,278 @@
+import Foundation
+
+// The gateways' payloads, copied verbatim from their own docs (see each fixture's source),
+// through Coucou's parsers.
+
+extension WhatsAppTests {
+ // GOWA docs/webhook-payload.md — text message
+ static let gowaText = #"""
+ {
+ "event": "message",
+ "device_id": "[email protected]",
+ "payload": {
+ "id": "3EB0C127D7BACC83D6A1",
+ "chat_id": "[email protected]",
+ "from": "[email protected]",
+ "from_lid": "251556368777322@lid",
+ "sender_display_name": "Saved Contact",
+ "from_name": "John Doe",
+ "timestamp": "2023-10-15T10:30:00Z",
+ "is_from_me": false,
+ "body": "Hello, how are you?"
+ }
+ }
+ """#
+
+ // GOWA docs/webhook-payload.md — image, auto-download, with caption
+ static let gowaImage = #"""
+ {
+ "event": "message",
+ "device_id": "[email protected]",
+ "payload": {
+ "id": "3EB0C127D7BACC83D6A3",
+ "chat_id": "[email protected]",
+ "from": "[email protected]",
+ "from_name": "John Doe",
+ "timestamp": "2025-07-13T11:05:51Z",
+ "body": "Check this out!",
+ "image": {
+ "path": "statics/media/1752404751-ad9e37ac-c658-4fe5-8d25-ba4a3f4d58fd.jpeg",
+ "caption": "Check this out!"
+ }
+ }
+ }
+ """#
+
+ // GOWA docs/webhook-payload.md — audio
+ static let gowaAudio = #"""
+ {
+ "event": "message",
+ "device_id": "[email protected]",
+ "payload": {
+ "id": "3EB0C127D7BACC83D6A5",
+ "chat_id": "[email protected]",
+ "from": "[email protected]",
+ "from_name": "John Doe",
+ "timestamp": "2023-10-15T10:55:00Z",
+ "audio": "statics/media/1752404905-b9393cd1-8546-4df9-8a60-ee3276036aba.ogg"
+ }
+ }
+ """#
+
+ // GOWA docs/webhook-payload.md — delivery receipt
+ static let gowaAck = #"""
+ {
+ "event": "message.ack",
+ "device_id": "[email protected]",
+ "timestamp": "2025-07-18T22:44:20Z",
+ "payload": {
+ "ids": [
+ "3EB00106E8BE0F407E88EC"
+ ],
+ "chat_id": "[email protected]",
+ "from": "[email protected]",
+ "from_lid": "251556368777322@lid",
+ "sender_display_name": "Saved Contact",
+ "receipt_type": "delivered",
+ "receipt_type_description": "means the message was delivered to the device (but the user might not have noticed)."
+ }
+ }
+ """#
+
+ // GOWA: a group message mentioning the account. The docs print none; built from the
+ // fields event_message.go always sets (chat_id @g.us, from = the member, "@<number>" in body).
+ static let gowaGroupMention = #"""
+ {"event":"message","device_id":"[email protected]","payload":{"id":"G1","chat_id":"[email protected]","from":"[email protected]","from_name":"John Doe","timestamp":"2025-07-13T11:05:51Z","is_from_me":false,"body":"@628987654321 tu viens ?"}}
+ """#
+
+ // OpenWA docs/12-troubleshooting-faq.md — 1:1 text message.received
+ static let openwaText = #"""
+ {
+ "event": "message.received",
+ "timestamp": "2026-02-02T10:30:00Z",
+ "sessionId": "3f2a9c1e-7b4d-4e8a-9c2f-1d5e6a7b8c9d",
+ "idempotencyKey": "msg_3f2a9c1e-7b4d-4e8a-9c2f-1d5e6a7b8c9d_ABC123_DEF456_f1e2d3c4-b5a6-7890-1234-567890abcdef",
+ "deliveryId": "dlv_550e8400-e29b-41d4-a716-446655440000",
+ "data": {
+ "id": "ABC123_DEF456",
+ "from": "[email protected]",
+ "chatId": "[email protected]",
+ "body": "Hello!",
+ "type": "text",
+ "timestamp": 1706868600,
+ "fromMe": false,
+ "isGroup": false,
+ "kind": "individual"
+ }
+ }
+ """#
+
+ // OpenWA docs/22-n8n-integration.md — minimal message.received (fields left out on purpose)
+ static let openwaMinimal = #"""
+ {
+ "event": "message.received",
+ "timestamp": "2024-01-15T10:30:00Z",
+ "sessionId": "default",
+ "idempotencyKey": "msg_default_3EB0F5A2B4C..._f1e2d3c4-b5a6-7890-1234-567890abcdef",
+ "deliveryId": "dlv_0f8c1a2b-3c4d-5e6f-7a8b-9c0d1e2f3a4b",
+ "data": {
+ "id": "3EB0F5A2B4C...",
+ "chatId": "[email protected]",
+ "from": "[email protected]",
+ "body": "Hello!",
+ "type": "text",
+ "timestamp": 1705312200
+ }
+ }
+ """#
+
+ // OpenWA: a group voice note with a mention. No full example in the docs; built from
+ // whatsapp-engine.interface.ts (author, mentionedIds, type "voice", contact.pushName).
+ static let openwaGroupVoice = #"""
+ {"event":"message.received","timestamp":"2026-02-02T10:30:00Z","sessionId":"s1","idempotencyKey":"k","deliveryId":"dlv_2","data":{"id":"3EB0VOICE","from":"[email protected]","to":"[email protected]","chatId":"[email protected]","author":"[email protected]","body":"","type":"voice","timestamp":1706868600,"fromMe":false,"isGroup":true,"kind":"group","mentionedIds":["[email protected]"],"contact":{"pushName":"Budi"},"media":{"mimetype":"audio/ogg; codecs=opus","omitted":true,"sizeBytes":9000}}}
+ """#
+
+ static func runGatewayTests() {
+ print("\nGOWA webhook (docs/webhook-payload.md)")
+ do {
+ if case .message(let m) = WAWebhook.parse(kind: .gowa, body: Data(gowaText.utf8)) {
+ check("id and chat", m.id == "3EB0C127D7BACC83D6A1" && m.chat == "[email protected]")
+ check("the saved contact's name first", m.senderName == "Saved Contact")
+ check("text", m.text == "Hello, how are you?" && m.media == .none)
+ check("RFC3339 date", m.date == Date(timeIntervalSince1970: 1_697_365_800))
+ check("not mine", !m.fromMe)
+ } else { check("text parsed", false) }
+
+ if case .message(let m) = WAWebhook.parse(kind: .gowa, body: Data(gowaImage.utf8)) {
+ check("image label, caption kept", m.media == .image && m.text == "Check this out!")
+ check("is_from_me missing → not mine", !m.fromMe)
+ } else { check("image parsed", false) }
+
+ if case .message(let m) = WAWebhook.parse(kind: .gowa, body: Data(gowaAudio.utf8)) {
+ check("audio is a voice label, no duration", m.media == .voice(seconds: nil) && m.previewKey == ("whatsapp.media.voice", ""))
+ } else { check("audio parsed", false) }
+
+ check("a receipt is ignored", WAWebhook.parse(kind: .gowa, body: Data(gowaAck.utf8)) == .ignored)
+ check("not JSON → nil", WAWebhook.parse(kind: .gowa, body: Data("nope".utf8)) == nil)
+
+ if case .message(let m) = WAWebhook.parse(kind: .gowa, body: Data(gowaGroupMention.utf8)) {
+ check("a group mention of the account", m.mentionsMe && m.sender == "[email protected]")
+ var inbox = WAInbox()
+ check("…reaches the pill despite muted groups", inbox.add(m, filters: WAFilters()) == .notify)
+ } else { check("group parsed", false) }
+ }
+
+ print("\nOpenWA webhook (docs/06, docs/12, docs/22)")
+ do {
+ if case .message(let m) = WAWebhook.parse(kind: .openwa, body: Data(openwaText.utf8)) {
+ check("id and chat", m.id == "ABC123_DEF456" && m.chat == "[email protected]")
+ check("epoch seconds", m.date == Date(timeIntervalSince1970: 1_706_868_600))
+ check("text", m.text == "Hello!" && !m.fromMe)
+ var inbox = WAInbox()
+ inbox.add(m, filters: WAFilters())
+ check("@c.us folded into the same chat as GOWA's form",
+ inbox.conversations["[email protected]"] != nil)
+ } else { check("text parsed", false) }
+
+ check("missing fields tolerated", {
+ if case .message(let m) = WAWebhook.parse(kind: .openwa, body: Data(openwaMinimal.utf8)) {
+ return m.id == "3EB0F5A2B4C..." && !m.fromMe
+ }
+ return false
+ }())
+
+ if case .message(let m) = WAWebhook.parse(kind: .openwa, body: Data(openwaGroupVoice.utf8), me: "6280000000000") {
+ check("group sender is the author", m.sender == "[email protected]" && m.senderName == "Budi")
+ check("voice label", m.media == .voice(seconds: nil))
+ check("mentionedIds name the account", m.mentionsMe)
+ } else { check("group parsed", false) }
+
+ let test = #"{"event":"test","data":{"message":"This is a test webhook from OpenWA","webhookId":"w","url":"u"}}"#
+ check("the test ping is ignored", WAWebhook.parse(kind: .openwa, body: Data(test.utf8)) == .ignored)
+ let sent = openwaText.replacingOccurrences(of: "message.received", with: "message.sent")
+ .replacingOccurrences(of: #""fromMe": false"#, with: #""fromMe": true"#)
+ if case .message(let m) = WAWebhook.parse(kind: .openwa, body: Data(sent.utf8)) {
+ check("message.sent is mine", m.fromMe)
+ } else { check("sent parsed", false) }
+ }
+
+ print("\nSignatures")
+ do {
+ // OpenWA sdk/javascript/test/webhook.test.ts: "the gateway's generateSignature produces
+ // this header for this body".
+ let secret = "test-secret-0123456789"
+ let body = Data(#"{"event":"message.received","timestamp":"2026-02-02T10:00:00.000Z","sessionId":"s1","idempotencyKey":"k","deliveryId":"dlv_1","data":{"text":"héllo 👋"}}"#.utf8)
+ let header = "sha256=d74a41bb687f31ed4c932f76f524116100ca4120d2cabb7a469ee5d928122f70"
+ check("OpenWA's own fixture", WAWebhook.signature(body: body, secret: secret) == header)
+ check("verified", WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": header], body: body, secret: secret))
+ var flipped = body
+ flipped[flipped.startIndex + 3] ^= 1
+ check("a flipped byte fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": header], body: flipped, secret: secret))
+ check("the wrong secret fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": header], body: body, secret: secret + "x"))
+ check("no prefix fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": String(header.dropFirst(7))], body: body, secret: secret))
+ check("SHA256= fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": "SHA256=" + header.dropFirst(7)], body: body, secret: secret))
+ check("truncated fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": String(header.dropLast())], body: body, secret: secret))
+ check("missing header fails", !WAWebhook.verify(kind: .openwa, headers: [:], body: body, secret: secret))
+ check("empty secret fails", !WAWebhook.verify(kind: .openwa, headers: ["x-openwa-signature": header], body: body, secret: ""))
+ check("GOWA's header is its own", !WAWebhook.verify(kind: .gowa, headers: ["x-openwa-signature": header], body: body, secret: secret))
+ // RFC 4231 test case 2 (GOWA prints no fixture; same HMAC-SHA256, hex lowercase).
+ check("RFC 4231", WAWebhook.signature(body: Data("what do ya want for nothing?".utf8), secret: "Jefe")
+ == "sha256=5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843")
+ let long = String(repeating: "k", count: 100)
+ let sig = WAWebhook.signature(body: Data("x".utf8), secret: long)
+ check("a key longer than a block", sig.count == 71 && WAWebhook.verify(kind: .gowa, headers: ["x-hub-signature-256": sig], body: Data("x".utf8), secret: long))
+ }
+
+ print("\nREST answers")
+ do {
+ let devices = #"{"code":"SUCCESS","message":"List devices","results":[{"id":"coucou","state":"disconnected","created_at":"2024-01-01T00:00:00Z"},{"id":"my-device-id","phone_number":"628123456789","display_name":"John Doe","state":"logged_in","jid":"[email protected]","created_at":"2024-01-01T00:00:00Z"}]}"#
+ let d = WAGOWA.device(Data(devices.utf8))
+ check("GOWA: the logged-in device", d?.id == "my-device-id" && d?.status == WAStatus(link: .connected, me: "[email protected]"))
+ let fresh = #"{"code":"SUCCESS","message":"List devices","results":[{"id":"coucou","state":"disconnected","created_at":"2024-01-01T00:00:00Z"}]}"#
+ check("GOWA: never logged in → QR", WAGOWA.device(Data(fresh.utf8))?.status.link == .needsQR)
+ check("GOWA: no device", WAGOWA.device(Data(#"{"code":"SUCCESS","message":"x","results":[]}"#.utf8)) == nil)
+ let login = #"{"code":"SUCCESS","message":"Success","results":{"device_id":"coucou","qr_duration":30,"qr_link":"http://localhost:3000/statics/qrcode/scan-qr-b0b7bb43-9a22-455a-814f-5a225c743310.png"}}"#
+ let qr = WAGOWA.qrPath(Data(login.utf8))
+ check("GOWA: QR path only, fetched from the gateway", qr?.path == "/statics/qrcode/scan-qr-b0b7bb43-9a22-455a-814f-5a225c743310.png" && qr?.seconds == 30)
+ check("GOWA: error code", WAGOWA.errorCode(Data(#"{"code":"ALREADY_LOGGED_IN","message":"you are already logged in."}"#.utf8)) == "ALREADY_LOGGED_IN")
+
+ let msgs = #"{"code":"SUCCESS","message":"ok","results":{"data":[{"id":"M2","chat_jid":"[email protected]","sender_jid":"[email protected]","sender_display_name":"John","content":"","timestamp":"2025-07-13T11:06:00Z","is_from_me":false,"media_type":"document","filename":"devis.pdf"},{"id":"M1","chat_jid":"[email protected]","sender_jid":"[email protected]","content":"salut","timestamp":"2025-07-13T11:05:00Z","is_from_me":true,"media_type":""}],"pagination":{"limit":10,"offset":0,"total":2},"chat_info":{"jid":"[email protected]","name":"Famille","last_message_time":"2025-07-13T11:06:00Z"}}}"#
+ let list = WAGOWA.messages(Data(msgs.utf8), me: nil)
+ check("GOWA stored messages", list.count == 2 && list[0].media == .document(name: "devis.pdf") && list[1].fromMe)
+ check("GOWA group name from chat_info", list[0].chatName == "Famille")
+ let chats = #"{"code":"SUCCESS","message":"ok","results":{"data":[{"jid":"[email protected]","name":"John","last_message_time":"2025-07-13T11:06:00Z","archived":false}],"pagination":{"limit":25,"offset":0,"total":1}}}"#
+ check("GOWA chats", WAGOWA.chats(Data(chats.utf8)).first?.name == "John")
+
+ let session = #"[{"id":"0b5d6c3e-1111-4a2b-9c3d-123456789abc","name":"coucou","status":"ready","phone":"628123456789","pushName":"Me"}]"#
+ let s = WAOpenWA.firstSession(Data(session.utf8))
+ check("OpenWA session", s?.id == "0b5d6c3e-1111-4a2b-9c3d-123456789abc" && s.map(WAOpenWA.status) == WAStatus(link: .connected, me: "628123456789"))
+ check("OpenWA QR state", WAOpenWA.status((id: "x", status: "qr_ready", phone: nil)).link == .needsQR)
+ check("OpenWA start when stopped", WAOpenWA.needsStart("created") && !WAOpenWA.needsStart("qr_ready"))
+ let png = Data([0x89, 0x50, 0x4E, 0x47])
+ let qrBody = #"{"qrCode":"data:image/png;base64,\#(png.base64EncodedString())","status":"qr_ready"}"#
+ check("OpenWA QR data URL", WAOpenWA.qrPNG(Data(qrBody.utf8)) == png)
+ let stored = #"{"messages":[{"id":"9f0c","sessionId":"s","waMessageId":"3EB0AB","chatId":"[email protected]","from":"[email protected]","to":"[email protected]","chatName":"Alice","author":null,"body":"See you","type":"text","direction":"incoming","timestamp":1719306115,"metadata":null,"status":"delivered","createdAt":"2024-06-25T09:01:55Z"}],"total":1}"#
+ let om = WAOpenWA.messages(Data(stored.utf8), me: nil)
+ check("OpenWA stored messages", om.first?.id == "3EB0AB" && om.first?.chatName == "Alice" && om.first?.fromMe == false)
+ let oc = #"[{"id":"[email protected]","name":"Alice","isGroup":false,"kind":"individual","unreadCount":2,"timestamp":1719306115,"lastMessage":"See you tomorrow","lastMessageType":"text","archived":false,"pinned":false,"muted":false}]"#
+ check("OpenWA chats", WAOpenWA.chats(Data(oc.utf8)).first?.unread == 2)
+ check("OpenWA error, string or list", WAOpenWA.errorMessage(Data(#"{"statusCode":400,"message":["a","b"],"error":"Bad Request"}"#.utf8)) == "a, b")
+ }
+
+ print("\nMentions and ids")
+ do {
+ check("same user across forms", WAJID.sameUser("[email protected]", "628:[email protected]") && !WAJID.sameUser("[email protected]", "[email protected]"))
+ check("a mention needs the whole number", WAMention.textMentions("hey @33612345678!", me: "[email protected]")
+ && !WAMention.textMentions("hey @336", me: "[email protected]"))
+ var inbox = WAInbox()
+ inbox.add(WAMessage(id: "o1", chat: "[email protected]", sender: "me", senderName: "Louis", text: "yo",
+ date: Date(), fromMe: true), filters: WAFilters())
+ check("my own first message doesn't name the chat after me",
+ inbox.conversations["[email protected]"]?.name == "+33600000003")
+ inbox.add(WAMessage(id: "o2", chat: "[email protected]", sender: "x", senderName: "Marie", text: "yo",
+ date: Date()), filters: WAFilters())
+ check("…their reply does", inbox.conversations["[email protected]"]?.name == "Marie")
+ }
+ }
+}
diff --git a/windows/src/i18n/strings.json b/windows/src/i18n/strings.json
index 8f4a06fa..3245e925 100644
--- a/windows/src/i18n/strings.json
+++ b/windows/src/i18n/strings.json
@@ -90,6 +90,17 @@
"ru": "Неверное слово или не тот человек? Исправьте через меню ⋯ строки. Исправленные слова запоминаются для следующих звонков.",
"id": "Kata yang salah, atau orang yang salah? Perbaiki dari menu ⋯ di baris itu. Kata yang kamu perbaiki diingat untuk panggilan berikutnya."
},
+ "API key (owa_k1_…)": {
+ "zh-Hans": "API 密钥(owa_k1_…)",
+ "hi": "API कुंजी (owa_k1_…)",
+ "es": "Clave API (owa_k1_…)",
+ "ar": "مفتاح API (owa_k1_…)",
+ "fr": "Clé API (owa_k1_…)",
+ "bn": "API কী (owa_k1_…)",
+ "pt-BR": "Chave de API (owa_k1_…)",
+ "ru": "API-ключ (owa_k1_…)",
+ "id": "Kunci API (owa_k1_…)"
+ },
"API key (AI Studio)": {
"zh-Hans": "API 密钥 (AI Studio)",
"hi": "API कुंजी (AI Studio)",
@@ -607,6 +618,17 @@
"ru": "Автоматизация не разрешена",
"id": "Otomatisasi tidak diizinkan"
},
+ "Basic auth (user:password, if set)": {
+ "zh-Hans": "基本认证(用户:密码,如已设置)",
+ "hi": "बेसिक ऑथ (user:password, अगर सेट हो)",
+ "es": "Auth básica (usuario:contraseña, si la hay)",
+ "ar": "مصادقة أساسية (مستخدم:كلمة مرور، إن وُجدت)",
+ "fr": "Auth basique (utilisateur:mot de passe, si activée)",
+ "bn": "বেসিক অথ (user:password, থাকলে)",
+ "pt-BR": "Auth básica (usuário:senha, se houver)",
+ "ru": "Basic auth (пользователь:пароль, если задан)",
+ "id": "Basic auth (pengguna:sandi, jika ada)"
+ },
"Battery {0} %": {
"zh-Hans": "电量 {0}%",
"hi": "बैटरी {0} %",
@@ -783,6 +805,17 @@
"ru": "Чат — другие провайдеры",
"id": "Chat — penyedia lain"
},
+ "Checking for new messages every 20 s.": {
+ "zh-Hans": "每 20 秒检查一次新消息。",
+ "hi": "हर 20 सेकंड में नए संदेश जाँचे जा रहे हैं।",
+ "es": "Comprobando mensajes nuevos cada 20 s.",
+ "ar": "التحقق من الرسائل الجديدة كل 20 ث.",
+ "fr": "Vérification des nouveaux messages toutes les 20 s.",
+ "bn": "প্রতি ২০ সেকেন্ডে নতুন বার্তা দেখা হচ্ছে।",
+ "pt-BR": "Verificando novas mensagens a cada 20 s.",
+ "ru": "Проверка новых сообщений каждые 20 с.",
+ "id": "Memeriksa pesan baru setiap 20 dtk."
+ },
"Choose the tools you use. Coucou only shows what you declare here.": {
"zh-Hans": "选择你使用的工具。Coucou 只显示你在这里声明的内容。",
"hi": "वे टूल चुनें जो आप उपयोग करते हैं। Coucou केवल वही दिखाता है जो आप यहाँ घोषित करते हैं।",
@@ -1146,6 +1179,28 @@
"ru": "Подключено",
"id": "Terhubung"
},
+ "Connected as {0}": {
+ "zh-Hans": "已连接:{0}",
+ "hi": "{0} के रूप में कनेक्टेड",
+ "es": "Conectado como {0}",
+ "ar": "متصل باسم {0}",
+ "fr": "Connecté en tant que {0}",
+ "bn": "{0} হিসেবে সংযুক্ত",
+ "pt-BR": "Conectado como {0}",
+ "ru": "Подключено как {0}",
+ "id": "Terhubung sebagai {0}"
+ },
+ "Connected as {0}.": {
+ "zh-Hans": "已连接:{0}。",
+ "hi": "{0} के रूप में कनेक्टेड।",
+ "es": "Conectado como {0}.",
+ "ar": "متصل باسم {0}.",
+ "fr": "Connecté en tant que {0}.",
+ "bn": "{0} হিসেবে সংযুক্ত।",
+ "pt-BR": "Conectado como {0}.",
+ "ru": "Подключено как {0}.",
+ "id": "Terhubung sebagai {0}."
+ },
"Connected · loading…": {
"zh-Hans": "已连接 · 加载中…",
"hi": "जुड़ा है · लोड हो रहा है…",
@@ -1168,6 +1223,17 @@
"ru": "Подключено · {detail}",
"id": "Terhubung · {detail}"
},
+ "Connecting to the gateway…": {
+ "zh-Hans": "正在连接网关…",
+ "hi": "गेटवे से जुड़ रहा है…",
+ "es": "Conectando con la pasarela…",
+ "ar": "جارٍ الاتصال بالبوابة…",
+ "fr": "Connexion à la passerelle…",
+ "bn": "গেটওয়েতে সংযুক্ত হচ্ছে…",
+ "pt-BR": "Conectando ao gateway…",
+ "ru": "Подключение к шлюзу…",
+ "id": "Menghubungkan ke gateway…"
+ },
"Connecting…": {
"zh-Hans": "正在连接…",
"hi": "कनेक्ट हो रहा है…",
@@ -1179,6 +1245,17 @@
"ru": "Подключение…",
"id": "Menghubungkan…"
},
+ "Contact": {
+ "zh-Hans": "联系人",
+ "hi": "संपर्क",
+ "es": "Contacto",
+ "ar": "جهة اتصال",
+ "fr": "Contact",
+ "bn": "পরিচিতি",
+ "pt-BR": "Contato",
+ "ru": "Контакт",
+ "id": "Kontak"
+ },
"Continue…": {
"zh-Hans": "继续…",
"hi": "जारी रखें…",
@@ -1322,6 +1399,17 @@
"ru": "Coucou составляет расшифровку по участникам…",
"id": "Coucou sedang menulis transkrip, per orang…"
},
+ "Coucou only talks to the gateway on this Mac. Messages stay in memory, are never logged or saved, and are forgotten when Coucou quits. No photo or media is ever downloaded.": {
+ "zh-Hans": "Coucou 只与这台 Mac 上的网关通信。消息只保存在内存中,从不记录或保存,退出 Coucou 时即被清除。从不下载任何照片或媒体。",
+ "hi": "Coucou सिर्फ़ इस Mac पर चल रहे गेटवे से बात करता है। संदेश मेमोरी में रहते हैं, कभी लॉग या सेव नहीं होते, और Coucou बंद होने पर भुला दिए जाते हैं। कोई फ़ोटो या मीडिया डाउनलोड नहीं होता।",
+ "es": "Coucou solo habla con la pasarela de este Mac. Los mensajes se quedan en memoria, nunca se registran ni se guardan, y se olvidan al cerrar Coucou. Nunca se descarga ninguna foto ni archivo.",
+ "ar": "يتواصل Coucou فقط مع البوابة على هذا الـMac. تبقى الرسائل في الذاكرة، ولا تُسجَّل ولا تُحفَظ أبدًا، وتُنسى عند إغلاق Coucou. لا تُنزَّل أي صورة أو وسائط.",
+ "fr": "Coucou ne parle qu’à la passerelle sur ce Mac. Les messages restent en mémoire, ne sont jamais journalisés ni enregistrés, et sont oubliés quand Coucou quitte. Aucune photo ni aucun média n’est téléchargé.",
+ "bn": "Coucou শুধু এই Mac-এর গেটওয়ের সঙ্গে কথা বলে। বার্তা মেমরিতে থাকে, কখনও লগ বা সেভ হয় না, এবং Coucou বন্ধ হলে মুছে যায়। কোনো ছবি বা মিডিয়া ডাউনলোড হয় না।",
+ "pt-BR": "O Coucou só fala com o gateway neste Mac. As mensagens ficam na memória, nunca são registradas nem salvas e são esquecidas quando o Coucou fecha. Nenhuma foto ou mídia é baixada.",
+ "ru": "Coucou общается только со шлюзом на этом Mac. Сообщения хранятся в памяти, никогда не пишутся в журнал и не сохраняются, и забываются при выходе из Coucou. Фото и медиа не загружаются.",
+ "id": "Coucou hanya berbicara dengan gateway di Mac ini. Pesan tetap di memori, tidak pernah dicatat atau disimpan, dan dilupakan saat Coucou ditutup. Tidak ada foto atau media yang diunduh."
+ },
"Coucou reads back results in the spoken language, using a synthesized voice. 100% on-device.": {
"zh-Hans": "Coucou 用语音语言朗读结果。完全在设备上处理。",
"hi": "Coucou बोली जाने वाली भाषा में परिणाम पढ़ता है। सब कुछ डिवाइस पर।",
@@ -1355,6 +1443,17 @@
"ru": "Coucou записывает звонки текстом прямо на Mac с помощью Parakeet и различает голоса второй небольшой моделью. Обе скачиваются один раз (около 650 МБ), дальше всё работает без сети.",
"id": "Coucou menulis panggilanmu di Mac dengan Parakeet, dan membedakan suara dengan model kecil kedua. Keduanya diunduh sekali (sekitar 650 MB), lalu semuanya bekerja luring."
},
+ "Coucou’s webhook port": {
+ "zh-Hans": "Coucou 的 Webhook 端口",
+ "hi": "Coucou का वेबहुक पोर्ट",
+ "es": "Puerto del webhook de Coucou",
+ "ar": "منفذ webhook في Coucou",
+ "fr": "Port du webhook de Coucou",
+ "bn": "Coucou-র ওয়েবহুক পোর্ট",
+ "pt-BR": "Porta do webhook do Coucou",
+ "ru": "Порт вебхука Coucou",
+ "id": "Port webhook Coucou"
+ },
"Counted on your Mac, never sent anywhere.": {
"zh-Hans": "在你的 Mac 上统计,从不发送。",
"hi": "आपके Mac पर गिनी जाती हैं, कहीं भेजी नहीं जातीं।",
@@ -1586,6 +1685,17 @@
"ru": "Отключить",
"id": "Putuskan"
},
+ "Document": {
+ "zh-Hans": "文档",
+ "hi": "दस्तावेज़",
+ "es": "Documento",
+ "ar": "مستند",
+ "fr": "Document",
+ "bn": "ডকুমেন্ট",
+ "pt-BR": "Documento",
+ "ru": "Документ",
+ "id": "Dokumen"
+ },
"Don't keep": {
"zh-Hans": "不保留",
"hi": "न रखें",
@@ -1971,6 +2081,17 @@
"ru": "Полные предложения и абзацы — для писем.",
"id": "Kalimat lengkap dan paragraf, untuk email."
},
+ "Gateway": {
+ "zh-Hans": "网关",
+ "hi": "गेटवे",
+ "es": "Pasarela",
+ "ar": "البوابة",
+ "fr": "Passerelle",
+ "bn": "গেটওয়ে",
+ "pt-BR": "Gateway",
+ "ru": "Шлюз",
+ "id": "Gateway"
+ },
"Gemini CLI hooks": {
"zh-Hans": "Gemini CLI 钩子",
"hi": "Gemini CLI हुक",
@@ -2389,6 +2510,28 @@
"ru": "Наведение открывает остров; он сворачивается вскоре после того, как указатель уходит. Щёлкните внутри, чтобы он остался открытым.",
"id": "Mengarahkan kursor ke pulau akan membukanya; pulau menutup lagi sesaat setelah kursor pergi. Klik di dalamnya agar tetap terbuka."
},
+ "Ignore this chat": {
+ "zh-Hans": "忽略此聊天",
+ "hi": "इस चैट को अनदेखा करें",
+ "es": "Ignorar este chat",
+ "ar": "تجاهل هذه الدردشة",
+ "fr": "Ignorer ce chat",
+ "bn": "এই চ্যাট উপেক্ষা করো",
+ "pt-BR": "Ignorar esta conversa",
+ "ru": "Игнорировать этот чат",
+ "id": "Abaikan chat ini"
+ },
+ "Ignored chats": {
+ "zh-Hans": "已忽略的聊天",
+ "hi": "अनदेखी चैट",
+ "es": "Chats ignorados",
+ "ar": "الدردشات المتجاهَلة",
+ "fr": "Chats ignorés",
+ "bn": "উপেক্ষিত চ্যাট",
+ "pt-BR": "Conversas ignoradas",
+ "ru": "Игнорируемые чаты",
+ "id": "Chat yang diabaikan"
+ },
"Inbox": {
"zh-Hans": "收件箱",
"hi": "इनबॉक्स",
@@ -2675,6 +2818,17 @@
"ru": "В реальном времени",
"id": "Langsung"
},
+ "Live: new messages arrive at once.": {
+ "zh-Hans": "实时:新消息会立即送达。",
+ "hi": "लाइव: नए संदेश तुरंत आते हैं।",
+ "es": "En directo: los mensajes nuevos llegan al instante.",
+ "ar": "مباشر: تصل الرسائل الجديدة فورًا.",
+ "fr": "En direct : les nouveaux messages arrivent tout de suite.",
+ "bn": "লাইভ: নতুন বার্তা সঙ্গে সঙ্গে আসে।",
+ "pt-BR": "Ao vivo: as novas mensagens chegam na hora.",
+ "ru": "В реальном времени: новые сообщения приходят сразу.",
+ "id": "Langsung: pesan baru datang seketika."
+ },
"Loading models…": {
"zh-Hans": "正在加载模型…",
"hi": "मॉडल लोड हो रहे हैं…",
@@ -2752,6 +2906,17 @@
"ru": "Локальные модели",
"id": "Model lokal"
},
+ "Location": {
+ "zh-Hans": "位置",
+ "hi": "लोकेशन",
+ "es": "Ubicación",
+ "ar": "موقع",
+ "fr": "Position",
+ "bn": "লোকেশন",
+ "pt-BR": "Localização",
+ "ru": "Местоположение",
+ "id": "Lokasi"
+ },
"Longest session": {
"zh-Hans": "最长会话",
"hi": "सबसे लंबा सेशन",
@@ -2818,6 +2983,17 @@
"ru": "Главный: {0}",
"id": "Utama: {0}"
},
+ "Make room in Active pills to show the WhatsApp pill (4 at most).": {
+ "zh-Hans": "请在“活跃胶囊”中腾出位置以显示 WhatsApp(最多 4 个)。",
+ "hi": "WhatsApp पिल दिखाने के लिए सक्रिय पिल्स में जगह बनाएँ (अधिकतम 4)।",
+ "es": "Libera un hueco en Píldoras activas para mostrar la de WhatsApp (4 como máximo).",
+ "ar": "أفرغ مكانًا في الحبوب النشطة لعرض حبة واتساب (4 كحد أقصى).",
+ "fr": "Libère une place dans Pills actives pour afficher la pill WhatsApp (4 au maximum).",
+ "bn": "WhatsApp পিল দেখাতে সক্রিয় পিলে জায়গা খালি করুন (সর্বোচ্চ ৪টি)।",
+ "pt-BR": "Libere um espaço em Pílulas ativas para mostrar a do WhatsApp (no máximo 4).",
+ "ru": "Освободите место в активных пилюлях для WhatsApp (не больше 4).",
+ "id": "Kosongkan tempat di Pil aktif untuk menampilkan pil WhatsApp (maksimal 4)."
+ },
"Man": {
"zh-Hans": "男声",
"hi": "पुरुष",
@@ -2873,6 +3049,17 @@
"ru": "Мало памяти",
"id": "Memori menipis"
},
+ "Message": {
+ "zh-Hans": "消息",
+ "hi": "संदेश",
+ "es": "Mensaje",
+ "ar": "رسالة",
+ "fr": "Message",
+ "bn": "বার্তা",
+ "pt-BR": "Mensagem",
+ "ru": "Сообщение",
+ "id": "Pesan"
+ },
"Microphone unavailable": {
"zh-Hans": "麦克风不可用",
"hi": "माइक्रोफ़ोन अनुपलब्ध",
@@ -3016,6 +3203,17 @@
"ru": "Выключить / включить звук",
"id": "Bisukan / aktifkan suara"
},
+ "Mute groups (unless I’m mentioned)": {
+ "zh-Hans": "群组静音(除非提到我)",
+ "hi": "ग्रुप म्यूट करें (जब तक मेरा ज़िक्र न हो)",
+ "es": "Silenciar grupos (salvo si me mencionan)",
+ "ar": "كتم المجموعات (إلا إذا أُشير إليّ)",
+ "fr": "Groupes muets (sauf si on me mentionne)",
+ "bn": "গ্রুপ মিউট (আমাকে উল্লেখ না করলে)",
+ "pt-BR": "Silenciar grupos (exceto quando me mencionam)",
+ "ru": "Без звука в группах (если меня не упомянули)",
+ "id": "Bisukan grup (kecuali saya disebut)"
+ },
"My PRs": {
"zh-Hans": "我的 PR",
"hi": "मेरे PR",
@@ -3269,6 +3467,17 @@
"ru": "Нет музыкального приложения",
"id": "Tidak ada app musik"
},
+ "No new messages": {
+ "zh-Hans": "没有新消息",
+ "hi": "कोई नया संदेश नहीं",
+ "es": "No hay mensajes nuevos",
+ "ar": "لا رسائل جديدة",
+ "fr": "Aucun nouveau message",
+ "bn": "নতুন বার্তা নেই",
+ "pt-BR": "Nenhuma mensagem nova",
+ "ru": "Нет новых сообщений",
+ "id": "Tidak ada pesan baru"
+ },
"No other open app": {
"zh-Hans": "没有其他打开的 App",
"hi": "कोई और ऐप खुला नहीं",
@@ -3566,6 +3775,17 @@
"ru": "Ollama отключён.",
"id": "Ollama terputus."
},
+ "On your phone: WhatsApp › Settings › Linked devices › Link a device, then scan this code.": {
+ "zh-Hans": "在手机上:WhatsApp › 设置 › 已关联的设备 › 关联新设备,然后扫描此二维码。",
+ "hi": "फ़ोन पर: WhatsApp › सेटिंग्स › लिंक किए गए डिवाइस › डिवाइस लिंक करें, फिर यह कोड स्कैन करें।",
+ "es": "En tu teléfono: WhatsApp › Ajustes › Dispositivos vinculados › Vincular un dispositivo, y escanea este código.",
+ "ar": "على هاتفك: واتساب › الإعدادات › الأجهزة المرتبطة › ربط جهاز، ثم امسح هذا الرمز.",
+ "fr": "Sur ton téléphone : WhatsApp › Réglages › Appareils connectés › Connecter un appareil, puis scanne ce code.",
+ "bn": "ফোনে: WhatsApp › সেটিংস › লিঙ্ক করা ডিভাইস › ডিভাইস লিঙ্ক করুন, তারপর এই কোডটি স্ক্যান করুন।",
+ "pt-BR": "No celular: WhatsApp › Configurações › Dispositivos conectados › Conectar dispositivo, e escaneie este código.",
+ "ru": "На телефоне: WhatsApp › Настройки › Связанные устройства › Привязка устройства, затем отсканируйте этот код.",
+ "id": "Di ponsel: WhatsApp › Setelan › Perangkat tertaut › Tautkan perangkat, lalu pindai kode ini."
+ },
"On-device when your Mac supports it, nothing to download.": {
"zh-Hans": "Mac 支持时在设备上完成,无需下载。",
"hi": "Mac समर्थन करे तो डिवाइस पर ही, कुछ डाउनलोड नहीं करना।",
@@ -4127,6 +4347,28 @@
"ru": "Участник {0}",
"id": "Orang {0}"
},
+ "Phone number or chat id to ignore": {
+ "zh-Hans": "要忽略的号码或聊天 ID",
+ "hi": "अनदेखा करने के लिए नंबर या चैट id",
+ "es": "Número o id de chat que ignorar",
+ "ar": "رقم أو معرّف دردشة لتجاهله",
+ "fr": "Numéro ou identifiant de chat à ignorer",
+ "bn": "উপেক্ষা করার নম্বর বা চ্যাট id",
+ "pt-BR": "Número ou id da conversa a ignorar",
+ "ru": "Номер или id чата для игнорирования",
+ "id": "Nomor atau id chat yang diabaikan"
+ },
+ "Photo": {
+ "zh-Hans": "照片",
+ "hi": "फ़ोटो",
+ "es": "Foto",
+ "ar": "صورة",
+ "fr": "Photo",
+ "bn": "ছবি",
+ "pt-BR": "Foto",
+ "ru": "Фото",
+ "id": "Foto"
+ },
"Pin / unpin notch": {
"zh-Hans": "固定/取消固定岛",
"hi": "आइलैंड पिन / अनपिन",
@@ -4237,6 +4479,17 @@
"ru": "Аккуратный",
"id": "Rapi"
},
+ "Port {0} is taken: pick another one. Checking every 20 s meanwhile.": {
+ "zh-Hans": "端口 {0} 已被占用:请换一个。在此期间每 20 秒检查一次。",
+ "hi": "पोर्ट {0} पहले से इस्तेमाल में है: कोई और चुनें। तब तक हर 20 सेकंड में जाँच।",
+ "es": "El puerto {0} está ocupado: elige otro. Mientras tanto, se comprueba cada 20 s.",
+ "ar": "المنفذ {0} مستخدم: اختر منفذًا آخر. في الأثناء يتم التحقق كل 20 ث.",
+ "fr": "Le port {0} est déjà pris : choisis-en un autre. Vérification toutes les 20 s en attendant.",
+ "bn": "পোর্ট {0} ব্যস্ত: অন্যটি বেছে নিন। ততক্ষণ প্রতি ২০ সেকেন্ডে দেখা হচ্ছে।",
+ "pt-BR": "A porta {0} está ocupada: escolha outra. Enquanto isso, verificando a cada 20 s.",
+ "ru": "Порт {0} занят: выберите другой. Пока проверка каждые 20 с.",
+ "id": "Port {0} sudah dipakai: pilih yang lain. Sementara itu diperiksa setiap 20 dtk."
+ },
"Previous": {
"zh-Hans": "上一首",
"hi": "पिछला",
@@ -4457,6 +4710,17 @@
"ru": "Перезагрузить звуки",
"id": "Muat ulang suara"
},
+ "Remove": {
+ "zh-Hans": "移除",
+ "hi": "हटाएँ",
+ "es": "Quitar",
+ "ar": "إزالة",
+ "fr": "Retirer",
+ "bn": "সরাও",
+ "pt-BR": "Remover",
+ "ru": "Убрать",
+ "id": "Hapus"
+ },
"Remove from favorites": {
"zh-Hans": "取消收藏",
"hi": "पसंदीदा से हटाएँ",
@@ -4776,6 +5040,17 @@
"ru": "Говорите идею как получится: она вставится как чёткий промпт (цель, контекст, шаги, ограничения, критерии готовности) для Claude Code, Cursor или ChatGPT.",
"id": "Ucapkan idemu sesukamu: hasilnya ditempel sebagai prompt yang jelas (tujuan, konteks, langkah, batasan, selesai jika), siap untuk Claude Code, Cursor, atau ChatGPT."
},
+ "Scan the QR code in Settings": {
+ "zh-Hans": "请在设置中扫描二维码",
+ "hi": "सेटिंग्स में QR कोड स्कैन करें",
+ "es": "Escanea el código QR en Ajustes",
+ "ar": "امسح رمز QR في الإعدادات",
+ "fr": "Scanne le QR code dans les réglages",
+ "bn": "সেটিংসে QR কোড স্ক্যান করুন",
+ "pt-BR": "Escaneie o QR code nos Ajustes",
+ "ru": "Отсканируйте QR-код в настройках",
+ "id": "Pindai kode QR di Pengaturan"
+ },
"Schedule": {
"zh-Hans": "日程",
"hi": "शेड्यूल",
@@ -5040,6 +5315,17 @@
"ru": "Показывать остров горячей клавишей",
"id": "Tampilkan island dengan pintasan"
},
+ "Show my WhatsApp messages": {
+ "zh-Hans": "显示我的 WhatsApp 消息",
+ "hi": "मेरे WhatsApp संदेश दिखाएँ",
+ "es": "Mostrar mis mensajes de WhatsApp",
+ "ar": "عرض رسائل واتساب",
+ "fr": "Afficher mes messages WhatsApp",
+ "bn": "আমার WhatsApp বার্তা দেখাও",
+ "pt-BR": "Mostrar minhas mensagens do WhatsApp",
+ "ru": "Показывать мои сообщения WhatsApp",
+ "id": "Tampilkan pesan WhatsApp saya"
+ },
"Show my agent sessions on my iPhone": {
"zh-Hans": "在我的 iPhone 上显示我的 Agent 会话",
"hi": "मेरे iPhone पर मेरे एजेंट सेशन दिखाएं",
@@ -5183,6 +5469,28 @@
"ru": "Статистика",
"id": "Statistik"
},
+ "Stay quiet during a Focus": {
+ "zh-Hans": "专注模式期间保持安静",
+ "hi": "फ़ोकस के दौरान शांत रहें",
+ "es": "No molestar durante un modo Concentración",
+ "ar": "التزام الهدوء أثناء التركيز",
+ "fr": "Rester discret pendant une Concentration",
+ "bn": "ফোকাসের সময় চুপ থাকো",
+ "pt-BR": "Ficar quieto durante um Foco",
+ "ru": "Не беспокоить в режиме фокусирования",
+ "id": "Tetap tenang saat mode Fokus"
+ },
+ "Sticker": {
+ "zh-Hans": "贴纸",
+ "hi": "स्टिकर",
+ "es": "Sticker",
+ "ar": "ملصق",
+ "fr": "Sticker",
+ "bn": "স্টিকার",
+ "pt-BR": "Figurinha",
+ "ru": "Стикер",
+ "id": "Stiker"
+ },
"Stop": {
"zh-Hans": "停止",
"hi": "रोकें",
@@ -5370,6 +5678,17 @@
"ru": "Задачи",
"id": "Tugas"
},
+ "Test connection": {
+ "zh-Hans": "测试连接",
+ "hi": "कनेक्शन जाँचें",
+ "es": "Probar la conexión",
+ "ar": "اختبار الاتصال",
+ "fr": "Tester la connexion",
+ "bn": "সংযোগ পরীক্ষা",
+ "pt-BR": "Testar a conexão",
+ "ru": "Проверить подключение",
+ "id": "Uji koneksi"
+ },
"Test the voice": {
"zh-Hans": "试听声音",
"hi": "आवाज़ आज़माएँ",
@@ -5447,6 +5766,72 @@
"ru": "Для чистки нужен ваш ключ Claude. Добавьте его в Настройки → Чат.",
"id": "Perapian memakai kunci Claude-mu. Tambahkan di Pengaturan → Obrolan."
},
+ "The gateway URL isn’t valid (http://…)": {
+ "zh-Hans": "网关地址无效(http://…)",
+ "hi": "गेटवे URL मान्य नहीं है (http://…)",
+ "es": "La URL de la pasarela no es válida (http://…)",
+ "ar": "عنوان البوابة غير صالح (http://…)",
+ "fr": "L’URL de la passerelle n’est pas valide (http://…)",
+ "bn": "গেটওয়ের URL সঠিক নয় (http://…)",
+ "pt-BR": "A URL do gateway não é válida (http://…)",
+ "ru": "Неверный адрес шлюза (http://…)",
+ "id": "URL gateway tidak valid (http://…)"
+ },
+ "The gateway answers and is connecting to WhatsApp…": {
+ "zh-Hans": "网关有响应,正在连接 WhatsApp…",
+ "hi": "गेटवे जवाब दे रहा है और WhatsApp से जुड़ रहा है…",
+ "es": "La pasarela responde y se está conectando a WhatsApp…",
+ "ar": "البوابة تستجيب وتتصل بواتساب…",
+ "fr": "La passerelle répond et se connecte à WhatsApp…",
+ "bn": "গেটওয়ে সাড়া দিচ্ছে এবং WhatsApp-এ সংযুক্ত হচ্ছে…",
+ "pt-BR": "O gateway responde e está se conectando ao WhatsApp…",
+ "ru": "Шлюз отвечает и подключается к WhatsApp…",
+ "id": "Gateway merespons dan sedang terhubung ke WhatsApp…"
+ },
+ "The gateway answers. Scan the QR code below with your phone.": {
+ "zh-Hans": "网关有响应。请用手机扫描下面的二维码。",
+ "hi": "गेटवे जवाब दे रहा है। नीचे दिया QR कोड फ़ोन से स्कैन करें।",
+ "es": "La pasarela responde. Escanea el código QR de abajo con tu teléfono.",
+ "ar": "البوابة تستجيب. امسح رمز QR أدناه بهاتفك.",
+ "fr": "La passerelle répond. Scanne le QR code ci-dessous avec ton téléphone.",
+ "bn": "গেটওয়ে সাড়া দিচ্ছে। নিচের QR কোডটি ফোনে স্ক্যান করুন।",
+ "pt-BR": "O gateway responde. Escaneie o QR code abaixo com o celular.",
+ "ru": "Шлюз отвечает. Отсканируйте QR-код ниже телефоном.",
+ "id": "Gateway merespons. Pindai kode QR di bawah dengan ponselmu."
+ },
+ "The gateway doesn’t answer: is it running?": {
+ "zh-Hans": "网关没有响应:它在运行吗?",
+ "hi": "गेटवे जवाब नहीं दे रहा: क्या वह चल रहा है?",
+ "es": "La pasarela no responde: ¿está en marcha?",
+ "ar": "البوابة لا تستجيب: هل هي قيد التشغيل؟",
+ "fr": "La passerelle ne répond pas : est-elle lancée ?",
+ "bn": "গেটওয়ে সাড়া দিচ্ছে না: এটি চালু আছে?",
+ "pt-BR": "O gateway não responde: ele está rodando?",
+ "ru": "Шлюз не отвечает: он запущен?",
+ "id": "Gateway tidak merespons: apakah sedang berjalan?"
+ },
+ "The gateway refused Coucou’s address ({0}). Checking every 20 s instead.": {
+ "zh-Hans": "网关拒绝了 Coucou 的地址({0})。改为每 20 秒检查一次。",
+ "hi": "गेटवे ने Coucou का पता अस्वीकार किया ({0})। इसके बजाय हर 20 सेकंड में जाँच।",
+ "es": "La pasarela rechazó la dirección de Coucou ({0}). Se comprueba cada 20 s en su lugar.",
+ "ar": "رفضت البوابة عنوان Coucou ‏({0}). يتم التحقق كل 20 ث بدلًا من ذلك.",
+ "fr": "La passerelle a refusé l’adresse de Coucou ({0}). Vérification toutes les 20 s à la place.",
+ "bn": "গেটওয়ে Coucou-র ঠিকানা প্রত্যাখ্যান করেছে ({0})। এর বদলে প্রতি ২০ সেকেন্ডে দেখা হচ্ছে।",
+ "pt-BR": "O gateway recusou o endereço do Coucou ({0}). Verificando a cada 20 s no lugar.",
+ "ru": "Шлюз отклонил адрес Coucou ({0}). Вместо этого проверка каждые 20 с.",
+ "id": "Gateway menolak alamat Coucou ({0}). Sebagai gantinya diperiksa setiap 20 dtk."
+ },
+ "The gateway refuses the credentials": {
+ "zh-Hans": "网关拒绝了凭据",
+ "hi": "गेटवे ने क्रेडेंशियल अस्वीकार किए",
+ "es": "La pasarela rechaza las credenciales",
+ "ar": "البوابة ترفض بيانات الاعتماد",
+ "fr": "La passerelle refuse les identifiants",
+ "bn": "গেটওয়ে পরিচয়পত্র প্রত্যাখ্যান করছে",
+ "pt-BR": "O gateway recusa as credenciais",
+ "ru": "Шлюз отклоняет учётные данные",
+ "id": "Gateway menolak kredensial"
+ },
"The history is off. Turn it on in Settings → Privacy.": {
"zh-Hans": "历史记录已关闭。请在“设置”→“隐私”中打开。",
"hi": "इतिहास बंद है। इसे सेटिंग्स → गोपनीयता में चालू करें।",
@@ -5722,6 +6107,17 @@
"ru": "Включить диктовку",
"id": "Aktifkan dikte"
},
+ "Turned off in Settings": {
+ "zh-Hans": "已在设置中关闭",
+ "hi": "सेटिंग्स में बंद है",
+ "es": "Desactivado en Ajustes",
+ "ar": "متوقف في الإعدادات",
+ "fr": "Désactivé dans les réglages",
+ "bn": "সেটিংসে বন্ধ",
+ "pt-BR": "Desativado nos Ajustes",
+ "ru": "Выключено в настройках",
+ "id": "Dimatikan di Pengaturan"
+ },
"Uninstall": {
"zh-Hans": "卸载",
"hi": "अनइंस्टॉल करें",
@@ -5766,6 +6162,17 @@
"ru": "Без ограничений и бесплатно",
"id": "Tanpa batas dan gratis"
},
+ "Unofficial integration: it goes through a gateway you run on this Mac. Use it on your own account only. WhatsApp may restrict accounts that abuse it.": {
+ "zh-Hans": "非官方集成:通过你在这台 Mac 上运行的网关工作。仅限用于你自己的账号。滥用时 WhatsApp 可能会限制账号。",
+ "hi": "अनौपचारिक इंटीग्रेशन: यह इस Mac पर चल रहे गेटवे से होकर काम करता है। सिर्फ़ अपने अकाउंट पर इस्तेमाल करें। दुरुपयोग पर WhatsApp अकाउंट सीमित कर सकता है।",
+ "es": "Integración no oficial: pasa por una pasarela que ejecutas en este Mac. Úsala solo con tu propia cuenta. WhatsApp puede restringir las cuentas que abusen.",
+ "ar": "تكامل غير رسمي: يمرّ عبر بوابة تشغّلها على هذا الـMac. استخدمه على حسابك فقط. قد يقيّد واتساب الحسابات عند إساءة الاستخدام.",
+ "fr": "Intégration non officielle : elle passe par une passerelle que tu lances sur ce Mac. À utiliser sur ton propre compte uniquement. WhatsApp peut restreindre un compte en cas d’abus.",
+ "bn": "অনানুষ্ঠানিক ইন্টিগ্রেশন: এটি এই Mac-এ চালানো একটি গেটওয়ে দিয়ে কাজ করে। শুধু নিজের অ্যাকাউন্টে ব্যবহার করুন। অপব্যবহারে WhatsApp অ্যাকাউন্ট সীমিত করতে পারে।",
+ "pt-BR": "Integração não oficial: passa por um gateway que você executa neste Mac. Use só na sua própria conta. O WhatsApp pode restringir contas em caso de abuso.",
+ "ru": "Неофициальная интеграция: работает через шлюз, запущенный на этом Mac. Используйте только со своим аккаунтом. WhatsApp может ограничить аккаунт при злоупотреблении.",
+ "id": "Integrasi tidak resmi: berjalan lewat gateway yang kamu jalankan di Mac ini. Gunakan hanya di akunmu sendiri. WhatsApp bisa membatasi akun yang menyalahgunakannya."
+ },
"Until Parakeet is downloaded, Coucou uses your Mac's speech recognition.": {
"zh-Hans": "在下载 Parakeet 之前,Coucou 使用 Mac 的语音识别。",
"hi": "जब तक Parakeet डाउनलोड नहीं होता, Coucou Mac की वाक् पहचान इस्तेमाल करता है।",
@@ -5810,6 +6217,17 @@
"ru": "Используется чатом. Список берётся из твоего аккаунта Anthropic.",
"id": "Digunakan oleh chat. Daftar berasal dari akun Anthropic Anda."
},
+ "Video": {
+ "zh-Hans": "视频",
+ "hi": "वीडियो",
+ "es": "Vídeo",
+ "ar": "فيديو",
+ "fr": "Vidéo",
+ "bn": "ভিডিও",
+ "pt-BR": "Vídeo",
+ "ru": "Видео",
+ "id": "Video"
+ },
"Voice": {
"zh-Hans": "声音",
"hi": "आवाज़",
@@ -5832,6 +6250,17 @@
"ru": "Используется голос: {0}",
"id": "Suara yang dipakai: {0}"
},
+ "Voice message": {
+ "zh-Hans": "语音消息",
+ "hi": "वॉइस संदेश",
+ "es": "Audio",
+ "ar": "رسالة صوتية",
+ "fr": "Vocal",
+ "bn": "ভয়েস বার্তা",
+ "pt-BR": "Áudio",
+ "ru": "Голосовое",
+ "id": "Pesan suara"
+ },
"Voice type": {
"zh-Hans": "声音类型",
"hi": "आवाज़ का प्रकार",
@@ -6008,6 +6437,17 @@
"ru": "На каком бы языке вы ни говорили, вставится на: {0}.",
"id": "Apa pun bahasamu, ditempel dalam {0}."
},
+ "WhatsApp (experimental)": {
+ "zh-Hans": "WhatsApp(实验性)",
+ "hi": "WhatsApp (प्रायोगिक)",
+ "es": "WhatsApp (experimental)",
+ "ar": "واتساب (تجريبي)",
+ "fr": "WhatsApp (expérimental)",
+ "bn": "WhatsApp (পরীক্ষামূলক)",
+ "pt-BR": "WhatsApp (experimental)",
+ "ru": "WhatsApp (экспериментально)",
+ "id": "WhatsApp (eksperimental)"
+ },
"When Coucou hears the words on the left, it writes the ones on the right.": {
"zh-Hans": "Coucou 听到左边的词时,会写成右边的词。",
"hi": "जब Coucou बाईं ओर के शब्द सुनता है, तो दाईं ओर के शब्द लिखता है।",
@@ -6283,6 +6723,17 @@
"ru": "Вчера",
"id": "Kemarin"
},
+ "You": {
+ "zh-Hans": "你",
+ "hi": "आप",
+ "es": "Tú",
+ "ar": "أنت",
+ "fr": "Toi",
+ "bn": "আপনি",
+ "pt-BR": "Você",
+ "ru": "Вы",
+ "id": "Kamu"
+ },
"You say": {
"zh-Hans": "你说",
"hi": "आप बोलते हैं",
@@ -6503,6 +6954,17 @@
"ru": "только что",
"id": "baru saja"
},
+ "macOS doesn’t let this build of Coucou read the Focus state yet: messages still arrive, Mochi keeps reacting.": {
+ "zh-Hans": "macOS 暂不允许此版本的 Coucou 读取专注状态:消息仍会到达,Mochi 仍会做出反应。",
+ "hi": "macOS अभी Coucou के इस बिल्ड को फ़ोकस की स्थिति पढ़ने नहीं देता: संदेश आते रहेंगे, Mochi प्रतिक्रिया देता रहेगा।",
+ "es": "macOS aún no deja a esta versión de Coucou leer el estado de Concentración: los mensajes siguen llegando y Mochi sigue reaccionando.",
+ "ar": "لا يسمح macOS بعد لهذا الإصدار من Coucou بقراءة حالة التركيز: تستمر الرسائل في الوصول ويستمر Mochi في التفاعل.",
+ "fr": "macOS ne laisse pas encore cette version de Coucou lire l’état Concentration : les messages arrivent quand même, Mochi continue de réagir.",
+ "bn": "macOS এখনও Coucou-র এই বিল্ডকে ফোকাসের অবস্থা পড়তে দেয় না: বার্তা আসতে থাকবে, Mochi সাড়া দিতে থাকবে।",
+ "pt-BR": "O macOS ainda não deixa esta versão do Coucou ler o estado do Foco: as mensagens continuam chegando e o Mochi continua reagindo.",
+ "ru": "macOS пока не даёт этой сборке Coucou читать состояние фокусирования: сообщения приходят, Mochi реагирует.",
+ "id": "macOS belum mengizinkan build Coucou ini membaca status Fokus: pesan tetap masuk, Mochi tetap bereaksi."
+ },
"min without movement": {
"zh-Hans": "分钟无动作",
"hi": "मिनट बिना हलचल",