Chapter 2. Interacting with REST API in WordPress
In the previous chapter, we became familiar with the basics of REST API, how RESTful services work, and how to issue and manage basic REST commands in different languages and using different methods.
Now that the introduction is out of the way, it is time for us to actually get started with REST API in WordPress. In the last chapter, we have seen the benefits of using REST API in WordPress and all that it can bring to the table in terms of features.
Starting from this chapter, we will now be seeing how to use REST API when working with WordPress. This chapter will introduce you to basic GET and POST requests and then will teach you how to deal with posts in WordPress via REST API. Furthermore, you will also learn how to handle posts, post metadata or meta fields, and then copy posts from one remote site to another.