MCPcopy Index your code
hub / github.com/codeaashu/claude-code / createSpanAttributes

Function createSpanAttributes

src/utils/telemetry/sessionTracing.ts:156–169  ·  view source on GitHub ↗
(
  spanType: SpanType,
  customAttributes: Record<string, string | number | boolean> = {},
)

Source from the content-addressed store, hash-verified

154}
155
156function createSpanAttributes(
157 spanType: SpanType,
158 customAttributes: Record<string, string | number | boolean> = {},
159): Record<string, string | number | boolean> {
160 const baseAttributes = getTelemetryAttributes()
161
162 const attributes: Record<string, string | number | boolean> = {
163 ...baseAttributes,
164 'span.type': spanType,
165 ...customAttributes,
166 }
167
168 return attributes
169}
170
171/**
172 * Start an interaction span. This wraps a user request -> Claude response cycle.

Callers 7

startInteractionSpanFunction · 0.85
startLLMRequestSpanFunction · 0.85
startToolSpanFunction · 0.85
startToolExecutionSpanFunction · 0.85
executeInSpanFunction · 0.85
startHookSpanFunction · 0.85

Calls 1

getTelemetryAttributesFunction · 0.85

Tested by

no test coverage detected