May 04 2021
02:06 AM
- last edited on
Mar 05 2024
01:10 PM
by
TechCommunityAP
May 04 2021
02:06 AM
- last edited on
Mar 05 2024
01:10 PM
by
TechCommunityAP
Anyone managed to get the work items using ADO REST API? I have setup everything but each time I try to preview data (ADO wit) or run the activity, I am getting error:
Error occurred when deserializing source JSON file ''. Check if the data is in valid JSON object format. Unexpected character encountered while parsing value: <. Path '', line 0, position 0.>
I have constructed REST API as below and using POST method https://dev.azure.com/{organization}/{project}/{team}/_apis/wit/wiql?api-version=6.0
My rest API url: https://dev.azure.com/MyOrg/myproj/myteam/_apis/wit/wiql?api-version=6.0
further info on variable:
@apiBody1={ "query": "Select [System.Id] From WorkItems Where [System.WorkItemType] In ('
@apiBody2=' and [System.AreaPath] = 'mypath'" } --sometime this also has '\' such as mypath\subpath
further I am concatenating the variables:
@{concat(variables('apiBody1'),item().WorkItemType,variables('apiBody2'))}
May 04 2021 04:02 AM - edited May 05 2021 12:24 AM
I am using PAT for authentication.