VSTS Authenticating with vssClientCredentials

Viewed 1582

I am currently trying to connect to a VSTS project using the code below, I have previously connected successfully after entering credentials into the dialog box shown.

if (!IsConnected)
{
    sourceControl = release.SourceControl;
    connection = new VssConnection(new Uri(sourceControl), new VssClientCredentials());
    workItemTrackingHttpClient = connection.GetClient<WorkItemTrackingHttpClient>();
}

The dialog box is no longer shown and an exception is thrown:

TF400813: Resource not available for anonymous access. Client authentication required.

I am unaware of any changes that could have caused this to break, any help would be greatly appreciated.

1 Answers
Related