import requests


def get_buffer(url):
    """
    Retrieve a buffer from a URL as an in-memory buffer.
    :param url: URL for a given document to request
    :return: bytes, request response
    """
    # Get response
    response = requests.get(url)
    if response.status_code == 404:
        return None
    else:
        return response.content