Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GraphQL not accepting the Bearer token sent via restassured #1925

Closed
veeramanib opened this issue May 28, 2019 · 1 comment
Closed

GraphQL not accepting the Bearer token sent via restassured #1925

veeramanib opened this issue May 28, 2019 · 1 comment

Comments

@veeramanib
Copy link

veeramanib commented May 28, 2019

Hi, I am trying to test the graphql queries via restassured. When i try to pass bearer token via header, its not accepting the token and gives this error:

{"timestamp":"2019-05-28T20:47:48.065+0000","status":403,"error":"Forbidden","message":"Invalid Access Token.User Not logged In")

Here's my restassured call:

response = given().relaxedHTTPSValidation().header(new Header("Authorization", "Bearer " + token)) .contentType(ContentType.JSON).request().body(request).when().post(baseUrl);

what im doing wrong here? Same thing works fine from Postman & Graphiql

@IvanGoncharov
Copy link
Member

Hi @veeramanib,

This questing is unrelated to graphql-js since it doesn't deal with HTTP.
Please, open a question on StackOverflow or repo issue to client or server library you are using.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants