I have a strange problem when I try to make this plugin work on one site I recently got from a client.
When I try to access http://lpdf.dev/wp-json.php/posts, everything works smoothly, I can see my posts of different types.
But when I query http://lpdf.dev/wp-json.php/posts?type=faute (faute is a custom type) or even http://lpdf.dev/wp-json.php/posts?type=post I get a 404 status code AND some data in my JSON :-/
WordPress is v3.6.1. Any idea how to fix or at least debug this?
I get a 200 but the data is not filtered by post_type. Out of curiosity: why would it work? Seems inconsistent with the doc.
Just to be clear: when querying http://lpdf.dev/wp-json.php/posts?type=faute I get the correct data but the status code is 404.
For those passing by, I ended up circumventing the problem by creating my own endpoint based on my custom post type, just follow the docs: https://github.com/WP-API/WP-API/blob/master/docs/guides/extending.md
@abulte Is there anything that still needs attention in this issue to be resolved?
@rachelbaker thanks for checking in. Like I said I got around the problem by using a custom endpoint. So the original bug may still be present, we need to test against the latest release which I haven't had a chance to do. But if nobody else has complained about that...
I suspect this is related to the same issue that made #46 necessary. Can you try using the latest version from here and see if that fixes it? :)
@abulte To clarify....you should be able to GET all posts of a certain post type by passing the query string. However, you cannot POST data using a query string url. I am not sure if that is the issue here, but I know our documentation surrounding this could use some clarification.
Closing, as we don't have any further feedback. Let me know if we can do anything further here.