Proper way to pass JSON to a query

I’m using the Google Sheets Insert Many query and named it New_Shipment. I have a JS object (helper) that has a function call submitShipment that is creating an array and storing it in updatedData. I confirmed via console this array looks good. Then the last line of the function runs New_Shipment.run(updatedData).

What do I put in the New_Shipment query to use that array I am passing? I tried {{this.params}} and it is just passing the string “{{this.params}}”, similarly I tried {{this.params.updatedData}} with the same result.

Temporarily I’m just having the submitShipment function run storeValue(“testData”,updatedData) and then New_Shipment use {{appsmith.store.testData}} but that does not seem like the “right” way of doing it.

Hello Eric!
Try running the query like this: New_Shipment.run({ updatedData: updatedData }). Then, in the query, you can use {{this.params.updatedData}}.
Please fork this sample app that demonstrates how to do it.