Hello,
As we mentioned in the previous reply, this is not a permission issue.
Please read the last reply carefully and follow the steps mentioned above and then test the situation again on the website.
Don’t hesitate to get in touch if you have any other questions.
As per your last reply, I did save the permalinks setting and rebuild the analytics and still am getting this 404. I’ve flushed all cache in cloudlfare and the site. Is there anything else that could be causing this 404 error?
I’ve read your response, please read mine:
The route that you showed is returning a 404 error which is not a permission issue but rather the REST route is missing on the website.
Please make sure that you save your permalinks and rebuild the index for Analytics by going to WordPress Dashboard > Rank Math > Status & Tools > Database Tools.
This is to prevent the route to call an undefined post on your website, which is the root cause of the issue.
I know it’s a 404 and I did what you asked:
As per your last reply, I did save the permalinks setting and rebuild the analytics and still am getting this 404. I’ve flushed all cache in cloudlfare and the site. Is there anything else that could be causing this 404 error?
The error points to: /wp-json/rankmath/v1/an/post/undefined?_locale=user. While /wp-json/rankmath/v1/ appears to be rendering RankMatch is still pulling /wp-json/rankmath/v1/an/post/undefined?_locale=user. Not sure why.
It’s not working. I’m asking for your next idea since I’m out of ideas and I didn’t write this plugin…..
Hello,
This is the REST API route used to fetch Analytics data for specific posts/pages on your website.
Since it’s showing undefined
where it should show the post GUID that is set in the Analytics objects table it’s likely that the index for the Analytic it’s not updated.
Please head over to WordPress Dashboard > Rank Math > Status & Tools > Database Tools and rebuild the index for the Analytics module.
This should take anywhere between a couple of minutes and a couple of hours depending on the number of posts/pages you have on that website.
Also, note that this will only work consistently if you have an active cron job on the website that can run the scheduled actions generated by these steps.
Don’t hesitate to get in touch if you have any other questions.
I totally get what you are saying. I have manually rebuilt it as instructed and I’m still getting this error. Is there any possibility that anything else could be causing this?
Hello,
This is an issue with the object IDs not being able to get fetched and as such, it returns an undefined
error.
There’s likely some mismatch in the database but without seeing exactly the structure and how the IDs are getting parsed it’s almost impossible to pinpoint the exact issue.
Rest assured this won’t cause any issues with the normal functionality of the plugin, except for the Analytic module.
Don’t hesitate to get in touch if you have any other questions.
Hello,
Glad that we could clarify the situation to some extent.
Please feel free to reach out to us again in case you need any other assistance.
We are here to help.
Thank you.