pdfrestful-urlbusiness-objectsopendocument

Retrieving PDF report from BO 4.1 Webservice


I am trying to migrate my web service client from BO 3.x to BO 4.1 RESTful.

The existing implementation of BO 3.x uses BO Java SDK to get CUID and doc properties to get the PDF report by using below inputs.

I have constructed my client code to get Logon token from RESTful Web service. However I am not sure how to retrieve the PDF file now in BO 4.1.

Many of the samples I have seen use sIDType and iDocID parameters along with token value to retrieve the document by constructing a URL like below http://server:port/BOE/OpenDocument/opendoc/openDocument.jsp?token=[LogonToken]&iDocID=[XXXX]&sIDType=CUID

My question : Is it must to have iDocID to retrieve document using URL pattern above or is it possible to construct a URL using report path / CUID and fill parameters (without using iDocID) to retrieve PDF report from BO Web service.

Please assist me on this. Thanks


Solution

  • Note the &sIDType=CUID parameter in your sample URL -- that indicates that the page is expecting the value of iDocID to be a CUID. Without sIDType=CUID, it would expect the value to be an integer document ID.

    That is, you only need the CUID, not the document ID. Also, CUID is unique, so there would be no value in specifying both CUID and path.

    Incidentally, instead of specifying a CUID or ID, you can specify the document's path and name. However, this functionality is deprecated in BI4.1.

    Prompt values can be supplied to openDocument using the lsS and lsM parameters (for single-select and multi-select prompts, respectively).

    See the openDocument documentation here.