You could replace your call to wp_ajax for a custom REST endpoint.
This should be useful: https://developer.wordpress.org/rest-api/extending-the-rest-api/adding-custom-endpoints/
Related Posts:
- How can I make an Ajax login form work with FORCE_SSL_ADMIN enabled?
- Help making my pagination plugin better
- admin-ajax returning 400 error when request is made with Fetch API
- Delete Custom Dashboard Widgets
- Editor access to plugin settings
- How to pass JavaScript variable to PHP in wordpress widget?
- jQuery AJAX call not executing in Plugin
- Errors while using ajax from external wordpress page
- I can’t access wordpress functions from an ajax php call
- Built in admin ajax hooks?
- delete_user_meta Delete one value out of array
- How can I ‘reactivate’ .PHP files within a WP plugin that have been marked ‘inactive’?
- How to use wp-ajax in wp-cron
- Calling shortcode in wp_localize_script strips result
- how to use ajax to display from database and load more in wordpress plugin
- Dashboard Disappears after Upgrade
- Ajax with jQuery UI dialog not working
- Dashboard Widget Form
- Shortcode in AJAX popup
- jQuery Plugin to use WordPress functions in AJAX request
- $wpdb working with ajax but showing ajax error instead of success
- Why none of the plugins that have ajax doesn’t work in my website?
- Why do plugins that cause ‘unexpected output’ create AJAX problems?
- AJAX button run function
- How to put JQuery/Ajax inside shortcode?
- WordPress Ajax Posting from App
- Using a custom plugin to capture input data via Ajax and PHP
- Ajax contact form widget plugin data not insert in database
- woocommerce_package_rates not fired when wordpress woocommerce accessed as non ajax
- Why WordPress plugin url ajax doesn’t work?
- AJAX in plugin wp_send_json() sending html
- Ajax call returning 0
- Ajax fail and get 504 error
- Ajax Search Lite: Customize Autoscroll
- Create tabs in admin options page from custom post type loop
- How to exclude certain files from the plugin editor?
- Post Comments with Ajax in WordPress
- Submit Form data to another page via Ajax (WordPress Way)
- plugin shortcode not working on ajax request call
- wordpress add_action() issue in ajax call
- Allowed memory size exhausted problem
- How can i force wp-admin to use 2-column dashboard layout? [closed]
- PHP script from functions php is loaded via admin-ajax to div…and the result is 0, not the desired content
- Ajax Plugin Not Echoing Response
- WordPress Ajax code is not Working
- don’t call ajax if not plugin page
- coding a WordPress AJAX Form using PHP to check if User is Logged Out and Show error
- woocommerce search by sku and title ajax
- Where Should i write the code for wordpress ajax voting?
- Remove value from array within post meta ajax admin
- Convert to shortcode?
- How to include my Ajax calls in one function instead of calling different ones every time?
- Ajax Call in page theme not working?
- Call ajax on the frontend
- Using AJAX to run SQL statement and populate dropdown
- Displaying URL Based on User Input from a Form W/in a Dashboard Widget
- Problem with ajax plugin for refreshing posts
- Widget Screen Locked
- best way to run a php script away from the template?
- Stopping WordPress’ WYSIWYG Editor from Converting “didn’t” into “didn””””’t”?
- Need help creating asynchronous data scraper in WordPress
- Ajax call not working in wordpress through a plugin
- Ajax 400 error when used inside a plugin
- Strange admin-ajax / CSS / $_SESSION issue
- wp_query ‘s’ parameter does not work with WC_AJAX
- wc_get_template_part doesnt display the content [duplicate]
- Jquery POST Ajax Return null data in wordpress
- In a plugin, How to update a json file using ajax
- Cannot pass value variable to WP AJAX functions
- WordPress Dashboard add user password not working, etc
- Can you add a shortcode to a custom post type that gets the post_title, post_content, etc. and then passes that to a plugin function?
- JS working when used normally but not in wordpress
- Use AJAX to fetch Current Post Thumbnail for WordPress when Uploaded throughMedia Uploader Frontend
- How to avoid the 403 Forbidden error in a WP Plugin with Ajax and PHP
- wp-admin/admin-ajax.php 400 (Bad Request) plugin
- Why is my form going to frontend on html form submission present on the php files inside my custom plugin?
- AJAX update fails for public/non-admin users
- WordPress Ajax request “Failed to load resource: the server responded with a status of 400 ()”
- How to disable/enable PHP plugin functionality based on a TinyMCE toggle-button
- Not able to upload Plugins/ Theme from Admin backend
- ajax voting for custom post type
- Conditional Fields depending on checkboxes
- 504 Timeout gateway when trying to pay for an order in Woocommerce. What else can I do?
- Help with customising love it plugin (use within foreach)
- Ajax call fails and returns [object Object]
- wordpress ajax pagination object value does not change
- WordPress update plugin through Dashboard/Plugins displaying error
- What’s the preferred method of writing AJAX-enabled plugins?
- using jquery serialize in ajax operation for plugin
- Like/Dislike Bar not working when updating
- Ajax Not Working If The Handler is Located Outside Plugin Submenu Page Function
- Build and ajax plugin not work
- Capturing POST data
- Trouble Removing Plugin [closed]
- How to change response of admin-ajax request?
- How to create plugin list groups?
- Ajax not working for logged in users
- Advanced Ajax Page Loader and Masonry Grid
- How to create load more button without a plugin?
- How to make a rest style plugin?