Allow arrays to be serialized as body parameters 

Rebased on 7e60fc5