Hi,
I am trying to fetch a few options for a custom field from a C# endpoint.
I know that the response expected is an array of key-value pairs which should have tile & value.
The problem is that it seems that monday can not parse the return string as 1) it is include in quotes as it comes from a C# end point and 2) it contains escaped characters in order to includes quotes.
I don’t get any error in my recipe but the list is always empty.
I have tried with various combinations for escapes characters but I haven’t found a working solution .
Just as an example this is one the return string the endpoint returns in one of my tries.
Hi,
It is a typo, I meant to write the returning string.
My code is
string options = @“[{”“title”“:”“to_upper_case”“,”“value”“:”“TO_UPPER_CASE”“},{”“title”“:”“to_lower_case”“,”“value”“:”“TO_LOWER_CASE”“}]”;
return Request.CreateResponse(HttpStatusCode.OK, options)
I have also tried with with the escaped quote \" instead of ".
Thanks for your suggestion. It perfectly worked.
We prefer to return strings instead of the objects believing that we have better control but we don’t.