All transaction types in ArFS leverage a specific tag for the Content-Type (also known as mime-type) of the data that is included in the transaction. ArFS clients must determine what the mime-type of the data is, in order for Arweave gateways and browsers to render this content appropriately.
All public drive, folder and file (metadata only) entity transactions all use a JSON standard, therefore they must have the following content type tag
Content-Type: "<application/json>""
However, a file’s data transaction must have its mime-type determined. This is stored in the file’s corresponding metadata transaction JSON’s dataContentType
and also in a content type tag in the data transaction itself.
Content-Type: "<file's mime-type>""
All private drive, folder and file (metadata and data) entity transactions must have the following content type tag, since they are encrypted.
Content-Type: "<application/octet-stream>""
ArDrive-Core includes methods to determine a file’s mime-type.
Comments
0 comments
Please sign in to leave a comment.