Showing results for 
Search instead for 
Did you mean: 
Frequent Visitor

Error in fetching the data from Service Now

I am trying to integrate Service Now API using flows with my Power Apps application and I am not able to retrieve data from Service Now. Is there any other way to integrate Service Now with my Power apps application? 

The Error I am getting is : "The execution of template action 'Apply_to_each' failed: the result of the evaluation of 'foreach' expression '@items('Apply_to_each_2')?['number']' is of type 'String'. The result must be a valid array"

Kindly help me with this!

Super User III
Super User III

Hello @NischalSimha 


The error message that you are getting is saying the value 'number' that you are passing in is not a array.

basically you will have to pass the Apply to each loop a array value, so it has something to loop over.


If you could please share a screenshot of your flow

Did I answer your question? Mark my post as a solution!

If you like my post please hit the Thumbs Up

Proud to be a Flownaut!

Check out my blog for Power Automate tips,
tricks, and guides

Super User
Super User

Were you able to successfully establish service now connection? Try to use a Non SSO user of Service now and may be rest_api_explorer  role.

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community

Helpful resources

MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

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.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (1,477)