Yes, there is a REST API at /wp-json
with core content endpoints for posts pages etc
For example, my current latest blog post:
https://tomjn.com/2018/07/23/deployment-and-wordpress/
Is available via a GET
request as a JSON object at:
https://tomjn.com/wp-json/wp/v2/posts/862
And I can send a similar object via an authenticated POST
request to create a new post to https://tomjn.com/wp-json/wp/v2/posts/
, or a HTTP UPDATE
or DELETE
request.
Note that WP includes an auth method out of the box that requires a nonce and a cookie of a user capable of creating posts in order to do this. For external applications, you will need a plugin to implement OAuth1/2 or another authentication scheme of your choosing
Related Posts:
- How to remove a column from the Posts page
- How to retrieve text only from wp_content() not from wp_excerpt()?
- Skip post in loop and mixin later
- Show WordPress Custom Taxonomy Items Based On a Selected Item From Another Custom Taxonomy
- Add existing images from Media Library in to custom gallery
- How to put last edited entry on top of the blog-post list?
- Reverse chronology of post listing
- Order Posts by Alphabetical for Each Letter
- Get post embedded image caption
- Odd/even class on article tag
- Filter/Remove HTML Elements on all posts and pages
- how “manage_posts_custom_column” action hook relate to “manage_${post_type}_columns” filter hook?
- How to get posts by multiple post slugs? [duplicate]
- Changing next and previous post link text
- Define a name to the posts slug
- Check is_single() outside loop
- Only display a certain number of posts, dependent on how many posts there are available in a query
- how to replace embedded “full” sized images within a post with the “large” ones
- Get Posts via Taxonomy Term Name with Space
- Change default Posts page
- Batch process: remove first image from post content
- Create post for every user?
- Facebook Share Thumbnail
- Auto “expire” all of an authors posts on spcific date
- How to pass Post_ID variable from theme’s Single.php to custom Plugin using AJAX
- Yearly archive page for future year
- How blog page in WordPress works : blog page retrieve first post ID
- Delete WordPress posts from URL list sql query
- Posts with multiple authors with different roles
- Custom WordPress Theme: Publish Date and Display Date for posts right beside each other
- How to change permalink on post click on post listing page
- current post with current author
- Addition Text to Post Titles (Custom Post Types) in RSS
- Why aren’t my posts/pages showing up in my WordPress Theme?
- Assign category to new post via URL
- Blog post per page setting conflicting with custom WP_Query?
- Show certain posts in a LIST format that members have been granted access to
- WordPress Rest API Create Post
- WordPress custom Query for Posts in Category display posts multiple times
- performance of post_exists
- Categories list into registration form
- WordPress Local And Live Site
- Add a custom meta box in the post options that loads some html code in the header
- How do I locate the exact location where this error is occurring 404 page not found
- How would one change the default url structure of attachments?
- Use two different post_per_page limits with infinite scroll
- How do I manage my users post before publish?
- How to dynamically parse and transform post/page content before displaying it?
- WP move posts to different path
- getting “Object of class WP_Post could not be converted to string” – when it is a string
- How to get posts published on the latest date?
- how to set social icons to product / post template (Auros theme)? [closed]
- Change the color of the Password Protected Post titles
- Bolding several words at once
- Post Form Results to Table in Same page
- I don’t want the complete article to show on homepage
- wp_query if have posts show date but not in loop
- Get posts from current category?
- Send email to admin with post author
- posts going to 2 pages/categories only show up in 1
- How do I get the image that is submitted with a post, when I’m in the loop?
- How to output all taxonomy links from a custom post type in a menu?
- Return records between two meta datetimes saved as strings
- Cannot create new posts or upload images using media manager
- How can i showcase all my galleries?
- Rewrite image links from attachment id to attachment link
- How do I change the template specifically for single posts?
- wp-insert-post execute from server?
- Change the size of the featured image for post?
- Set featured image as hero image on each page
- Get origin or context of a how a post got created and/or updated
- Change URL of previous posts and next posts link in WordPress
- The letter “i” appears capitalised even when I don’t mean to capitalise them
- Custom Post Type Rewrite URL
- I want to show recent post according to category of the post in single.php?
- Limit amount of categories displayed in a post
- WP_Query sort by meta_value_num or date
- Category and Posts in front page
- I lost the link to my posts in my menu bar
- Allow registering user to select post category when signing up to blog
- How do I get a certain set of posts from the database?
- How do I use slideToggle inside a wordpress post?
- Display author bio box
- Bulk posts from DRAFT Section
- Stop images from being displayed on the front-end of the site
- Facebook share thumbnail not showing until refreshed
- I am not getting result from php function that is json encoded
- Add something after all sticky posts in The Loop
- Customize search results to include custom posts and display in a specific template page
- Custom permalink based on custom post type fields
- Query posts from a specific category and selected tag
- Get post id on click of thumbnail
- Can’t get pagination to work
- Order by ‘s’ using WP_Query()
- Post thumbnail height problem
- Password protection doesn’t prompt for password on pages
- How can I add Author’s phone number to wp profile and make it appear in wp-admin/edit.php columns
- How can I fixe the article title problem?
- Automatically select category based on user role
- What is the proper use of guid for images in wp_posts?