Refactored building of request bodies