Zaraz Worker Variables - Session Persistence

When using Worker Variables within Zaraz a request is sent to the worker on every event. Adding the ability to persist the variable across the “page” or “session” would offer significant benefits and reduced Worker consumption.

For Example, I am using the Zaraz Facebook Tool to consume the Conversion API Key from an external API using a Worker. However, whenever a click event occurs, a tab change, or any event occurs, the Worker is hit again to retrieve the value. This value can be persisted across the entire session as it does not change. I would use zaraz.set(‘key’, 'value, {scope: ‘session’}), but this API Key is meant to be private and not publicly accessible.

Zaraz is explicitly designed to not store persist any data, so doing something like this would be very big undertaking. I recommend looking into Masked Variables and JSONata to see if you can get rid of the API dependency.