Established sending and receiving json strings to and from the client.