List of all default Rest API endpoints on WordPress website

Advertisement

In WordPress, there are a lot of default rest API endpoints that may help you while developing.

How to access the rest API endpoints? How to access the rest API endpoints?

You can access the rest API endpoints through URLs. E.g. http://wpdigits.com/wp-json/wp/v2/posts

The above URL shows the list of all posts in the form of JSON.

In this example endpoint, a Domain name is http://wpdigits.com/ and the /wp-json/ shows all the default endpoints.

Below is the list of all default rest API endpoints from any WordPress fresh set up.

/wp/v2/posts,
/wp/v2/posts/(?P<id>[\d]+),
/wp/v2/posts/(?P<parent>[\d]+)/revisions,
/wp/v2/posts/(?P<parent>[\d]+)/revisions/(?P<id>[\d]+),
/wp/v2/posts/(?P<id>[\d]+)/autosaves,
/wp/v2/posts/(?P<parent>[\d]+)/autosaves/(?P<id>[\d]+),
/wp/v2/pages,
/wp/v2/pages/(?P<id>[\d]+),
/wp/v2/pages/(?P<parent>[\d]+)/revisions,
/wp/v2/pages/(?P<parent>[\d]+)/revisions/(?P<id>[\d]+),
/wp/v2/pages/(?P<id>[\d]+)/autosaves,
/wp/v2/pages/(?P<parent>[\d]+)/autosaves/(?P<id>[\d]+),
/wp/v2/media,
/wp/v2/media/(?P<id>[\d]+),
/wp/v2/blocks,
/wp/v2/blocks/(?P<id>[\d]+),
/wp/v2/blocks/(?P<id>[\d]+)/autosaves,
/wp/v2/blocks/(?P<parent>[\d]+)/autosaves/(?P<id>[\d]+),
/wp/v2/types,
/wp/v2/types/(?P<type>[\w-]+),
/wp/v2/statuses,
/wp/v2/statuses/(?P<status>[\w-]+),
/wp/v2/taxonomies,
/wp/v2/taxonomies/(?P<taxonomy>[\w-]+),
/wp/v2/categories,
/wp/v2/categories/(?P<id>[\d]+),
/wp/v2/tags,
/wp/v2/tags/(?P<id>[\d]+),
/wp/v2/users,
/wp/v2/users/(?P<id>[\d]+),
/wp/v2/users/me,
/wp/v2/comments,
/wp/v2/comments/(?P<id>[\d]+),
/wp/v2/search,
/wp/v2/block-renderer/(?P<name>core/block),
/wp/v2/block-renderer/(?P<name>core/latest-comments),
/wp/v2/block-renderer/(?P<name>core/archives),
/wp/v2/block-renderer/(?P<name>core/categories),
/wp/v2/block-renderer/(?P<name>core/latest-posts),
/wp/v2/block-renderer/(?P<name>core/shortcode),
/wp/v2/settings,
/wp/v2/theme
%d bloggers like this: