url, protocol and on_open are params to connect