Validate HTTP API user input

For example, raft indices must be sane integers.
I'm kind of loath to have panics in production code for long-running services, even though apparently that's golang style.