I am glad that you figured something out and want to share it with the community. We depend on people like you
We have a whole documentation with stuff like this. The command you found is already documented in our user manual. I must admit it’s hidden. You only find it if you are really sure it’s there and you know the path. It took me a while to find it.
Uploading Files to a Public Link Using cURL
To upload a file "file.txt" to a public link with token "70mX9s7KOZwfmdi" (https://example.com/s/70mX9s7KOZwfmdi; no password):
Maybe you could open an Issue at the docs repo so that we could somehow improve the visibility of this entry so people like you would simply find the command instead of spending time re-event the wheel