Twitch Online Stream return

Hello all! A buddy and I just created a script to bring up a live streamer of twitch on vlc through a terminal command, and it works great as long as the stream is live. Otherwise it tells us it can't find the stream. Now we want to make a terminal command to tell us which of our followed users in our twitch account are online and streaming. Something like went enter a command in the terminal and the code prints out the streamers names so we know which we can type in to get the live streamer to work. However we are kind of stuck and don't really know what to do. Would anyone be able to help or give suggestions? Thank you!

Here's what we have:
In bash:

#!/bin/bash
if [ "$2" == "-nochat" ]
then
    livestreamer twitch.tv/$1 best --player vlc
else
    livestreamer twitch.tv/$1 best --player vlc & java -jar ~/.chatty_app/Chatty.jar
fi
exit

In Python:

import requests

array = []
with open("~/.list.txt", "r") as ins:
    for user in ins:
        user = user.strip();
        url = "https://api.twitch.tv/kraken/streams/" + user
        if requests.get(url).status_code != 200:
            array.append(user + ": offline")
        else:
            array.append(user + ": online")

for x in range(0,len(array)):
    print array[x]

---------- Post updated at 02:24 PM ---------- Previous update was at 02:19 PM ----------

API: