tag:help.appveyor.com,2012-11-13:/discussions/questions/1029-having-trouble-seeing-2nd-project-in-vs-onlineAppVeyor: Discussion 2018-08-25T01:54:21Ztag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T03:09:14Z2015-02-23T03:09:14ZHaving trouble seeing 2nd Project in VS Online<div><p>Is it Git or TFVC repo?</p>
<p>First of all, try to re-authorize VSO in AppVeyor. Go to
<a href="https://ci.appveyor.com/account">https://ci.appveyor.com/account</a>
and revoke VSO access. Then go back to "New project" page and
authorize VSO again.</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T03:27:16Z2015-02-23T03:27:16ZHaving trouble seeing 2nd Project in VS Online<div><p>worked for me.</p>
<p>thanks</p></div>rajindersinghtag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T03:31:16Z2015-02-23T03:31:16ZHaving trouble seeing 2nd Project in VS Online<div><p>Cool, thanks for the update!</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T16:46:30Z2015-02-23T16:46:30ZHaving trouble seeing 2nd Project in VS Online<div><p>Now that I can see the 2nd project I tried adding it to
Appveyor. I am getting this error:</p>
<p>Error adding webhook to VSO repository: Forbidden</p>
<p>what type of access do I need on VSO to be able to add
webhook?<br>
My client swears that he has give me the same access on both of my
projects.</p></div>rajindersinghtag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T16:49:46Z2015-02-23T16:49:46ZHaving trouble seeing 2nd Project in VS Online<div><p>Have you been able to add it?</p>
<p>-Feodor</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T17:13:30Z2015-02-23T17:13:30ZHaving trouble seeing 2nd Project in VS Online<div><p>When I add it I get this error</p>
<p>Error adding webhook to VSO repository: Forbidden</p>
<p>and add fails.</p></div>rajindersinghtag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T17:17:08Z2015-02-23T17:17:08ZHaving trouble seeing 2nd Project in VS Online<div><p>Is it Git or TFVC repo?</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T17:43:25Z2015-02-23T17:43:25ZHaving trouble seeing 2nd Project in VS Online<div><p>TFVC</p></div>rajindersinghtag:help.appveyor.com,2012-11-13:Comment/361105222015-02-23T18:00:10Z2015-02-23T18:00:10ZHaving trouble seeing 2nd Project in VS Online<div><p>OK, if you are absolutely sure permissions on both projects are
equal you can try adding webhook using VSO REST API and your
credentials.</p>
<p>You can use "alternative credentials" and Basic authentication:
<a href=
"http://www.visualstudio.com/integrate/get-started/auth/overview">http://www.visualstudio.com/integrate/get-started/auth/overview</a></p>
<p>AppVeyor uses the following calls to add webhook to TFVC
repository:</p>
<p>1st request - get project ID:</p>
<pre>
<code>GET https://{account-name}.visualstudio.com/DefaultCollection/_apis/projects/{project-name}</code>
</pre>
<p>Project ID is a guid in response.</p>
<p>2nd request - add hook subscription:</p>
<pre>
<code>POST https://{account-name}.visualstudio.com/DefaultCollection/_apis/hooks/subscriptions?api-version=1.0-preview.1</code>
</pre>
<p>Body:<br></p>
<pre>
<code>{
"consumerActionId" = "httpRequest",
"consumerId" = "webHooks",
"consumerInputs" = {
"url" = "{webhook url}"
},
"eventType" = "tfvc.checkin",
"publisherId" = "tfs",
"publisherInputs": {
"path": "$/your-tfs/project",
"projectId": "{projectId}"
}
}</code>
</pre></div>Feodor Fitsner