I'am writing an app using Google App Engine and I want to integrate it with google drive api. Specifically I want to implement the functionality that when you right click on a txt file in the drive UI, it lets me open the file using my app as described here.
I have gone through the oauth2 using decorators in python on the server side and I am able to e.g. read information from drive files from my app.
My app is also listed in Drive under settings > Managing Apps
But it still does not show up under the Open With menu.
I have also enabled the Drive Api in the developer console, and set a Open URL to a URL under my domain and Default file extension to txt
What am I missing?
Apparently I had not enabled the correct scopes in my server-side OAuth2 authorization.
Previously I had only the scope:
https://www.googleapis.com/auth/drive
However, when I enabled the following scopes
https://www.googleapis.com/auth/drive.install
https://www.googleapis.com/auth/drive.file
profile
It worked
Related
Can we directly open a desktop application on a button click event from React application? I need to open a locally installed software project file to launch in desktop mode. I have an .aprx file to launch ArcGIS Pro software which I am trying to invoke from front end.
Tried to code using anchor link, but encountered error saying "Not allowed to load local resource" !
Thanks,
Paul
Tried to invoke the .aprx file using full local path but failed.
Nope, that isn't possible due to various security restrictions. However, if the application handles custom URL schemes (e.g. some-app://a-resource), you can redirect to those URLs which would open a browser prompting the user for confirmation if they'd like to open the application. That's the approach that web apps like Word online use to make the "open in desktop app" work.
I have deployed a Java Web application on Google Cloud platform and have purchased a domain and SSL Certificate from GoDaddy.com.
Its a simple application with a login page and a registration, where a specific(only one user) will have login credentials and post login will submit a form which will be saved in google DATASTORE in Google Cloud Platform(GCP).
I have two queries here :
1)
My application works perfectly,on my machine and even few machines around my home (as i have verified in few cyber centres around) but not at a client place located in different city(150 miles away). I'm not sure,as the client is not running any firewall or any browser plugin, as i have not visited the client place yet.
The call is as below.
Domain purchased from godaddy.com is : "ABC.in"
App engine project linked to this domain is : "web-abc"
If we hit "ABC.in" in browser it will in-turn call "web-abc.appspot.com".
in the background.Now though the login page loads,the client complains that the next subsequent pages does not load and page becomes blank.But for me in my system it works perfectly,as i can see the updated DATASTORE in GCP.
2)
Once i configure my DNS at GoDaddy.com, i'm unable to make any changes to the project hosted on GCP app engine.So i decided to create a new project and host it on the GCP. But GCP app engine page does not show any option to replace a project as it showed me during my first project setup.
I need to replace project "web-abc" linked to "ABC.in" with "web-pqr".
Please Please help...!
Thanks
To answer your second query you can just rest your CNAME record in the GODADDY DNS configuration and add the web-pqr reqq. That should work. Rest of the question< i really don't get it. Please share some error message or the screenshot when you try make change to your exiting project.
I believe there is an undocumented Google API available to create and manage Google Cloud Console (and App Engine) projects on behalf of third party users.
Does anyone know how to use it?
I think older versions of the Google Eclipse Plugin obtained an OAuth2 token in the (undocumented) scope https://www.googleapis.com/auth/appengine.admin, and this allowed it to generate a Cloud Console project on your behalf. The latest version doesn't seem to do this. App Engine's own appcfg.py also uses this scope, but doesn't seem to do much more than deploy the code - I'm looking to change core settings for the project, such as Name, Redirect URLs, and Web Origins.
Any information would be appreciated.
I maintain a WordPress plugin providing secure Google Apps Login for end users, and currently have to give detailed instructions to admins for creating a new Cloud Console project manually, and entering settings such as Redirect URL. Ideally, I would create a simple on-line service to do all of this for them.
Thank you!
It is possible to programmatically create a new Developer Console project on behalf of a Google Account (yes, you read that right). You do so in a very roundabout way:
Request the https://www.googleapis.com/auth/drive.scripts scope from the user (standard OAuth 2.0 flow).
Use the Drive API's drive.insert method to create a new file with a mimetype of application/vnd.google-apps.script.
Somehow try to get the project ID, maybe by uploading some Apps Script code? This is the part that I was never able to figure out.
A little known fact is that every Google Apps Script project has a hidden Developer Console project associated with it. This project is not shown in the list of projects, but it does exist. It is created automatically when the user starts a new Apps Script project, and the drive.insert method is enough to cause this to happen.
How do you get to the hidden project? Well, the only way I know of is to open the Apps Script project from the Drive website, open the "Resources > Advanced Google Services" dialog, and click the link to the Developer Console. You'll find the project ID in the URL.
Aside from not being shown in your list of projects and not being able to use App Engine, this is a normal Developer Console project. You can add additional OAuth client credentials, service accounts, Compute Engine instances, etc. And of course once you have a project ID, all of the various management APIs will work: creating new virtual machines, making use of a service account's impersonation ability, etc.
Suppose I have a video hosting site, like youtube. When user clicks on a link on the site, I want to open a WinRT application for a better viewing experience, how would I do that?
How do I pass parameters into the WinRT application, to let it know what video it should stream? I need to be able to go back and forth, so I assume I can introduce a hyperlink to go back to the site from the app.
The other possibility is to embed the application on the site itself. How would that work? Can you still inline an applet style application on the site itself (eg. flash/silverlight)?
It is possible to launch a Windows Store app, given that you know the URI scheme associated with that application. For example, the Games app has the xboxgames: associated with it. If you insert a link with that URI scheme, the shell will pick it up as an internal reference. Read more details here.
You might also be interested in reading more on how to connect your website to a Windows Store app here.
Edit: It is possible to have an associated url: see accepted answer from Den Delimarsky.
Alternatively, a Windows Store app can declare file type associations. So you could make the user download a file (for example "video.customExtension"), which could contain informations, such as the video the app should play. In the same way as it works for Office Live Meeting when you download a meeting file to start a meeting.
If the user download that kind of file from your website, and that he doesn't have the corresponding app installed, he will be prompted to look for an app that can open that file in the store, and he will find your app.
And finally, no you can't embbed an Windows 8 Store app in a webpage.
Without using Google Checkout, I would like to provide a link that allows a user to download digital content directly to their Google Drive account. Does anyone have advice on how this might achieved?
We have our own shopping cart system and host my own content.
We simply wish to provide a link to our content that transfers the digital content to the location of the consumer's choosing.
--Charles
We currently don't provide such widgets for web developers. You can however use the REST API to accomplish such a thing.
Please refer to the Drive API Documentation for how to do it server-side. For a client-side application (full JavaScript), you can refer to the StackOverflow answer.
The Drive SDK currently requires applications to be installed in a user's account through the Chrome Web Store; we are actively working on making the story better for users and developers so stay tuned!