Page tree
Skip to end of metadata
Go to start of metadata

GraphQL is still just a REST call, so it has a Request property passed into the getRequest() method. The response is accessible as a string via the getResultContent() method. It is passed to the ResultContainer property which is accessible via the getResultContainer() method and auto-parsed via the parseResultContainer() method.

The ResultContainer will contain:

  • a DataContainer property with the data response, accessed via getData() method. That will contain methods to retrieve the relevant content you need.
  • potentially a List of ErrorContainer objects for any errors returned, accessed via getErrors() method.

Your code should check for errors and handle accordingly. However, if the DataContainer is null, an exception will be raised to advise that you check for errors. getResultContent() is useful then to check the string data returned from the request.

Note: a small number of GraphQL requests cannot be run from an application - "me" and "people(name)" - which run based on your organisation. These currently return an HTTP 500 error.

3 Comments

  1. Anonymous

    Legitimate custom nursing writing services are not hard to come across for those in need of Affordable Nursing Writing Services and nursing research writing services. 

  2. Anonymous

    I am reading it with very keen interest but I can not give this post more time for completely reading it because now I am going to write the assignments for the students of    Dissertation Help UK 

Write a comment…