'Updates outgoing requests with a serialized body.
Args:
headers: dict, request headers
path_params: dict, parameters that appear in the request path
query_params: dict, parameters that appear in the query
body_value: object, the request body as a Python object, which must be
serializable by json.
Returns:
A tuple of (headers, path_params, query, body)
headers: dict, request headers
path_params: dict, parameters that appear in the request path
query: string, query part of the request URI
body: string, the body serialized as JSON'

def request(self, headers, path_params, query_params, body_value):

    query = self._build_query(query_params)
    headers['accept'] = self.accept
    headers['accept-encoding'] = 'gzip,    deflate'
    if ('user-agent' in headers):
        headers['user-agent'] += '    '
    else:
        headers['user-agent'] = ''
    headers['user-agent'] += ('google-api-python-client/%s    (gzip)' % __version__)
    if (body_value is not None):
        headers['content-type'] = self.content_type
        body_value = self.serialize(body_value)
    self._log_request(headers, path_params, query, body_value)
    return (headers, path_params, query, body_value)
