@hot-updater/aws 1.0.0-rc.35 → 1.0.0-rc.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -95,12 +95,33 @@ type DatabaseHttpResponse = DatabaseJsonObject & {
95
95
  readonly body_truncated: boolean;
96
96
  readonly received_at_ms: number;
97
97
  };
98
+ /** What a kept UNCHANGED row changed against its installation's head. */
99
+ type BundleEventChangeKind = "first_seen" | "bundle" | "release" | "app_version" | "channel" | "native_build";
100
+ /**
101
+ * An UNCHANGED report the server keeps: what it changed against its
102
+ * installation's head, and the running values the head held before it. A
103
+ * report from an installation without a head is `first_seen` alone, with no
104
+ * previous values: the installation is new to this server, not necessarily
105
+ * to its device.
106
+ */
107
+ type BundleEventChange = DatabaseJsonObject & {
108
+ readonly kinds: BundleEventChangeKind[];
109
+ readonly previous: (DatabaseJsonObject & {
110
+ readonly bundle_id: string;
111
+ readonly release_id: string | null;
112
+ readonly app_version: string;
113
+ readonly channel: string;
114
+ readonly min_bundle_id?: string;
115
+ }) | null;
116
+ };
98
117
  /** Ancillary report data; queryable identity and lifecycle fields stay on the row. */
