KB PS Unable to find package UiPath.Activities.Api - rpapub/WatchfulAnvil GitHub Wiki

Problem: Missing NuGet Package UiPath.Activities.Api

Symptoms

  • Build fails for WorkflowAnalyzerRules projects.
  • Errors when restoring packages.
  • Output shows:
    error NU1101: Unable to find package UiPath.Activities.Api.
    

Root Cause

The UiPath.Activities.Api package is hosted hosted on a private Azure DevOps NuGet feed and is not available on the default NuGet sources like nuget.org. Your environment is missing the UiPath MyGet package source required to resolve this dependency.

Solution

✅ Recommended Fix

Solution 1: Using Visual Studio (GUI)

  1. Open Visual Studio Go to ToolsNuGet Package ManagerPackage Manager Settings.

  2. Add a new package source Under Package Sources, click the + button.

  3. Enter source details:

    • Name: UiPath-Official
    • Source: https://uipath.pkgs.visualstudio.com/Public.Feeds/_packaging/UiPath-Official/nuget/v3/index.json
  4. Click OK to save and close the dialog.

  5. Restore packages Right-click on the solution in Solution Explorer → Restore NuGet Packages.


Solution 2: Using nuget.exe (CLI)

  1. Download nuget.exe if not already available.

  2. Add the UiPath feed:

    nuget sources Add -Name UiPath-Official -Source https://uipath.pkgs.visualstudio.com/Public.Feeds/_packaging/UiPath-Official/nuget/v3/index.json
    
  3. Restore the solution:

    nuget restore WatchfulAnvil.sln
    

🔄 Alternative Workarounds

  • Option: Use dotnet CLI with a temporary source:

    dotnet restore --source https://uipath.pkgs.visualstudio.com/Public.Feeds/_packaging/UiPath-Official/nuget/v3/index.json
    
  • Option: Create a nuget.config file in your solution directory with the UiPath feed listed under <packageSources>.


References

Sample error in Visual Studio Output Window

Build started at 5:55 PM...
1>------ Build started: Project: CPM.WorkflowAnalyzerRules, Configuration: Debug Any CPU ------
2>------ Build started: Project: CPRIMA.WorkflowAnalyzerRules, Configuration: Debug Any CPU ------
Failed to restore C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPRIMA.WorkflowAnalyzerRules\CPRIMA.WorkflowAnalyzerRules.csproj (in 319 ms).
Failed to restore C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPM.WorkflowAnalyzerRules\CPM.WorkflowAnalyzerRules.csproj (in 319 ms).
Failed to restore C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\tests\CPRIMA.WorkflowAnalyzerRules.Tests\CPRIMA.WorkflowAnalyzerRules.Tests.csproj (in 335 ms).
NuGet package restore failed. Please see Error List window for detailed warnings and errors.
1>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPM.WorkflowAnalyzerRules\CPM.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
1>Done building project "CPM.WorkflowAnalyzerRules.csproj" -- FAILED.
2>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPRIMA.WorkflowAnalyzerRules\CPRIMA.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
2>Done building project "CPRIMA.WorkflowAnalyzerRules.csproj" -- FAILED.
2>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPRIMA.WorkflowAnalyzerRules\CPRIMA.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
2>Done building project "CPRIMA.WorkflowAnalyzerRules.csproj" -- FAILED.
2>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPRIMA.WorkflowAnalyzerRules\CPRIMA.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
1>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPM.WorkflowAnalyzerRules\CPM.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
2>Done building project "CPRIMA.WorkflowAnalyzerRules.csproj" -- FAILED.
3>------ Build started: Project: CPRIMA.WorkflowAnalyzerRules.Tests, Configuration: Debug Any CPU ------
1>Done building project "CPM.WorkflowAnalyzerRules.csproj" -- FAILED.
3>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\tests\CPRIMA.WorkflowAnalyzerRules.Tests\CPRIMA.WorkflowAnalyzerRules.Tests.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
3>Done building project "CPRIMA.WorkflowAnalyzerRules.Tests.csproj" -- FAILED.
1>C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPM.WorkflowAnalyzerRules\CPM.WorkflowAnalyzerRules.csproj : error NU1101: Unable to find package UiPath.Activities.Api. No packages exist with this id in source(s): Microsoft Visual Studio Offline Packages, nuget.org
1>Done building project "CPM.WorkflowAnalyzerRules.csproj" -- FAILED.
4>------ Build started: Project: CPM.WorkflowAnalyzerRules.Tests, Configuration: Debug Any CPU ------
4>CSC : error CS0006: Metadata file 'C:\Users\tutor\source\repos\github.com\rpapub\WatchfulAnvil\src\CPM.WorkflowAnalyzerRules\obj\Debug\net8.0\ref\CPM.WorkflowAnalyzerRules.dll' could not be found
4>Done building project "CPM.WorkflowAnalyzerRules.Tests.csproj" -- FAILED.
========== Build: 0 succeeded, 4 failed, 0 up-to-date, 0 skipped ==========
========== Build completed at 5:55 PM and took 03.752 seconds ==========