Sorry. Noob question.
I set up my first flow yesterday and I'm stoked it's working! I'm triggering it via a webhook POST from an app called Geofency which POSTs to webhookrelay. Geofency doesn't provide an option to supply custom JSON code. You can only use their immutable JSON variables and values (some of which I can set a value for). I piped the payload to a series of 2 switches that check "name" (of the geofence location) and "entry" (1=entry, 0=exit).
However, I'm preparing to add a few more functions to the switch that come from things other than geofency (e.g. IFTTT -> webhookrelay) and it seems limiting to be corralled into using these variables and trying to keep their values unique across different triggering platforms. There does not seem to be a variable in the static JSON whose value is something like "geofency" that I could switch on per platform, so I could put another switch in front of it to be able to set up different types of triggers without variables stepping on one another.
I learned that webhookrelay only gives you one free public URL endpoint, so I believe I have to differentiate the types of triggers using the JSON content.
First of all, what's the best practice? Should I create a different flow with a webhookrelay input for each triggering platform? Or should I put all actions triggered by a webhookrelay input in the same flow?
Is there a way to inject a variable in the JSON somehow, e.g.
"triggering_platform": "geofency" (like a way to detect where the POST came from and inject JSON based on the source) or do I need to treat the "variable" "name" as reserved for geofency and set values to some delimited value like "geofency-home" and "ifttt-weather", split on the dash, and switch on the first value? If not, or if I encounter another platform that doesn't have a "name" variable in a static JSON payload that I can set, how would I check if the "name" variable is present in the switch?
I don't want to start down some path and discover a flaw in my method and have to redo everything? Has anyone else encountered this issue? How did you design your flows around it?