[GH-ISSUE #1273] Improve file / formData upload #425

Closed
opened 2026-03-16 15:16:05 +03:00 by kerem · 4 comments
Owner

Originally created by @onion-yz on GitHub (Oct 15, 2020).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/1273

Originally assigned to: @liyasthomas on GitHub.

When the master is selected, files cannot be uploaded, and the number of files always shows no files. Checking the network payload, it is true that no files have been sent.
When selecting the release version v1.9.9, select application/x-www-form-urlencoded or application/json, the request payload is [object FormData], and the backend receives the string "[object FormData]". After parsing with tools, the format is found to be:

**------WebKitFormBoundarytpKqpaSAK4waEBzF
Content-Disposition: form-data; name="0"; filename="aaaaa.txt"
Content-Type: text/plain

------WebKitFormBoundarytpKqpaSAK4waEBzF
Content-Disposition: form-data; name="1"; filename="bbbb.txt"
Content-Type: text/plain

------WebKitFormBoundarytpKqpaSAK4waEBzF
Content-Disposition: form-data; name="data"

{"ccc":"ccc"}
------WebKitFormBoundarytpKqpaSAK4waEBzF--**

This format does not feel right, the correct one should be:

-----------------------------7e4cf3bac0c86
Content-Disposition: form-data; name="ccc"

ccc
-----------------------------7e4cf3bac0c86
Content-Disposition: form-data; name="ddd"

ddd
-----------------------------7e4cf3bac0c86
Content-Disposition: form-data; name="0"; filename="aaaaa.txt"
Content-Type: text/plain

aaaaaa

-----------------------------7e4cf3bac0c86
Content-Disposition: form-data; name="1"; filename="bbbb.txt"
Content-Type: text/plain

aaaaaa

-----------------------------7e4cf3bac0c86--

Otherwise,I hope that the file name can be modified on the front end, otherwise the file names received by the back end are all 0,1... These default names are not convenient for back-end debugging

Originally created by @onion-yz on GitHub (Oct 15, 2020). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/1273 Originally assigned to: @liyasthomas on GitHub. When the master is selected, files cannot be uploaded, and the number of files always shows no files. Checking the network payload, it is true that no files have been sent. When selecting the release version v1.9.9, select application/x-www-form-urlencoded or application/json, the request payload is [object FormData], and the backend receives the string "[object FormData]". After parsing with tools, the format is found to be: **------WebKitFormBoundarytpKqpaSAK4waEBzF Content-Disposition: form-data; name="0"; filename="aaaaa.txt" Content-Type: text/plain ------WebKitFormBoundarytpKqpaSAK4waEBzF Content-Disposition: form-data; name="1"; filename="bbbb.txt" Content-Type: text/plain ------WebKitFormBoundarytpKqpaSAK4waEBzF Content-Disposition: form-data; **name="data"** **{"ccc":"ccc"}** ------WebKitFormBoundarytpKqpaSAK4waEBzF--** This format does not feel right, the correct one should be: -----------------------------7e4cf3bac0c86 **Content-Disposition: form-data; name="ccc"** **ccc** -----------------------------7e4cf3bac0c86 **Content-Disposition: form-data; name="ddd"** **ddd** -----------------------------7e4cf3bac0c86 Content-Disposition: form-data; name="0"; filename="aaaaa.txt" Content-Type: text/plain aaaaaa -----------------------------7e4cf3bac0c86 Content-Disposition: form-data; name="1"; filename="bbbb.txt" Content-Type: text/plain aaaaaa -----------------------------7e4cf3bac0c86-- Otherwise,I hope that the file name can be modified on the front end, otherwise the file names received by the back end are all 0,1... These default names are not convenient for back-end debugging
kerem 2026-03-16 15:16:05 +03:00
  • closed this issue
  • added the
    feature
    label
Author
Owner

@liyasthomas commented on GitHub (Oct 21, 2020):

I've pushed a fix for this issue. Ability to rename files will be added ASAP.

<!-- gh-comment-id:713421097 --> @liyasthomas commented on GitHub (Oct 21, 2020): I've pushed a fix for this issue. Ability to rename files will be added ASAP.
Author
Owner

@onion-yz commented on GitHub (Oct 22, 2020):

I've pushed a fix for this issue. Ability to rename files will be added ASAP.

thx

<!-- gh-comment-id:714077171 --> @onion-yz commented on GitHub (Oct 22, 2020): > I've pushed a fix for this issue. Ability to rename files will be added ASAP. thx
Author
Owner

@nelsontky commented on GitHub (Feb 15, 2021):

Any updates regarding this issue. If no I don't mind having a go at this feature!

<!-- gh-comment-id:778879093 --> @nelsontky commented on GitHub (Feb 15, 2021): Any updates regarding this issue. If no I don't mind having a go at this feature!
Author
Owner

@liyasthomas commented on GitHub (Feb 15, 2021):

@nelsontky we would love to work with you on this. Feel free to ping me on Discord or Telegram @liyasthomas.

<!-- gh-comment-id:778885923 --> @liyasthomas commented on GitHub (Feb 15, 2021): @nelsontky we would love to work with you on this. Feel free to ping me on [Discord](https://t.me/hoppscotch) or [Telegram](https://discord.gg/GAMWxmR) `@liyasthomas`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#425
No description provided.