GCP.Observability reference
BucketsDatasetsLink
Section titled “BucketsDatasetsLink”Source:
src/GCP/Observability/BucketsDatasetsLink.ts
A Cloud Observability dataset link that creates a linked BigQuery
dataset over an observability analytics dataset (typically
_Trace/Spans).
A dataset may have only one link. Create, update, and delete are
long-running operations. Links have no labels field — Alchemy stamps
ownership into the description. linkId and the parent dataset are
identity; replacement is delete-first because a dataset cannot hold
two links.
BucketsDatasetsLink: Creating a Link
Section titled “BucketsDatasetsLink: Creating a Link”Link the default trace dataset to BigQuery
const link = yield* GCP.Observability.BucketsDatasetsLink("Analytics", { dataset: "projects/my-project/locations/us-central1/buckets/_Trace/datasets/Spans", description: "bigquery analytics",});Named link from bucket and dataset ids
const link = yield* GCP.Observability.BucketsDatasetsLink("Analytics", { bucket: "_Trace", dataset: "Spans", linkId: "trace_spans", displayName: "Trace spans",});BucketsDatasetsLink: Updating a Link
Section titled “BucketsDatasetsLink: Updating a Link”Change props on the same logical id; the engine keeps the physical id.
const link = yield* GCP.Observability.BucketsDatasetsLink("Analytics", { dataset: "projects/my-project/locations/us-central1/buckets/_Trace/datasets/Spans", description: "updated analytics",});TraceScope
Section titled “TraceScope”Source:
src/GCP/Observability/TraceScope.ts
A Cloud Observability trace scope — a named collection of projects whose traces are queried together in Trace Explorer.
Trace scopes exist only in the global location. They have no labels
field, so Alchemy stamps ownership into the description for list /
nuke. traceScopeId and location are identity — changing either
replaces the scope. resourceNames and description update in place.
The system-managed _Default scope cannot be deleted.
TraceScope: Creating a Trace Scope
Section titled “TraceScope: Creating a Trace Scope”Generated name covering this project
const scope = yield* GCP.Observability.TraceScope("App", { resourceNames: ["projects/my-project"], description: "application traces",});Named scope
const scope = yield* GCP.Observability.TraceScope("App", { traceScopeId: "app-traces", resourceNames: ["projects/my-project"],});TraceScope: Updating a Trace Scope
Section titled “TraceScope: Updating a Trace Scope”Change props on the same logical id; the engine keeps the physical id.
const scope = yield* GCP.Observability.TraceScope("App", { resourceNames: ["projects/my-project"], description: "all application traces",});