App Environment
Obtain the basic information about the app and the environment in which it's running.
npm install @dynatrace-sdk/app-environment
Interfaces
UserDetails
Information about currently logged user
Properties
Name | Type |
---|---|
email*required | string |
id*required | string |
name*required | string |
Functions
getAppId
getAppId(): string
Retrieves the app id.
Returns
Return type | Description |
---|---|
string | app id defined in app config. |
getAppName
getAppName(): string
Retrieves the app name.
Returns
Return type | Description |
---|---|
string | app name defined in app config. |
getAppVersion
getAppVersion(): string
Retrieves the app version.
Returns
Return type | Description |
---|---|
string | app version defined in app manifest. |
getCurrentUserDetails
getCurrentUserDetails(): UserDetails
Retrieves the information about currently logged user
Returns
Return type | Description |
---|---|
UserDetails | id, name and email of currently logged user. |
getEnvironmentId
getEnvironmentId(): string
Retrieves the environment id.
Returns
Return type | Description |
---|---|
string | environment id on which app is run. |
getEnvironmentUrl
Still have questions?
Find answers in the Dynatrace Community