Limiting the number of entities in the response

Hello every one!

I’m using your GraphQL data access point to extract some data. For example, the following code:

query TargetDiseases {
  target(ensemblId: "ENSG00000157764") {
    id
    approvedSymbol
    associatedDiseases {
      count
      rows {
        disease {
          id
          name
        }
        datasourceScores {
          id
          score
        }
      }
    }
  }
}


This query returns 1220 diseases related to this target. How can I limit the number of diseases in the answer, directly from the query?

Thank you !

Hi @Orlando_B, and welcome to the Open Targets Community! :tada:

If you want to limit the number of diseases the query returns, try:

1 Like