# Client-side Cloud Function caching

**URL:** <https://community.parseplatform.org/t/client-side-cloud-function-caching/2792>\
**Category:** Cloud Code\
**Created:** [July 13, 2022, 7:17pm UTC](https://community.parseplatform.org/t/client-side-cloud-function-caching/2792 "2022-07-13T19:17:13Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![marcus](https://community.parseplatform.org/letter_avatar_proxy/v4/letter/m/85e7bf/32.png) [@marcus](https://community.parseplatform.org/u/marcus)\
**Post date:** [July 13, 2022, 7:17pm UTC](https://community.parseplatform.org/t/client-side-cloud-function-caching/2792/1 "2022-07-13T19:17:13Z")

</div>

Hi all - We are working on improving the client-side caching of some of our Cloud Functions. We want to be able to rely on client-side http-level caching to accomplish this, but after some searching, it seems like it would have to involve a custom endpoint that internally calls the function (ref: [Http response headers in cloud function response - #2 by davimacedo](https://community.parseplatform.org/t/http-response-headers-in-cloud-function-response/2486/2)).

My questions are:

- Does Parse allow clients to call Cloud Functions via http GET? And/or can Cloud Functions set their own response headers?
- Taking a step back, is there a Parse-recommended way to handle the client-side caching of Cloud Function responses?

Thank you!

---

<div class="post-metadata">

**Author:** ![davimacedo](https://community.parseplatform.org/user_avatar/community.parseplatform.org/davimacedo/32/316_2.png) [@davimacedo](https://community.parseplatform.org/u/davimacedo)\
**Post date:** [July 13, 2022, 10:48pm UTC](https://community.parseplatform.org/t/client-side-cloud-function-caching/2792/2 "2022-07-13T22:48:15Z")

</div>

For calling cloud code functions via http GET, you can create a custom endpoint in your Express.js app that triggers the cloud function and set the headers, if necessary. It shouldn’t be hard to be done.

In terms of client-side caching for cloud functions, the easiest way I can imagine is by creating a dictionary in which the key could be a hash of an object such as `{ functionName, params }` and the value could be the result.
