https://indexforwp.com/how-to-secure-your-own-rest-api-routes-in-wordpress