Rune Becker-Olsen
Rune Becker-Olsen

Reputation: 46

How to add a comment to a git pull request via tfs api

I am working on implementing a script that would (hopefully) help in the following scenario:

Our team is using TFS 2013 where our source code is stored in a number of git repositories.

Our development process is like this:

Where the script comes in is that we have some automatic build and test jobs (some runs as build definitions in tfs, some runs outside tfs), and would like to have feedback from these jobs as a part of the pull request so the reviewers get this feedback as well. This is very much inspired by the traditional gerrit/jenkins setup.

Our plan is to use the TFS REST api regarding pull requests: https://www.visualstudio.com/integrate/api/git/pull-requests and do the following:

Based on the documentation of the tfs REST api in the link above, all of this seems to be possible, except for the ability to post a comment in the pull request.

Is there another api for interacting with the pull requests in tfs where it is possible to add a comment to the pull request?

Upvotes: 1

Views: 1408

Answers (1)

Tomer W
Tomer W

Reputation: 3443

I think Git/Pull-Requests/Threads API Documemntation is what you are searching for
They call "Comments" as "Comment Threads" and in the documentation,
its put as "Threads"

Upvotes: 1

Related Questions