Wrote code to communicate with server