Update Data in API using POST

Hi team,

I was trying to pass Json data to be posted using Https request activity. However, when I see the output data from the variable that carries the input Json it comes like you see here.

When I do not want @ and double quotation marks (“”)

I believe the data that goes into the Body aka Jsonbody has to look like

{
“globalInStoreDatesBOs”: [
{
“styleNumber”: 0,
“colorwayNumber”: 0,
“seasonTagCode”: “202511”,
“exceptionalInStoreStartDate”: “2020-12-31”,
“exceptionalInStoreEndDate”: “2020-12-31”,
“lastUpdatedByApplicationUser”: “string”
}
]
}
OR

FYI - when I try to process in Postman it works perfectly fine.

======

I’ve done configuration you see in the below screenshot, but I keep receiving 401 error.

I suspect that has to with the Json farmat being loaded to the body

Any insight please?

Thank you
sisay

401 means you are not authenticated.

The value for Authorization should look like "Bearer " + access_token and not "Bearer" + access_token.

Make sure that access_token is having a value and its value didn’t expire already.

1 Like

Can you pass the access token to the headers in http request, let us know what you got

Actually, you’re right @marian.platonov that the issue was with the whitespace between "Bearer " + AccessToken. I can confirm that I was able to post.

Thank you, a lot.
Sisay

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.