I am using "send_blob" to download pdf from google app engine blobstore. How can i enable CORS for this?I have tried adding
self.response.headers.add_header("Access-Control-Allow-Origin", "*")
to the function where i call send_blob but it is not working.
CORS on App Engine For Python-based applications in Google App Engine, the self.response.headers.add_header() method can be used, such as:
For Java-based applications, use resp.addHeader():
And for Go-based applications, use w.Header().Add():
Found the solution in
http://enable-cors.org/server_appengine.html
Added a basehandler for blobstore download handler.