Source | Prefix | Pattern | Example |
---|---|---|---|
Self Hosted | time.com |
/wp-json/wp/v2/posts |
List posts |
Public API | public-api.wordpress.com |
/wp/v2/sites/$site/posts/ |
List posts |
Public API WordPress.com Deprecated* | public-api.wordpress.com |
/rest/v1.1/sites/$site/posts/ |
List posts |
*Jetpack still relies on v1 for certain features. For example a POST
request is made for the related feature.
https://public-api.wordpress.com/rest/v1/sites/{$site}/posts/$post_id/related/
-
Self Hosted can be extended and manipulated to meet custom needs.
-
The endpoints for the public api have a few more options like
sites
andmenus
, but those require authentication.