Cache server-to-server requests (SvelteKit)

Hi there! I use SvelteKit and need to cache requests made from a page server load function to a server endpoint. For now here's my setup (attached), but it doesn't seems to work. Have you some ideas? Do I need to cache manually using the Cache API? Cheers!
No description
No description
1 Reply
Chaika
Chaika9mo ago
hmm, not sure I understand your setup fully, the api is where, also in a function? If your function is calling another function on your Custom domain you might just get cache, wouldn't work on the pages.dev. You can always use the Cache API: https://developers.cloudflare.com/workers/runtime-apis/cache/ eitherway though, it'd give you more control and work on the pages.dev as well
Cloudflare Docs
Cache · Cloudflare Workers docs
Control reading and writing from the Cloudflare global network cache.
Want results from more Discord servers?
Add your server