Yesterday, I tried installing the WordPress REST API plugin on a test site on my Mac running MAMP. I followed the directions up to a certain point on two courses on Lynda.com, but then came to a screeching halt after seeing 404 errors in the console.
According to the documentation, with the plugin activated, I should see JSON if I went to an endpoint such as http://localhost/…/wp-json/.
But alas, I got nothing. Just 404.
What am I doing wrong?
I searched for answers on GitHub and StackOverflow, but none of the proposed answers fixed my problems. By a mere fluke, I somehow restarted MAMP on my Mac, and then noticed later I could see JSON.
Why did it now start working? I honestly don’t know. I didn’t see “Restart your server” as an answer in any of the forums or threads. But that seemed to have taken care of the problem.
Anyway, if you’re trying to run the WordPress REST API plugin using MAMP and you get 404 errors, try restarting MAMP. I don’t know if this is an issue with live servers, but I’m just throwing out that solution.