While trying out the example for updating the example for "Add a link",
Failing body:
$body = @(@(
[ordered]@{
op = 'add'
path = '/relations/-'
value = @{
rel = 'System.LinkTypes.Related'
url = "$url_value"
attributes = @{
comment = "Linking the workitem"
}
}
}
[ordered] @{
op = 'add'
path = '/fields/System.Tags'
value = "devops"
}
Error:
error=;{"$id":"1","innerException":null,"message":"Value {\r\n \"url\": \"https://dev.azure.com/organization/project/_apis/wit/workItems/2206\",\r\n \"attributes\": \"System.Collections.Hashtable\",\r\n \"rel\": \"System.LinkTypes.Related\"\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}
Working body:
$body = @(@(
[ordered]@{
op = 'add'
path = '/relations/-'
value = @{
rel = 'System.LinkTypes.Related'
url = "$url_value"
}
}
[ordered] @{
op = 'add'
path = '/fields/System.Tags'
value = "devops"
}
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
ID: db41f842-3e23-d6dc-5caf-de87516b051d
Version Independent ID: a063d33b-7a9b-7ad1-f77d-bee88cfc429c
While trying out the example for updating the example for "Add a link", Failing body:
Error: error=;{"$id":"1","innerException":null,"message":"Value {\r\n \"url\": \"https://dev.azure.com/organization/project/_apis/wit/workItems/2206\",\r\n \"attributes\": \"System.Collections.Hashtable\",\r\n \"rel\": \"System.LinkTypes.Related\"\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}
Working body: $body = @(@(
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.