CalderaWP / searchwp-api-route

Adds an endpoint to the WordPress REST API for searching via SearchWP
33 stars 15 forks source link

Getting rest_route_not found after setting up plugin #10

Open smokeyfro opened 5 years ago

smokeyfro commented 5 years ago

Hey Josh,

First off, thanks for sharing Search API plugin - I've been working on some custom endpoints for our site, but your plugin pretty much does what we're after :)

I've installed the plugin and setup a supplemental search engine in SearchWP, but when I try check the responses using https://winefolly.staging.wpengine.com/wp-json/swp-api/?search=chardonnay&engine=wines, I get a rest_no_route code 404 error.

Any ideas what I'm missing?

conschneider commented 4 years ago

Hi @smokeyfro,

Very late answer, but maybe still helpful. Your route needs to be a little different. Change swp-api >> swp_api. That will make it work: wp-json/swp_api/search.