Commit Jennie's changes & some formatting cleanup
add mediaType generation