Why you don't need an SDK with Prepr CMS

When implementing a headless CMS, you might assume you need to use a dedicated SDK to include Prepr CMS in your front end. Since Prepr CMS includes a GraphQL API for content delivery, using Apollo Client or a similar GraphQL client to fetch content eliminates the need for an SDK.

Apollo Client already handles everything you need

Apollo Client (opens in a new tab) is a powerful GraphQL client that simplifies data fetching and management. It provides:

  • Querying so you can fetch content directly with GraphQL.

  • Built-in caching mechanisms to improve performance and reduce API calls.

  • State management to normalize data and manage it efficiently.

Since GraphQL APIs are self-documenting and strongly typed, Apollo Client allows you to interact directly with the CMS without requiring additional SDKs.

Apollo Client is scalable

Apollo Client is scalable because it's optimized for edge deployment and serverless applications as follows:

  • It comes with normalized cache that reduces redundant requests and optimizes data retrieval, improving performance in distributed environments.
  • It minimizes network requests by batching queries and deduplicating them, which is beneficial for scalable applications.
  • It works well with edge computing platforms by reducing latency and improving data fetching performance.
  • It integrates seamlessly with serverless GraphQL APIs (like Apollo Server running on AWS Lambda).

Easier debugging and tooling

Apollo Client integrates seamlessly with developer tools like Apollo DevTools, making it easier to inspect queries, analyze cache, and debug issues—capabilities that may not be as robust when using a CMS-specific SDK.

Next steps

Check out one of the framework quick start guides to get you started in a few minutes to implement your front end using the Apollo client. To make the most of all Prepr features including A/B testing and personalization, check out the Next.js complete guide.

Was this article helpful?

We’d love to learn from your feedback