I found the problem. It was two-fold.
The \n needs to be in double quotes: “\n”I needed to add options to the json_encode as it was adding another
$data_json = json_encode($data,JSON_UNESCAPED_LINE_TERMINATORS | JSON_UNESCAPED_SLASHES);
Thanks Scott- appreciate for the effort. I am using Curl also.
My php Code setting up the string (as address):
$shippingaddress = $order->shipping_address_1 . ‘,\n’ . $order->shipping_address_2 . ‘\n’ . $order->shipping_city . ‘,\n’ . $order->shippin...
Whoops, sorry, typo. I used \n and still no luck. Even tried /n just in case, but it still just writes the sentence in one line with the \n in the text.