- Oracle WebCenter Portal Online Help
- Online Help Topics for Shared Assets
- Assets
- REST Data Sources
- Create New/Edit REST Data Source
Create New/Edit REST Data Source
To create or edit a REST data source:
- Enter a Name and optional Description for the data source.
- Enter a valid Resource Path URL against which the REST data source will be created, then click Test to confirm the resource path is valid and that it returns data. For example, the resource path
http://dev.markitondemand.com/Api/v2/Quote?symbol=AAPL
provides stock quotes.Note:
The Resource Path must support at least theGET
method, along with any other method (PUT
,POST
,DELETE
). - In the list of Parameters populated based on the resource path provided, remove or add parameters as needed.
Note:
If you modify the Resource Path URL, the list of parameters will be refreshed, and you may need to respecify the required data source parameters. - Select a Data Source Return Type that specifies data type returned by the Resource Path URL. A URL can return data in either XML format or JSON format.
- Select or deselect Use Portal Proxy and Use Authentication as required. For an external REST URL, select Use Portal Proxy.
- Select or deselect Enable Caching as required, and enter values for Time To Live (ms) and Max Weight.
- From the Methods list, select the method to assign to the REST data source:
GET
,PUT
,POST
, orDELETE
. - In the list of Parameters populated based on the resource path provided, remove or add parameters as needed.
- Type payload values in the Request Payload and Response Payload fields as required. Tip: Enter the Resource Path URL in a browser to see what data is returned.
Note:
While the Resource Path URL can be the same for all methods (
GET
,PUT
,POST
,DELETE
), the Request Payload and Response Payload can be different for each method. You will need to provide separate payload values for every method that you specify.An example of XML for Request Payload may look similar to:
<opportunity> <city>DOCUMENT</city> <comment>Default</comment> <country>US</country> <createdBy>LHUGHES</createdBy> <creationDate>2015-10-01T00:00:00-08:00</creationDate> <currencyCode>USD</currencyCode> <customerInfo> <contactEmail>david@abccorp.com</contactEmail> <contactName>David</contactName> <contactPhone>9987656781</contactPhone> <customerPhone>9987656781</customerPhone> </customerInfo> <formattedAddress>559 Cooper St, SEATTLE, WASHINGTON 98102</formattedAddress> <locationId>300100000393851</locationId> <opportunityId>300100029659792</opportunityId> <opportunityName>OpptyForABCCorp</opportunityName> <opportunityNumber>CDRM_23685</opportunityNumber> <postalCode>98102</postalCode> <primaryOrganizationId>201</primaryOrganizationId> <primaryRevenueId>300100029659793</primaryRevenueId> <products> <productName>Server - Class III</productName> <quantity>10</quantity> <totalPrice>8000</totalPrice> <unitPrice>800</unitPrice> </products> <products> <productName>Pro Server</productName> <quantity>15</quantity> <totalPrice>11250</totalPrice> <unitPrice>750</unitPrice> </products> <revenue>8000</revenue> <salesStage>01 - Qualification</salesStage> <targetPartyId>100000015802569</targetPartyId><targetPartyName>Designs Cooper</targetPartyName> </opportunity>
- If you selected Use Authentication:
-
Click Next.
-
On the Auth page, select existing credentials, or click Add Credentials to create a new credential (if you have been granted the required permission to create a new credential).
-
On the Credentials page, select from the Select Security Type list:
-
Basic Authentication support is provided via the External Application Service of WebCenter Portal. The user name and password for the REST service are stored in the OPSS Credential Store using the External Application Service. When a data visualization is rendered at runtime, WebCenter Portal retrieves these credentials to present the data on the page.
-
OAuth support is provided by OWSM integrated with REST Data Control. ADF REST Data Control supports only OAuth 2.0 using IDM OAuth Servers. External REST services that are protected using a non-IDM solution are not supported.
-
Taleo Token Generator authentication is provided by a custom security provider to propagate security at runtime. If authentication is successful, a Taleo token is issued. That token must be passed to each subsequent resource request to retrieve data.
-
-
Under Configuration, define or edit the login information, depending on the security type:
-
For Basic Authentication, enter the Login user name, and Password.
-
For OAuth, enter the Login user name, and Password corresponding to the Client ID and Password configured in OAuth server, and enter the Token Generator URL of the OAuth Server.
-
For Taleo Token Generator, enter the Login user name, and Password, and enter the Login URL and Org Code to access the Taleo end point. A user must be authenticated using user name, password, and organization code (company ID) on a defined login URL.
-
-
- Click Save.
The newly created data source is listed on the Assets or Shared Assets page.
The empty check box in the Available column indicates that it is not yet published and hence is not available to other users. To publish the data source, click the check box.