API integration without storing that data into mendix database.

I wanted to show the data in a datagrid from the API but I don’t wanted to save that data into the mendix database.Please help me to do the same with either a good documentation or your project...
3 answers

It depends on, how you are consuming the REST service. If you are consuming it in background via scheduled event or something, then it is not possible.

If you are opening a page and wanted to consume the REST service there, then

  1. make the datagrid use datasource as Microflow
  2. using the JSON, create import mapping and entities required. NOTE: entities must be non-persistent
  3. consume REST service, with the JSON returned by API and import mapping, create your objects for entities
  4. return the created list in the datasource

NOTE: you can also follow similar approach, from the action microflow, where you do all processing and the list must be associated with one parent non-persistent entity. This parent object can be passed to the page and in this case, the datasource for datagrid will be association.

You can follow this for all HTTP Methods


You can check out the documentation about REST services, there it is shown how get data from an API using JSON and using non-persistent entities: https://docs.mendix.com/refguide/integration/consume-a-rest-service/



It can be easily done by consuming the intended API and displaying it in grid through data source microflow.

Read more here