iot
iot copied to clipboard
Input method with a complex parameter.
I have a device that sends many data at a time. For example, it sends x, y, and z related to an employee id. So the value itself is a dict with many entries.
If the input action accepts JSON request, then we can pass a complex value such as a dict.
The current implementation accepts FORM data.
In the other case, we could call an input action with many parameters.
@etobella I find a way to support parameters as JSON (key, vals). How can I add it to the branch 16.0?
My main need is to connect ThingsBoard MQTT queue to odoo. And TB supports JSON in its rule chain. So, JSON parameter is a good choice for me.
My new approach supports both, form and JSON request body.
It may be useful for others too.
Sure! Make a PR and I will review it
There hasn't been any activity on this issue in the past 6 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. If you want this issue to never become stale, please ask a PSC member to apply the "no stale" label.