Workaround
As a workaround, post 2 separate rules to the policy to achieve the same result. Internally we map RUN_INMEMORY_CODE to 2 rules with PACKED and BUFFER_OVERFLOW operations. Making 2 requests to this API with 2 different operations as follows will achieve the same result as using RUN_INMEMORY_CODE:
operation: PACKED
operation: BUFFER_OVERFLOW