@fern-api/fdr-sdk 1.2.174-e2f8a24699 → 1.2.174-e7dedd2eea

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/js/index.mjs CHANGED
@@ -10493,8 +10493,52 @@ var ReindexResponseSchema = z21.object({
10493
10493
  /** The terminal Job outcome the endpoint waited for, or `queued` when called with `wait: false`. */
10494
10494
  outcome: z21.enum(["succeeded", "failed", "timed-out", "gone", "unrouted", "queued"]).optional()
10495
10495
  });
10496
+ var TelemetrySecondsSchema = z21.number().finite().min(0);
10497
+ var StaticBuildTelemetrySchema = z21.object({
10498
+ schemaVersion: z21.literal(1),
10499
+ /**
10500
+ * The Job's own view of which site and build this was. FDR logs the
10501
+ * promotion token's claim instead, which it signed itself; these are kept
10502
+ * only so a report can be matched back to the record in R2, and are absent
10503
+ * when the Job's environment did not name them.
10504
+ */
10505
+ domain: z21.string().max(253).optional(),
10506
+ buildId: z21.string().max(64).optional(),
10507
+ /** Parallel `astro build` shards the render used; cores and memory scale from it. */
10508
+ shards: z21.number().int().min(1),
10509
+ /** vCPU one shard reserved, for the pod's whole lifetime. */
10510
+ cpuPerShard: z21.number().finite().min(0),
10511
+ /** GiB one shard reserved, likewise. */
10512
+ memoryGiPerShard: z21.number().finite().min(0),
10513
+ /**
10514
+ * The pod's wall clock, first stage mark to last. Absent when the stages
10515
+ * left too few marks to span, in which case there is no cost to derive
10516
+ * either: a build that cannot be timed must not be logged as a free one.
10517
+ */
10518
+ durationSeconds: TelemetrySecondsSchema.optional(),
10519
+ /**
10520
+ * How long each stage of the Job ran, so a regression can be attributed to
10521
+ * one. Named stages rather than a map, so a stray stage file cannot widen
10522
+ * the log line FDR writes from this.
10523
+ */
10524
+ stageSeconds: z21.object({
10525
+ hydrate: TelemetrySecondsSchema.optional(),
10526
+ build: TelemetrySecondsSchema.optional(),
10527
+ export: TelemetrySecondsSchema.optional()
10528
+ }).default({}),
10529
+ /**
10530
+ * Which build this was of its deployment. A shadow build renders the same
10531
+ * deployment without being served; its cost is the thing being judged, so
10532
+ * it must be separable in a query rather than derivable from a name.
10533
+ */
10534
+ variant: z21.enum(["normal", "shadow"]).optional(),
10535
+ /** The original build's id when `variant` is `shadow`. */
10536
+ shadowOf: z21.string().max(64).optional()
10537
+ });
10496
10538
  var PromoteStaticBuildInputSchema = z21.object({
10497
- token: z21.string().min(1)
10539
+ token: z21.string().min(1),
10540
+ /** Best effort: `.catch(undefined)` so a publish cannot fail over a measurement. */
10541
+ telemetry: StaticBuildTelemetrySchema.optional().catch(void 0)
10498
10542
  });
10499
10543
  var PromoteStaticBuildResponseSchema = z21.object({
10500
10544
  buildId: z21.string(),