Shiv
Shiv

Reputation: 31

How to Test performance of Graphql API

I want to test the performance of graphics API, but Jmeter shows me the error of 400(Bad request) every time.

what I am doing is this:-

1.Created an Http Header Manager and provided respective content type and tokens

2.Created an HTTP Request

In Body:- Provided Graphql query(formatted query which postman accept) 3.Added a Listener

Every time it is showing Bad request but the same process works fine with Postman.

Please help.

Upvotes: 3

Views: 1748

Answers (1)

Dmitri T
Dmitri T

Reputation: 168147

If your requests works fine in Postman you can just record it with JMeter

  1. Prepare JMeter for recording. The easiest way is using JMeter Templates feature.

    JMeter HTTP(S) Test Script Recorder from Template

  2. Prepare Postman for recording. Configure it to use JMeter as a Global Proxy

    JMeter Postman Proxy

  3. Execute your test in Postman

  4. JMeter will capture the request and store it under Thread Group -> Recording Controller

Upvotes: 2

Related Questions