Skip to Content

pages

Search and paginate through pages

Authentication

Public Access: Accessible with the public API key

Query Structure

{ pages( first: Int after: String last: Int before: String query: String sortKey: PageSortKey reverse: Boolean ) { # PageConnection fields } }

Arguments

ArgumentTypeRequiredDescription
firstIntNoReturns the first n elements.
afterStringNoReturns elements after cursor.
lastIntNoReturns the last n elements.
beforeStringNoReturns elements before cursor.
queryStringNoSearch query string to filter pages by title or content.
sortKeyPageSortKeyNoThe key to sort pages by.
reverseBooleanNoReverse the order of the underlying list.

Return Type

PageConnection - A connection object containing a list of pages with pagination information.

Example

query { pages(first: 10, query: "about", sortKey: TITLE, reverse: false) { edges { node { id title handle body } cursor } pageInfo { hasNextPage hasPreviousPage } } }