import requests


def get_data(stock, start_date):
    """Fetch a maximum of the 100 most recent records for a given 
    stock starting at the start_date.

    Args:
        stock (string): Stock Ticker
        start_date (int): UNIX date time
    """

    # Build the query string
    request_url = f"https://api.pushshift.io/reddit/search/comment/?q={stock}&sort=asc&size=100&after={start_date}"

    # get the query and convert to json
    result_json = requests.get(request_url).json()

    return result_json