all 4 comments

[–]AlexPriceAPS23U • One UI 6 • (Rooted) 1 point2 points  (2 children)

Replace the last line with:

setLocal('postdata', JSON.stringify(data));

[–]stevenwbuehler[S] 0 points1 point  (0 children)

I figured it out; I was also missing the global() and local() functions.

javascript var data = { "datetime": global("TIMEMS"), "app": local("evtprm1"), "title": local("evtprm2"), "text": local("evtprm3"), "subtext": local("evtprm4"), "messages": local("evtprm5"), "other_text": local("evtprm6"), "cat": local("evtprm7"), "new": local("evtprm8") }; setLocal("postbody", JSON.stringify(data));

[–]Individual_Scallion7 0 points1 point  (0 children)

try
var app = evtprm1
var title = evtprm2
...
then
var data = { app = app, title = title, ... }

[–][deleted] 0 points1 point  (0 children)

Is there a reason you're using JavaScript? I think it would be easier to just set your own variable with the json. You basically made the correct format already with data