MCPcopy Create free account
hub / github.com/hashintel/hash / getClient

Method getClient

apps/hash-api/src/telemetry/telemetry.ts:51–62  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

49 private client: RudderAnalytics | null | undefined = undefined;
50
51 private getClient(): RudderAnalytics | null {
52 if (this.client === undefined) {
53 if (!RUDDERSTACK_KEY) {
54 this.client = null;
55 return null;
56 }
57 this.client = new RudderAnalytics(RUDDERSTACK_KEY, {
58 dataPlaneUrl: RUDDERSTACK_DATA_PLANE_URL,
59 });
60 }
61 return this.client;
62 }
63
64 /** The single place a request-scoped envelope is built. */
65 private buildEnvelope(

Callers 3

emitMethod · 0.95
emitPageMethod · 0.95
identifyActorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected