Command line switch with input paramter

Hi everyone,
I have a command line switch that turns on and off my A/C unit.
Its an external http server device that I communicate via command line curl with the parameters built in, for example:

curl -X POST http://10.0.0.3/bedroom/23/on

where 23 is the desired temperature for this room.
Is it possible to make it configurable, that next to my switch I will have a slider for possible temperatures, and I select them?
I also have automated scenes that turns on and off that room, is it possible to inject temperatures from there as well?