This commit DRYs up the indices folder as well as fixing a few minor mishaps that were in the docs.
Adds the validate query API to the high level rest client.