cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Mohanrajgmr13
Frequent Visitor

MICROSOFT FLOW FOR ADD NEW TAG TO TERMSET AND PARSE OBJECT

Hi,

Iam trying to add tag to "TermSet" using Add object in ms flow connector. With api/v2.1/termstore/groups/sets/children

 

I am trying to parse JSON.

 

My Schema in "parse Json"

 

{ "type":"object", "Properties":{ "@@odata.context":{ "Type":"string" }, Id":{ "Type":"string" }, "IsDeprecated":{

"Type":"integer" }, "ChildrenCount":{ "Type":"integer" }, "CreatedDateTime":{ "Type":"string" }, "Labels":{ "Type":"array", "Items":{ "Type":"object" "Properties":{ "Name":{ "Type":"string" }, "isdefault":{ "type":"boolean" }, "LanguageTag": { "type":"string" } } } }, "Descriptions"{ "Type":"array", "Items":{ "Type":"object", "Properties":{ "Description":{ "Type":"string" }, "LanguageTag":{ "Type":"string" } } } }, "isAvailableForTagging":{ "type":"array", "Items":{ "type":"object", "Properties":{ "SetId":{ "Type":"string" }, "isAvailable":{ "type":"boolean" } } } } } }`

 

Iam getting error like

 

InvalidTemplate Unable to process template language expression in action'parse_Json' imputs at line 1 and column '49572':'Required Property 'content' expects a value but got null. Path".'.`.

 

Help me to clear this issue.

Thanks in Advance

7 REPLIES 7
jinivthakkar
Super User
Super User

@Mohanrajgmr13 please check this:

 

https://www.c-sharpcorner.com/blogs/how-to-create-term-in-term-store-using-power-automate

 

 

--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

DamoBird365
Super User
Super User

Hi @Mohanrajgmr13 ,

 

I checked your JSON at https://jsonformatter.org/json-parser and you have a few formatting issues.

 

For example id isn't encapsulated in "":

{ "type":"object", "Properties":{ "@@odata.context":{ "Type":"string" }, Id":{ "Type":"string" }, "IsDeprecated":{

A : instead of a , after object

"Type":"object":"Properties":{ "Name":{

And a missing : after descriptions.

 

Try this

 

{
"type": "object",
"Properties": {
"@@odata.context": {
"Type": "string"
},
"Id": {
"Type": "string"
},
"IsDeprecated": {
"Type": "integer"
},
"ChildrenCount": {
"Type": "integer"
},
"CreatedDateTime": {
"Type": "string"
},
"Labels": {
"Type": "array",
"Items": {
"Type": "object",
"Properties": {
"Name": {
"Type": "string"
},
"isdefault": {
"type": "boolean"
},
"LanguageTag": {
"type": "string"
}
}
}
},
"Descriptions": {
"Type": "array",
"Items": {
"Type": "object",
"Properties": {
"Description": {
"Type": "string"
},
"LanguageTag": {
"Type": "string"
}
}
}
},
"isAvailableForTagging": {
"type": "array",
"Items": {
"type": "object",
"Properties": {
"SetId": {
"Type": "string"
},
"isAvailable": {
"type": "boolean"
}
}
}
}
}
}

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Cheers,
Damien


P.S. take a look at my new blog here

 

 

As Iam new to MS Flow can you please provide me corrected JSON I can't understand what was the error, I have tried changing the id -> Id but same error occurs again

DamoBird365
Super User
Super User

@Mohanrajgmr13 

 

{
"type": "object",
"Properties": {
"@@odata.context": {
"Type": "string"
},
"Id": {
"Type": "string"
},
"IsDeprecated": {
"Type": "integer"
},
"ChildrenCount": {
"Type": "integer"
},
"CreatedDateTime": {
"Type": "string"
},
"Labels": {
"Type": "array",
"Items": {
"Type": "object",
"Properties": {
"Name": {
"Type": "string"
},
"isdefault": {
"type": "boolean"
},
"LanguageTag": {
"type": "string"
}
}
}
},
"Descriptions": {
"Type": "array",
"Items": {
"Type": "object",
"Properties": {
"Description": {
"Type": "string"
},
"LanguageTag": {
"Type": "string"
}
}
}
},
"isAvailableForTagging": {
"type": "array",
"Items": {
"type": "object",
"Properties": {
"SetId": {
"Type": "string"
},
"isAvailable": {
"type": "boolean"
}
}
}
}
}
}

Hi, @jinivthakkar 

 I tried this also but it shows error 

"status":400,

"Message": unexpected response from the service........

 

Like wise 

 

Help me regarding this issue.

 

Thanks in Advance

Hi @DamoBird365 

 

Again Iam facing same error in Parse JSON 

 

InvalidTemplate Unable to process template language expression in action'parse_Json' imputs at line 1 and column '49572':'Required Property 'content' expects a value but got null. Path".'.`.

MartinZamazal
Frequent Visitor

I had the same problem (Unexpected response from the service). It turned out that my account doesn't have rights to edit terms in this term store. I added acount to term store admins and it worked. I had to add it directly, not through group memebership.

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,197)