URL Aware Text-Based Filters on Reports via REST API
- 29 Jul 2021
- 1 Minute to read
- Print
- DarkLight
This documentation version is deprecated, please click here for the latest version.
URL Aware Text-Based Filters on Reports via REST API
- Updated on 29 Jul 2021
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Overview
This article demonstrates how to implement text-based filters on Reports as a URL parameter for a service API call. The URL generated on the Integration Details page of the Report has "contains.value=" at the end, which can be used to filter the Report by providing a filterable parameter after the = symbol. This example uses a Report populated with Account data from the Decisions environment.
Example:
- In the Designer Folder, select CREATE REPORT > Create Report from the Folder Actions Panel.
- Then, name Report and select Create to proceed to the Report Designer.
- In the Report Designer in the Data Sources column expand Common and add Account Data Source.
- In this example, add Account Id, Email Address, and Account Typefor the Data Fields.
- Next, add Email Address Contains Filter from Data Filters > Field Filters > Email Address.
- With this Filter selected, navigate to its Properties. Then, we chose the Runtime Editable option from Runtime Behavior dropdown. Select the checkbox labeled Show all data when filter value empty.
- This completes the Report. Save and close Report Designer.
- Back in the Designer Folder, select the Report. Then, from Action menu, select Run [Advanced] > Integration > View Integration Details.
- On the Integration Details Page Setup the Report to Run As: Service.
- Then, select Generate UI Code for testing in the further steps in this tutorial.
- Paste the generated URL into the browser and select Enter on the keyboard.
- The service call returns us an XML file with report data. All Portal Accounts should be viewed because a value has yet to be provided for the Filter parameter in the URL.
- Use the URL again but this time provide the Filter parameter with “user” as the value. Service call returns an XML file with the filtered data.
Was this article helpful?