{"record":{"id":"ae171d4f302b88e8","repo":"different-ai/openwork","slug":"service-name-is-required","errorCode":null,"errorMessage":"service name is required","messagePattern":"service name is required","errorType":"validation","errorClass":"ObservabilityConfigError","httpStatus":null,"severity":"error","filePath":"ee/packages/utils/src/observability.ts","lineNumber":151,"sourceCode":"  }\n\n  switch (backend) {\n    case \"none\":\n    case \"otel\":\n    case \"sentry\":\n      return backend\n    default:\n      throw new ObservabilityConfigError(\n        \"must be one of none, otel, sentry\",\n        \"DEN_OBSERVABILITY_BACKEND\",\n      )\n  }\n}\n\nfunction requireServiceName(serviceName: string): string {\n  const trimmed = serviceName.trim()\n  if (!trimmed) {\n    throw new ObservabilityConfigError(\"service name is required\")\n  }\n  return trimmed\n}\n\nfunction validateHttpUrl(value: string, envKey: string): string {\n  let parsed: URL\n  try {\n    parsed = new URL(value)\n  } catch {\n    throw new ObservabilityConfigError(\"must be an absolute http(s) URL\", envKey)\n  }\n\n  if (parsed.protocol !== \"http:\" && parsed.protocol !== \"https:\") {\n    throw new ObservabilityConfigError(\"must use http or https\", envKey)\n  }\n  if (!parsed.hostname) {\n    throw new ObservabilityConfigError(\"must include a hostname\", envKey)\n  }","sourceCodeStart":133,"sourceCodeEnd":169,"githubUrl":"https://github.com/different-ai/openwork/blob/2b7df46e8ae1517d64c896c7793d2d52ec845669/ee/packages/utils/src/observability.ts#L133-L169","documentation":"Error \"service name is required\" thrown in different-ai/openwork.","triggerScenarios":"Thrown at ee/packages/utils/src/observability.ts:151 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2b7df46e8ae1517d64c896c7793d2d52ec845669","analyzedAt":"2026-09-01T07:59:23.713Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}