Studio doesn’t seem to give any error for the above format but the api endpoint that I am calling is not accepting the key value pairs with single quotes.
It would be great if I could get an example on this
Thanks
This solution works absolutely fine when the value is not dynamic.
I am trying to get the value from a csv file as row(“row1”).ToString
That’s where I am facing the issue
You could try and create the json as a jobject then in the body field of the Http activity add the jobject as
jobject.tostring.
This works for me and then you can update the fields of the jobject dynamically. To create the jobject you can use the deserialize activity on a string variable. Once jobject is created you can update properties with an assign activity
To avoid the confusion of the many escape chars, you could create a separeted template of your json with some placeholder or string format and replace them on execution time.
Create a file, can be a txt or json file:
{“key”:“{0}”}
The {0} indicates that would the place that will be replaced when using String.Format
Use read txt file activity, then you’ll have a string var.