Is there a .NET API for REST API Build 2.0 for TFS 2015?

The REST API link for VS Team Services and TFS separates the Build 1.0 and Build 2.0 APIs.

It seems that this difference also exists in the .NET API, because when you run the following code, only the "old" XAML assembly definitions are listed, not the new ones.

var tpc = new TfsTeamProjectCollection(new Uri("http://tfsurl")); var buildServer = tpc.GetService<IBuildServer>(); var def = buildServer.QueryBuildDefinitions("Project Name"); // Finds only XAML definitions 

Is there a new DLL that I can reference to write equivalent code that will work with the new TFS or web API, all that is?

+8
c # tfs tfs2015 team-build
source share
1 answer

You are looking for:

  Microsoft.TeamFoundation.Build.WebApi.BuildDefinition 

in

  Microsoft.TeamFoundation.Build2.WebApi, Version=14.0.0.0 

You can contact them through:

  Microsoft.TeamFoundation.Build.WebApi.BuildHttpClient 

The easiest way to add it to your project is the Nuget Package:

 PM> Install-Package Microsoft.TeamFoundationServer.ExtendedClient 
+7
source share

All Articles