Automate your infrastructure to build, deploy, manage, and secure applications in modern cloud, hybrid, and on-premises environments.
Connect to any REST service without writing code and develop your apps faster with the new REST integration in Progress Rollbase.
In today’s world, most of the service providers provide APIs to access their services through RESTful web services. RESTful web services are lightweight, highly scalable and very commonly used to create APIs for web based applications. In this blog, you will learn how to connect such external REST services to Rollbase.
This feature also supports Basic Authentication.
Only administrators or equal admin privileged user can create a REST service type trigger.
Follow the below steps to create a new REST service trigger that integrates a REST endpoint to a Rollbase set of objects.
From the object definition page, click “New Trigger button” and select type as “REST service” from the next screen.
Name your trigger and trigger timing option, and then select Rest Service Configuration section (see screenshot below).
Enter your REST endpoint static URL Path, select your HTTP method. By default, Authorization is selected as “No Auth,” when you select Authorization as “Basic Auth” you need to provide details of Username and Password. Once you complete these details click on the Configure button which leads you to specify different metadata based on the HTTP method you selected.
For GET you can configure HTTP headers, URL Path & URL Parameters. For POST & PUT you can configure HTTP headers, URL Path & Request data as body JSON.
All these can be configured to either use data from a Rollbase record or to be constant values.
From mapper screen, you can create mapping fields or constant fields.
After adding mapping pairs, if one would like to edit/delete them that can be done by hovering on rows and clicking the edit and delete button. The user can also sort the order of mappings by drag and drop.
After you configure all required configurations, click on the Response tab or click “Configure Response” button. This will show the response tab, from which you can make a test connection to your REST endpoint and get a sample response to build a Response tree. Alternatively, you can build the response tree by copying the JSON response from the service into the text input. The response tree is required only if REST field values must be updated on the Rollbase side, otherwise you can simply ignore this Response Tree mapping (say for POST and PUT user can simply ignore any update to Rollbase field since most of the time POST and PUT will be an update at REST side). After the tree is built the user can add/delete/edit more nodes to Response right tree by using toolbar buttons.
From Response Tree, the user can map fields from REST service fields to Rollbase fields. If the user maps REST field to Rollbase Base object fields, then we update the Rollbase field value. If the user maps REST fields to Rollbase Related object fields, then we give the user three options:
Say the user would like to get a weather report for next 7 days from a REST service for a different Progress office. In Rollbase, create a "Building" object to denote a different Progress office across the country, create another object called "Day Wise Weather" and add a relationship with "Building" object.
Create a new "REST Serive" trigger, provide the URL and add a Query parameter to pass Progress office CityId and API key as mentioned above in the Request mapping section.
The next step will be building a sample Response tree by invoking a REST endpoint as mentioned above. Now you can map fields from Response Tree to Rollbase related fields. You will be asked the three options mentioned above. Then choose Add as new record.
Once Response mapping is done, click on the “OK” button to generate trigger code.
At this stage, without any coding you have a fully working call to an external REST service.
We recognize there are times when you would want to customize the processing of the service request or of the response. You can do that very simply with a little bit of JS code. We will go over how this works in the next section.
Rollbase enables users to connect any REST service without writing much code. The user doesn’t need to have any programming skill to connect to the REST service, and they can use a simple mapping tool to connect Rollbase and REST fields. This helps the user to build complex business application very quickly. Refer to the Rollbase documentation for more details.
New to Rollbase and want to try it out? You can sign up for a free trial here.
Subscribe to get all the news, info and tutorials you need to build better business apps and sites
You have the right to request deletion of your Personal Information at any time.
You can also ask us not to pass your Personal Information to third parties here: Do Not Sell My Info
Copyright © 2020 Progress Software Corporation and/or its subsidiaries or affiliates.All Rights Reserved.
Progress, Telerik, Ipswitch, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.