# HTTP gatling script request showing 400 response while the same seems to be working out fine on REST client.

**URL:** <https://community.gatling.io/t/http-gatling-script-request-showing-400-response-while-the-same-seems-to-be-working-out-fine-on-rest-client/636>\
**Category:** Gatling (Open-Source)\
**Created:** [October 28, 2013, 6:52am UTC](https://community.gatling.io/t/http-gatling-script-request-showing-400-response-while-the-same-seems-to-be-working-out-fine-on-rest-client/636 "2013-10-28T06:52:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nitin\_Wadhawan](https://avatars.discourse-cdn.com/v4/letter/n/7993a0/32.png) [@Nitin\_Wadhawan](https://community.gatling.io/u/Nitin_Wadhawan)\
**Post date:** [October 28, 2013, 6:52am UTC](https://community.gatling.io/t/http-gatling-script-request-showing-400-response-while-the-same-seems-to-be-working-out-fine-on-rest-client/636/1 "2013-10-28T06:52:50Z")

</div>

Hi,

I was trying to add a product in cart through http request. Following is my script-

[gatlingLogs.txt](https://community.gatling.io/uploads/short-url/saQ2N7TQtt7tt4OxZ9XXk6Q84qJ.txt) (9.22 KB)

---

<div class="post-metadata">

**Author:** ![Excilys](https://avatars.discourse-cdn.com/v4/letter/e/8797f3/32.png) [@Excilys](https://community.gatling.io/u/Excilys)\
**Post date:** [October 28, 2013, 7:15am UTC](https://community.gatling.io/t/http-gatling-script-request-showing-400-response-while-the-same-seems-to-be-working-out-fine-on-rest-client/636/2 "2013-10-28T07:15:48Z")

</div>

Hi,

There’s something suspicious here: you post data like a form, yet you set an “application/json” payload.  
Are you sure you’re not supposed to post a json payload?

Stéphane
