Korean Text from OpenAI API Saved with Broken Encoding in Firestore (No Custom Code)

Database & APIs

While the API call seems successful, the Korean text received from the API is being saved into my Firestore String field with broken encoding (Mojibake). Instead of the correct Korean characters ("안녕하세요..."), it looks like 안ë.... I've verified this isn't just a display issue; the data viewed directly in the FlutterFlow Content Manager shows this garbled text stored in the Firestore field itself. (See attached image showing the broken text in the transcribed_text field).

My Setup:

  • API Call Action: Using the standard FlutterFlow API Call action (POST request to OpenAI, default response_format=json).

  • Data Extraction: Using the standard "Get JSON Body Field" option with JSON Path $.text to get the text from the API response.

  • Firestore Action: Using the standard FlutterFlow Create Document action to save the data to a Firestore collection (transcriptions, field: transcribed_text, type: String).

  • No Custom Code: Importantly, I am not using any Custom Actions or Custom Functions between receiving the API response and saving it to Firestore.

What have you tried so far?

Troubleshooting Done:

  1. Confirmed the data corruption exists in the Firestore database itself.

  2. Confirmed no custom code is used in this data path.

  3. [CHOOSE SCENARIO A or B based on your actual test result and insert here]

    • [Scenario A]: I added a temporary Alert Dialog action right after the API Call (before Create Document) to display the extracted text value ($.text result). The text displayed in the alert dialog was already garbled/broken (안ë...). This suggests the encoding issue might be happening when FlutterFlow processes the API response or extracts the JSON path value.

    • [Scenario B]: I added a temporary Alert Dialog action right after the API Call (before Create Document) to display the extracted text value ($.text result). The text displayed in the alert dialog was correct, readable Korean. This suggests the data is fine after extraction but gets corrupted specifically during the Create Document action when writing to Firestore.

Did you check FlutterFlow's Documentation for this topic?
No
1