WordPress.org

Forums

WP REST API (WP API)
[resolved] No post objects returned - "No route was found matching the URL ..." (4 posts)

  1. groberts100
    Member
    Posted 1 year ago #

    Hi, I've installed the Json Rest API on two blogs and I can see json successfully returned from;

    curl http://yyy.co.uk/blog/wp-json.php/

    But not from this

    curl http://yyy.co.uk/blog/wp-json.php/posts/

    No post resources show up. In fact the output from the above does not show any post resources

    The message says;

    [{"code":"json_no_route","message":"No route was found matching the URL and request method"}]

    Both blogs have posts. I have tried installing both as a plugin and directly from git, copying wp-json.php and the other file each time.

    Any suggestions ? I'd love to use this plugin.

    Cheers,

    Guy

    https://wordpress.org/plugins/json-rest-api/

  2. groberts100
    Member
    Posted 1 year ago #

    Partial solution.

    I should have said that the WordPress instance I mentioned above is hosted in a sub domain of my home domain, which also uses a different instance of WP.

    I tried the plugin on another WP blog that has its own domain and it worked as advertised. (It was a Bitnami stack).

    Maybe the Rewrite rules needed changing, I don't know yet.

  3. oedipamaas
    Member
    Posted 1 year ago #

    I'm having the same issue. It should be noted that my site is under development and instead of being on a domain name, it's currently on an ip.

    So it looks like:

    http://55.677.xx.xx.x/nameofsite/wp-json.php

    Would taking this to a single site instance fix it? I can't put this on a domain name just yet. Posts returns no json but the initial test url does return everything as expected.

  4. Ryan McCue
    Member
    Plugin Author

    Posted 1 year ago #

    Hi! This looks like a bug we ran into with multisite; it should be fixed in the next version. Thanks for reporting this. :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP REST API (WP API)
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.