컨텐츠로 건너뛰기

statistic

Statistics 엔드포인트는 앱 및 조직에 대한 세부적인 분석 데이터를 제공합니다. 월간 활성 사용자(MAU), 저장소 사용량 및 대역폭 소비를 시간별로 추적할 수 있습니다. 이 데이터는 앱 성장, 리소스 사용 및 용량 계획을 모니터링하는 데 필수적입니다.

  • MAU (월간 활성 사용자): 최근 30일 동안 앱에 접근한 유니크한 기기 수
  • 저장소: 모든 번들 및 리소스의 바이트 단위 총 크기
  • 대역폭: 번들 다운로드를 위한 바이트 단위 총 데이터 전송량
  1. 정기적인 모니터링: 성장 및 사용 패턴을 추적하기 위해 통계를 정기적으로 확인하십시오
  2. 자원 계획: 저장소 및 대역폭 메트릭을 사용하여 용량 계획
  3. 사용자 참여: MAU를 사용하여 사용자 참여 동향을 이해
  4. 비용 관리: 자원 사용을 모니터링하여 비용 최적화

엔드포인트

엔드포인트

GET /statistics/app/:app_id/

GET /statistics/app/:app_id/

특정 앱의 성능을 모니터링하기 위한 이 엔드포인트는 앱별 성능을 확인하는 데 유용합니다.

Query Parameters

__CAPGO_KEEP_0__
interface StatsQuery {
from: Date // Start date for the statistics (format: YYYY-MM-DD)
to: Date // End date for the statistics (format: YYYY-MM-DD)
}

__CAPGO_KEEP_2__

__CAPGO_KEEP_3__
__CAPGO_KEEP_4__
curl -H "authorization: your-api-key" \
"https://api.capgo.app/statistics/app/com.demo.app/?from=2024-01-01&to=2024-02-01"

__CAPGO_KEEP_5__

__CAPGO_KEEP_3__
[
{
"date": "2024-01-01",
"mau": 1500,
"storage": 536870912, // 512MB in bytes
"bandwidth": 1073741824 // 1GB in bytes
},
{
"date": "2024-01-02",
"mau": 1550,
"storage": 537919488, // 513MB in bytes
"bandwidth": 1074790400 // 1.01GB in bytes
}
]

__CAPGO_KEEP_6__

__CAPGO_KEEP_3__

__CAPGO_KEEP_7__

__CAPGO_KEEP_0__

__CAPGO_KEEP_1__
interface StatsQuery {
from: Date // Start date for the statistics (format: YYYY-MM-DD)
to: Date // End date for the statistics (format: YYYY-MM-DD)
breakdown: boolean // default false, optional if true it return the breakdown by app
noAccumulate: boolean // default false, optional if true it will not accumulate data and just return day by day result
}

__CAPGO_KEEP_3__

__CAPGO_KEEP_4__
__CAPGO_KEEP_5__
curl -H "authorization: your-api-key" \
"https://api.capgo.app/statistics/org/046a36ac-e03c-4590-9257-bd6c9dba9ee8/?from=2024-01-01&to=2024-02-01"

__CAPGO_KEEP_7__

__CAPGO_KEEP_8__
[
{
"date": "2024-01-01",
"mau": 10000,
"storage": 536870912, // 512MB in bytes
"bandwidth": 1073741824 // 1GB in bytes
},
{
"date": "2024-01-02",
"mau": 10200,
"storage": 537919488, // 513MB in bytes
"bandwidth": 1074790400 // 1.01GB in bytes
}
]

__CAPGO_KEEP_10__

__CAPGO_KEEP_11__

모든 조직에 대한 접근 권한이 있는 경우에 모든 조직에 대한 집계 통계를 얻습니다. 전체 사용량 모니터링을 위해 완벽합니다.

Query Parameters

