Awareness API란 무엇인가요?
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
Google Awareness API를 사용하면 앱이 사용자의 현재 상황에 지능적으로 반응하도록 할 수 있습니다. Awareness API는 사용자 활동 및 근처의 비콘을 포함한 5가지 컨텍스트 유형을 노출합니다. 이러한 유형을 통해 앱은 이전에는 불가능했던 새로운 방식으로 사용자 환경을 구체화할 수 있습니다. 앱은 이러한 상황 정보 신호를 결합하여 사용자의 현재 상황을 추론할 수 있으며 이 정보를 이용해 사용자가 헤드폰을 연결하고 조그 다이얼로 조정하기 시작하면 재생목록 추천과 같이 맞춤형 환경을 제공할 수 있습니다.
Awareness API 이점
Awareness API는 다음과 같은 몇 가지 이점을 제공합니다.
- 구현 용이성: 앱에 API 하나만 추가하면 되므로 통합이 크게 간소화되고 생산성이 향상됩니다.
- 더 나은 컨텍스트 데이터: 원시 신호가 처리되어 품질이 개선됩니다. 예를 들어 고급 알고리즘은 높은 수준의 정확도로 사용자의 활동을 결정하는 데 사용됩니다.
- 최적의 시스템 상태: Awareness API는 앱에서 관리할 필요가 없도록 배터리 수명 및 데이터 사용량에 미치는 영향을 자동으로 관리합니다.
울타리 및 스냅샷
Awareness API는 앱에서 사용자의 현재 상황을 판단하기 위해 컨텍스트 신호를 가져오는 데 사용할 수 있는 두 가지 API로 구성됩니다.
- Fence API: 이 API를 사용하면 앱이 사용자의 현재 상황에 반응하고 컨텍스트 조건 조합이 충족될 때 알림을 제공할 수 있습니다. 예를 들어 사용자가 산책을 하면서 헤드폰을 연결할 때마다 펜스가 등록되면 Fence API는 앱이 실행 중이 아니더라도 앱에 콜백을 전송할 수 있습니다.
- Snapshot API: 이 API를 사용하면 앱에서 사용자의 현재 위치, 현재 날씨 상태와 같은 사용자의 현재 컨텍스트에 관한 정보를 요청할 수 있습니다.
컨텍스트 유형
컨텍스트는 Awareness API의 핵심입니다. 문맥 데이터에는 위치(위도 및 경도), 장소 유형(예: 공원 또는 커피숍), 활동(예: 걷기 또는 운전)과 같은 센서에서 파생된 데이터가 포함됩니다. 이러한 기본 유형 또는 신호를 결합하여 사용자의 상황을 더 구체적으로 추론할 수 있습니다. 다음 알림을 펼쳐 지원 중단된 문맥 시그널을 확인하세요.
다음 표에서는 현재 Awareness API에서 제공하는 기본 컨텍스트 유형을 설명합니다.
컨텍스트 유형 |
예 |
시간 |
현재 현지 시간 |
위치 |
위도 및 경도 |
활동 |
걷기, 달리기, 자전거 타기와 같은 사용자 활동이 감지됨 |
비콘 |
지정된 네임스페이스와 일치하는 근처 비콘 |
헤드폰 |
헤드폰 연결 여부 상태 |
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-08-31(UTC)
[null,null,["최종 업데이트: 2025-08-31(UTC)"],[[["\u003cp\u003eThe Google Awareness API lets your app intelligently respond to the user's context, such as their activity, location, and nearby beacons.\u003c/p\u003e\n"],["\u003cp\u003eIt offers benefits like easy implementation, improved context data quality, and automatic management of system resources.\u003c/p\u003e\n"],["\u003cp\u003eThe API provides two ways to access context: the Fence API for reacting to situations and the Snapshot API for requesting current information.\u003c/p\u003e\n"],["\u003cp\u003eSupported context types include time, location, activity, beacons, and headphone status, while places and weather signals are deprecated.\u003c/p\u003e\n"]]],[],null,["# What's the Awareness API?\n\nWith the Google Awareness API, you can enable your app to intelligently react to the\nuser's current situation. The Awareness API exposes five different\n[context types](#context-types), which include user activity,\nand nearby beacons. These types enable your app to refine the user experience in\nnew ways that weren't possible before. Your app can combine these context\nsignals to make inferences about the user's current situation, and use this\ninformation to provide customized experiences, such as a playlist suggestion\nwhen the user plugs in their headphones and starts to jog.\n\nAwareness API benefits\n----------------------\n\nThe Awareness API provides several benefits:\n\n- **Ease of implementation:** You only need to add a single API to your app, which greatly simplifies integration and improves your productivity.\n- **Better context data:** Raw signals are processed for improved quality. For example, advanced algorithms are used to determine the user's activity with a high level of accuracy.\n- **Optimal system health:** The Awareness API automatically manages its impact on battery life and data usage so that your app doesn't have to.\n\nFences and snapshots\n--------------------\n\nThe Awareness API consists of two distinct APIs that your app can use to\nget context signals in order to determine the user's current situation:\n\n- [**Fence API:**](/awareness/android-api/fence-api-overview) This API lets your app react to the user's current situation, and provides notification when a combination of context conditions are met. For example, whenever the user takes a walk and their headphones are plugged in. Once a fence is registered, the Fence API can send callbacks to your app even when it's not running.\n- [**Snapshot API:**](/awareness/android-api/snapshot-api-overview) This API lets your app request information about the user's current context, such as the user's current location and the current weather conditions.\n\nContext types\n-------------\n\nContext is at the heart of the Awareness API. Contextual data includes\nsensor-derived data such as location (latitude and longitude), place type,\nlike a park or coffee shop, and activity, such as a walk or drive. These basic\ntypes, or signals, can be combined to extrapolate the user's situation in more\nspecific detail. Expand the following notice to see which contextual signals\nhave been deprecated.\n**Deprecation notice: Places and Weather contextual signals** **Warning:**\n| The Places and Weather contextual signals, exposed by the\n| [`getPlaces()`](/android/reference/com/google/android/gms/awareness/SnapshotClient#getPlaces()), and\n| [`getWeather()`](/android/reference/com/google/android/gms/awareness/SnapshotClient#getWeather())\n| methods, were deprecated.\n|\n| - The Places contextual signal was turned off. Continued use of this signal was restricted to customers with existing implementations, through October 30, 2019. New implementations must use the [Places SDK for Android](/places/android-sdk) instead of the Places contextual signal.\n| - The Weather contextual signal has also been turned off. Continued use of this signal has been restricted to customers with existing implementations, through January 31, 2020. Google doesn't offer alternative functionality for the Weather contextual signal.\n\nThe following table describes the basic context types currently offered by\nthe Awareness API:\n\n| Context type | Example |\n|--------------|----------------------------------------------------------|\n| Time | Current local time |\n| Location | Latitude and longitude |\n| Activity | Detected user activity, like walking, running, or biking |\n| Beacons | Nearby beacons that match the specified namespace |\n| Headphones | Status of whether headphones are plugged in, or not |"]]