Build agent ID via TFS sdk - tfs

I am using the TFS2018 api and I need to get the build agent id for different team projects. How can I get the list of agent queue ids using the TFS sdk?

This is well-documented.
GET https://fabrikam-fiber-inc.visualstudio.com/DefaultCollection/Fabrikam-Fiber-Git/_apis/distributedtask/queues?api-version=3.0-preview.1

Related

Adding TFS add-in into Teams

We have TFS 2015 (on-premise) and Microsoft Teams in the cloud.
I am trying to find the TFS plug-in (all I can see is Azure DevOps) and want to be able to show TFS information inside of Teams.
I see lots of articles on how this use to work? But can't find it in my list of plugins to add into the system.
Is there something we need to do at a server level?
Thanks
There is an official extension-- Microsoft Teams Integration.
With using this, you are able to see activity about your Azure DevOps or Team Foundation Server projects directly in your Microsoft Teams channel, for example:
Work item updates
Pull requests
Code commits
Builds
Release deployments and approvals
Work item updates
Azure DevOps Kanban board
However, as the link declare clearly, it only work with Team Foundation Server 2017 Update 2 and above. It's not able to do this with TFS2015. You need to upgrade your TFS version. With higher version, you could also get more released new features in TFS.

TFS With Jira - Any tools?

I'm looking at integrating TFS with JIRA. I Want to run my test cases in TFS but when i raise bugs i want them to automatically update on the JIRA board. Is there anything out there that can make this possible?
Also would it automatically block the test case and link the bug in JIRA with it?
There is no such kind of build in feature or extension. However, you could raise bugs in TFS/Azure DevOps first when you run your test cases. Then synchronize your bugs with issues in Jira. It's not able to directly link the bug in JIRA with TFS test cases.
You could choose to use TFS4JIRA Azure DevOps integration.
TFS4JIRA is migration, integration and synchronization tool, which
bridges TFS / Azure DevOps and Jira (Server/DC/Cloud). Integrate
Azure DevOps with TFS4JIRA, to view your project or issue-associated
Azure DevOps check-ins in Jira, as well as synchronize changes made to
the issues and integrate Azure Jira work items.
Create your individual TFS4JIRA sync profiles and define the project collections which you want to work with.
Map your issue types, work item types, fields, values.
Hierarchy and subtasks synchronisation supported.
Enable your profile and, voila! – the synchronizer is making sure that Jira and Azure DevOps exchange information in the background.
If you already have some bug/issue work items in JIRA and want to import them to TFS on-premise server. There is an extension named Jira to Azure DevOps/TFS work item migration tool. It is used to Azure DevOps work item migration tool lets you export data from Jira and import it as work items in Azure DevOps or Microsoft Team Foundation Server. Here is the download page.

How to retrieve the Agent for a specific Release

The TFS Rest API allows me to get a specific Release for a Team Project
Ex. https://bla.visualstudio.com/MySuperProject/_apis/release/releases/666
I already found, how to get the related Pool of the Release. But is it possible to retrieve the Agent where the Release was deployed using the TFS Rest API ?
Thanks
You can get the release with all the details by calling REST API as shown below. You should use youraccount.vsrm.visualstudio
https://yourVSTSAccount.vsrm.visualstudio.com/yourproject/_apis/release/releases/releaseid
example
https://myac.vsrm.visualstudio.com/Project%20X/_apis/release/releases/106
gives the release agent in deployment steps as shown below

TFS REST API to create a tfs groups ( NOT TEAMS) for TFS 2017

I need help to get a curl request URL for REST API for TFS to create groups under team project. There is curl request for creating a team but I need it for creating a TFS Group.
That REST API doesn't exist in TFS up until at least a very recent version (read 2018rc) and even then I'm not sure it's exposed yet. It's a preview API on VSTS at the moment.
The old client object model, soap API is the way to go or using tfssecurity.exe.

How to get Version of TFS in Build Extension

I need to check version of client's TFS server using my TFS extension.My aim is to identify whether it is TFS 2015.2 (or later version) or TFS 2017. Is this feasible (inbuilt/ out of the box method available) or Is there any workaround available to achieve this. Please help.
As per below post it is possible to differentiate VSTS from TFS. But I need one step forward to get specific version.
How to limit build task only to VSTS not TFS
As far as I know, there is no related rest API will directly return TFS version number.
However as a workaround you could start from one place API-version. For example, the 3.0 API set was introduced with Team Foundation Server 2017. It's not support on TFS 2015.

Resources