def get_apps():

    result = requests.get(
        'https://api.heroku.com/apps',
        headers={'Accept': 'application/json'}
    )

    if result.status_code != 200:
        raise IOError(
            "No Status OK returned by heroku (got status=%d) " %
            result.status_code
        )

    return json.loads(result.text)
dataset/ETHPy150Open wercker/wercker-cli/werckercli/heroku.py/get_apps/original