Install the agent (.NET 7.0 and above)

  1. Add NuGet Atatus package in your application.

    copy
    icon/buttons/copy
    # Package Manager
    Install-Package Atatus.NetCoreAll -Version 2.0.1
    
    (or)
    
    # .NET CLI
    dotnet add package Atatus.NetCoreAll --version 2.0.1
    
  2. Add below initialization code into your Startup.cs file.

    For ASP.NET Core, once you reference the Atatus.NetCoreAll package, please call UseAllAtatus() extension method to enable auto instrumentation.

    Make sure to have the line app.UseAllAtatus(...) as the first line in the Configure method. If not, the correct timings of your request would not be captured.

    copy
    icon/buttons/copy
    using Atatus.NetCoreAll;
    
    var app = builder.Build();
    app.UseAllAtatus();
    
    // Your code here
    
  3. Add your Atatus configuration in your environment.

    copy
    icon/buttons/copy
    export ATATUS_LICENSE_KEY="YOUR_LICENSE_KEY"
    export ATATUS_APP_NAME="YOUR_APP_NAME"
    export ATATUS_ANALYTICS=true
    
  4. Restart your .NET server.

    Just restart your server and access it from your web app or curl. You will visualize your application's metrics within minutes.

In Program.cs file

  1. Add NuGet Atatus package in your application.

    copy
    icon/buttons/copy
    # Package Manager
    Install-Package Atatus.NetCoreAll -Version 2.0.1
    
    (or)
    
    # .NET CLI
    dotnet add package Atatus.NetCoreAll --version 2.0.1
    
  2. Add below initialization code into your Program.cs file.

    For ASP.NET Core, once you reference the Atatus.NetCoreAll package, please call UseAllAtatus() extension method to enable auto instrumentation.

    Make sure to have the line app.UseAllAtatus(...) as the first line in the Configure method. If not, the correct timings of your request would not be captured.

    copy
    icon/buttons/copy
    using Atatus.NetCoreAll;
    
    var app = builder.Build();
    
    // import your appsettings configuration.
    IConfiguration configuration = new ConfigurationBuilder()
                            .AddJsonFile("appsettings.json")
                            .Build();
    app.UseAllAtatus(configuration);
    
  3. Add your Atatus configuration in your appsettings.json file.

    copy
    icon/buttons/copy
    "Atatus": {
        "AppName": "YOUR_APP_NAME",
        "LicenseKey": "YOUR_LICENSE_KEY"
    }
    
  4. Restart your .NET server.

    Just restart your server and access it from your web app or curl. You will visualize your application's metrics within minutes.

Install the agent (Below .NET 7.0)

  1. Add NuGet Atatus package in your application.

    copy
    icon/buttons/copy
    # Package Manager
    Install-Package Atatus.NetCoreAll -Version 2.0.1
    
    (or)
    
    # .NET CLI
    dotnet add package Atatus.NetCoreAll --version 2.0.1
    
  2. Add below initialization code into your Startup.cs file.

    For ASP.NET Core, once you reference the Atatus.NetCoreAll package, please call UseAllAtatus() extension method to enable auto instrumentation.

    Make sure to have the line app.UseAllAtatus(...) as the first line in the Configure method. If not, the correct timings of your request would not be captured.

    copy
    icon/buttons/copy
    using Atatus.NetCoreAll;
    
    public class Startup
    {
      public void Configure(IApplicationBuilder app, IHostingEnvironment env)
      {
        app.UseAllAtatus(Configuration);
        // Your code here
      }
      // Your code here
    }
    
  3. Add your Atatus configuration in your appsettings.json file.

    copy
    icon/buttons/copy
    "Atatus": {
        "AppName": "YOUR_APP_NAME",
        "LicenseKey": "YOUR_LICENSE_KEY"
    }
    
  4. Restart your .NET server.

    Just restart your server and access it from your web app or curl. You will visualize your application's metrics within minutes.