My intention is to do bulk update of a test run steps. I have created test set folder -> test set instance-> test run. I can update a test run by posting json with url
https://qcurl/qcbin/rest/domains/DOMAIN_NAME/projects/PROJECT_NAME/runs/run_id
{"Fields":[{"Name":"status","values":[{"value":"Passed"}]}]}
This works fine
Now according to the API
Post, Put To create or update more than one entity of the same entity type, pass the data in the request body. Pass an XML string compliant with the Entities Collection Schema or a JSON string of the same format returned by a GET operation on the collection.
To create entities, use an HTTP POST call. To update entities, use an HTTP PUT call.
Pass one of these content-type headers: content-type="application/xml;type=collection" content-type="application/json;type=collection"
Use the content-type header that matches the data you are sending
now i tried many combinations of posting the json for bulk update , everytime i get an error with
{
"Id": "qccore.method-not-allowed",
"Title": "Method not allowed",
"ExceptionProperties": null,
"StackTrace": null
}
The json i tried to post to url
http://ALM_URI/runs/<run_id>/run-steps
{
"entities": [{
"Fields": [
{
"Name": "id",
"values": [{
"value": "1219"
}
]
}, {
"Name": "status",
"values": [{
"value": "Failed"
}
]
}
]
}, {
"Fields": [
{
"Name": "id",
"values": [{
"value": "1220"
}
]
}, {
"Name": "status",
"values": [{
"value": "Passed"
}
]
}
]
}
]
}
and this one as well
{
"data": [
{
"Fields": [
{
"Name": "id",
"values": [
{
"value": "1215"
}
]
},
{
"Name": "status",
"values": [
{
"value": "N/A"
}
]
}
]
},
{
"Fields": [
{
"Name": "id",
"values": [
{
"value": "1216"
}
]
},
{
"Name": "status",
"values": [
{
"value": "N/A"
}
]
}
]
}
]
}
So far none of them seems to be work. If anyone has done any bulk operations on any ALM API resources please can you point out where iam going wrong in posting request. FYI this is a PUT request . Thank you in advance