Skip to Content
Author's profile photo Bharath B N

Query the BusinessObjects repository using REST SDK (RWS)

This blog describes about Query the BusinessObjects repository using BI Platform REST API.

API Details:

API URL http://<host>:<port>/biprws/v1/cmsquery
HTTP Methods GET , POST
Data Formats Application/JSON, Application/XML
Headers x-sap-logontoken

This RWS API introduced from SAP BOE 4.2 SP03.

Using cmsquery REST API one can easily query the BusinessObjects repository and get the required information which is similar to Query Builder. (AdminTools URL : http://<host>:<port>/AdminTools ) but using REST API the result will be in XML/JSON format.

To explain more in detail, BusinessObjects repository made up of set of tables to hold the information about the BI content such as Universes, reports, Users, schedules, etc. These tables are encrypted in such a way that the information stored in these tables cannot be readable using conventional SQL query tools. This is the place where cmsquery REST API comes in to picture where in which this is the one and only door step through which we can query the metadata stored in the repository.

Repository:

The repository information is stored in the form of InfoObject and the CMS reads the InfoObjects from the virtual tables. Below are the BusinessObjects metadata virtual tables and their associated objects.
Table Description Type of Objects in Table
CI_SYSTEMOBJECTS InfoObjects that the BI Platform uses User, User Group, Server, Server Group,Folder, Connection, Calendar,Event
CI_APPOBJECTS InfoObjects that are used by documents Universe
CI_INFOOBJECTS InfoObjects that are consumed by the end user WebI, Crystal Report, FullClient, PowerPoint, Pdf, Excel, Word, Rtf, Txt,Program, Shortcut

No need of any special rights to use this REST API ( Admin must enable to use Restful Web services application to user in CMC applications).The response of this API contains the data based on user rights.

Note: Using cmsquery REST API user can only query the information stored in the CMS database not from the File repository files.

Basic properties of InfoObject:

InfoObject property Description
SI_ID Integer – Unique id generated for the Infobject within the environment
SI_NAME String – Name of the InfoObject
SI_KIND String – Type of the Infoobject
SI_CUID String – Cluster Unique Identifier of the InfoObject
SI_GUID String – Global Unique Identifier of the InfoObject
SI_RUID String – Unique id of the Infobject within the Object package
SI_PARENTID Integer – Parent Objects SI_ID
SI_OWNERID Integer – SI_ID of the InfoObject’s owner
SI_CREATION_TIME Date and Time – Creation time of InfoObject
SI_UPDATE_TS Date and Time – Last updated time of InfoObject

 

API WorkFlows (XML and JSON):

HTTP Method: GET  Data format : JSON

HTTP Method: POST  Data format : JSON

Response in JSON format:

HTTP Method: GET  Data format : XML

 

HTTP Method: POST  Data format : XML

Response in XML format:

 

Get x-sap-logontoken (Authectication):

Session Management in BI Platform REST SDK (RWS)

Learn More:

https://help.sap.com/viewer/db6a17c0d1214fd6971de66ea0122378/4.2.3/en-US/45aa70186e041014910aba7db0e91070.html

https://help.sap.com/doc/220244879d104f2e8e8b37e0fa0bdd2d/4.2.3/en-US/sbo42sp3_bip_rest_ws_en.pdf

Assigned Tags

      12 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Soumya Das
      Soumya Das

      Very Informative!

      Author's profile photo Nandan Tadahal
      Nandan Tadahal

      Good info.

       

      Author's profile photo Prahalad Prabhakar
      Prahalad Prabhakar

      Great blog  very informative!

      Author's profile photo Gregory Cable
      Gregory Cable

      Thank You Bharath,

      Seeing that you are with SAP, do you know when we will be able to retrieve the subobjects (ie: SI_SCHEDULEINFO)?

      The following query will filter based on the SI_SCHEDULEINFO.SI_SCHED_NOW object but it will not return any of the SI_SCHEDULEINFO objects in the select list.

      SELECT SI_NAME, SI_KIND, SI_SCHEDULE_STATUS, SI_SCHEDULEINFO.SI_DESTINATIONS, SI_SCHEDULEINFO.SI_OWNER, SI_CREATION_TIME, SI_STARTTIME, SI_ENDTIME, SI_SCHEDULEINFO.SI_MACHINE_USED, SI_SCHEDULEINFO.SI_PID, SI_PARENT_FOLDER, SI_SCHEDULEINFO.SI_ENDTIME, SI_SCHEDULEINFO.SI_FORMAT_INFO, SI_STATUSINFO
      FROM CI_INFOOBJECTS WHERE SI_SCHEDULE_STATUS = 3 AND SI_STARTTIME >= '2017.06.01.00.00.00' AND SI_SCHEDULEINFO.SI_SCHED_NOW = 0

       

      Regards,

      Greg

      Author's profile photo Bharath B N
      Bharath B N
      Blog Post Author

      Hi Greg,

      You will be able to retrieve the subobjects using "/cmsquery" RWS API from BOE 4.2 SP05 onwards.

      -Bharath

       

      Author's profile photo Kiran Kalam
      Kiran Kalam

      Is this possible to get the data from the subfolders by using nested quries

      Author's profile photo Bharath B N
      Bharath B N
      Blog Post Author

      NO.

      Please write a script : Loop the response and call API for each subfolder.

      Author's profile photo Shailendra Sharma
      Shailendra Sharma

      Hello Bharath,

      Do we have any alternative way for doing the same on 4.2 SP 02 ?

      Thanks in advance.

      Author's profile photo Bharath B N
      Bharath B N
      Blog Post Author

      You can use REST API or JAVA SDK, in both the ways, you have to write code.

       

      Author's profile photo Ali Kece
      Ali Kece

      Hello Bharath,

      Is it possible to get tables, joins, aliases, derived tables, etc. from old universe model’s (i mean unv not unx).

      Thanks.

      Author's profile photo Bharath B N
      Bharath B N
      Blog Post Author

      This API gives metadata details. I think you should explore semantic layer APIs for your case.

      Author's profile photo Trip Humphrey
      Trip Humphrey

      The XML data being returned in this example is not valid XML as far as I can tell.  The links in the 2-4 lines of the xml response you provide have ampserands in the href links.  Those should not be permitted in valid XML. In the other API endpoint responses elsewhere in the RWS apis they return with the ampersands properly escaped as &amp; but for some reason the cmsquery endpoint does not.