• Hello!

    I’ve tried looking around the forum but I can’t find anyone with the exact same problem as me.

    I get this in the admin dashboard :
    Here is an error associated with Connecting WP REST API
    Please Flushing rewrite rules by updating permalink in Settings->Permalinks and make sure the WP REST API is enabled.

    I tried :
    Flushing Permalink Settings
    Checking REST API status (I’ll come back to this later on)
    Check for plugin conflicts
    Check your .htaccess file

    None of them are causing the issue. The only thing that I could find that could help me (or anyone) to get this problem out of the way is when I try to go to “https://domain.com/wp-json/wp-statistics/v2/check”, this comes back :
    {“code”:”rest_no_route”,”message”:”No route was found matching the URL and request method.”,”data”:{“status”:404}}
    Moreover, when I go to “https://domain.com/wp-json/”, it seems to respond well.

    Any idea how to solve that issue ? thanks ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter karlyy1999

    (@karlyy1999)

    Coming back on this issue, as I did some troubleshooting on it, without success.

    The requests do get through the API. The request can be logged and checked. Seems like the issue is really coming from WP statistics… Or maybe I’m doing something wrong ?

    Especially as “wp-statistics/v2” is showing up along with a lot more “hits” for “wp-statistics” on the https://domain.com/wp-json/ answer!

    Moreover, when checking the logs from my server, I can see that some requests go through ! I’m really having a hard time understanding where this could come from…

    Domain.com – [06/Aug/2023:17:13:20 +0200] “GET /wp-json/wp-statistics/v2/metabox?ago=today&name=hitsmap&_=1691334793900 HTTP/1.1” 200 157 “https://domain.com/wp-admin/admin.php?page=wps_overview_page” “Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/115.0”


    Please let me know if you need more context or information!

    • This reply was modified 1 year, 3 months ago by karlyy1999.
    • This reply was modified 1 year, 3 months ago by karlyy1999.
    Reza

    (@reventon94)

    Greetings, @karlyy1999,

    I trust you’re in good health.

    I appreciate the comprehensive information you’ve shared regarding the issue at hand. Based on the details you’ve previously provided, I’m inclined to believe that altering the permalink structure might offer a solution. Consider selecting “Post Name” as the default structure. I recommend trying this approach and verifying if it rectifies the problem. In the event that this doesn’t yield the desired results, please don’t hesitate to reach out to me, and I’ll work with you to explore an alternative solution.

    Warm regards,

    Reza

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Here is an error associated with Connecting WP REST API’ is closed to new replies.