wp-graphql / wp-graphql-jwt-authentication

Authentication for WPGraphQL using JWT (JSON Web Tokens)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not showing draft posts

GideonWislang opened this issue · comments

I have successfully authenticated using a JWT auth token in the header like so:

"Authorization":"Bearer *************************"

Although when I query a draft post it seems to return null.

query DraftPost{post(id: 965, idType: DATABASE_ID) {
    databaseId
    slug
    status
  }

returns

{
    "data": {
        "post": null
    },
}

executing the same query in the GraphiQL IDE returns the expected result.

Really appreciate any help, cheers!