Some hosts will use a page cache for API routes to deal with this kind of problem. My initial thought would be to look at something like Cloudflare (they have some WordPress presets too) that would allow you to set up this kind of page cache for these API routes.
Interested to know how you get on as I’ve definitely seen similar issues with my site soon after sharing it on Mastodon!
Related Posts:
- Full page NGINX (or Cloudflare) caching and WordPress nonces
- WordPress REST API, Expired Nonce from Cache results in 403 forbidden
- How to cache a custom API call?
- How to modify the HTML output of Gutenberg block? (Youtube)
- Rest API nonce is being cached
- Steps to optimize WordPress in regard to server load and website speed?
- How to use WP-REST API to login user and get user data for Android app?
- How do I cache (core) API requests?
- WP REST API returns blank response if post is too long
- How to feed a HTML5’s EventSource with a REST API custom endpoint?
- Retrieve CSS and JS From the REST API
- How to Authenticate WP REST API with JWT Authentication using Fetch API
- WordPress 4.7 REST API endpoints
- Extremely slow WordPress website with 6000 posts
- REST API multiple media upload
- Can’t send emails through REST API
- 401 Error when trying to make a REST API call to site
- Does jQuery/Ajax send cookies when using the rest API or do I need to somehow add them?
- How to login to WordPress site using basic authentication HTTP headers?
- Can we access the REST request parameters from within the permission_callback to enforce a 401 by returning false?
- Upload image to wordpress using REST API
- Can I define multiple callback methods depending on the call method?
- Filter post content in REST API
- How to filter users on custom meta fields in WP JSON v2?
- How can I return an image from a custom REST API endpoint?
- How add meta fields to a user with the wp-api?
- WordPress Rest API response
- Check Password Strength using WordPress API
- Why does AWStats show /wp-json* as Viewed URLs
- How send get request to external api with username and password
- permission_callback has no effect
- Updating link on page via REST api
- How to order WordPress Rest API data
- WP Rest API – How to convert embedded to json object in Java [closed]
- featured image not found in json from wp rest api
- WordPress Caching On Demand
- WP REST API – Nonce passes wp_verify_nonce even after logout
- WP REST API plugin 500 errors?
- wp-cli command throws error : “SSL routines:tls_process_server_certificate:certificate verify failed” while querying https website
- Setting maintenance mode via REST API
- How to receive data by http POST request
- rendering view in backbone
- WP API querying a custom post type and a custom field
- Custom endpoint to get all custom taxonomy terms
- Notify Jenkins of new post on WordPress
- Curl requests sent two times
- Loop Performance > JSON files vs. WP_Query vs. REST API
- Check authentication credentials using WP REST API
- How to get author meta into post endpoint in api v2
- WordPress REST API V2: how to get list of all posts?
- Why does my site flash white every time it changes page? [closed]
- Getting 401 from ajax using an application password
- How to connect android app with WordPress website?
- WordPress REST API calls that depend on the WordPress User
- Register GET REST API route with multiple parameters
- Making internal rest requests non-blocking?
- How to include file attachment in ajax submission via the rest_api?
- WordPress HTTP API NTLM Authentication
- WordPress REST API parameters are not affecting a response
- How To Bulk Import wp_postmeta records in an API call?
- Rest API in self-hosted page doesn’t work [closed]
- Repeated nav bar queries failing to be cached
- WordPress custom REST API: How to validate input data by many context?
- Authenticate rest API except for contact-form-7
- How to access wordpress menu & submenu item through the REST API?
- WordPress Rest API- Allow creation of users with identical email addresses when only using rest api
- Inspecting WP_Rest_Request
- WordPress API fields modification
- wp_insert_post function and automatic trashing posts once is no longer in API
- How to deliver webp format of images to WP REST API
- register/login api
- WP Rest API in Android studio does not show Images
- WordPress improve REST API – SHORTINIT not work
- Update membership level via API request if using simple membership plugin
- Cache the registration of a custom post type?
- REST api header link href
- Rest API encoding of double quotes
- view counter update in WordPress REST api HTTP get
- update meta data (like view counter) by rest-api
- How Can I keep password protected posts in the json requests but not on frontend queries?
- Trouble Commenting via the WP REST API using nonces
- String Replace Caching & Chance of Collisions
- Debug Performance Issues
- Bluehost WebHost and performance problems with W3TC [closed]
- WordPress REST API not displaying all information
- Create a new page on front page for logged in user
- To what degree can use of caching-plugins and a CDN boost WordPress performance? [closed]
- In Rest API 2.0 is it possible to get some meta fields but not others?
- Is my WordPress site handing out sensitive information/misconfigured?
- Delete row from table using custom endpoint via API
- Fetch post by author slug
- Cant POST with REST API on WordPress
- WordPress json – How to use the content rendered from json
- Subscriber role cann’t add comment meta using REST API
- Restrict Image Sizes and Dimensions when Uploading via the WP Mobile App
- Can I use the Backbone REST API client outside WordPress?
- WordPress REST API function not calling from external site
- Issue with API after 6.2 update
- Verify user login and password over api
- How can i store cache of wordpress a database request without plugins?