Getting X-Appengine-Inbound-Appid from headers in Python 3

179 views
Skip to first unread message

Sukhdeep Singh Gill

unread,
Jan 27, 2022, 9:49:49 AM1/27/22
to Google App Engine
Hello,

We are migrating from Python 2 to Python 3 and one of our authentication checks is to assert App Identity using the App Identity Python API. In my Python 3 application, I'm unable to get the X-Appengine-Inbound-Appid data from headers. I printed the request headers in Flask by using the request.headers but the above needed information was not present. Also, I'm calling my Python 3 application via urlfetch from a current Python 2 application. 

Any help would be great. 

Thank you!

George (Cloud Platform Support)

unread,
Jan 27, 2022, 11:39:33 AM1/27/22
to Google App Engine
Hello, 

You can find relevant instructions and an example in the "Granting your app access to Cloud services" sub-chapter of the "Setting Up Access Control" documentation page. When using Python 3, one needs to authenticate to each service by means of a service API Client() call. 

Sukhdeep Singh Gill

unread,
Jan 27, 2022, 11:02:09 PM1/27/22
to Google App Engine
Got it, thank you!
Reply all
Reply to author
Forward
0 new messages