I´m sending this JSON
{
"path": "/relations/-",
"op": "add",
"value": {
"url": "https://www.google.de",
"attributes": {
"comment": "test"
},
"rel": "Hyperlink"
}
}but receiving following error message
Invoke-RestMethod : {"$id":"1","innerException":null,"message":"Value {\r\n \"url\": \"https://www.google.de\",\r\n \"attributes\": \"System.Collections.Hashtable\",\r\n \"rel\":
\"Hyperlink\"\r\n} does not match the expected type
Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItemRelation.","typeName":"Microsoft.VisualStudio.Services.Common.VssPropertyValidationException,
Microsoft.VisualStudio.Services.Common","typeKey":"VssPropertyValidationException","errorCode":0,"eventId":3000}
In **truncated**
+ ... dWorkItem = Invoke-RestMethod -Uri $url -Method patch -UseDefaultCred ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand Do you have an idea?
I´m using the onPremises Version Dev18.M170.8