The server hosting the api is returning http for absolute urls even though the page was loaded using https, does this have something to do with django rest framework? becaus
Are you using Rest Framework reverse() function to build URLs? http://www.django-rest-framework.org/api-guide/reverse/
It uses incoming request to determine the protocol used.