Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support gdocs as backend #9

Closed
mihi-tr opened this issue Sep 27, 2012 · 9 comments
Closed

Support gdocs as backend #9

mihi-tr opened this issue Sep 27, 2012 · 9 comments
Milestone

Comments

@mihi-tr
Copy link

mihi-tr commented Sep 27, 2012

This would be awesome with gdocs as a backend!

  • Read support is almost trivial (get this straight from recline)
  • Write support - now this is interesting and I (@rgrp) have thought about this a lot - see below for summary

Write Support to GDocs in JS

Google now use OAuth. This is normally a PITA to support (witness the hassle to get login to github via oauth) but Google specifically support client side stuff:

The Google OAuth 2.0 Authorization Server supports JavaScript applications (JavaScript running in a browser). Like the other scenarios, this one begins by redirecting a browser (popup, or full-page if needed) to a Google URL with a set of query string parameters that indicate the type of Google API access the application requires. Google handles the user authentication, session selection, and user consent. The result is an access token. The client should then validate the token. After validation, the client includes the access token in a Google API request. 1

To find out we need the Google Docs on OAuth for Client Side Apps

Links

@rufuspollock
Copy link
Contributor

@mihi-tr do you mean for read or for write?

@mihi-tr
Copy link
Author

mihi-tr commented Sep 27, 2012

both! so I can clean up my google spreadsheets with javascript

read is easy as it's already supported by recline, not sure about the write part though...

@mihi-tr
Copy link
Author

mihi-tr commented Sep 27, 2012

This would open transformer to a larger audience, which is good: I think the people using github already might not be the audience for it.

@rufuspollock
Copy link
Contributor

@mihi-tr understand re those already using github but note all you need is a github account (you don't need to be familiar with it!). Will add more about gdocs support above (been thinking about that for a long time)

@rufuspollock
Copy link
Contributor

Read support done in #14.

@rufuspollock
Copy link
Contributor

@mihi-tr so i've looked at this quite a bit more - see https://github.com/rgrp/gdocsjs. The basic issue is that GDocs API does not support CORS so in a pure browser environment there is no direct way to write to a GDocs spreadsheet. Options are a proxy or moving to an extension ...

@mihi-tr
Copy link
Author

mihi-tr commented Dec 3, 2012

Interesting, can it be done via JSONP? I'll have a look - does it just not support CORS for writing? Reading works well doesn't it?

@rufuspollock
Copy link
Contributor

@mihi-tr Yes we already have read support done (using JSONP) -- that was done 1+ years ago ;-)

Problem is write support which requires POST or similar for which JSONP is no help :-( -- as you will see the in linked repo and its README CORS is not supported. There's no real way round it directly - see the linked README for discussion of indirect ways round it ...

@rufuspollock
Copy link
Contributor

FIXED. (WONTFIX). Read has been done and write is problematic so WONTFIX - see https://github.com/rgrp/gdocsjs and https://github.com/rgrp/ideas/issues/27 (proxy API for gdocs) for further thoughts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants