Adding param to formdata in pre-request script

I have a POST form-data request setup, and I need to add two dynamically generated fields to it. I tried doing this:

pm.request.body.formdata.append({ key: “signature”, value: “iamspecial”, type: “text” });

and I see it added it to the formdata, but it never gets sent out to the network.

Is this possible? Thank you.

Hello @tylerwilson ,
have you tried the following?

pm.request.body.mode=“formdata”;
pm.request.body.formdata=[{key:“claimRequest”,value:“your json string”,type:“text”}];

Cheers