The JSON API lets you render Data from an external source, it can be a Local
Many providers are offering an access to data with an API, it means that you can render data coming from your own existing Database (MySQL, Oracle…) or from other solutions (Airtable, etc…).
Architecture of the Json API
If you want to learn about how to create an API Rest from your existing Database, please read this documentation:
Implementing your API
You will find below different possible Json API implementation scenarios:
By using a
Local JSON file source
, it is possible to implement a Master/Detail App with search functionalities, without using a Database.
You can use a JSON Repeater linked to a page with a JSON Displayer for displaying detailed information.
You can even link a JSON Search Box to the Repeater for adding search functionnalities.
By using the API provided by some third party solutions, you can also implement a master/detail App for loading your data into your APP.
For instance, Airtable provides an API usable in Thorium Builder.
See the screenshots below, created from one of the Airtable DB examples:
If you want to use data coming from an existing database, then you can use all the possibilities of the Json API Plugin, Master-detail, search & filters and even entering data.
If you already have an API on your database, then you can use it for creating your PWA, else you can create API in a very simple way, see the documentation Implementing your API
In this Chapter, we will describe what is happening and how the data are handled when using the JSON API.
Master Detail Implementation.
You can implement a JSON
that will call an API for displaying a set of data to the user. When the data are loaded, they are all added to memory, and the
will display only the data, depending on the Repeater settings.
If you implement a detail page with a Json displayer , the when the user will select a line on the Repeater, it will load the page and display all the information (depending on the displayer setup).
When the Page with the JSON
is loaded, you have 2 options, you can use the data already in Memory (the data from the API used with the JSON
) , or call another API that will load additional Data by passing an ID (a Primary Key)
Here is a schema of the different process steps:
Single Record Load
Using a JSON Displayer combined to a Repeater lets you implement a Master/Detail application, but you can also use the JSON Displayer for loading a single Record.
Of course in that case, the API used with the Displayer is Supposed to load a single Record.