sintaxi / dbox

NodeJS SDK for Dropbox API (THIS LIBRARY IS OBSOLETE!!)
514 stars 91 forks source link

Is it possible to use this with a hardcoded token #89

Open pketh opened 8 years ago

pketh commented 8 years ago

So I'm writing an app that only uses my specific dropbox account, so I don't need any of the oauth stuff. Can I initiate a 'client' that's just based on my token?

thanks

sintaxi commented 8 years ago

Yip! On Sep 11, 2015 16:36, "Pirijan Ketheswaran" notifications@github.com wrote:

So I'm writing an app that only uses my specific dropbox account, so I don't need any of the oauth stuff. Can I initiate a 'client' that's just based on my token?

thanks

— Reply to this email directly or view it on GitHub https://github.com/sintaxi/dbox/issues/89.

pketh commented 8 years ago

Thx!

hariawan commented 8 years ago

how do we do that?

like this?

var dbox = require('dbox');

var client = dbox.client(config.dropbox.accessToken);

client.put(blablablabla

or with appkey?

var dbox = require('dbox');

var Dropbox = dbox.app({
  app_key: config.dropbox.appKey,
  app_secret: config.dropbox.appSecret
});

var client = Dropbox.client(config.dropbox.accessToken);

client.put(blablablabla