开发者 | Andrew MAGIK |
---|---|
更新时间 | 2016年3月1日 16:30 |
PHP版本: | 4.4 及以上 |
WordPress版本: | 4.4.1 |
版权: | GPLv2 or later |
版权网址: | 版权信息 |
wp-json/wp/v2/all-terms
request (where categories and tags - standart taxonomies, and technologies - custom created taxonomy):
{ categories: [ { term_id: 9, name: "Downloads", slug: "downloads", term_group: 0, term_taxonomy_id: 9, taxonomy: "category", description: "", parent: 0, count: 1, filter: "raw" }, term_id: 1, name: "Uncategorized", slug: "uncategorized", term_group: 0, term_taxonomy_id: 1, taxonomy: "category", description: "", parent: 0, count: 4, filter: "raw" }, { term_id: 3, name: "Wordpress", slug: "wordpress", term_group: 0, term_taxonomy_id: 3, taxonomy: "category", description: "", parent: 0, count: 2, filter: "raw" } ], tags: [ { term_id: 16, name: "First tag", slug: "first-tag", term_group: 0, term_taxonomy_id: 16, taxonomy: "post_tag", description: "", parent: 0, count: 1, filter: "raw" }, { term_id: 17, name: "Second tag", slug: "second-tag", term_group: 0, term_taxonomy_id: 17, taxonomy: "post_tag", description: "", parent: 0, count: 1, filter: "raw" } ], technologies: [ { term_id: 15, name: "jQuery", slug: "jquery", term_group: 0, term_taxonomy_id: 15, taxonomy: "technologies", description: "", parent: 0, count: 1, filter: "raw" }, { term_id: 14, name: "Wordpress", slug: "wordpress", term_group: 0, term_taxonomy_id: 14, taxonomy: "technologies", description: "", parent: 0, count: 1, filter: "raw" } ] }
Check my other useful rest-api plugins: https://wordpress.org/plugins/tags/andrew-magik-rest-api.
/wp-content/plugins/
directory, or install the plugin through the WordPress plugins screen directly.You get get all available terms using GET request:
http://yoursite.name/wp-json/wp/v2/all-terms
This plugin is very useful when you want to create filters, or lists of all available categories/tags (for example tag cloud).
Yes, I have. You can check them by tag: https://wordpress.org/plugins/tags/andrew-magik-rest-api.