MCPcopy Create free account
hub / github.com/CopilotKit/CopilotKit / stripCloudKeys

Function stripCloudKeys

packages/shared/src/telemetry/lambda-client.ts:53–62  ·  view source on GitHub ↗
(
  obj: Record<string, unknown> | undefined,
)

Source from the content-addressed store, hash-verified

51const STRIPPED_KEYS = new Set(["cloud.public_api_key", "cloud.publicApiKey"]);
52
53function stripCloudKeys(
54 obj: Record<string, unknown> | undefined,
55): Record<string, unknown> {
56 if (!obj) return {};
57 const out: Record<string, unknown> = {};
58 for (const [k, v] of Object.entries(obj)) {
59 if (!STRIPPED_KEYS.has(k)) out[k] = v;
60 }
61 return out;
62}
63
64// Pull telemetry_id out of a CopilotKit license token without verifying
65// the signature. The token shape is a standard JWT

Callers 1

sendFunction · 0.85

Calls 2

entriesMethod · 0.80
hasMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…