I need to put table as new Postman variable, but I am probably doing something wrong with syntax, because when I try to used initialized table, there is "Unexpected token in JSON" error.
This is my initialization of table:
pm.variables.set("cr", {crypt_arr: [
{
key: "BTC",
used: false
},
{
key: "ETH",
used: false
},
{
key: "XRP",
used: false
}]});
This is how I use this table. Maybe there is something wrong there:
const crypto_arr = JSON.parse(pm.variables.get()).crypt_arr;
question from:
https://stackoverflow.com/questions/65884098/how-to-set-table-as-postman-variables-object 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…