Determine file extension and mimetype

Use this in the file path for s3 and the Put mimetype