Fix django 1.6 compability by switching self.request.raw_post_data to self.request.body

(cherry picked from commit 224ad46693f9981dbd1b6d6b40de6bf70b33f339)
Fix DeprecationWarning: Using mimetype keyword argument is deprecated, use content_type instead

(cherry picked from commit 6c1ae184e341f75bda66320d0ccf221aa857eefd)