Problem with my new presence?

I had created my own presence in Spark Web for chat. It works fine with connection type http but not with socket. Can anyone suggest me what to do to make it work with socket connection?