How to access response json object in "PowerApp Canvas" without adding response sample to the connector? - powerapps-canvas

I have a "customer api" to get profile infromation by ID.
A custom connector is created using this api.
Then the Connector is used in Canvas Power App.
Within the app data is stored in collection named "DataReceived".
Issue is:
if we don't add sample response body while creating custom connector, data in collection is a Boolean value as shown in the image 1.
But if we add sample response, we could access all the information which matches the sample schema. Data stored in collection is tabular as shown in image 2.
Image 1:
Image 2: canvas Power App "Collection" when "response sample is added" to the customs collector
So the main issue is:
Is there a way to access json data in powerapps(canvas) collection without adding "sample response" in the "custom connector"?

Related

How to GET only custom Field Names from Azure Form Recognizer API?

I trained a Custom Form Recognizer Model. It tests great. But I can't find the API endpoint to call that returns ONLY the key/value pairs for the form I sent the model to analyze.
Example:
I trained a custom model to find First name and Last name only
When I POST a PDF to the endpoint:
https://{my-project}.cognitiveservices.azure.com/formrecognizer/documentModels/{my-model}:analyze?api-version=2022-08-31
Then view JSON from the Operation-Location header:
https://form-rec-ocr-test.cognitiveservices.azure.com/formrecognizer/documentModels/{model-name}/analyzeResults/{GUID}?api-version=2022-08-31
I get aaaaallll the text on the submitted PDF instead of only the First name and Last name fields. I just want the key/value pairs to insert them into a table.
What is the correct API endpoint to call? The API docs here are focused on pre-build models instead of Custom Models.
For some reason, this was not lined out in any documentation I came across. Found the answer in this video #36:30.
The data was in the original JSON object, just at line 3300 under the document node.
Would simplify things if the Form Recognizer API could return ONLY the document array by defining a simple query parameter.

Data Factory: API call returning JSON format wont go to JSON file

In data factory I'm using a Copy Data activity where the Source is a REST API, that's returning data in JSON format, with a Sink thats a JSON file type in ADLS Storage.
The problem I'm having is that only the first record in the "Domestic Title Nos" array appears in the JSON file. The remaining records, however many, are not to be seen.
Also, when I "Preview" my data in the Source page, it shows all the nested data in the array.
API Call Returns this JSON data
Mapping in my Copy Data activity
File contents after sink to JSON file type
As shown in below screenshot, you have used items as Collection reference.
You need to use “Domestic Title Nos” as Collection reference.
Note: For records where the array marked as collection reference is
empty and the check box is selected, the entire record is skipped.
Refer - Schema and data type mapping in copy activity
In the end it worked out to be easier to download the entire JSON document using
this mapping and then used "Flatten" in a Data Flow to extract the parts that I needed.

Logic App dynamic content give null or ""

I want to create small automation between Jira and Azure. To do this, I execute HTTP trigger from Jira, which send all request properties to Azure Logic App. In "When a HTTP request is received" step in Logic App I can see properly JSON schema with all data which I need. In next steps for example I want to add user to Azure AD group. And problem starts here.
For example, I want to Initialize variable and set it with value from JSON. I choose properties from dynamic menu, but after script execute always it is null value ( but in first step in "raw output" I see whole schema with data). I tried many things - parse, compose, many different conversion - always without any luck - null value or "".
Expected value - when I want to initialize variable using Properties from Dynamic Content I want to have value from input json.
Output from Jira
Output with the same JSON send from Postman
Thanks for any help !
--
Flow example
Flow result
If you send the json with application/json content-type, you could just select the property with the dynamic content, however if not you have to parse it to json format with Parse Json action.
AS for the schema, you need use your json data to generate it with Use sample payload to generate schema. Paste the sample json payload.
Then you will be able to select property. However you could not implement it dynamic content, you have to write the expression. The format will be like this body('Parse_JSON')['test1'] and if your json has array data, you need to point the index it will be like this body('Parse_JSON')['test2'][0]['test3'].
Below is my test, you could have a try.

HTTP request from Jira to Logic App not working, but same json from Postman work

I`m trying to build a Logic app on Azure which will receive JSON from Jira and do some magic on the Azure side. I created a button in Jira flow, which will trigger a webhook to Azure App Logic address. In App Logic I had a step called "When HTTP trigger is received". For schema creation I used the JSON from Jira, so the schema should be okay.
The problem is working with the input. In raw file I can see whole JSON with all details and properties, but it's not divided in to variables automatically.
Step output directly from JIRA
Output from Postman
The headers are more or less the same, so that shouldn't be a problem. Without this output I can't work with variables from JSON correctly, because when I will use variables name from Dynamic Menu it will be null (or "")

Fusion Charts for representing data in graphical form

I am trying to render my data in a graph using fusion charts. I have a web service that returns the data in JSON format. I want to render chart for that data. can I directly give the URL of my web service so that I cannot set key value pairs. Is it possible to do so/ Can any one please tell me how to do this.
It can use a JSON URL/feed, a JSON Object (in JavaScript) or JSON String. This functionality is provided by FusionCharts class method setJSONUrl(). Example
myChart.setJSONUrl("Data.json");
See http://docs.fusioncharts.com/charts/contents/FirstChart/JSONData.html
FusionCharts Suite has a specific JSON structure for each category of charts. While passing the data to render method, data is expected in the pre defined format. Please refer to: http://docs.fusioncharts.com/charts/contents/DataFormats/JSON/Overview.html