You can do that by wiring a custom computation into the 'SpawnCount' property of the multiplier node.
In v1, the "Flux" value you could write to from layer-scripts was acting as a multiplier to the "SpawnCount" property of the emitter.
In v2, wiring something in the "SpawnCount" pin of the multiplier node will override whatever value you've set into the "SpawnCount" property. So you'll need to pre-multiply it.
Here's an example with a curve driving the emission rate of a multiplier:
You can see I exposed the "SpawnCount" pin and wired in a curve sampled over time, multiplied by 100.
Using this curve:
Will produce an emission spike at around ~60 particles/second (because it gets multiplied by 100), and the rest of the time it'll emit roughly 2-3 particles/second.
To expose the "SpawnCount" pin, you can select the multiplier node, and click on the little eye icon next to the property:
And last, Here's how I've setup the "CurveOverTime" node in this example:
The "CursorMode" property is set by default to "LifeRatio", which will not work if your multiplier node is set to infinite (which was my case), so here I've just set it to "Age", which is the time in seconds since this multiplier node was started.
"Cursor Range" is set to 3 meaning the curve will be stretched over 3 seconds, and "Repeat" is checked meaning if the emitter lasts for more than 3 seconds, the curve will loop.
Of course you can plug anything in there, you can expose an attribute in the effect interface panel and use that to drive the emission directly.
Final note: Doing computations like these in the layergraph directly currently has some limitations if you put them inside templates (sub-graphs). You won't be able to wire a template input into part of the computation that you wire into a layer. This is something we intend to implement pretty soon.
Anyway, for what you're trying to do, it should be fine !
Hope this helps !