Hi there
I have a API and a JSON file, but I have never worked with json files before, and dont know how to go about with this. Any help ? 🙂
https://data.brreg.no/enhetsregisteret/api/enheter/
Best regards
Solved! Go to Solution.
Hello,
The best way is to use the Download tool in order to get the data from the URL into Alteryx and then simply the JSON Parse Tool to "decode" the data. Both in the developer category.
It can then simply further processed by other Alteryx tools.
Please see example attached.
Kind regards
Matthias
Thanks for the attached workflow. But how do I go from there, and how can I get the data into different columns?
That works then with the "classic" prep and blend tools like formula, transpose, cross tab, etc.
Based on the initial formatting of the json by its issuer it can be that it's not automatically in the format you'd like to have it.
Could you scetch an example of your desired output scheme?
@Drole after you use a JSON Parse tool you will notice that it will create a JSON Name column and a JSON Value column. JSON stands for JavaScript Object Notation and the JSON Name column will have a period separator. You normally follow the JSON Parse tool with a Text to Columns tool where you split the JSON Name column into however many columns are needed and then use a Crosstab tool to pivot the data. You will also notice that there will be one of the column that has a numerical value that indicates the block of values that will make up each row after transforming the data. You will want to check the box to group by this column.
@Venkatesh1122 I am pretty sure that you copied the safelinks version of the URL rather than the actual endpoint you are looking for:
Many organizations run URLs through this when opening from email to check if they are safe first. I would first open the URL in a browser and then copy the actual URL from there.
Additionally, JSON parsing is not used on HTML, as the HTML is simply the formatting code that is returned from a webpage. If you are expecting JSON elements to be returned it likely indicates that your URL endpoint is not correct.