Is there a way for me to leverage on the CUBA platform to rapidly build-up UI components and wire-up the respective action buttons to invoke external API calls (eg: where there are existing REST APIs being exposed by other legacy applications in the enterprise)?
Also, can this be done without the need to configure any data store/persistence for my new application built on CUBA platform (since the persistence tier in this enterprise setup is effectively residing on the other legacy applications)
I haven’t yet used REST API with Cuba Platform but I’m intending to do it soon. For this reason I discovered this documentation that could help you :
Hi, Stan
I’ve had a quick browse through on the documentation - it looks to concentrate on being able to provide REST APIs to allow other applications to interact with our CUBA platform-based application. I’m actually looking for the reverse scenario - where my UI components built on CUBA platform interacts with other applications via APIs.
You can create a set of non-persistent entities corresponding to the data model of your external services - see “Not persistent” option in the “Entity type” field of the “New CUBA Entity” dialog. Then use loadDelegate for data loaders and commitDelegate for DataContext to load and save data using your services instead of CUBA middleware.
A simpler solution would be using KeyValueEntity, below is an example of loading data from a REST service and displaying it in a table: