feat(addon): show AI bot online in Discuss when agent is healthy

Extend cron_ping_all to upsert a bus.presence row for the
activeblue_ai_bot user, mirroring the agent service's reachability:
green dot when /health responds 200, offline otherwise. Drop the cron
interval from 5m to 1m so the presence stays fresh (Odoo's presence
client expects refreshes well under a minute).
This commit is contained in:
Carlos Garcia
2026-04-25 17:05:55 -04:00
parent d49a51a5e8
commit 5e9b4b244c
2 changed files with 26 additions and 1 deletions

View File

@@ -6,7 +6,7 @@
<field name="model_id" ref="model_ab_ai_bot"/>
<field name="state">code</field>
<field name="code">model.cron_ping_all()</field>
<field name="interval_number">5</field>
<field name="interval_number">1</field>
<field name="interval_type">minutes</field>
<field name="active">True</field>
</record>