Get Post Types

This endpoint gets all active post types, this means all post types that either have published posts OR post types added through the "default-post-types". It will return an array of the post types active.

The endpoint is "get/postTypes". Here's an example:

fetch(`www.mysite.com/api/get/postTypes/`)
.then((blob) => {
return blob.json()
})
.then((data) => {
// This will print out an array of the different post types
console.log(data.content)
})