統計
インストール手順とこのプラグインの全マークダウンガイドを含む設定用の質問をコピーする。
統計情報エンドポイントは、詳細なアプリと組織の分析情報を提供します。アプリと組織の成長、リソース使用状況、容量計画を監視するために、月間有効ユーザー数(MAU)、ストレージ使用量、バンド幅消費量を異なる時間間隔で追跡できます。このデータは、容量計画、リソース使用状況、成長を監視するために不可欠です。
メトリクスを理解する
「メトリクスを理解する」のセクション- MAU (月間有効ユーザー数)30日間でアプリにアクセスしたユニークなデバイスの数
- ストレージすべてのバンドルとリソースの合計サイズ(バイト単位)
- 帯域幅: バンドルダウンロードの合計データ転送量(バイト)
ベストプラクティス
セクション「ベストプラクティス」- 定期的な監視: 統計を定期的に確認して成長と使用パターンを追跡する
- リソース計画: ストレージと帯域幅のメトリックを使用して容量計画
- ユーザー関与: MAUを使用してユーザー関与の傾向を理解する
- コスト管理: リソースの使用を監視してコストを最適化する
エンドポイント
セクション「エンドポイント」GET /statistics/app/:app_id/
セクション「GET /statistics/app/:app_id/」特定のアプリの統計を取得します。このエンドポイントは、個々のアプリのパフォーマンスを監視するのに役立ちます。
クエリ パラメータ
コピー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/app/com.demo.app/?from=2024-01-01&to=2024-02-01"例の応答
セクション「例の応答」[ { "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 }]GET /statistics/org/:org_id/
セクション「GET /statistics/org/:org_id/」特定の組織の統計を取得します。組織レベルの使用状況を監視するのに役立ちます。
クエリ パラメータ
セクション「クエリ パラメータ」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}例のリクエスト
セクション「例のリクエスト」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_1__
__CAPGO_KEEP_2__[ { "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_3__
__CAPGO_KEEP_2____CAPGO_KEEP_4__
__CAPGO_KEEP_5__
__CAPGO_KEEP_6__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_7__
__CAPGO_KEEP_8__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」のセクション特定のアプリのバンドル使用状況の統計を取得し、指定された期間内にユーザー間でバンドル(バージョン)の分布を表示します。
クエリパラメータ
「クエリパラメータ」のセクション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"}一般的な使用例のセクション
コピー- Growth Tracking: 時系列でMAUの成長を監視する
- Resource Optimization: ストレージとバンド幅の使用状況を追跡してコストを最適化する
- Capacity Planning: 将来のリソースのニーズを計画するのにトレンドを使用する
- Usage Reports: 利用状況の報告書を定期的にステークホルダーに提供する
- Bundle (version) Distribution Analysis: アプリのバンドル(バージョン)ごとのユーザー分布とバンドル使用状況の統計を理解する
Tips for Analysis
: 分析のためのアドバイス- 期間を比較する: 1 か月ごとに 1 年ごとにトレンドを確認する
- 比率を追跡する: ユーザーごとの帯域幅やアプリごとのストレージを監視する
- 異常な使用量のスパイクにアラートを設定する: 使用量の異常なスパイクにアラートを設定する
- 定期的なバックアップ: 統計を定期的にエクスポートして過去の分析を行う
- バンドル (バージョン) の採用: バンドルの使用状況を使用して新しいバンドルの採用率を追跡する
統計から続ける
: 統計から続けるIf you are using __CAPGO_KEEP_0__/__CAPGO_KEEP_1__ for __CAPGO_KEEP_0__/__CAPGO_KEEP_1__ and __CAPGO_KEEP_0__/__CAPGO_KEEP_1__, 統計 to plan storage and file handling, connect it with __CAPGO_KEEP_0__/__CAPGO_KEEP_1__-data-storage-sqlite for the implementation detail in capgo/capacitor-data-storage-sqlite, Using capgo/capacitor-data-storage-sqlite for the native capability in capgo/capacitor-data-storage-sqlite, capgo/capacitor-data-storage-sqlite for the implementation detail in capgo/capacitor-data-storage-sqlite, Using capgo/capacitor-data-storage-sqlite for the native capability in capgo/capacitor-data-storage-sqlite, capgo/capacitor-file for the implementation detail in capgo/capacitor-file, Using capgo/capacitor-file for the native capability in Using capgo/capacitor-file, and capgo/capacitor-uploader @capgo/capacitor-uploader.