Creating Web Service - RESTful Links

To create a web service link:
  1. From the Navigation menu, browse to Data Adapters > Access Links.

  2. On the List page toolbar, click the New New Button button.

    You can create a maximum of 75 access links in a department.  

  3. On the Properties page, on the General tab, provide the following details:

    1. Name: Type the name for the web service link.

    2. Description: Type a brief description.

    3. Type: Select Web Service - RESTful link from the dropdown list.

    4. Method: Provide the API input method by selecting one of the following options from the dropdown list.

      1. Delete

      2. Put

      3. Post

      4. Get

    Web- Restful access link

  4. On the Input tab, provide the following details:

    URL, Body, and Header values accept the input variables in the format <%variable_name%>. These variables can be mapped to business object macros to pass contextual data to the web-services call.

    • URL: Provide the request URL.

    • Authentication: If you have created an authentication configuration for this data link, select the appropriate configuration from the dropdown list. For more information, see About Data Adapter Authentication . If authentication is not required, select None.

    • Accept: Select the format you wish the output of the data link to use: application/json or application/xml.

    • Content-type: Select the format for the content the web services link expects as an input. Select either application/json, application/xml, or application/x-www-form-urlencoded.

    • Body: Provide the body for the response.

    • Headers: Provide the name and value for any additional response header fields and click the Add button.

    Input

  5. On the Output tab, click the New New Button button. 

  6. Provide the output path information:

    • Extract Or Filter: Select one of the options from the dropdown. Select Extract to fetch the attribute or an object from the original web-services response. Select Filter to filter an attribute/object from the above extracted object.  Extraction and filters work based on the XPATH and JSON query.

    • PATH: Provide the path for the response. Enter XPATH query when expected output is in XML format. OR enter JSON query when expected output is in JSON format. An example of JSON output:
      {
      "firstName" : "John",
      "lastName" : "Bell",
      "age" : 26,
      "address" : {
      "streetAddress": " 1252 Borregas Avenue ",
      "city" : " Sunnyvale ",
      "postalCode"   : " 94089 " }   
      }

      JSON Query to fetch Fist name from the above output Extract or Filter :  Extact   PATH  :   $.firstName

      Click the Return button or press Enter on the keyboard to add the output path.

    • Internal Field Name: Provide the response field name.

    • Decoding: Provide the decoding format if necessary.

    Output

  7. Click the Save button.

Related Topics