How can we help you today?

Modify URL Parameters Feature for ShortPoint Connections


When working with ShortPoint connections, you can either enter a custom URL or have one automatically generated when you select a local data source. This guide shows you how to use the Change Parameters feature to dynamically change your connection's URL by editing, adding, or removing parameters as needed.


This feature is currently available in the following ShortPoint connection types:


Prerequisites


How does the Change Parameters feature work

You might want to dynamically change URL parameters in your ShortPoint connections based on real-time data, such as the currently logged-in user. However, you may face different limitations depending on your connection type:

  • Local data source: The connection URL cannot be edited directly
  • REST API and Microsoft Graph API connection: While you can edit the full URL, manually updating parameters for dynamic data isn't practical


This is where the Change Parameters feature becomes useful—it lets you automatically adjust parameters regardless of your connection type.


Here is an example REST API connection URL:



The URL Query Parameters are represented by the value beginning after the question mark (?) in the URL, which in our case would be:


?$select=Id,Title,Body


If you would like an extra parameter to be appended to the URL, for example:


$filter=userId eq 12


You need a way to edit the URL. Since you can't edit the URL directly, you'll need to use the Change Parameters field instead. You can add custom JavaScript code that extracts the current URL parameters as a JavaScript string, modifies the parameters as needed, and reattaches the updated parameters to the URL before connecting.


Change parameters in ShortPoint Connect


It will process the URL parameters so that the final URL becomes:

/sap/fiori/shortpointwidgetbeta/destinations/shortpoint-sharepoint_announcements/_api/web/lists/GetByTitle('Announcements')/Items?$select=Id,Title,Body&$filter=userId eq 12


The feature takes a single argument called parameters, which contains the URL parameters as a string. If you leave the Change Parameters field empty, the function will extract the existing URL parameters without making any changes. The default value is:

return parameters;


In the example provided above, the value of the parameters argument would be: 


?$select=Id,Title,Body


Since the parameters argument is a string, you can use standard string manipulation methods to modify it. In the simplest case, you would just need to add (concatenate) the following to the end of the initial string:


$filter=userId eq 12


That means we need to apply the following JavaScript code. Please note that we are adding an ampersand (&) since we now have multiple parameters, and has to be used as a separator.


parameters += '&$filter=userId eq 12';
return parameters;


The updated URL query parameters will be displayed at the top of the Change Parameters function once you click on the Connect button:



Here is another use case:



Modifying URL Parameters

Here are the steps that you need to take to be able to apply dynamically modified URL parameters in ShortPoint Connections:


Step 1: Set up your connection

  • Switch to Grid Mode (ShortPoint Connect is currently only available in Grid Mode).
  • Open the Design Element settings and go to the Connect tab.
  • Select a connection type.
  • Ensure that all the required fields are completed to establish a successful connection.


REST API connection


Step 2: Enable Advanced Settings

  • Scroll down and look for the Enable Advanced Settings toggle. Toggle it on.


Enable advanced settings


Step 3: Input your custom parameters

  • In the Change Parameters field, input your new parameters.


insert updated parameters


Step 4: Hit Connect

  • Once done, click the Connect button. 


You can then proceed to map the data you want to display in the Items tab and update your Design Element.


Now, you can insert dynamic parameters into your URL before connecting using the Change Parameters feature in ShortPoint Connect.


Related articles:


Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.

World's best intranet sites are designed using ShortPoint

Get started today! Learn more
See all 36 topics

Start a trial

Ignite your vision. Install ShortPoint directly on your site, or play in sandbox mode. No credit card required.

Get started today

World’s best intranet sites are designed using ShortPoint

Thousands of companies using ShortPoint everyday to design, brand and build award winning intranet sites.

Get started Learn more