Updated at September 7, 2026 01:25 PM
box.broadcast()
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 tovalue— 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)