Create a REST Web Service for GET Account API

After creating the Similar Accounts REST web service, create another REST web service for GET Account API. Here’s how you create it:

  1. On the Web Services page, click the new web service icon.
  2. On the Select Connection Type window, select REST and click OK.
  3. On the Create REST Web Service Connection page, enter a Connection Name. For example, GET_Accounts.

    Ensure that you use same connection name in Global Function Groovy. See the Create a Global Function for SalesMLQueryAPI Similar Records section in this topic.

  4. Leave the API-based REST Service check box blank.
  5. Select OData for REST Service Type.
  6. Enter a URL in the format, https://<host>/crmRestApi/resources/latest/accounts. For example, https://fuscdrmsmcxxx-fa-ext.oracle.com/crmRestApi/resources/latest/accounts.
  7. Select Call with Basic Authentication for Authentication Scheme.
  8. Add your Credential Key.
    Add the web service details.
  9. Next, enter information in the Select and Configure Methods against the Resource section:
    1. Select the GET check box.
    2. Let the Method Name be GET and Format be JSON.
    3. Leave Request Payload blank.
    4. Select Code Sample for Response Payload and enter the following code into the text field: { "items" : [], "count" : 1, "hasMore" : false, "limit" : 25, "offset" : 0, "links" : []}

    Select the GET configure method.
  10. Save and close.