UserAgentHelper class
Utility class for generating user agent strings for Copilot Studio client requests.
Methods
| get |
Generates a user agent string appropriate for the current environment.
|
| get |
Gets the SDK version number. |
| get |
Gets just the version string without environment details. |
Method Details
getProductInfo()
Generates a user agent string appropriate for the current environment.
- For browser environments, includes the browser's user agent.
- For Node.js environments, includes Node version, platform, architecture, and release.
static function getProductInfo(): string
Returns
string
A user agent string for HTTP headers.
getVersion()
Gets the SDK version number.
static function getVersion(): string
Returns
string
The version number (e.g., "0.1.0")
getVersionString()
Gets just the version string without environment details.
static function getVersionString(): string
Returns
string
The version string (e.g., "CopilotStudioClient.agents-sdk-js/0.1.0")