wp-json/wp/v2 not caching
-
I have a few JSON requests I’m making and none of them cache. Here are the three calls that I am making:
/wp-json/wp/v2/posts?_embed=wp%3Aterm%2Cwp%3Afeaturedmedia&per_page=10&page=1&orderBy=date&order=desc&lang=en&_locale=user /wp-json/wp/v2/topic?_fields=id%2Cname%2Cslug&per_page=100&lang=en&_locale=user /wp-json/wp/v2/content-region?_fields=id%2Cname%2Cslug&per_page=100&lang=en&_locale=user
In terms of the response I get, here is the output for the first one:
Request URL: /wp-json/wp/v2/posts?_embed=wp%3Aterm%2Cwp%3Afeaturedmedia&per_page=10&page=1&orderBy=date&order=desc&lang=en&_locale=user Request Method: GET Status Code: 200 OK Access-Control-Allow-Headers: Authorization, X-WP-Nonce, Content-Disposition, Content-MD5, Content-Type Access-Control-Expose-Headers: X-WP-Total, X-WP-TotalPages, Link Allow: GET, POST Cache-Control: no-cache, must-revalidate, max-age=0, no-store, private ...
My hunch is this is not working based on the fact I’m getting a no-cache response for Cache-Control. Any insight would be greatly appreciated.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘wp-json/wp/v2 not caching’ is closed to new replies.