API splats arguments list when sending commands to a device

Fix for issue #33 "Wrong number of arguments passed in RESTful JSON API when sending a command
Edit".