如何通过 autho 2 详细信息在 Azure DevOps 中创建测试套件

How to pass autho 2 details white creating a test suite in Azure DevOps

我正在尝试使用 Rest API 在 Azure DevOps 中创建一个测试套件。但是这里我不确定如何提供安全细节。

他们在文档中提到了以下详细信息。我像这样在 Postman 中传递它。我也尝试在客户端 ID 和客户端密码中提供我的凭据。请指导

{"$id":"1","innerException":null,"message":"A potentially dangerous Request.Path value was detected from the client (&).","typeName":"System.Web.HttpException, System.Web","typeKey":"HttpException","errorCode":0,"eventId":0}

有几种方法可以调用 Azure DevOps REST API,在你的问题中,它使用 Oauth 2.0 流程进行身份验证,你可以按照这个 doc 获取令牌并调用 API.

在你的情况下,如果不需要使用Oauth 2.0流程进行身份验证,其实我建议你使用PAT(个人访问令牌)来调用API,只需生成一个并使用postman里面的,参考这个doc.