Select the checkboxes of all the projects to which you want to add the NuGet package. Make sure you're adding the package to your native projects, as the target files within our package interact with the build.
Select OK.
Add the Dynatrace MAUI NuGet package to your MAUI project.
Use .NET CLI
Use the following command to add the Dynatrace dependency to your project:
dotnet add package Dynatrace.OneAgent.MAUI
For more information, please see our nuget.org page.
3. Initialize the package
The start method is required for the OneAgent to initialize and capture data.
using Dynatrace.MAUI;
Agent.Instance.Start();
Verify your installation
After installing and configuring the Dynatrace .NET MAUI NuGet package, verify that data is being collected:
Open your app and perform several actions (navigate between screens, tap buttons, and make network requests).
Go to your mobile frontend in Dynatrace:
Go to Experience Vitals > Overview.
Select Mobile to view all mobile frontends.
Select the frontend you want to configure.
Verify that sessions and user actions appear in the data.
This data can also be analyzed directly in Grail using DQL.
It may take a few minutes for data to appear in Dynatrace after the first app launch.
Next steps
After completing the initial setup, consider exploring the following topics to enhance your monitoring capabilities: