Ask a Question

GraphQL Project

rammar
New Contributor

GraphQL Project

Hello,

I am currently using ReadyAPI to test a graphQL API  included in a Project.

The problem is i can not automatically import the GraphQL Schema directly through URL ( Using the same url, i can execute requests via postman)

Another problem I tried to create Rest Request with Post and mentionning my endpoint for GraphQL, i could not figure out how to include my querry parameter in the reques, I have always : 

<message>The GraphQL request is empty.</message>
<extensions>
<code>INVALID_REQUEST</code>

 

Any help ?

 

Thank you

 

2 REPLIES 2
CoreyVernon
Staff

Re: GraphQL Project

Hi @rammar 

In order to include your query parameter for your POST request, you would add this under the request body in a tab called "Query variables". Here you can include the parameters of your request. I have provided a link to the ReadyAPI documentation on GraphQL request. I hope this helps with your usecase. 

 

https://support.smartbear.com/readyapi/docs/requests/graphql.html

 

rammar
New Contributor

Re: GraphQL Project

 
 
 
thank you for response, I already did that, My problem is that whatever I put in my request, I always get the ampty response.
 As i dont have a file *.graphql to import the GraphQL schema, I use a link (same link  that I use to send requests via postman)
. Moreover in the document that you provided, there is a field where to right my request. As I am enable to import the GrapQL API ( through Url), the only way I tried to send requests is by using RestAPI and writing manually the endpoint, making a post http request and insert parameters in Rest table.
This solution did not work for me, So I am wondering why I can execute requests in postman, and by importing the postman collection into Ready API; I don't have similar response (empty responses)
 
Thank you
cancel
Showing results for 
Search instead for 
Did you mean: