Showing results for 
Search instead for 
Did you mean: 
Helper V
Helper V

Pass an array as a parameter from PowerApps to Custom connector

Hello, I have a custom connector which is calling an Azure cognitive search API with facets.  When I test it within the connector I get the correct response body. Here is the request I am passing in the connector. Here Facets is an array which I am passing.. the other parameters are simple texts.(string)


"facets: ["PrimaryBusinessSectorValue,count:1,"ReferredByValue,count:1"]


 And this is the response.



I get two sets of results for both  ReferredByValue and PrimaryBusinessSectorValue as shown above.


In the PowerApps , here is what I am passing. 



ClearCollect(ColResponse, API.query("<api_key>",

{ Search : TextInput.text,
  Count : "true"
  Facets : Table({Value : PrimaryBusinessSectorValue,count:1},{Value : 
  SearchType : "simple"




However I am not getting the response for both the facet values.. I get only the PrimaryBusinessSectorValue....
ideally in the collection I should see for both PrimaryBusinessSectorValue and ReferredByValue







@P_SA wrote:




  Facets : Table({Value : PrimaryBusinessSectorValue,count:1},{Value : 




You have {Value : PrimaryBusinessSectorValue,count:1} duplicated twice and ReferredByValue is not present.


If you correct it and make one of the records have Value:ReferredByValue, does it resolve your issue? 

Sorry that was a typo. I have corrected the initial post.  I am passing both the values from PowerApps

@P_SA For this part:

"facets: ["PrimaryBusinessSectorValue,count:1,"ReferredByValue,count:1"]

Could you clarify this part, there might be some typos here as well.

Please check on the Custom Connector schema and see what is defined for the request, if it is possible, to provide it as well, but at least to check on it.


Also please give an example of a valid request as if it were being issued directly.


I suspect this part might be of issue, (even if no longer considering the typo):

Facets : Table({Value : PrimaryBusinessSectorValue,count:1},{Value : 


I am not sure this is sending the request in the way that is expected.


If you could clarify this part, it might help.

Helper V
Helper V

This is the definition for the request.


this is the body of the request.


and this is the response body.




Helper V
Helper V

I managed to correct this by loading the response in the default response body of the connector

Helpful resources

Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (1,732)