Can I access sampler instrument keyzone?

I would like to create a tool to apply a sampler instument DSP destructively.
So the plan is to:

  1. Find instrument keyzone
  2. Sample each key in the keyzone and add it to an instrument at the same key

I am new to Renoise’s Lua api, I could’t find anything keyzone related at first glance…