Skip to content

feat: version discovery, User-Agent, trace_id, ToolContext, telemetry#102

Merged
saurabhjain1592 merged 13 commits intomainfrom
feat/version-discovery
Mar 3, 2026
Merged

feat: version discovery, User-Agent, trace_id, ToolContext, telemetry#102
saurabhjain1592 merged 13 commits intomainfrom
feat/version-discovery

Conversation

@saurabhjain1592
Copy link
Member

@saurabhjain1592 saurabhjain1592 commented Mar 1, 2026

Summary

  • Version discovery and capability detection via /api/v1/version
  • User-Agent header fix (was hardcoded "1.0.0", now uses SDK_VERSION)
  • Capability detection for feature gating
  • traceId field on workflow create/status/list operations
  • ToolContext class for per-tool governance within tool_call steps
  • Anonymous runtime telemetry (fire-and-forget checkpoint ping on client init)
  • telemetry(Boolean) builder option, AXONFLOW_TELEMETRY=off / DO_NOT_TRACK=1 opt-out

Test plan

  • mvn test passes (1011 tests, 0 failures, 0 errors)
  • E2E: workflow-control Java example passes with trace_id assertions

- Add SDK_VERSION constant (3.8.0) in AxonFlowConfig
- Fix default User-Agent from axonflow-java-sdk/1.0.0 to axonflow-sdk-java/3.8.0
- Extend HealthStatus with capabilities and sdkCompatibility fields
- Add PlatformCapability and SDKCompatibility types
- Add hasCapability() method on HealthStatus
- Log warning when SDK version is below platform min_sdk_version
- Update tests for new HealthStatus constructor
@saurabhjain1592 saurabhjain1592 changed the title feat: version discovery, User-Agent fix, capability detection feat: version discovery, User-Agent fix, capability detection, trace_id, ToolContext Mar 1, 2026
P1: Add backward-compatible constructor overloads for HealthStatus (4-arg)
and workflow types (CreateWorkflowRequest, CreateWorkflowResponse,
StepGateRequest, WorkflowStatusResponse, ListWorkflowsOptions) to avoid
breaking callers that don't use new traceId/toolContext parameters.

P1: Make capabilities list immutable and never-null in HealthStatus
constructor. Add null guard to hasCapability() to prevent NPE.

P2: Make PlatformCapability and SDKCompatibility final. Add
equals/hashCode/toString to both. Update HealthStatus
equals/hashCode/toString to include capabilities and sdkCompatibility.

P2: Strip pre-release suffixes in compareSemver before parsing to handle
versions like "3.8.0-beta.1" correctly.

Changelog: Add traceId, ToolContext, and toolContext entries to [3.8.0].
Fire-and-forget checkpoint ping on client init with SDK version, OS,
arch, runtime version, deployment mode, and enabled features. Off by
default for community/sandbox, on for production. Opt out via
AXONFLOW_TELEMETRY=off or DO_NOT_TRACK=1.
@saurabhjain1592 saurabhjain1592 changed the title feat: version discovery, User-Agent fix, capability detection, trace_id, ToolContext feat: version discovery, User-Agent, trace_id, ToolContext, telemetry Mar 2, 2026
Production mode without credentials (community/self-hosted) now defaults
telemetry to OFF, matching Go/TypeScript SDKs and documented policy.
Add unique instance_id, config disable integration, timeout handling,
non-200 response, AXONFLOW_TELEMETRY integration, and enterprise mode
payload verification tests.
Remove credential-based default logic. Telemetry is now ON by default
for all modes except sandbox. Opt out via DO_NOT_TRACK=1,
AXONFLOW_TELEMETRY=off, or telemetry config flag.
Align with cross-SDK contract: trim DO_NOT_TRACK and AXONFLOW_TELEMETRY
before comparison so "1 " and " off" are handled correctly.
@saurabhjain1592 saurabhjain1592 merged commit 725dc9a into main Mar 3, 2026
9 checks passed
@saurabhjain1592 saurabhjain1592 deleted the feat/version-discovery branch March 3, 2026 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant