App Engine + Webmaster Tools - python

I've been trying for a while now to get my Python App Engine app onto the Chrome Web Store, however, when I try to upload, Google tells me I need to confirm that its my domain (I'm on an appspot.com domain). I have tried the first 3 methods (meta tag, file, and analytics) in several different ways but they haven't worked. Is there any way around this? Or, rather, how can I verify an App Engine domain?

When I go to http://book-tracker.appspot.com/ it asks me for my Google Account.
Try disabling login required before trying activation.

Related

Connect domain to pythonanywhere

I did a webpage in pythonanywhere and I'm using the subdomain they gave me (username.pythonanywhere.com) but I have a domain that I want to use for this project (I bought the domain in domain.com). I already expanded my plan in pythonanywhere to put my own domain but I've been trying without sucess. This is the documentation that I've been reading.
pythonanywhere documentation
Image of the Domain.com panel
Is the first time that I make this and a pretty confused.

How to authenticate app to act as if it was my logged in google account

I have written scripts connecting to the google API to connect to bigquery and google sheets and slides.
However, currently I am trying to write a script that would be able to access a non-google site for which I am required to be signed in with my gmail account to access.
So essentially when I access this site in a browser, I am asked to login using gmail and allow the site to verify my details, and in return I can view the page. If I don't login with google I cannot view the page.
I am not sure how/if the google authentication process for my app could be set up in a way for it to login as if it was myself. But can anybody give me some advice on how I can get my app to pass the google sign-in process, so that my app can access the contents of the website?
Please let me know if I can clarify.
Thanks!
If choosing not to use Google API is okay, and if it is only one specific website that you would like to access, then I would suggest looking into doing this using Selenium. You can simulate the way you use the browser so the script can do it for you. Here is a tutorial on a simple login use-case that might be relevant to your problem.
Hope it helps.

use django-allauth to request and store oauth credentials only

i have a django project using django-allauth.
I want to add the ability for users to provide their consent for my web app to interface with the google api.
I think django-allauth has this all neatly packaged away but the docs and the implementation are (appropriately) targeted towards login authentication.
What i want to do is:
display a page where users can click a button that says "Connect my google account"
have users provide their consent on the google page
process the oauthcall back using allauth internals
Is there an example of this somewhere? I tried searching but i think i don't know what keywords to search for.
Any assistance apprecieated

Facebook calling Google App Engine code using GET instead of POST

I've been developing a Facebook app using Google App Engine in Python and the pyfacebook bindings. For weeks everything worked fine but suddenly it stopped.
At first I thought it was a code change so I rolled back the entire dev directory to a version I knew worked, but still it failed. It's possible a change I made to the application's settings caused the issue but, if so, I can't figure out what.
I've figured out that the problem is that instead of calling the post(self) method of my Main class, Facebook is calling using a GET.
Does anyone know why Facebook would use a GET method instead of a POST? It's an IFrame app.
Thanks,
The typical flow for a user when using the application begins with the user landing at some Canvas URL, like http://apps.facebook.com/runwithfriends/. At this point, Facebook will load up it's chrome, and render a tag to your application. You'll notice there isn't a src specified. Using some JavaScript and the tag, Facebook triggers a POST request to your application. This is done for security reasons, as the sensitive user data won't be sent via the HTTP Referrer header as long it's sent as POST data.
Although I'm not completely sure this was the cause, it appears I changed from an FBML app to an IFrame app. FBML mode relies on POST calls but IFrame appears to use GET. I'm inferring this answer from what I read here as well as from the observations I'm seeing and this being the only answer that makes any sense.

Programmatic login and use of non-api-supported Google services

Google provides APIs for a number of their services and bindings for several languages. However, not everything is supported. So this question comes from my incomplete understanding of things like wget, curl, and the various web programming libraries.
How can I authenticate programmatically to Google?
Is it possible to leverage the existing APIs to gain access to the unsupported parts of Google?
Once I have authenticated, how do I use that to access my restricted pages? It seems like the API could be used do the login and get a token, but I don't understand what I'm supposed to do next to fetch a restricted webpage.
Specifically, I am playing around with Android and want to write a script to grab my app usage stats from the Android Market once or twice a day so I can make pretty charts. My most likely target is python, but code in any language illustrating non-API use of Google's services would be helpful. Thanks folks.
You can get the auth tokens by authenticating a particular service against https://www.google.com/accounts/ClientLogin
E.g.
curl -d "Email=youremail" -d "Passwd=yourpassword" -d "service=blogger" "https://www.google.com/accounts/ClientLogin"
Then you can just pass the auth tokens and cookies along when accessing the service. You can use firebug or temper data firefox plugin to find out the parameter names etc.
You can use something like mechanize, or even urllib to achieve this sort of thing. As a tutorial, you can check out my article here about programmatically submitting a form .
Once you authenticate, you can use the cookie to access restricted pages.
CLientLogin is now deprecated: https://developers.google.com/accounts/docs/AuthForInstalledApps
How can we authenticate programmatically to Google with OAuth2?
I can't find an expample of request with user and password parameter as in the CLientLogin :(
is there a solution?

Categories