기기 사용자 식별자 조회 | 초기화와 모듈 확인 | Appbox Android SDK 가이드
기기 사용자 식별자 조회
기기 사용자 식별자 조회
AppBox.getDeviceUserId(callback)
Kotlin
1
AppBox.getDeviceUserId { deviceUserId, error ->
2
if (error != null) return@getDeviceUserId
3
linkDeviceUser(deviceUserId)
4
}
1
AppBox.getDeviceUserId(new AppBoxValueCallback<String>() {
2
@Override
3
public void onComplete(String deviceUserId, Throwable error) {
4
if (error != null) return;
5
linkDeviceUser(deviceUserId);
6
}
7
});
Request 항목 정의
| Request 항목 | 필수여부 | 설명 | 기본값 |
|---|---|---|---|
| callback | 필수 | AppBoxValueCallback<String> | - |
Response 항목 정의
| Response 결과값 | |
|---|---|
deviceUserId | 기기 사용자 식별자 문자열. 실패 시 null |
| 오류 | error: 초기화 전 호출, 또는 appbox-push, appbox-webview 둘 다 없는 구성 |
appbox-push 또는 appbox-webview 중 하나가 필요합니다. appbox-core만 추가한 구성에서는 실패합니다. 서비스 회원 ID가 아니며 광고 식별자도 아닙니다. 기기 단위 식별자입니다. 값을 로그에 그대로 출력하지 않습니다.
웹 브릿지에서는 appbox.getDeviceUserId입니다.