Live data from Hacker News

The Dropbox API

blog.dropbox.com

21–30 of 48 posts

Re: The Dropbox API

#21

Seems like its all server code. It'd be nice to do x-domain posts straight from the browser to Dropbox.

This would be incredible. Web apps that are 100% HTML5/Javascript/LocalStorage could then use Dropbox to store/retrieve data in the cloud.

How would that differ from S3? Is the concept that people would also have a better local UI on their data directory?

Re: The Dropbox API

#22
Kudos to the Dropbox team for developing their product into a platform. Giving developers an opportunity to develop things on top of their product keeps not only the community excited about things to do with Dropbox, it also gives them fresh ideas from how people consider to use it.

Re: The Dropbox API

#23

Seems like its all server code. It'd be nice to do x-domain posts straight from the browser to Dropbox.

If it is not possible, I think it is more a web programming limitation rather than Dropbox failing to implement something.

Everything their SDKs do can also be done using their REST API (https://www.dropbox.com/developers/reference/api) and they support JSONP to allow cross-domain GET queries. However, my understanding is that JSONP is not supported for other REST methods, most importantly POSTs. A person claims to have found a workaround for doing POSTs via JSONP here: http://stackoverflow.com/questions/5345493/using-put-post-de....

Has anyone tried that or know of a way to do cross-domain POSTs?

Re: The Dropbox API

#24
post #21

Earlier quoted context omitted.

This would be incredible. Web apps that are 100% HTML5/Javascript/LocalStorage could then use Dropbox to store/retrieve data in the cloud.

How would that differ from S3? Is the concept that people would also have a better local UI on their data directory?

It is much cheaper to scale an application putting data onto peoples' Dropbox folders instead of S3. For S3, you would have to pay for the total amount of storage used by your customers; with Dropbox you wouldn't have to pay anything for storage, and for the most part your users wouldn't have to either since each gets a certain amount for free.

Re: The Dropbox API

#25
This is interesting although I really really wished they had used oauth v2 since it is so much better and is designed to give a first class experience on mobile devices.

In fact I can't think of any good reason to use the older version but I would like to hear if there are anybody who has different experiences since I haven't worked much with it.

Re: The Dropbox API

#26

My personal favorite apps that use the API: plaintext: http://itunes.apple.com/us/app/plaintext-dropbox-text-editin... http://ifttt.com https://www.hellofax.com http://greplin.com

Wow, so could that plain text file be a JavaScript file in my public Dropbox folder?

yep. You'll want to change it so Plaintext doesn't operate out of a folder, but can see your whole Dropbox. See FAQ #11 here: http://www.hogbaysoftware.com/products/plaintext/faq

Re: The Dropbox API

#27

Seems like its all server code. It'd be nice to do x-domain posts straight from the browser to Dropbox.

If it is not possible, I think it is more a web programming limitation rather than Dropbox failing to implement something. Everything their SDKs do can also be done using their REST API ( https://www.dropbox.com/developers/reference/api ) and they support JSONP to allow cross-domain GET queries. However, my understanding is that JSONP is not supported for other REST methods, most importantly POSTs. A person claims to…

You can do cross-domain POSTs. You just cannot get a response from the server. Often times though you can get the length of the response. This can be used to do a POST to change settings on an unsecured Wi-Fi routers, for example and checking whether the call succeeded or not by the length of the response.

The method described in the SO answer is similar, from what I can tell, to what DISQUS uses. I believe they call it JSONPI: http://alexsexton.com/thirdparty/#forms-are-cool-too

Re: The Dropbox API

#28
post #25

This is interesting although I really really wished they had used oauth v2 since it is so much better and is designed to give a first class experience on mobile devices. In fact I can't think of any good reason to use the older version but I would like to hear if there are anybody who has different experiences since I haven't worked much with it.

OAuth 2 is way simpler but requires HTTPS, which may have overhead at scale.

Re: The Dropbox API

#29
post #25

This is interesting although I really really wished they had used oauth v2 since it is so much better and is designed to give a first class experience on mobile devices. In fact I can't think of any good reason to use the older version but I would like to hear if there are anybody who has different experiences since I haven't worked much with it.

If you use the SDKs on mobile devices, users can auth via their Dropbox native app if they have it installed. https://www.dropbox.com/developers/reference/sdk

Re: The Dropbox API

#30
post #21

Earlier quoted context omitted.

How would that differ from S3? Is the concept that people would also have a better local UI on their data directory?

It is much cheaper to scale an application putting data onto peoples' Dropbox folders instead of S3. For S3, you would have to pay for the total amount of storage used by your customers; with Dropbox you wouldn't have to pay anything for storage, and for the most part your users wouldn't have to either since each gets a certain amount for free.

Exactly. With Dropbox, you're making storage the customer's problem and not yours. You could argue this is bad for the customer, but you end up with a web app with next-to-no server overhead: just serve your static files and everything else is taken care of. No different than the many mobile apps that sync to iCloud/Dropbox already.
Post reply on HN