99
118
  type DatabaseBundleEventMetadata = DatabaseJsonObject & {
100
119
  readonly cohort: string;
101
120
  readonly update_strategy: "fingerprint" | "appVersion" | null;
102
121
  readonly fingerprint_hash: string | null;
103
122
  readonly sdk_version: string | null;
123
+ /** The native build's built-in bundle ID, when the SDK reports it. */
124
+ readonly min_bundle_id?: string;
104
125
  /** `UPDATE_FAILED`: what failed. */
105
126
  readonly failure?: BundleEventFailure;
106
127
  readonly http_response?: DatabaseHttpResponse;
@@ -108,6 +129,19 @@ type DatabaseBundleEventMetadata = DatabaseJsonObject & {
108
129
  readonly delivery?: "patch" | "manifest" | "archive" | "unknown";
109
130
  /** `UPDATE_DOWNLOADED`: a patch failed and the full files came instead. */
110
131
  readonly patch_fallback?: boolean;
132
+ /** A kept `UNCHANGED` row: what it changed, which the server sets. */
133
+ readonly change?: BundleEventChange;
134
+ /**
135
+ * A download or apply that arrived after its installation already ran its
136
+ * target, as when a reload cut the first runtime's report short: the
137
+ * server keeps it in history, but it moves and counts nothing.
138
+ */
139
+ readonly late?: true;
140
+ /**
141
+ * A launch or crash of a bundle whose download report never arrived: the
142
+ * server counted that download with it.
143
+ */
144
+ readonly implied_download?: true;
111
145
  };
112
146
  type BundleEventRowBase = {
113
147
  readonly id: string;
@@ -150,13 +184,14 @@ interface InsightsScope {
150
184
  }
151
185
  /**
152
186
  * Raw event predicates; recovery is attributed to the source bundle. An
153
- * UNCHANGED report is kept as no event, so no filter names it.
187
+ * UNCHANGED filter matches the kept rows that moved an installation to the
188
+ * bundle without an apply report.
154
189
  */
155
190
  type InsightsBundleEventFilter = InsightsScope & ({
156
191
  readonly type: "RECOVERED";
157
192
  readonly fromBundleId: string;
158
193
  } | {
159
- readonly type: "UPDATE_DOWNLOADED" | "UPDATE_APPLIED" | "UPDATE_FAILED";
194
+ readonly type: "UPDATE_DOWNLOADED" | "UPDATE_APPLIED" | "UPDATE_FAILED" | "UNCHANGED";
160
195
  readonly toBundleId: string;
161
196
  });
162
197
  type InsightsEventFilter = {
@@ -276,7 +311,10 @@ interface InsightsGetAppUsageResult {
276
311
  readonly bundleDistribution: readonly {
277
312
  readonly appVersion: string;
278
313
  readonly platform: "ios" | "android";
314
+ /** The release the installations run; null for none. */
279
315
  readonly releaseId: string | null;
316
+ /** The native build's built-in bundle, when they run it. */
317
+ readonly builtinBundleId: string | null;
280
318
  readonly installations: number;
281
319
  }[];
282
320
  readonly measuredAtMs: number;
@@ -607,6 +645,38 @@ declare const plugins: readonly [import("@hot-updater/plugin-core").HotUpdaterPl
607
645
  readonly sort: readonly ["bucket_start_ms"];
608
646
  };
609
647
  }, never, readonly ["channel", "platform", "app_version", "release_id", "bucket_start_ms"]>;
648
+ readonly insights_builtin_distribution: import("@hot-updater/plugin-core").AggregateDefinition<{
649
+ readonly channel: {
650
+ readonly type: "string";
651
+ };
652
+ readonly platform: {
653
+ readonly type: "string";
654
+ readonly maxLength: 16;
655
+ };
656
+ readonly app_version: {
657
+ readonly type: "string";
658
+ };
659
+ readonly release_id: {
660
+ readonly type: "string";
661
+ readonly maxLength: 36;
662
+ };
663
+ readonly builtin_bundle_id: {
664
+ readonly type: "string";
665
+ readonly maxLength: 36;
666
+ };
667
+ readonly bucket_start_ms: {
668
+ readonly type: "integer";
669
+ };
670
+ }, "latest_installations", {
671
+ readonly byScope: {
672
+ readonly eq: readonly ["channel", "platform"];
673
+ readonly sort: readonly ["bucket_start_ms"];
674
+ };
675
+ readonly byVersion: {
676
+ readonly eq: readonly ["channel", "platform", "app_version"];
677
+ readonly sort: readonly ["bucket_start_ms"];
678
+ };
679
+ }, never, readonly ["channel", "platform", "app_version", "release_id", "builtin_bundle_id", "bucket_start_ms"]>;
610
680
  readonly insights_latest_by_bundle: import("@hot-updater/plugin-core").AggregateDefinition<{
611
681
  readonly platform: {
612
682
  readonly type: "string";
package/dist/index.d.mts CHANGED
@@ -95,12 +95,33 @@ type DatabaseHttpResponse = DatabaseJsonObject & {
95
95
  readonly body_truncated: boolean;
96
96
  readonly received_at_ms: number;
97
97
  };
98
+ /** What a kept UNCHANGED row changed against its installation's head. */
99
+ type BundleEventChangeKind = "first_seen" | "bundle" | "release" | "app_version" | "channel" | "native_build";
100
+ /**
101
+ * An UNCHANGED report the server keeps: what it changed against its
102
+ * installation's head, and the running values the head held before it. A
103
+ * report from an installation without a head is `first_seen` alone, with no
104
+ * previous values: the installation is new to this server, not necessarily
105
+ * to its device.
106
+ */
107
+ type BundleEventChange = DatabaseJsonObject & {
108
+ readonly kinds: BundleEventChangeKind[];
109
+ readonly previous: (DatabaseJsonObject & {
110
+ readonly bundle_id: string;
111
+ readonly release_id: string | null;
112
+ readonly app_version: string;
113
+ readonly channel: string;
114
+ readonly min_bundle_id?: string;
115
+ }) | null;
116
+ };
98
117
  /** Ancillary report data; queryable identity and lifecycle fields stay on the row. */
99
118
  type DatabaseBundleEventMetadata = DatabaseJsonObject & {
100
119
  readonly cohort: string;
101
120
  readonly update_strategy: "fingerprint" | "appVersion" | null;
102
121
  readonly fingerprint_hash: string | null;
103
122
  readonly sdk_version: string | null;
123
+ /** The native build's built-in bundle ID, when the SDK reports it. */
124
+ readonly min_bundle_id?: string;
104
125
  /** `UPDATE_FAILED`: what failed. */
105
126
  readonly failure?: BundleEventFailure;
106
127
  readonly http_response?: DatabaseHttpResponse;
@@ -108,6 +129,19 @@ type DatabaseBundleEventMetadata = DatabaseJsonObject & {
108
129
  readonly delivery?: "patch" | "manifest" | "archive" | "unknown";
109
130
  /** `UPDATE_DOWNLOADED`: a patch failed and the full files came instead. */
110
131
  readonly patch_fallback?: boolean;
132
+ /** A kept `UNCHANGED` row: what it changed, which the server sets. */
133
+ readonly change?: BundleEventChange;
134
+ /**
135
+ * A download or apply that arrived after its installation already ran its
136
+ * target, as when a reload cut the first runtime's report short: the
137
+ * server keeps it in history, but it moves and counts nothing.
138
+ */
139
+ readonly late?: true;
140
+ /**
141
+ * A launch or crash of a bundle whose download report never arrived: the
142
+ * server counted that download with it.
143
+ */
144
+ readonly implied_download?: true;
111
145
  };
112
146
  type BundleEventRowBase = {
113
147
  readonly id: string;
@@ -150,13 +184,14 @@ interface InsightsScope {
150
184
  }
151
185
  /**
152
186
  * Raw event predicates; recovery is attributed to the source bundle. An
153
- * UNCHANGED report is kept as no event, so no filter names it.
187
+ * UNCHANGED filter matches the kept rows that moved an installation to the
188
+ * bundle without an apply report.
154
189
  */
155
190
  type InsightsBundleEventFilter = InsightsScope & ({
156
191
  readonly type: "RECOVERED";
157
192
  readonly fromBundleId: string;
158
193
  } | {
159
- readonly type: "UPDATE_DOWNLOADED" | "UPDATE_APPLIED" | "UPDATE_FAILED";
194
+ readonly type: "UPDATE_DOWNLOADED" | "UPDATE_APPLIED" | "UPDATE_FAILED" | "UNCHANGED";
160
195
  readonly toBundleId: string;
161
196
  });
162
197
  type InsightsEventFilter = {
@@ -276,7 +311,10 @@ interface InsightsGetAppUsageResult {
276
311
  readonly bundleDistribution: readonly {
277
312
  readonly appVersion: string;
278
313
  readonly platform: "ios" | "android";
314
+ /** The release the installations run; null for none. */
279
315
  readonly releaseId: string | null;
316
+ /** The native build's built-in bundle, when they run it. */
317
+ readonly builtinBundleId: string | null;
280
318
  readonly installations: number;
281
319
  }[];
282
320
  readonly measuredAtMs: number;
@@ -607,6 +645,38 @@ declare const plugins: readonly [import("@hot-updater/plugin-core").HotUpdaterPl
607
645
  readonly sort: readonly ["bucket_start_ms"];
608
646
  };
609
647
  }, never, readonly ["channel", "platform", "app_version", "release_id", "bucket_start_ms"]>;
648
+ readonly insights_builtin_distribution: import("@hot-updater/plugin-core").AggregateDefinition<{
649
+ readonly channel: {
650
+ readonly type: "string";
651
+ };
652
+ readonly platform: {
653
+ readonly type: "string";
654
+ readonly maxLength: 16;
655
+ };
656
+ readonly app_version: {
657
+ readonly type: "string";
658
+ };
659
+ readonly release_id: {
660
+ readonly type: "string";
661
+ readonly maxLength: 36;
662
+ };
663
+ readonly builtin_bundle_id: {
664
+ readonly type: "string";
665
+ readonly maxLength: 36;
666
+ };
667
+ readonly bucket_start_ms: {
668
+ readonly type: "integer";
669
+ };
670
+ }, "latest_installations", {
671
+ readonly byScope: {
672
+ readonly eq: readonly ["channel", "platform"];
673
+ readonly sort: readonly ["bucket_start_ms"];
674
+ };
675
+ readonly byVersion: {
676
+ readonly eq: readonly ["channel", "platform", "app_version"];
677
+ readonly sort: readonly ["bucket_start_ms"];
678
+ };
679
+ }, never, readonly ["channel", "platform", "app_version", "release_id", "builtin_bundle_id", "bucket_start_ms"]>;
610
680
  readonly insights_latest_by_bundle: import("@hot-updater/plugin-core").AggregateDefinition<{
611
681
  readonly platform: {
612
682
  readonly type: "string";