This app is meant to take the JSON results that are generated by the steps outlined here.
- Streamlit needs to be installed
If you do not have Streamlit installed, you can install it by executing the below command:
pip install streamlit
If you are using VS Code, you can open a new Terminal window and copy and paste the above to install Streamlit.
Assumptions:
- You are using VS Code
- Streamlit has been installed
-
Clone this repo to your local machine
-
Open a new Terminal window and navigate to the folder where this repo has been cloned to
-
Once you are in the folder of this repo, type in:
streamlit run app.py
-
This should load the app, and it should even open up your default web browser and navigate you to a an address similar to:
http://localhost:8501/
-
In your Terminal window, you should see output that resembles something similar to the below:
PS F:\postman_json_to_csv> streamlit run app.py You can now view your Streamlit app in your browser. Local URL: http://localhost:8501 Network URL: http://192.168.1.249:8501
-
When you arrive to the main page of the application, it will look like this.
- The option for File will allow you to browse and select a JSON file to load. You would select this option if you opted to paste the results from Postman and save them into a .json file.
- The option for Text will allow you to paste the results that you copied from Postman directly into the app
- If you paste in the results, you will need to press the Tab button after pasting in the data
-
You will then be shown all of the keys, in alphabetical order, that are available to export
-
Remove and/or rearrange the order of the keys as you see fit
-
Once you have selected and arranged the keys that you wish to have exported, press the Export to CSV button. You should receive a message about the export being successful, and be shown the file name of the export.
-
In the same folder, you will now have a CSV file that starts off with "JSONtoCSV_" and then has a time stamp.