Query Parameters 섹션
interface StatsQuery {
from: Date // Start date for the statistics (format: YYYY-MM-DD)
to: Date // End date for the statistics (format: YYYY-MM-DD)
}
터미널 창
curl -H "authorization: your-api-key" \
"https://api.capgo.app/statistics/user/?from=2024-01-01&to=2024-02-01"
[
{
"date": "2024-01-01",
"mau": 25000,
"storage": 1073741824, // 1GB in bytes
"bandwidth": 2147483648 // 2GB in bytes
},
{
"date": "2024-01-02",
"mau": 25500,
"storage": 1074790400, // 1.01GB in bytes
"bandwidth": 2148532224 // 2.01GB in bytes
}
]

GET /statistics/app/:app_id/bundle_usage

GET /statistics/app/:app_id/bundle_usage

특정 앱에 대한 배포본 사용 통계를 가져오고, 사용자 중에서 배포본(버전) 분포를 지정 기간 동안 보여줍니다.

Query Parameters

Query Parameters
interface BundleUsageQuery {
from: Date // Start date for the statistics (format: YYYY-MM-DD)
to: Date // End date for the statistics (format: YYYY-MM-DD)
}

터미널 창

복사
예시 응답
curl -H "authorization: your-api-key" \
"https://api.capgo.app/statistics/app/com.demo.app/bundle_usage?from=2024-01-01&to=2024-02-01"

복사

복사
{
"labels": ["2024-01-01", "2024-01-02", "2024-01-03"],
"datasets": [
{
"label": "1.0.0",
"data": [60.5, 58.2, 55.3]
},
{
"label": "1.0.1",
"data": [39.5, 41.8, 44.7]
}
]
}

일반적인 오류 상황과 그에 대한 대응:

// Invalid body
{
"status": "Invalid body",
"error": "Invalid date format or missing parameters"
}
// Permission denied
{
"status": "You can't access this app",
"error": "Insufficient permissions to access statistics"
}
// Permission denied for organization
{
"status": "You can't access this organization",
"error": "Insufficient permissions to access organization statistics"
}
// No organizations found for user statistics
{
"status": "No organizations found",
"error": "No organizations found"
}
// Internal server error
{
"status": "Cannot get app statistics",
"error": "Internal server error message"
}

일반적인 사용 사례

일반적인 사용 사례 섹션
  1. 성장 추적시간에 따른 MAU 성장 모니터링
  2. 리소스 최적화저장소 및 대역폭 사용량을 통해 비용 최적화
  3. 수용력 계획미래의 리소스 요구를 위해 트렌드 사용
  4. 사용 보고서: 주기적인 사용 보고서를 이해주자
  5. 배포 버전 분포 분석: 사용자들이 다양한 앱 배포 버전 (버전) 에 걸쳐 어떻게 분포되어 있는지 배포 사용 통계를 통해 이해
  1. 기간 비교: 월간 또는 연간 추세를 비교
  2. 비율 추적: 사용자당 대역폭 또는 앱당 저장 공간을 모니터링
  3. 경고 설정: 사용량에 이상적인 급증을 위한 경고를 설정
  4. 정규 백업: 역사 분석을 위해 정기적으로 통계를 내보내기
  5. 버전 번들 수용: 새로운 버전 번들의 수용률을 추적하기 위해 번들 사용을 사용

Statistics에서 계속

Statistics에서 계속

Capgo를 사용하는 경우 Capgo Capgo를 사용하여 저장소와 파일 처리를 계획하고 연결하세요. @capgo/capacitor-data-storage-sqlite @capgo/capacitor-data-storage-sqlite의 implementation detail @capgo/capacitor-data-storage-sqlite native 기능을 사용하는 @capgo/capacitor-data-storage-sqlite에 대해 @capgo/capacitor-file @capgo/capacitor-file의 구현 세부 사항에 대해 @capgo/capacitor-file을 사용하여 native 기능을 사용하는 @capgo/capacitor-file에 대해, 그리고 @capgo/capacitor-uploader @capgo/capacitor-uploader의 구현 세부 사항에 대해