Search code examples
azurerestpostmanazure-devops-rest-api

Azure devops rest API postman error Value cannot be null.\r\nParameter name: TestPointUpdateParams


Hello I'm trying to update the outcome of a test point with the azure devops rest api using postman from active to passed

This is the request i'm using:

PATCH https://dev.azure.com/fodservices/Training%20projects/_apis/testplan/Plans/70152/Suites/70154/TestPoint?api-version=6.1-preview.2

And this is the body

{
    "value" : [
    {
            "id": 11431,
            "isActive": false,
            "results": {
                
                "outcome": "passed"
            }
    }
]
}

I'm getting a 400 bad request error and the message is : Value cannot be null.\r\nParameter name: TestPointUpdateParams Anyone can help what I'm doing wrong please

postman error


Solution

  • According to my research, we need to update the request body as the following json. For more details, please refer to here

    [
        {
                "id": 1,
                "results": {              
                      "outcome": "passed"
                }         
        }
    ]
    
    

    For example

    PATCH https://dev.azure.com/{organization}/{project}/_apis/test/Plans/{planId}/Suites/{suiteId}/points/{pointIds}?api-version=6.0
    
    [
        {
                "id": 1,
                "results": {              
                      "outcome": "passed"
                }         
        }
    ]
    

    enter image description here