Data Queries That are Available with GraphCMS

GraphQL Query API

GraphQL Query API

You can define and query your own GraphQL content API.. A query API is an interface to your content stored inside GraphCMS, that is generated on fields you create.

Easily query individual and related content with one GraphQL endpoint.

Build your own query API
GraphQL as you know it

GraphQL as you know it

Everything you do in GraphCMS is automatically documented. Use our GraphQL Explorer to create and save queries for you or your team later.

When querying your endpoint, you'll have all of your query and argument input types documented as you usually would with GraphiQL.

Level up your GraphQL queries

Combine one or more query arguments to filter, sort and translate your query response.

Locales

Query for content using a preferred locale, or an array of locales in order of preference.

Stage

Query data in a specific stage.

Paginate

Use the before, after, first, last and, skip arguments to paginate when querying your content.

Filter

Extensively filter your content using a single or multiple filters, including relational filters, with the where argument.

Ordering

Order content results ascending or descending with the orderBy argument.


GraphQL queries at a glance

Query GraphCMS via GraphQL for your content.

query {
pages {
id
title
slug
}
}

Simple GraphQL Query

Single Queries are just that! Query one object or content node.

query {
pages {
id
title
slug
authors(
orderBy: createdAt__DESC,
) {
id
name
}
}
}

Relational GraphQL Query

Query for data across relations with GraphQL. GraphCMS takes care of the heavy lifting, providing you a single, declarative API to query your related content.

query {
pages(
first: 5,
locale: [de, en],
stage: PUBLISHED,
createdAt__DESC,
) {
id
title
slug
authors {
id
name
}
}
}

GraphQL Query with arguments

Easily query for the first 5 articles in a different locale, and stage.

It's Easy To Get Started

GraphCMS plans are flexibly suited to accommodate your growth. Get started for free, or request a demo to discuss larger projects with more complex needs