initiated socket connection and communication with twitter api