samedi 7 juillet 2018

JSON If Statement Not Working

I'm not use to coding in JSON so I don't know what I'm doing wrong. Basically, what I'm trying to achieve is that there is a variable for a web hook that basically says "alert type = 1" means website is up, and "alert type =2" means website is down.

I'm trying to create a webhook JSON code to send a different message if the alert type is set to either 1 or 2. Please help me in understanding what I'm doing wrong.

Here is the code I've got so far;

{.if (* alertType *) = "2"
}
Our Website is Offline {.if
}

Aucun commentaire:

Enregistrer un commentaire