[api] do not read the post body unless we have to for validate

This reduces memory usage for chromium commits - at least I hope so