Skip to content

Commit

Permalink
Readme update
Browse files Browse the repository at this point in the history
  • Loading branch information
Salil Kothadia committed Feb 7, 2017
1 parent b8626c6 commit 973234e
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,26 @@

Extension of wp/v2/posts api to allow query multiple post types


## About

Want to get your site's posts, pages, articles, events/?
Endpoint is '/wp-json/wp/v2/multiple-post-type'
`GET` request to `/wp-json/wp/v2/multiple-post-type`.
Get the page with slug "about-me"? `GET /wp-json/wp/v2/multiple-post-type?slug=about-me`.
search term "awesome"? `GET /wp-json/wp/v2/multiple-post-type?search=awesome`.
Want to get your site's posts, pages, articles, events?

Use the Endpoint: '/wp-json/wp/v2/multiple-post-type'

List: `GET` request to `/wp-json/wp/v2/multiple-post-type`.

Get the page with slug "about-me": `GET /wp-json/wp/v2/multiple-post-type?slug=about-me`.

Search term "awesome": `GET /wp-json/wp/v2/multiple-post-type?search=awesome`.


## Credits

Build using the code shared by Ruben Vreeken, (https://github.com/Rayraz)
on stackoverflow (http://stackoverflow.com/questions/38059805/query-multiple-post-types-using-wp-rest-api-v2-wordpress)


## License

[GPLv3+](http://www.gnu.org/licenses/gpl-3.0.html)
Expand Down

0 comments on commit 973234e

Please sign in to comment.