I have a custom API (HTTP GET) which returns data in JSON format. A part of the data returned will just be used as metadata and the rest would be values that will be put on screen. When I inspect the network calls, I can see that the JSON data is being successfully returned by the API.
ex:
{
"id": "58f093f48de7",
"index": 0,
"name": "test"
}
I tried the network call in two ways,
UpdateContext({resultJSON:GetJSONData.GetJSONData()})
and
ClearCollect(resultJSON,GetJSONData.GetJSONData())
How should I access the data in resultJSON?
I am not able to access it like resultJSON.id or resultJSON.index.
In Collections section I see the resultJSON collection with only one column 'Value' and resultJSON.value returns no data.
When I inspected the network calls of some sample PowerApps, there were calls to getCollectionDataSource/getColumnsAndTypes which returns the field names like 'id', 'index', 'name', etc. Is this something that I can leverage?
Solved! Go to Solution.
Hi Karthikb,
Could you show me more details about your Swagger file definition for a further investigation?
I have seen a documentation about “Customize your Swagger definition for PowerApps”, please check it for a reference:
https://powerapps.microsoft.com/en-us/tutorials/customapi-how-to-swagger/
Best regards,
Mabel Mao
Hi Karthikb,
Could you show me more details about your Swagger file definition for a further investigation?
I have seen a documentation about “Customize your Swagger definition for PowerApps”, please check it for a reference:
https://powerapps.microsoft.com/en-us/tutorials/customapi-how-to-swagger/
Best regards,
Mabel Mao
Hi,
Thanks for your help. I've figured out the issue and am able to use my custom API. The swagger file required additional fields defining my response data format.
The following post also was related to my issue and the solution helped.
Thanks,
Karthik
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
User | Count |
---|---|
204 | |
180 | |
62 | |
32 | |
30 |
User | Count |
---|---|
324 | |
270 | |
104 | |
74 | |
56 |