How to send an analog command to a device

I am using the ESP8266 demo code.
I would like to create a slider on the dashboard that will send a command+analog value as device command.
example: slider moved to 228 will cause a command sent to the device “SetAnalogValue 228”
Then the command handler on the ESP should decipher command & parameter.

Can you help me please?