Skip to content

Message Cache Object

Message cache is a simple key-value pair, in-memory-only array associated with the message. Once the message finishes processing through the channel, the message cache is discarded and is no longer available, unless Save message cache for each message is enabled on the channel's Message State Persistence tab, in which case the message cache is stored alongside the message data and retained according to the channel's message retention policy. The following Message Cache object functions are available:

Function Description
Check Value Exists Check for the existence of a value associated with the key. Returns true if a value is found, false otherwise.
Get Value Get the value associated with the key. Accepts an optional defaultValue returned when the key is not present (defaults to null).
Set Value Set the value associated with the key. Returns the previous value associated with the key.