Table of Contents

Class UserAgent

Namespace
DatabentoDotNet
Assembly
DatabentoDotNet.Dbn.dll

The identity string this client sends on every request: the live gateway's client= field on authentication, and the historical client's HTTP User-Agent header. One string, because both are the same identity — there is deliberately no second, HTTP-specific variant.

public static class UserAgent
Inheritance
UserAgent
Inherited Members

Remarks

Port of upstream's USER_AGENT (lib.rs:288-295), which formats Databento/{crate version} Rust {os}-{arch}. **The leading token is deliberately DatabentoDotNet, not Databento**: this is a third-party client, and a user agent that says otherwise would misattribute this library's traffic — and its bugs — to the vendor's own clients in their logs. Same reason the package is not Databento.*; see CLAUDE.md, "Naming".

The platform token is .NET's runtime identifier — osx-arm64, linux-x64, win-x64 — which carries the OS and the architecture that upstream reports separately.

This type moved here from DatabentoDotNet.Live in #32. DatabentoDotNet.UserAgent.Build() reads its own version off typeof(UserAgent).Assembly, which now resolves to the codec assembly rather than the live one. That is not a behavior change: every project shares VersionPrefix from Directory.Build.props, so the rendered version is identical either way — it would only start to matter if a project were ever versioned independently of the others.

Properties

Value

The user agent for this build, computed once.

public static string Value { get; }

Property Value

string