{"type":"state","session":"default","paused":false,"status":"qr","transportMode":"whatsapp-web.js","info":{"name":null,"redactedNumber":null},"totalConsented":15133,"totalPending":10,"uptimeSeconds":5929,"inbound":{"receivedTotal":186675,"ignoredTotal":241,"repliedTotal":186630,"syntheticInboundTotal":15885,"syntheticIgnoredTotal":0,"syntheticReplyTotal":15829,"syntheticAudioTranscribedTotal":182,"syntheticAudioTranscriptionErrorTotal":0,"syntheticVoiceReplyGeneratedTotal":273,"syntheticVoiceReplyPayloadTotal":273,"syntheticVoiceReplySentTotal":0,"syntheticVoiceReplyErrorTotal":4,"syntheticVoiceReplyCooldownSkipTotal":77,"syntheticProcessingTimeoutTotal":41,"syntheticHandlerErrorTotal":0,"audioTranscribedTotal":277,"audioTranscriptionErrorTotal":0,"voiceReplyGeneratedTotal":292,"voiceReplyPayloadTotal":248,"voiceReplySentTotal":0,"voiceReplyErrorTotal":40,"voiceReplyCooldownSkipTotal":26,"processingTimeoutTotal":43,"handlerErrorTotal":2,"ignoredByReason":{"empty_text":5,"status":225,"notification":11},"processStartedAt":"2026-08-06T14:51:37.863Z","updatedAt":"2026-08-06T14:51:37.863Z","lastInboundAt":"2026-08-06T14:19:59.034Z","lastInboundTransport":"openwa","lastInboundChat":"***0002","lastInboundType":"chat","lastPrimaryInboundAt":"2026-07-29T10:36:43.728Z","lastPrimaryInboundTransport":"whatsapp-web.js","lastPrimaryInboundChat":"***9102","lastPrimaryInboundType":"chat","lastOpenWAInboundAt":"2026-08-06T14:19:59.034Z","lastOpenWAInboundChat":"***0002","lastSyntheticInboundAt":"2026-08-06T14:00:21.754Z","lastSyntheticInboundTransport":"openwa","lastSyntheticInboundChat":"***9501","lastSyntheticInboundType":"chat","lastSyntheticIgnoredAt":null,"lastSyntheticIgnoredReason":null,"lastSyntheticReplyAt":"2026-08-06T14:00:23.278Z","lastSyntheticReplyTransport":"openwa","lastSyntheticReplyChat":"***9501","lastIgnoredAt":"2026-08-06T06:02:45.528Z","lastIgnoredReason":"status","lastIgnoredTransport":"whatsapp-web.js","lastIgnoredChat":null,"lastReplyAt":"2026-08-06T14:20:00.731Z","lastReplyTransport":"openwa","lastReplyChat":"***0002","lastPrimaryReplyAt":"2026-08-01T07:48:09.168Z","lastPrimaryReplyTransport":"whatsapp-web.js","lastPrimaryReplyChat":"***4138","lastOpenWAReplyAt":"2026-08-06T14:20:00.731Z","lastOpenWAReplyChat":"***0002","lastAudioTranscribedAt":"2026-06-30T11:52:14.344Z","lastAudioTranscriptionTransport":"openwa","lastAudioTranscriptionChat":"***7049","lastAudioTranscriptionType":"ptt","lastAudioTranscriptionMimeType":"audio/wav","lastAudioTranscriptionSizeBytes":74016,"lastAudioTranscriptionErrorAt":null,"lastAudioTranscriptionError":null,"lastVoiceReplyGeneratedAt":"2026-06-30T11:52:14.363Z","lastVoiceReplyPayloadAt":"2026-06-30T11:52:14.364Z","lastVoiceReplySentAt":null,"lastVoiceReplyTransport":"openwa","lastVoiceReplyChat":"***7049","lastVoiceReplyErrorAt":null,"lastVoiceReplyError":null,"voiceReplyTtsCooldownUntil":null,"voiceReplyTtsCooldownReason":null,"voiceReplyTtsCooldownSetAt":null,"lastVoiceReplyCooldownSkipAt":"2026-06-30T11:52:14.363Z","lastProcessingTimeoutAt":"2026-07-23T08:46:38.372Z","lastProcessingTimeoutTransport":"openwa","lastProcessingTimeoutChat":"***6002","lastProcessingTimeoutMs":9000,"lastHandlerErrorAt":"2026-06-29T11:35:46.039Z","lastHandlerError":"t","latency":{"count":0,"timeoutsLastHour":0}},"primaryInbound":{"ok":false,"transportMode":"whatsapp-web.js","verificationRequired":true,"blockingProductionOnly":false,"transportReachable":false,"lastPrimaryActivityAt":"2026-08-01T07:48:09.168Z","lastPrimaryAgeMs":463338199,"validMaxAgeMs":86400000,"lastAnyActivityAt":"2026-08-06T14:20:00.731Z","lastInboundTransport":"openwa","lastReplyTransport":"openwa","anyIsOnlyShadow":false,"reason":"primary_transport_observed_stale"},"responseReadiness":{"canAnswer":false,"reason":"transport_not_ready","paused":false,"status":"qr","unresolved":0,"tolerance":2,"receivedTotal":186675,"repliedTotal":186630,"ignoredTotal":241,"primaryInbound":{"ok":false,"transportMode":"whatsapp-web.js","verificationRequired":true,"blockingProductionOnly":false,"transportReachable":false,"lastPrimaryActivityAt":"2026-08-01T07:48:09.168Z","lastPrimaryAgeMs":463338199,"validMaxAgeMs":86400000,"lastAnyActivityAt":"2026-08-06T14:20:00.731Z","lastInboundTransport":"openwa","lastReplyTransport":"openwa","anyIsOnlyShadow":false,"reason":"primary_transport_observed_stale"},"lastInboundAt":"2026-08-06T14:19:59.034Z","lastReplyAt":"2026-08-06T14:20:00.731Z","lastIgnoredAt":"2026-08-06T06:02:45.528Z","lastIgnoredReason":"status","lastHandlerErrorAt":"2026-06-29T11:35:46.039Z","lastHandlerError":"t","processingTimeoutTotal":43},"transport":{"ok":false,"waState":null,"lastProbeAt":"2026-08-06T14:55:51.956Z","lastOkAt":null,"lastErrorAt":"2026-08-06T14:55:51.956Z","lastError":"bot status qr","latencyMs":0,"probeTimeoutMs":2500},"recentChats":{"ok":false,"lastProbeAt":null,"lastOkAt":null,"lastErrorAt":null,"lastError":null,"totalChats":0,"directChats":0,"groupChats":0,"unreadDirectChats":0,"unreadDirectTotal":0,"latestDirectAt":null,"latestDirectChat":null,"latestDirectFromMe":null,"latestDirectMessageAt":null,"latestDirectMessageType":null,"recentDirectWithin15m":0,"sample":[]},"missedInbound":{"enabled":true,"lastRunAt":null,"lastRecoveredAt":null,"lastErrorAt":null,"lastError":null,"runTotal":0,"recoveredTotal":0,"recoveredUnreadTotal":0,"recoveredRecentReadTotal":0,"skippedTotal":0,"recentReadScanTotal":0,"recentReadCandidateTotal":0,"recentReadSkippedTotal":0,"recentReadErrorTotal":0,"lastRecentReadErrorAt":null,"lastRecentReadError":null,"cachedFetchTotal":0,"cachedFetchHitTotal":0,"cachedFetchErrorTotal":0,"lastMessageFallbackTotal":0,"messageCreateBackstopSeenTotal":0,"messageCreateBackstopRecoveredTotal":0,"messageCreateBackstopSkippedTotal":0,"messageCreateBackstopDeferredTotal":0,"messageCreateBackstopErrorTotal":0,"lastMessageCreateBackstopErrorAt":null,"lastMessageCreateBackstopError":null,"transportMode":"whatsapp-web.js","recentReadLookbackMs":600000,"recentReadMaxChats":3},"connectedAccount":{"name":null,"redactedNumber":null},"inboundTesting":{"ready":false,"primaryInboundVerified":false,"primaryInboundReason":"primary_transport_observed_stale","connectedAccount":{"name":null,"redactedNumber":null},"selfAccountInboundBlocked":false,"requiredTestNumber":"external_consented_contact","pendingExternalCount":4,"consentedExternalCount":14894,"recommendedContact":{"chat":"***9102","status":"consented","since":"2026-07-29T10:36:43.934Z","reason":null,"action":"send_test_message_from_contact"},"candidates":[{"chat":"***9102","status":"consented","since":"2026-07-29T10:36:43.934Z","reason":null,"action":"send_test_message_from_contact"},{"chat":"***1679","status":"consented","since":"2026-07-22T07:22:20.626Z","reason":null,"action":"send_test_message_from_contact"},{"chat":"***6169","status":"consented","since":"2026-07-20T10:38:35.169Z","reason":null,"action":"send_test_message_from_contact"}],"nextAction":"Far inviare un messaggio WhatsApp di test dal numero ***9102.","canUseConnectedAccountForInbound":false,"reason":"connected_account_not_available","operatorHint":"Per i test inbound usa un numero WhatsApp diverso da quello collegato al bot."},"capabilities":{"audioTranscription":true,"voiceReply":true,"voiceReplyForAudio":true,"voiceReplyPrimaryDelivery":"whatsapp_webjs_media","voiceReplyDeliveryModes":{"openwa":"response_payload","whatsappWebJs":"direct_media"},"voiceReplyForAudioDailyLimit":3,"voiceReplyForAudioMaxChars":650,"voiceReplyFallback":{"available":true,"bytes":160464},"voiceReplyTtsCooldown":{"active":false,"until":null,"remainingMs":0,"reason":null,"label":null}},"productionGate":{"available":true,"status":"failed","stale":true,"finishedAt":"2026-07-23T10:16:44.421Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":1696931,"failedStep":"Health gate","totalSteps":5,"expectedStepCount":5,"passedSteps":2,"skippedSteps":0,"failedSteps":3,"valid":false},"preCutoverGate":{"available":true,"status":"failed","stale":true,"finishedAt":"2026-07-23T10:52:28.715Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":1098,"failedStep":"Full gate fresco","totalSteps":5,"expectedStepCount":5,"passedSteps":3,"skippedSteps":0,"failedSteps":2,"valid":false},"cutoverPreflight":{"available":true,"status":"failed","stale":true,"finishedAt":"2026-06-30T13:17:16.993Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":197,"failedStep":"Transport legacy operativo","totalSteps":18,"expectedStepCount":18,"passedSteps":13,"skippedSteps":0,"failedSteps":5,"valid":false},"cutoverGate":{"available":true,"status":"failed","stale":true,"finishedAt":"2026-06-30T13:17:31.279Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":5288,"failedStep":"OpenWA connected","totalSteps":1,"expectedStepCount":1,"passedSteps":0,"skippedSteps":0,"failedSteps":1,"valid":false},"primaryInboundWatch":{"available":true,"status":"failed","ok":false,"stale":true,"refreshedFromCurrentStatus":true,"checkedAt":"2026-07-08T20:13:03.555Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":11432,"attempts":5,"failedReason":"primary_transport_observed_stale","recommendedContact":{"chat":"***9102","status":"consented","since":"2026-07-29T10:36:43.934Z","reason":null,"action":"send_test_message_from_contact"},"operatorHint":"Non usare ***8221 per test inbound: è il numero collegato al bot. Far inviare un messaggio WhatsApp di test dal numero ***3375.","lastPrimaryActivityAt":"2026-08-01T07:48:09.168Z","lastAnyActivityAt":"2026-08-06T14:20:00.731Z","valid":false},"goLiveVerify":{"available":true,"status":"failed","stale":true,"finishedAt":"2026-07-04T12:33:23.794Z","currentProcessStartedAt":"2026-08-06T14:51:37.863Z","durationMs":182966,"failedStep":"Primary inbound watch","totalSteps":1,"expectedStepCount":3,"passedSteps":0,"skippedSteps":0,"failedSteps":1,"valid":false},"deploymentReadiness":{"stage":"not_ready","message":"Il sistema non ha ancora superato i controlli minimi.","nextAction":"Far inviare un messaggio WhatsApp di test dal numero ***9102.","productionReady":false,"liveOperationalReady":false,"preCutoverReady":false,"readyForPartnerTesting":false,"readyExceptPrimaryInbound":false,"readyExceptCutover":false,"readyExceptOpenWAQr":false,"requiresCutover":true,"requiresOpenWAQrScan":true,"primaryTransport":"whatsapp-web.js","primaryTransportReady":false,"primaryInboundVerified":false,"inboundVerification":{"ready":false,"primaryInboundVerified":false,"primaryInboundReason":"primary_transport_observed_stale","connectedAccount":{"name":null,"redactedNumber":null},"selfAccountInboundBlocked":false,"requiredTestNumber":"external_consented_contact","pendingExternalCount":4,"consentedExternalCount":14894,"recommendedContact":{"chat":"***9102","status":"consented","since":"2026-07-29T10:36:43.934Z","reason":null,"action":"send_test_message_from_contact"},"candidates":[{"chat":"***9102","status":"consented","since":"2026-07-29T10:36:43.934Z","reason":null,"action":"send_test_message_from_contact"},{"chat":"***1679","status":"consented","since":"2026-07-22T07:22:20.626Z","reason":null,"action":"send_test_message_from_contact"},{"chat":"***6169","status":"consented","since":"2026-07-20T10:38:35.169Z","reason":null,"action":"send_test_message_from_contact"}],"nextAction":"Far inviare un messaggio WhatsApp di test dal numero ***9102.","canUseConnectedAccountForInbound":false,"reason":"connected_account_not_available","operatorHint":"Per i test inbound usa un numero WhatsApp diverso da quello collegato al bot."},"remainingActions":["verify_primary_inbound","scan_openwa_shadow_qr","refresh_full_gate","refresh_precutover_gate","refresh_cutover_gate"],"gates":{"production":false,"preCutover":false,"cutover":false},"components":{"response":false,"graph":true,"events":true,"primaryTransportReady":false,"primaryInboundVerified":false,"readyExceptPrimaryInbound":false,"openwaConnected":false,"openwaQrReady":true,"openwaShadowQrReady":true,"openwaShadowConnected":false},"blockers":["transport_not_ready","primary_transport_observed_stale"]},"operationalReadiness":{"openwa":{"enabled":false,"mode":"whatsapp-web.js","runtimeOk":null,"runtimeStatus":"disabled","runtimeSession":null,"shadowRuntime":{"enabled":true,"primaryTransport":false,"mode":"shadow","status":"session_present","runtimeUrl":"127.0.0.1:2785","sessionName":"pordenone","sessionId":"824877...bae6","sessionStatus":"qr_ready","sessionConnected":false,"sessionCount":1,"qrAvailable":true,"qrLength":6498,"webhookCount":1,"webhookHeadersConfigured":true,"checkedAt":"2026-08-06T16:30:28.010Z","autoEnsure":{"enabled":true,"running":false,"lastAttemptAt":"2026-08-06T14:51:43.998Z","lastResult":null},"error":null},"sessionConnected":null,"sessionName":null,"inboundWebhookEndpoint":"/api/openwa/webhook","outboundWebhookConfigured":false,"apiKeyEnabled":true,"gatewayReady":false,"ready":false,"lastInboundAt":"2026-08-06T14:19:59.034Z","lastInboundAgeMs":7828976,"lastReplyAt":"2026-08-06T14:20:00.731Z","lastReplyAgeMs":7827279,"stale":false,"staleAfterMs":21600000},"openwaShadowRuntime":{"enabled":true,"primaryTransport":false,"mode":"shadow","status":"session_present","runtimeUrl":"127.0.0.1:2785","sessionName":"pordenone","sessionId":"824877...bae6","sessionStatus":"qr_ready","sessionConnected":false,"sessionCount":1,"qrAvailable":true,"qrLength":6498,"webhookCount":1,"webhookHeadersConfigured":true,"checkedAt":"2026-08-06T16:30:28.010Z","autoEnsure":{"enabled":true,"running":false,"lastAttemptAt":"2026-08-06T14:51:43.998Z","lastResult":null},"error":null},"eventsCache":{"mode":"fresh","ready":true,"usableEntries":2,"fallbackEntries":1,"futureItems":299,"totalItems":600,"completeEntries":4,"freshestUpdatedAt":"2026-08-06T16:21:45.703Z","refresh":{"enabled":true,"intervalMs":1800000,"startupDelayMs":20000,"running":false,"runTotal":4,"lastReason":"timer","lastStartedAt":"2026-08-06T16:21:39.000Z","lastFinishedAt":"2026-08-06T16:21:45.707Z","lastDurationMs":6707,"lastStatus":"ok","lastError":null,"lastResults":[{"key":"comune","label":"Calendario Comune","ok":true,"empty":false,"items":539,"durationMs":6706},{"key":"cinemazero-cinema","label":"Cinema Sotto le Stelle","ok":true,"empty":false,"items":1,"durationMs":237},{"key":"pordenone2027","label":"Pordenone 2027","ok":true,"empty":true,"items":0,"durationMs":925},{"key":"comune-news","label":"Novità Comune","ok":true,"empty":false,"items":60,"durationMs":1279}]}},"graph":{"enabled":true,"reachable":true,"ok":true,"neo4jAvailable":true,"ready":true,"stale":false,"pages":38,"candidatePending":0,"answerIssueOpen":0,"candidatePendingTarget":400,"candidatePendingMax":500,"candidateAtTarget":false,"queueDepth":0,"queueDropped":0,"crawlOk":37,"crawlFail":0,"crawlOptionalUnavailable":4,"refreshStartedAt":"2026-08-06T16:00:06.059Z","refreshFinishedAt":"2026-08-06T16:00:31.898Z"},"localRouter":{"enabled":true,"model":"qwen3:1.7b","timeoutMs":3500,"status":"hot_path","nonBlocking":false,"hotPathAvailable":true,"coolingDownUntil":null,"lastError":null,"lastResolvedError":null,"health":{"ok":true,"running":false,"checkedAt":"2026-08-06T16:26:50.976Z","ageMs":217036,"latencyMs":1238,"error":null,"reason":"warm-reprobe","maxLatencyMs":10000,"ttlMs":600000,"failureRetryMs":60000}},"codexCli":{"enabled":false,"model":"gpt-5.4-mini","reasoningFast":"low","reasoningSmart":"medium","coolingDownUntil":null,"lastError":null},"eventAiReview":{"enabled":true,"coolingDownUntil":null,"lastError":null}}}