# \#mobile

**URL:** https://community.apollographql.com/tag/mobile/4.md

[Latest](https://community.apollographql.com/latest.md) · [Categories](https://community.apollographql.com/categories.md) · [Tags](https://community.apollographql.com/tags.md)

---

## [Multi-module codegen: "unused fragment" warnings for fragments used only in downstream modules](https://community.apollographql.com/t/multi-module-codegen-unused-fragment-warnings-for-fragments-used-only-in-downstream-modules/9942)

<div class="topic-metadata">

**Author:** [@Iulian\_Iancu\_mindera](https://community.apollographql.com/u/Iulian_Iancu_mindera)\
**Replies:** 1\
**Last updated:** [July 7, 2026, 1:11pm UTC](https://community.apollographql.com/t/multi-module-codegen-unused-fragment-warnings-for-fragments-used-only-in-downstream-modules/9942 "2026-07-07T13:11:10Z")

</div>

We have a large multi-module Android project using Apollo Kotlin 5.0.1. To share GraphQL fragments across features we put each shared fragment in its own Gradle module and wire cross-module codegen with metadata: apol…

---

## [Is CacheAndNetwork FetchPolicy going to be deprecated in future?](https://community.apollographql.com/t/is-cacheandnetwork-fetchpolicy-going-to-be-deprecated-in-future/9821)

<div class="topic-metadata">

**Author:** [@vijay\_v\_joshi](https://community.apollographql.com/u/vijay_v_joshi)\
**Replies:** 1\
**Last updated:** [May 6, 2026, 8:20am UTC](https://community.apollographql.com/t/is-cacheandnetwork-fetchpolicy-going-to-be-deprecated-in-future/9821 "2026-05-06T08:20:55Z")

</div>

Hello Team, I see this comment “// CacheAndNetwork is deprecated but should still work” , Is there plan to deprecate this FetchPolicy in future. If not, why was this comment added to the code? Thank you, Vijay

---

## [How to optimize graphql queries for interactive web apps?](https://community.apollographql.com/t/how-to-optimize-graphql-queries-for-interactive-web-apps/9616)

<div class="topic-metadata">

**Author:** [@carla-bruni88](https://community.apollographql.com/u/carla-bruni88)\
**Replies:** 0\
**Last updated:** [January 1, 2026, 7:01pm UTC](https://community.apollographql.com/t/how-to-optimize-graphql-queries-for-interactive-web-apps/9616 "2026-01-01T19:01:10Z")

</div>

Hi everyone, I’m working on a web app that integrates dynamic content and interactive features. One challenge I’ve faced recently involves optimizing graphql queries for performance, especially when handling media-heavy…

---

## [Managing performance and rate limits with complex queries](https://community.apollographql.com/t/managing-performance-and-rate-limits-with-complex-queries/9588)

<div class="topic-metadata">

**Author:** [@valerie31](https://community.apollographql.com/u/valerie31)\
**Replies:** 0\
**Last updated:** [December 15, 2025, 8:51pm UTC](https://community.apollographql.com/t/managing-performance-and-rate-limits-with-complex-queries/9588 "2025-12-15T20:51:06Z")

</div>

Hi everyone, I’m running into some performance issues with Apollo when certain clients send deeply nested or repeated queries. Even with caching in place, I’m seeing spikes in execution time and occasional rate-limit pr…

---

## [Cannot destructure property '\_\_extends' of '\_tslib.default' as it is undefined](https://community.apollographql.com/t/cannot-destructure-property-extends-of-tslib-default-as-it-is-undefined/9501)

<div class="topic-metadata">

**Author:** [@Chenter\_PHAI](https://community.apollographql.com/u/Chenter_PHAI)\
**Replies:** 3\
**Last updated:** [December 5, 2025, 4:56am UTC](https://community.apollographql.com/t/cannot-destructure-property-extends-of-tslib-default-as-it-is-undefined/9501 "2025-12-05T04:56:53Z")

</div>

Hello, anyone can help me with this? I got error while exporting my EXPO App with embed and web as well. Thanks! bun expo export:embed --eager --platform ios --dev Cannot destructure property ‘\_\_extends’ of ‘\_tslib.…

---

## [Best Practice for Handling Build Type-Specific Schema Endpoints in Android Multi-Module Setup](https://community.apollographql.com/t/best-practice-for-handling-build-type-specific-schema-endpoints-in-android-multi-module-setup/9524)

<div class="topic-metadata">

**Author:** [@Lana\_Mozharovska](https://community.apollographql.com/u/Lana_Mozharovska)\
**Replies:** 0\
**Last updated:** [October 23, 2025, 7:16am UTC](https://community.apollographql.com/t/best-practice-for-handling-build-type-specific-schema-endpoints-in-android-multi-module-setup/9524 "2025-10-23T07:16:25Z")

</div>

Hi Apollo Community, I’m working on a multi-module Android project and trying to figure out the best way to handle schema downloads based on our app’s build types. Our Setup: :app module: Defines buildTypes (debug, s…

---

## [Apollo iOS bypassing URLSession's cache-control behaviour by checking its own store first in \`.returnCacheDataElseFetch\`](https://community.apollographql.com/t/apollo-ios-bypassing-urlsessions-cache-control-behaviour-by-checking-its-own-store-first-in-returncachedataelsefetch/9417)

<div class="topic-metadata">

**Author:** [@grse](https://community.apollographql.com/u/grse)\
**Replies:** 2\
**Last updated:** [September 2, 2025, 12:34am UTC](https://community.apollographql.com/t/apollo-ios-bypassing-urlsessions-cache-control-behaviour-by-checking-its-own-store-first-in-returncachedataelsefetch/9417 "2025-09-02T00:34:05Z")

</div>

Hi team, While digging into caching behavior in Apollo iOS, I noticed something I wanted to clarify. In CacheReadInterceptor, the .returnCacheDataElseFetch currently checks Apollo’s store first: case .returnCacheDataEl…

---

## [Android Best Practice: Mocking Fragments vs. Using Separate UI Models?](https://community.apollographql.com/t/android-best-practice-mocking-fragments-vs-using-separate-ui-models/9235)

<div class="topic-metadata">

**Author:** [@Lana\_Mozharovska](https://community.apollographql.com/u/Lana_Mozharovska)\
**Replies:** 4\
**Last updated:** [June 24, 2025, 3:14pm UTC](https://community.apollographql.com/t/android-best-practice-mocking-fragments-vs-using-separate-ui-models/9235 "2025-06-24T15:14:22Z")

</div>

I have a design pattern question regarding apollo-kotlin on Android, specifically about the best way to structure data for the UI layer (Jetpack Compose) to allow for easy testing and previews. There seem to be two comm…

---

## [📣 The new Apollo Kotlin Normalized Cache is here!](https://community.apollographql.com/t/the-new-apollo-kotlin-normalized-cache-is-here/9083)

<div class="topic-metadata">

**Author:** [@Benoit\_Lubek](https://community.apollographql.com/u/Benoit_Lubek)\
**Replies:** 0\
**Last updated:** [May 20, 2025, 2:58pm UTC](https://community.apollographql.com/t/the-new-apollo-kotlin-normalized-cache-is-here/9083 "2025-05-20T14:58:23Z")

</div>

:megaphone: The new Apollo Kotlin Normalized Cache is here, now in GA! We’ve been working over the past year on this new version, bringing: Pagination support Expiration (TTL) Garbage collection and trimming Partial r…

---

## [Mutating cache crashing immediately](https://community.apollographql.com/t/mutating-cache-crashing-immediately/8437)

<div class="topic-metadata">

**Author:** [@arvinshen](https://community.apollographql.com/u/arvinshen)\
**Replies:** 1\
**Last updated:** [May 7, 2025, 7:19pm UTC](https://community.apollographql.com/t/mutating-cache-crashing-immediately/8437 "2025-05-07T19:19:06Z")

</div>

I am trying to mutate my cache, but it is crashing immediately when using ApolloStore.withinReadWriteTransaction(\_:callbackQueue:completion:) and need help troubleshooting as I don’t know what is causing this issue. I re…

---

## [Cache performance debugging](https://community.apollographql.com/t/cache-performance-debugging/8881)

<div class="topic-metadata">

**Author:** [@daronimo](https://community.apollographql.com/u/daronimo)\
**Replies:** 3\
**Last updated:** [April 14, 2025, 4:45pm UTC](https://community.apollographql.com/t/cache-performance-debugging/8881 "2025-04-14T16:45:02Z")

</div>

Hey all - Following up in this forum after speaking in person with some members of your team last week. We were wondering if there was any general advice for how to debug or instrument the Apollo Client cache performanc…

---

## [Parse JSON response into GraphQL response with alias and custom adapter](https://community.apollographql.com/t/parse-json-response-into-graphql-response-with-alias-and-custom-adapter/8895)

<div class="topic-metadata">

**Author:** [@PuneetS](https://community.apollographql.com/u/PuneetS)\
**Replies:** 2\
**Last updated:** [April 14, 2025, 6:25am UTC](https://community.apollographql.com/t/parse-json-response-into-graphql-response-with-alias-and-custom-adapter/8895 "2025-04-14T06:25:57Z")

</div>

Hi I have a use-case of parsing a JSON response into GraphQL response using adapters autogenerated by Apollo Kotlin. I have defined some aliases into my GraphQL query which i want to be mapped accordingly but since ther…

---

## [Do I need the OPTIONS endpoint if my only intended clients are native mobile apps?](https://community.apollographql.com/t/do-i-need-the-options-endpoint-if-my-only-intended-clients-are-native-mobile-apps/8859)

<div class="topic-metadata">

**Author:** [@jleangstartup](https://community.apollographql.com/u/jleangstartup)\
**Replies:** 0\
**Last updated:** [April 7, 2025, 10:33am UTC](https://community.apollographql.com/t/do-i-need-the-options-endpoint-if-my-only-intended-clients-are-native-mobile-apps/8859 "2025-04-07T10:33:58Z")

</div>

From what I can gather, the OPTIONS endpoint is used to help facilitate CRSF (Cross-Site Request Forgery) prevention. If my server is only intended for native mobile apps, I am guessing I don’t need it? and also don’t n…

---

## [Schedule App Refresh in the background](https://community.apollographql.com/t/schedule-app-refresh-in-the-background/8751)

<div class="topic-metadata">

**Author:** [@rajivjhoomuck](https://community.apollographql.com/u/rajivjhoomuck)\
**Replies:** 4\
**Last updated:** [March 24, 2025, 11:10pm UTC](https://community.apollographql.com/t/schedule-app-refresh-in-the-background/8751 "2025-03-24T23:10:09Z")

</div>

Hi, When my app is in the background, I need to wake it up periodically to refresh data. I am not sure how to achieve that since, from what I have seen so far, the URLSessionConfiguration that is passed to the URLSessio…

---

## [How to create a GraphQL response from json?](https://community.apollographql.com/t/how-to-create-a-graphql-response-from-json/7824)

<div class="topic-metadata">

**Author:** [@JanC](https://community.apollographql.com/u/JanC)\
**Replies:** 2\
**Last updated:** [March 21, 2025, 5:27pm UTC](https://community.apollographql.com/t/how-to-create-a-graphql-response-from-json/7824 "2025-03-21T17:27:54Z")

</div>

Hi, I have a saved json response of GetCustomersQuery and I’d like to instantiante the GetCustomersQuery.Data using that saved file. It is described in the docs but when I do it, I get the exception JSONDecodingError.mi…

---

## [Alice in Wonderland: Federation on the other side of the mirror](https://community.apollographql.com/t/alice-in-wonderland-federation-on-the-other-side-of-the-mirror/8686)

<div class="topic-metadata">

**Author:** [@Aleksandar\_Susnjar](https://community.apollographql.com/u/Aleksandar_Susnjar)\
**Replies:** 0\
**Last updated:** [March 6, 2025, 2:53pm UTC](https://community.apollographql.com/t/alice-in-wonderland-federation-on-the-other-side-of-the-mirror/8686 "2025-03-06T14:53:20Z")

</div>

What we love about Federation is that it can take a complex supergraph request and distribute the processing of it to relevant subgraphs. It takes one thing, creates multiple, aggregates responses and sends them back (we…

---

## [Apollo 4 Cold Start Delay: API Response Logging Immediately but Repository Receives After Delay](https://community.apollographql.com/t/apollo-4-cold-start-delay-api-response-logging-immediately-but-repository-receives-after-delay/8591)

<div class="topic-metadata">

**Author:** [@Sebastian\_Sharun](https://community.apollographql.com/u/Sebastian_Sharun)\
**Replies:** 7\
**Last updated:** [February 21, 2025, 12:01pm UTC](https://community.apollographql.com/t/apollo-4-cold-start-delay-api-response-logging-immediately-but-repository-receives-after-delay/8591 "2025-02-21T12:01:13Z")

</div>

I’m developing an Android native app in Kotlin using Apollo 4. When I call the home page API, the HTTP Logger Interceptor logs the response immediately. However, the response only reaches my repository after roughly 1 se…

---

## [How to initialise inline fragments manually?](https://community.apollographql.com/t/how-to-initialise-inline-fragments-manually/8094)

<div class="topic-metadata">

**Author:** [@akshaymantasolutions](https://community.apollographql.com/u/akshaymantasolutions)\
**Replies:** 1\
**Last updated:** [January 16, 2025, 7:14pm UTC](https://community.apollographql.com/t/how-to-initialise-inline-fragments-manually/8094 "2025-01-16T19:14:47Z")

</div>

I am trying to initiate inline fragments manually due to some api requirements like below. let details = BalanceHistoryQuery.Data.Me.BalanceHistoryEvents.Edge.Node.Details(\_dataDict: node.details.\_\_data) But details ob…

---

## [Upgrading from 0.53 to 1.0 in Apollo iOS Getting “Multiple Commands produce" error](https://community.apollographql.com/t/upgrading-from-0-53-to-1-0-in-apollo-ios-getting-multiple-commands-produce-error/8063)

<div class="topic-metadata">

**Author:** [@akshaymantasolutions](https://community.apollographql.com/u/akshaymantasolutions)\
**Replies:** 3\
**Last updated:** [January 9, 2025, 11:41am UTC](https://community.apollographql.com/t/upgrading-from-0-53-to-1-0-in-apollo-ios-getting-multiple-commands-produce-error/8063 "2025-01-09T11:41:07Z")

</div>

We are trying to upgrade our iOS Apollo library from 0.53 to 1.15.3. We have followed the steps mentioned in this migration doc But we are getting this error in Xcode after performing all the steps

---

## [Help with Configuring Apollo iOS Code Generation](https://community.apollographql.com/t/help-with-configuring-apollo-ios-code-generation/7977)

<div class="topic-metadata">

**Author:** [@ruvalcaba18](https://community.apollographql.com/u/ruvalcaba18)\
**Replies:** 4\
**Last updated:** [January 6, 2025, 11:39pm UTC](https://community.apollographql.com/t/help-with-configuring-apollo-ios-code-generation/7977 "2025-01-06T23:39:31Z")

</div>

Hi everyone, I’m using Apollo and GraphQL in an iOS project, and I’m trying to configure the code generation for my queries and mutations. Following the Apollo documentation, I noticed that it generates a Swift Package …

---

## [I cannot fire the onConnected event](https://community.apollographql.com/t/i-cannot-fire-the-onconnected-event/7868)

<div class="topic-metadata">

**Author:** [@cld](https://community.apollographql.com/u/cld)\
**Replies:** 0\
**Last updated:** [October 2, 2024, 3:20pm UTC](https://community.apollographql.com/t/i-cannot-fire-the-onconnected-event/7868 "2024-10-02T15:20:56Z")

</div>

Hi, I have an Aws AppSync service that I would like to establish a Websocket connection with my mobile app built in React Native I am using the libraries @apollo/client/link/ws and @subscriptions-transport-ws this is …

---

## [How to get graphql express server to run on ip address instead of localhost](https://community.apollographql.com/t/how-to-get-graphql-express-server-to-run-on-ip-address-instead-of-localhost/7717)

<div class="topic-metadata">

**Author:** [@Geenzie](https://community.apollographql.com/u/Geenzie)\
**Replies:** 0\
**Last updated:** [July 20, 2024, 2:36pm UTC](https://community.apollographql.com/t/how-to-get-graphql-express-server-to-run-on-ip-address-instead-of-localhost/7717 "2024-07-20T14:36:08Z")

</div>

I’m working on a project using react-native with expo and graphql in the frontend and nodejs with mongodb and graphql in the backend. Currently, I’m trying to test my project on a real device, but I can’t even sign-in. I…

---

## [Migration from apollo android to apollo kotlin](https://community.apollographql.com/t/migration-from-apollo-android-to-apollo-kotlin/7598)

<div class="topic-metadata">

**Author:** [@tkhat](https://community.apollographql.com/u/tkhat)\
**Replies:** 1\
**Last updated:** [June 10, 2024, 8:20pm UTC](https://community.apollographql.com/t/migration-from-apollo-android-to-apollo-kotlin/7598 "2024-06-10T20:20:02Z")

</div>

I am trying to migrate from apollo android to apollo 3.8.2 this is Error class from apollo kotlin class Error( val message: String, val locations: List\<Error.Location\>?, val path: List\<Any\>?, val extensions: Map\<St…

---

## [Is there a way for using the same structs with different requests?](https://community.apollographql.com/t/is-there-a-way-for-using-the-same-structs-with-different-requests/5096)

<div class="topic-metadata">

**Author:** [@gklka](https://community.apollographql.com/u/gklka)\
**Replies:** 3\
**Last updated:** [June 6, 2024, 12:06pm UTC](https://community.apollographql.com/t/is-there-a-way-for-using-the-same-structs-with-different-requests/5096 "2024-06-06T12:06:01Z")

</div>

Hello! I have several Queries and Mutations which logically share the same object (struct). For example the getUser(id) method returns the same User as the listUsers (which returns an array of users in this example) and…

---

## [iOS app build is failing in build server](https://community.apollographql.com/t/ios-app-build-is-failing-in-build-server/7580)

<div class="topic-metadata">

**Author:** [@Anil](https://community.apollographql.com/u/Anil)\
**Replies:** 1\
**Last updated:** [June 4, 2024, 6:26pm UTC](https://community.apollographql.com/t/ios-app-build-is-failing-in-build-server/7580 "2024-06-04T18:26:27Z")

</div>

I have integrated Apollo iOS sdk using pods. sdk v 1.11.0 I have setup everything as per the docs and generated the code and build is succeeding in my local machine. However, after pushing the changes to repository bui…

---

## [Initialize ApolloClient (iOS) with multiple endpoints](https://community.apollographql.com/t/initialize-apolloclient-ios-with-multiple-endpoints/7554)

<div class="topic-metadata">

**Author:** [@Anil](https://community.apollographql.com/u/Anil)\
**Replies:** 1\
**Last updated:** [May 24, 2024, 9:30pm UTC](https://community.apollographql.com/t/initialize-apolloclient-ios-with-multiple-endpoints/7554 "2024-05-24T21:30:53Z")

</div>

I have an iOS app which needs to hit two different endpoints to fetch data. How to initiate ApolloClient with two different endpoints? I couldn’t find a straight answer in internet, any help is appreciated. Note: Those …

---

## [I have to call generate apollo-ios-cli in script when i build the code](https://community.apollographql.com/t/i-have-to-call-generate-apollo-ios-cli-in-script-when-i-build-the-code/7546)

<div class="topic-metadata">

**Author:** [@Sreenidhi](https://community.apollographql.com/u/Sreenidhi)\
**Replies:** 1\
**Last updated:** [May 24, 2024, 11:14am UTC](https://community.apollographql.com/t/i-have-to-call-generate-apollo-ios-cli-in-script-when-i-build-the-code/7546 "2024-05-24T11:14:16Z")

</div>

How to include code gen for iOS in form of script in build phases or anywhere in form of bash so that i need not run generate apollo-ios-cli manually everytime there is a change in query, since this is only available cur…

---

## [Tips for migrating from NPM-based codegen to apollo-ios-cli?](https://community.apollographql.com/t/tips-for-migrating-from-npm-based-codegen-to-apollo-ios-cli/7477)

<div class="topic-metadata">

**Author:** [@jamesonwilliams](https://community.apollographql.com/u/jamesonwilliams)\
**Replies:** 1\
**Last updated:** [May 6, 2024, 10:03pm UTC](https://community.apollographql.com/t/tips-for-migrating-from-npm-based-codegen-to-apollo-ios-cli/7477 "2024-05-06T22:03:23Z")

</div>

Hi there! I’m trying to upgrade our iOS project from the old NPM-based code gen to the new apollo-ios-cli. To start, I’m hoping to configure the apollo-ios-cli to work similarly to our current setup. I’ve been reading th…

---

## [Cursor based pagination](https://community.apollographql.com/t/cursor-based-pagination/867)

<div class="topic-metadata">

**Author:** [@redderick2](https://community.apollographql.com/u/redderick2)\
**Replies:** 15\
**Last updated:** [April 25, 2024, 4:28pm UTC](https://community.apollographql.com/t/cursor-based-pagination/867 "2024-04-25T16:28:18Z")

</div>

I was going through the apollo docs for cursor based pagination and I assumed that these fields were given to us: edges { node { author text } } pageInfo { endC…

---

## [Apollo Client useLazyQuery making request 4-6 times](https://community.apollographql.com/t/apollo-client-uselazyquery-making-request-4-6-times/7424)

<div class="topic-metadata">

**Author:** [@Doug\_Niccum](https://community.apollographql.com/u/Doug_Niccum)\
**Replies:** 4\
**Last updated:** [April 24, 2024, 1:09pm UTC](https://community.apollographql.com/t/apollo-client-uselazyquery-making-request-4-6-times/7424 "2024-04-24T13:09:37Z")

</div>

I am currently building a React Native application utilizing the Apollo Client to make requests to a Laravel-hosted GraphQL server. The issue that I am running into is that each query that I execute, regardless if I am u…

[Next page](https://community.apollographql.com/tag/mobile/4.md?match_all_tags=true&page=1&tags%5B%5D=mobile)
