web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Template Language Invalid
Power Automate
Answered

Template Language Invalid

(0) ShareShare
ReportReport
Posted on by 84

Hello all, 

 

I have been struggling with this for about a week now and have tired a quite a few different things; including using an initialize/append string instead of array then splitting the string. 

 

Basically, I am using list rows present in a table with a column that contains user UPN -> initialize array variable -> Apply to each loop -> Salesforce Get Record action passing through user UPNs -> Compose to write out the Salesforce Contact ID -> Append to Array Variable -> Compose to write out the Array. 

 

When doing so it is returning what is expected similar to:

[
  "XXXXXAW",
  "XXXXXAH"
]
As a safety measure, I am using a parse Json to make sure this is an array next using the schema:
{
    "type""array",
    "items": {
        "type""string"
    }
}
Finally, I am doing another apply to each loop taking the body output from the the Parse Json -> Compose to write out the individual Contact ID's -> Salesforce connector to assign assets to the specific contact ID. 
 
I am getting the following error:
 
InvalidTemplate. Unable to process template language expressions in action 'Create_record' inputs at line '0' and column '0': 'The template language expression 'outputs('Indiv.ContactID')?['$']' cannot be evaluated because property '$' cannot be selected. Property selection is not supported on values of type 'String'. Please see https://aka.ms/logicexpressions for usage details.'.
 
Flow keeps changing the Input (red arrow in screenshot) from the output of Indiv.ContactID to what is seen. 
 
Please help!!!!!
DH2023_0-1709782976191.pngDH2023_2-1709782999776.png

 

 

Categories:
I have the same question (0)
  • Verified answer
    ManishSolanki Profile Picture
    15,091 Super User 2025 Season 2 on at

    Hi @DH2023 

     

    Pls try the below expression:

    @{outputs('Indiv.ContactID')}

    If that does not work, then pls share the input of compose action by expanding the action.

     

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

  • DH2023 Profile Picture
    84 on at

    That did it! Thank you!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard