# Problem of double quotes in POST body

**URL:** <https://forum.robotframework.org/t/problem-of-double-quotes-in-post-body/4852>\
**Category:** RequestsLibrary\
**Created:** [21 October 2022 08:58 UTC](https://forum.robotframework.org/t/problem-of-double-quotes-in-post-body/4852 "2022-10-21T08:58:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pascal](https://avatars.discourse-cdn.com/v4/letter/p/e9a140/32.png) [@Pascal](https://forum.robotframework.org/u/Pascal)\
**Post date:** [21 October 2022 08:58 UTC](https://forum.robotframework.org/t/problem-of-double-quotes-in-post-body/4852/1 "2022-10-21T08:58:58Z")

</div>

Hi gents,  
I’m very new to Robot Framework and Python as well (a couple of days now I’m using it), but I’m facing an issue when trying to post my request.

My concern is that I need to have double quotes around my body values in the request :

Here is what I get :  
headers={‘User-Agent’: ‘python-requests/2.28.1’, ‘Accept-Encoding’: ‘gzip, deflate’, ‘Accept’: ‘_/_’, ‘Connection’: ‘keep-alive’, ‘adoriaClientKey’: ‘ef7dc91b-d778-4800-b6d0-1f9438240989’, ‘Content-Type’: ‘application/json; charset=utf-8’, ‘Cache-Control’: ‘no-cache’, ‘Content-Length’: ‘38’}  
body=number=5&from=2022-10-21&to=2022-10-21

Here is what I need to have :  
headers={‘User-Agent’: ‘python-requests/2.28.1’, ‘Accept-Encoding’: ‘gzip, deflate’, ‘Accept’: ‘_/_’, ‘Connection’: ‘keep-alive’, ‘adoriaClientKey’: ‘ef7dc91b-d778-4800-b6d0-1f9438240989’, ‘Content-Type’: ‘application/json; charset=utf-8’, ‘Cache-Control’: ‘no-cache’, ‘Content-Length’: ‘38’}  
body= **number=“5”&from=“2022-10-21”&to=“2022-10-21”**

Here is my piece of script :

```
Post data From External Pricelist TariffNumber
    [Arguments] ${iso}
    ... ${keyValue}
    ... ${internalSiteCode}
    ... ${priceListCode}
    ... ${tariffNumber}
    ... ${from}
    ... ${to}

    Create Session mysession ${UrlExtPricelist} verify=true
    &{body}= Create Dictionary
    ... number=${tariffNumber}
    ... from=${from}
    ... to=${to}

    &{header}= Create Dictionary
    ... key=${keyValue}
    ... Content-Type=application/json; charset=utf-8
    ... Cache-Control=no-cache

    ${response}= POST On Session mysession
    ... /${iso}/site/${internalSiteCode}/priceList/${priceListCode}/tariffNumber
    ... headers=${header}
    ... data=${body}
    RETURN ${response}

```

Thanks in advance for help 🙏

---

<div class="post-metadata">

**Author:** ![Pascal](https://avatars.discourse-cdn.com/v4/letter/p/e9a140/32.png) [@Pascal](https://forum.robotframework.org/u/Pascal)\
**Post date:** [24 October 2022 14:04 UTC](https://forum.robotframework.org/t/problem-of-double-quotes-in-post-body/4852/2 "2022-10-24T14:04:12Z")

</div>

Continuing the discussion from [Problem of double quotes in POST body](https://forum.robotframework.org/t/problem-of-double-quotes-in-post-body/4852):

I have the answer to my problem. I should have used

> json=${body}

rather than

> data=${body}

.
