You can use the Raw exec driver on Windows for this purpose:
task "webservice" {
driver = "raw_exec"
config {
command = "my-binary"
args = ["-flag", "1"]
}
}
Raw exec disabled by default you will need to enable it in your configuration for the clients
client {
enabled = true
network_speed = 10
options {
"driver.raw_exec.enable" = "1"
}
}