Does Universal Cloud REST API support Chinese characters via POST method #228
-
Hello Team, Is there any doc available to show Universal Cloud REST API support chinese characters via POST method? For GET method, it is able to capture Chinese characters in good conditions. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments
-
Hello @JiaChee, Can you provide some more context on what issue you're encountering? Everything in the workflows should be UTF-8 so there shouldn't be any issue with Chinese characters as a general rule. |
Beta Was this translation helpful? Give feedback.
-
We did find the source of the issue. In general Chinese or other UTF-8 characters aren't a problem. We have discovered however that if the HTTP response Header with charset Header without charset The latter isn't wrong as the RFC for the We'll be changing this to default to UTF-8 if no |
Beta Was this translation helpful? Give feedback.
-
Issue created: #246 |
Beta Was this translation helpful? Give feedback.
-
This fix for this has been released @JiaChee - please see the details in #246 |
Beta Was this translation helpful? Give feedback.
We did find the source of the issue. In general Chinese or other UTF-8 characters aren't a problem. We have discovered however that if the HTTP response
Content-type
header doesn't contain acharset
attribute, the defaultcharset
was usingConsts.ISO_8859_1
which is not UTF-8.Header with charset
Content-Type: application/json; charset=utf-8
Header without charset
Content-Type: application/json
The latter isn't wrong as the RFC for the
application/json
content-type doesn't require you to specify acharset
if it's the default (which is UTF-8) - https://datatracker.ietf.org/doc/html/rfc4627We'll be changing this to default to UTF-8 if no
charset
is specified in the next RPM release.