Edited chat functions to use data argument
Added sockets documentation