code: func (e *sessionMessages) SessionState(ctx context.Context) (string, error) {
  	channel := e.SessionMessageChannel("OnConnected")
  	defer e.CloseSessionMessageChannel(channel)
  	select {
  	case <-ctx.Done():
  		return "", ctx.Err()
  	case message := <-channel:
  		connectedInfo := &onConnectedEvent{}
  		err := json.Unmarshal(message.Content, connectedInfo)
  		if err != nil {
  			return "", err
  		}
  		return connectedInfo.SessionState, nil
  	}
  }
docs: // SessionState returns either SESSION_CREATED or SESSION_ATTACHED to describe the status of the current websocket session