Od wersji sgcWebSockets 4.4.7 obsługiwane jest API Socket.IO 3.
Teraz domyślnie po utworzeniu instancji klienta Socket.IO jest on skonfigurowany dla API 3.*
Przykład
Poniżej znajdziesz prosty przykład połączenia z serwerem Socket.IO API 3
// create websocket client
oClient := TsgcWebSocketClient.Create(nil);
oClient.Host := 'socketio-chat-h9jt.herokuapp.com';
oClient.Port := 443;
oClient.TLS := True;
oClient.TLSOptions.Version := tls1_2;
// create socket.io client
oSocketIO := TsgcWSAPI_SocketIO.Create(nil);
oSocketIO.Client := oClient;
oSocketIO.API := ioAPI3;
// connect
oClient.connect;
// send a message
oClient.WriteData('42["add user", "MyUser"]');

