nft.storage
nft.storage copied to clipboard
Upload a single file, Add the Filename parameter
According to the document:
https://nft.storage/docs/how-to/mint-custom-metadata/
To upload a single file, send a POST request to /upload
with the binary file data as the request body.
appropriate for the content, for example, image/jpeg.
I wrote an upload program in PHP, as requested. It uploads successfully, but the result is not the same as in the demo: The files
array is blank, instead of the demo which has the file name and file type.
I have looked through the docs and found that only multipart can upload files with a filename.
I uploaded the file using multipart and it worked, but it was treated as a folder, which only had one file with a corresponding filename. (Maybe I've got one of the steps wrong?)
I would like to be able to transfer the file name of this file along with the contents of the file directly.