# 사용자가 온라인 상태인지 지속 체크하는 방법

**URL:** <https://community.sendbird.com/t/topic/7331>\
**Category:** JavaScript\
**Tags:** react-js, chatsdk\
**Created:** [May 16, 2023, 6:00am UTC](https://community.sendbird.com/t/topic/7331 "2023-05-16T06:00:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![JBEEKIM](https://avatars.discourse-cdn.com/v4/letter/j/d07c76/32.png) [@JBEEKIM](https://community.sendbird.com/u/JBEEKIM)\
**Post date:** [May 16, 2023, 6:00am UTC](https://community.sendbird.com/t/topic/7331/1 "2023-05-16T06:00:05Z")

</div>

1. 메세지를 보내는 사람이 상대방이 접속한 여부를 확인할 수 있는방법?
2. 상대방의 평균 응답시간 조회 방법(기대치, ex 평균 10분 이내 응답)  
UI 및 회원관리 자체 구현 중

[현재 구현 방식]  
채널 진입 \>  
const sendbirdChat = await SendbirdChat.init 을 통해 객체 생성하고  
await sendbirdChat.connect(userIdInputValue, userTokenInputValue)를 통해 접속  
접속했을 때 각 채널 사용자들의 connectionStatus 속성값을 확인하여 접속 여부 확인 가능  
=\> 해당 기능은 정상 작동하는 것으로 확인

그러나 예를 들면  
A 유저와 B 유저가 있을 때

A 유저 입장에서  
A = 접속, B = 미접속 상태일 때  
connectionStatus를 확인해보면 정상적으로 B는 미접속 상태  
그러나 그 후에 B = 접속 상태가 되어도 B는 여전히 미접속 상태  
connectionStatus를 실시간으로 확인 하는 방법 필요

> 추적하여 미접속시 자체 앱푸시 발송을 위함

- 채팅을 보낼때 (상대방에게 보내기 전) 접속 여부를 체크할 수 있는 방법이 있는지?
