@cuylabs/agent-foundry-agentserver-core
v4.4.0
Published
Shared TypeScript host utilities for Foundry Agent Server protocol packages
Maintainers
Readme
@cuylabs/agent-foundry-agentserver-core
Shared host utilities for TypeScript Foundry Agent Server protocol packages.
This package mirrors the protocol-agnostic parts of Python
azure-ai-agentserver-core: configuration resolution, request/session ID
sanitization, request correlation IDs, server-version header formatting, and
standard error envelopes. Protocol packages such as
@cuylabs/agent-foundry-agentserver-invocations build their HTTP surface on top
of these helpers.
Observability
Core always creates OpenTelemetry-compatible request spans and installs the Node async context manager so protocol handlers can read active baggage. It sets the Foundry baggage keys used by the Python host:
azure.ai.agentserver.invocation_id
azure.ai.agentserver.session_idExporter setup is optional and is driven by the same environment variables used by hosted agents:
| Variable | Behavior |
| --- | --- |
| APPLICATIONINSIGHTS_CONNECTION_STRING | Enables Azure Monitor export through the package's optional @azure/monitor-opentelemetry dependency |
| OTEL_EXPORTER_OTLP_ENDPOINT | Enables OTLP HTTP trace export through the package's optional OpenTelemetry exporter dependencies |
Protocol packages call configureAgentServerObservability() by default. Apps
that already own OpenTelemetry setup can disable package-managed exporter setup
at the protocol layer and keep the span/baggage helpers.
