• I have successfully hooked up the jwt-auth plugin and tested it successfully using postman, getting a token for my valid login.

    As a test I have a page on my site set to hidden, so it can only be seen by an admin. When I call the page endpoint with the relevant slug I get an empty array. And if I switch off the private setting I get the full data back.

    I want to be able to get private page data when I have been verified as logged in

    /wp-json/wp/v2/pages?slug=everything

    I am passing the valid token in my header as specified, but I still cant get this data for this page back.

    Authorization: Bearer <my valid token>

    What do I need to do to get data for a private page returned?

  • The topic ‘Get private page with the REST Api’ is closed to new replies.