Class LinksAPI


@Component public class LinksAPI extends BaseAPI
Methods to make API requests using v0 API for Linking Records
Since:
3.2
Author:
Kavit Shah
  • Constructor Details

    • LinksAPI

      public LinksAPI()
  • Method Details

    • linkRecord

      public org.apache.http.HttpResponse linkRecord(String user, String password, int expectedStatusCode, String sourcePath, List<String> nodeRefs) throws UnsupportedEncodingException
      Creates the Link
      Parameters:
      user - The username of the user to use.
      password - The password of the user.
      expectedStatusCode - The expected return status code.
      sourcePath - The Source of link the record. This should be in the format "{site}/{container}/{path}", "{site}/{container}", "{store_type}/{store_id}/{id}/{path}", "{store_type}/{store_id}/{id}" or "{store_type}/{store_id}".
      nodeRefs - The Node that needs to be linked.
      Returns:
      The HTTP Response.
      Throws:
      AssertionError - If the API didn't return the expected status code.
      UnsupportedEncodingException