/apollo-kotlin

:rocket:  A strongly-typed, caching GraphQL client for the JVM, Android, and Kotlin multiplatform.

Primary LanguageKotlinMIT LicenseMIT

Apollo Client

Discourse Slack Discord

OSS Snapshots Apollo Preview Maven Central

Revved up by Develocity

☑️ Apollo Clients User Survey
What do you like best about Apollo Kotlin? What needs to be improved? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Kotlin usage and allow us to serve you better.

🚀 Apollo Kotlin

Apollo Kotlin is a strongly typed GraphQL client that generates Kotlin models for your GraphQL operations.

Apollo Kotlin executes operations against a GraphQL server and returns results as operation-specific Kotlin types. This means you don't have to deal with parsing JSON, or passing around Maps and making clients cast values to the right type manually. You also don't have to write model types yourself, because these are generated from the GraphQL definitions your app uses.

Because generated types are operation-specific, you can only access data that you actually specify as part of an operation. If you don't ask for a particular field in an operation, you can't access the corresponding property on the returned data structure.

This library is designed with Android in mind, but you can use it in any Kotlin application, including KMP (Kotlin Multi Platform).

📚 Documentation

All Apollo Kotlin documentation, including caching and helpful recipes, can be found at:
https://www.apollographql.com/docs/kotlin/

The Apollo Kotlin API reference can be found at:
https://apollographql.github.io/apollo-kotlin/kdoc/

👨‍💻 Who is Apollo?

Apollo builds open-source tools and commercial services to make application development easier, better, and accessible to more people. We help you ship faster with:

  • GraphOS - The platform for building, managing, and scaling a supergraph: a unified network of your organization's microservices and their data sources—all composed into a single distributed API.
  • Apollo Federation – The industry-standard open architecture for building a distributed graph. Use Apollo’s gateway to compose a unified graph from multiple subgraphs, determine a query plan, and route requests across your services.
  • Apollo Client – The most popular GraphQL client for the web. Apollo also builds and maintains Apollo iOS and Apollo Kotlin.
  • Apollo Server – A production-ready JavaScript GraphQL server that connects to any microservice, API, or database. Compatible with all popular JavaScript frameworks and deployable in serverless environments.

🎓 Learn how to build with Apollo

Check out the Odyssey learning platform, the perfect place to start your GraphQL journey with videos and interactive code challenges. Join the Apollo Community to interact with and get technical help from the GraphQL community.