It appears like that the restful sensors do not support providing a template for the payload attribute, making it seemingly impossible to provide any variables or dynamic data in the request payload.
a) Is there some form of workaround? I guess I could use a shell command sensor and just use curl?
b) Is this something the HA team has considered adding? I would assume it’s a reasonably common use-case and shouldn’t be too complicated to add. A lot of the other attributes for RESTful sensors already support templates.
This is not something that I have a current personal need for anymore, so it’s not very high on my priorities list. If someone else wants to put up a new pull request based on my old one, I’d be more than happy to support that.
Otherwise I might get to it at some time. It seems useful to a lot of people. But can’t make any promises or commitments to timelines.
Depending on what you are trying to do specifically this may or may not work for you, but you could use a shell_command that calls out into curl (assuming curl is installed on the host/container) or into a python shell script that uses Python requests to send those requests.
You can retrieve returned data with service return values and you can provide arguments to shell_command using the data property. See the documentation for details.