feat(mesh): gossipAutomationManifest for AUTOMATION_MANIFEST_UPSERT
Emit automation-manifest on inbound gossip so peers can merge hooks and automod snapshots without HTTP or central integration servers. Co-authored-by: Cursor <[email protected]>
This commit is contained in:
@@ -350,6 +350,9 @@ class PearcordGuild extends EventEmitter {
|
||||
if (method === RPC.APP_EVENT) {
|
||||
this.emit('app-event', payload)
|
||||
}
|
||||
if (method === RPC.AUTOMATION_MANIFEST_UPSERT) {
|
||||
this.emit('automation-manifest', payload)
|
||||
}
|
||||
if (method === RPC.BOT_INSTALL_UPSERT) {
|
||||
this.emit('bot-install', payload)
|
||||
}
|
||||
@@ -617,6 +620,10 @@ class PearcordGuild extends EventEmitter {
|
||||
broadcastGossip(this, RPC.APP_EVENT, payload)
|
||||
}
|
||||
|
||||
gossipAutomationManifest (payload) {
|
||||
broadcastGossip(this, RPC.AUTOMATION_MANIFEST_UPSERT, payload)
|
||||
}
|
||||
|
||||
gossipBotInstall (bot) {
|
||||
broadcastGossip(this, RPC.BOT_INSTALL_UPSERT, bot)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user