Updated at July 17, 2026 02:08 PM
box.broadcast()
box.broadcast(key, value)
Update the value of a particular key and notify all key watchers of the update.
Parameters:
-
key(string) — key name of the event to subscribe to -
value— any data that can be encoded in MsgPack
Returns
none
Possible errors:
- The value can't be encoded as MsgPack.
- The key refers to a
box.system event
Example:
-- Broadcast value 42 for the 'foo' key.box.broadcast('foo', 42)