When querying for Page’s (built using the Compose feature) in Contentful’s GraphQL API, there is not a way to currently filter the collection by the Content Type of the underlying entry. For example, if I have a content type called Article
and I create a Page in compose that references Article
in the content
field, I have no way of querying the GraphQL API with a filter that can return only Article Page’s. I have to request all Page’s and then manually filter out the ones that have an Article
linked.
In the REST API, this can be accomplished with a query like:
'fields.content.sys.contentType.sys.id': 'article'
but there doesn’t seem to be an equivalent filter available in the PageFilter
input type in the GraphQL schema.